while wait() do
local w = UserInputService:IsKeyDown(Enum.KeyCode.W)
if w then
print("W was held down")
model = game.Workspace.Model
model.PrimaryPart.CFrame = CFrame.new(model.PrimaryPart.Position + Vector3.new(0,0,-2))
else
print("W was not")
end
local model = game.Workspace.Model
model.PrimaryPart.CFrame = CFrame.new(model.PrimaryPart.Position)
end
The script works fine, but the model doesn't seem to collide with anything.
I turned CanCollide to true in everything in the model.
