|
| 24 Oct 2014 02:40 PM |
Everything works here, the chairspeed is inserted but, heres my issue
Mouse.KeyDown:connect(function(key) if I press any key it says "Not Working", even if I press W or S.
I've had this plenty of times with KeyDown and I'm not sure what I've been doing wrong.
function Seat(hit) wait(0.05) Player = game.Players:GetPlayerFromCharacter(hit.Parent) if Player then wait(0.1) if hit.Parent:findFirstChild("Humanoid") and hit.Parent.Humanoid.Sit == true then if script.Parent:findFirstChild("ChairSpeed") then return end elseif not script.Parent:findFirstChild("ChairSpeed") then local Speed = Instance.new("BodyVelocity", script.Parent) Speed.Name = "ChairSpeed" Mouse = Player:GetMouse() Mouse.KeyDown:connect(function(key) key = key:lower() if key == "w" then Speed.P = 2500 elseif key == "s" then Speed.P = 0 else print("Not Working") end end) end end end
script.Parent.Touched:connect(Seat) |
|
|
| Report Abuse |
|
|
YOSkater
|
  |
| Joined: 19 Mar 2011 |
| Total Posts: 13337 |
|
|
| 24 Oct 2014 02:56 PM |
w is a key that already has a designated job try q or e |
|
|
| Report Abuse |
|
|
YOSkater
|
  |
| Joined: 19 Mar 2011 |
| Total Posts: 13337 |
|
|
| 24 Oct 2014 02:57 PM |
keys you can't use:
i, o, w, a, s, d |
|
|
| Report Abuse |
|
|
|
| 24 Oct 2014 03:09 PM |
| Tried e and q same result. |
|
|
| Report Abuse |
|
|