Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Z cannot be assigned How do I make this work?

Asked by 5 years ago
Im trying to subtract every single milisecond but it's not working for me it keeps returning a error in the output saying Z cannot be assigned





local BodyVelocity = script.Parent.BodyVelocity





while true do

wait()

BodyVelocity.Velocity.Z = BodyVelocity.Velocity.Z - 1 --Subtracts every milisecond



end
0
try BodyVelocity.Velocity = BodyVelocity.Velocity - Vector3.new(0, 0, 1) MegaManSam1 207 — 5y
0
Yeah, Roblox Studio doesn't allow you to change one axis specifically, so you have to do something like what MegaManSam1 said. Knineteen19 307 — 5y

Answer this question