gangman67
|
  |
| Joined: 04 Jun 2011 |
| Total Posts: 798 |
|
|
| 18 Dec 2015 09:39 PM |
How to flippin use I tried this UserInputService.InputBegan:connect(function(UserInput) if UserInput.UserInputType == Enum.UserInputType.Keyboard then if UserInput.KeyCode == Enum.KeyCode.Q then while UserInputService:IsKeyDown(Enum.KeyCode.Q) do wait() print("gang was here :3") end end end end) |
|
|
| Report Abuse |
|
|
|
| 18 Dec 2015 09:45 PM |
| I like your thinking, but try making InputBegan flag something to run constantly. Have an InputEnded flag something to end the constantly running loop thing. |
|
|
| Report Abuse |
|
|
|
| 18 Dec 2015 09:47 PM |
I may be wrong on first guess, but I think you use get service for the user input service
game:GetService('UserInputService') |
|
|
| Report Abuse |
|
|
gangman67
|
  |
| Joined: 04 Jun 2011 |
| Total Posts: 798 |
|
|
| 18 Dec 2015 09:50 PM |
@Cody, I did that before but I figured this would be nicer as IsKeyDown Is what this is for(I believe :p) @Rob, I do have that but I forgot to copy :p |
|
|
| Report Abuse |
|
|
|
| 18 Dec 2015 09:57 PM |
| Idk I don't see anything wrong with that code... |
|
|
| Report Abuse |
|
|
|
| 18 Dec 2015 10:13 PM |
I personally don't like UserInputService, I think you should use KeyDown/KeyUp. It's a lot easier to use, even if it is deprecated.
#code while true do end |
|
|
| Report Abuse |
|
|
Vexture
|
  |
| Joined: 27 Jan 2011 |
| Total Posts: 630 |
|
|
| 18 Dec 2015 10:16 PM |
a few problems i noticed define userinputservice as a variable that equals game:GetService("UserInputService")
and for "userInput," if userInput.InputType == Enum.InputType.input then
not userInputType lol |
|
|
| Report Abuse |
|
|
gangman67
|
  |
| Joined: 04 Jun 2011 |
| Total Posts: 798 |
|
|
| 18 Dec 2015 11:22 PM |
| Sorry I was away and @Above what do you mean? |
|
|
| Report Abuse |
|
|