I was making a game that was supposed to shrink the infected parts every 9 seconds. I got everything done, and when I joined, the parts were not shrinking at all. I found some error messages in the console that were saying like Expected Vector3, got number
. How do I write this script in a vector3 format?
while true do wait(1) script.Parent.Size = script.Parent.Size -1 wait(8) end
Thanks!
Size is a group of three numbers so you have to use a Vector3
.
while true do wait(1) script.Parent.Size = script.Parent.Size - Vector3.new(1,1,1)-- probably want to make the one a smaller number wait(8) end
That's how you would apply a vector3. Vectors are also used for position and rotation. Good luck!