rblxxx
|
  |
| Joined: 15 Jan 2013 |
| Total Posts: 626 |
|
|
| 28 Jul 2013 12:32 PM |
I need help with this script. It is supposed to be a map changer that changes the map every time you click a button. But it wont remove the map every time I click the button. Please help!
debounce = false int = Instance.new("IntValue",Workspace) int.Value = 1
function mapone() wait(13) game.Lighting.Map1:Clone().Parent = Workspace int.Value = 2 end
function remove() if game.Workspace:findFirstChild("Map1") then game.Workspace.Map1:Destroy() end if game.Workspace:findFirstChild("Map2") then game.Workspace.Map2:Destroy() end int.Value = 1 end
function maptwo() game.Workspace.Map1:Destroy() wait(13) game.Lighting.Map2:Clone().Parent = Workspace int.Value = 3 end
function touched(hit) hum = hit.Parent:FindFirstChild("Humanoid")--to make sure its a person if hum ~= nil then if int.Value == 1 then mapone() elseif int.Value == 2 then maptwo() elseif int.Value == 3 then remove() end end end wait(2) debounce = true
script.Parent.Touched:connect(touched) |
|
|
| Report Abuse |
|
|
rblxxx
|
  |
| Joined: 15 Jan 2013 |
| Total Posts: 626 |
|
| |
|
|
| 28 Jul 2013 12:34 PM |
| Don't bump it less than a minute after you post it.... |
|
|
| Report Abuse |
|
|
rblxxx
|
  |
| Joined: 15 Jan 2013 |
| Total Posts: 626 |
|
| |
|
| |
|