|
| 28 Jul 2014 05:12 PM |
It's supposed to be a command script. When you type "reset" into the chat it is supposed to kill you, but for some reason it doesn't work.
function processCommand(speaker, message) -- if someone chatted "reset" if message == "reset" then -- Destroy the player's head (speaker.Head:Destroy()) end end |
|
|
| Report Abuse |
|
|
|
| 28 Jul 2014 05:14 PM |
| All it tells me is that there is a syntax error near "end" |
|
|
| Report Abuse |
|
|
| |
|
BLOXLUA
|
  |
| Joined: 16 Mar 2013 |
| Total Posts: 453 |
|
|
| 28 Jul 2014 05:20 PM |
| I don't think you can put "()" around that. |
|
|
| Report Abuse |
|
|
Vuva
|
  |
| Joined: 22 Jan 2010 |
| Total Posts: 1102 |
|
|
| 28 Jul 2014 05:21 PM |
Erm yeah, change this line: (speaker.Head:Destroy()) to this: speaker.Head:Destroy() |
|
|
| Report Abuse |
|
|
smiley599
|
  |
| Joined: 23 Jan 2010 |
| Total Posts: 21869 |
|
| |
|
vm9
|
  |
| Joined: 29 Nov 2007 |
| Total Posts: 347 |
|
|
| 28 Jul 2014 05:27 PM |
| Put a bracket at the end of the second end (the one at the bottom). |
|
|
| Report Abuse |
|
|
BLOXLUA
|
  |
| Joined: 16 Mar 2013 |
| Total Posts: 453 |
|
| |
|
smiley599
|
  |
| Joined: 23 Jan 2010 |
| Total Posts: 21869 |
|
| |
|
vm9
|
  |
| Joined: 29 Nov 2007 |
| Total Posts: 347 |
|
|
| 28 Jul 2014 05:29 PM |
| Sorry I am just starting out with Lua and thought I could help ;_; |
|
|
| Report Abuse |
|
|
BLOXLUA
|
  |
| Joined: 16 Mar 2013 |
| Total Posts: 453 |
|
|
| 28 Jul 2014 05:30 PM |
| It's okay. Don't cry child, shhhhhh. |
|
|
| Report Abuse |
|
|
|
| 28 Jul 2014 06:23 PM |
| STill doesn't work :| When I tested the game and typed "reset" nothing happened. |
|
|
| Report Abuse |
|
|
| |
|
128GB
|
  |
| Joined: 17 Apr 2014 |
| Total Posts: 8056 |
|
|
| 28 Jul 2014 06:40 PM |
Game.Players.PlayerAdded:connect(function(player) player.Chatted:connect(function(input) if input:lower == "reset" and player.Character and player.Character.Parent == Workspace then player.Character:BreakJoints() end end) end) |
|
|
| Report Abuse |
|
|