|
| 26 Jan 2013 04:33 PM |
ok this is my map changer it teleports players and changes the map, but it wont remove the map after it puts it into workspace it just gets another map out Please Help
heres the script
while true do game.Lighting.Map1:clone().Parent = game.Workspace wait(60)-- map timer pos=Vector3.new(0,0,0) -- where i teleport for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(pos) game.Workspace.Map1:remove() end game.Lighting.Map2:clone().Parent = game.Workspace wait(60)-- map timer pos=Vector3.new(0,0,0) -- where i teleport for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(pos) game.Workspace.Map2:remove() end game.Lighting.Map3:clone().Parent = game.Workspace wait(60)-- map timer pos=Vector3.new(0,0,0) -- where i teleport for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(pos) game.Workspace.Map3:remove() end end |
|
|
| Report Abuse |
|
|
|
| 26 Jan 2013 04:40 PM |
| It's cause it's looped. All it's doing is looping the whole script. |
|
|
| Report Abuse |
|
|
| |
|
UnAdmin
|
  |
| Joined: 10 Jul 2012 |
| Total Posts: 4706 |
|
|
| 26 Jan 2013 04:48 PM |
a = true b = false c = false pos=Vector3.new(0,1,0) while wait(60) do if a == true then a = false game.Lighting.Map1:Clone().Parent = game.Workspace if game.Workspace:findFirstChild("Map3") ~= nil then game.Workspace.Map3:Destroy() end b = true elseif b == true then b = false game.Lighting.Map2:Clone().Parent = game.Workspace if game.Workspace:findFirstChild("Map1") ~= nil then game.Workspace.Map1:Destroy() end c = true elseif c == true then c = false game.Lighting.Map3:Clone().Parent = game.Workspace if game.Workspace:findFirstChild("Map2") ~= nil then game.Workspace.Map2:Destroy() end a = true end for i,v in pairs(game.Players:GetPlayers()) do v.Character.Humanoid.Health = 0 end wait(6) for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(pos) end end |
|
|
| Report Abuse |
|
|
|
| 26 Jan 2013 07:02 PM |
Dude if this works UR AWSOME!!!!
(On my iPhone can't try it out :( |
|
|
| Report Abuse |
|
|
| |
|
TheMyrco
|
  |
| Joined: 13 Aug 2011 |
| Total Posts: 15105 |
|
|
| 27 Jan 2013 03:38 PM |
It's because you deleted the map in a for loop...meaning it would remove it multiple times, but would nto exist after ran once and error.
I guess this should work, judging on what you did/tried
while true do local map = game.Lighting.Map1:Clone() map.Parent = Workspace wait(60)-- map timer for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(Vector3.new()) end map:Destroy()
local map = game.Lighting.Map2:Clone() map.Parent = Workspace wait(60)-- map timer for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(Vector3.new()) end map:Destroy()
local map = game.Lighting.Map3:Clone() map.Parent = Workspace wait(60)-- map timer for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(Vector3.new()) end map:Destroy() end |
|
|
| Report Abuse |
|
|
|
| 27 Jan 2013 03:40 PM |
Is there any output? If not, there is probably some confliction with the names, which would be fixed by setting a variable to the map like so :
while true do local map=game.Lighting.Map1:clone() map.Parent = game.Workspace map:MakeJoints() wait(60)-- map timer pos=Vector3.new(0,0,0) -- where i teleport for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(pos) end map:remove() local map=game.Lighting.Map2:clone() map.Parent = game.Workspace map:MakeJoints() wait(60)-- map timer pos=Vector3.new(0,0,0) -- where i teleport for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(pos) end map:remove() local map=game.Lighting.Map3:clone() map.Parent = game.Workspace map:MakeJoints() wait(60)-- map timer pos=Vector3.new(0,0,0) -- where i teleport for i,v in pairs(game.Players:GetPlayers()) do v.Character:MoveTo(pos) end map:remove() end
|
|
|
| Report Abuse |
|
|
|
| 27 Jan 2013 03:45 PM |
| ok it changed maps but didnt teleport me. the teleporting is the main thing... |
|
|
| Report Abuse |
|
|
TheMyrco
|
  |
| Joined: 13 Aug 2011 |
| Total Posts: 15105 |
|
|
| 27 Jan 2013 03:47 PM |
| It should, unless you spawn at (0, 0 ,0) |
|
|
| Report Abuse |
|
|
|
| 27 Jan 2013 03:50 PM |
| HAHAHA!!! i added a few things and got it to work!! cool beans! |
|
|
| Report Abuse |
|
|
|
| 27 Jan 2013 03:51 PM |
| thanks themycro!!! ive worked on this for a long time now. i really apreciate it |
|
|
| Report Abuse |
|
|
|
| 27 Jan 2013 04:02 PM |
| ok how am i suppose to add messages now?? i tryed adding them in but didnt show up. |
|
|
| Report Abuse |
|
|
TheMyrco
|
  |
| Joined: 13 Aug 2011 |
| Total Posts: 15105 |
|
|
| 27 Dec 2013 09:36 AM |
| local m = Instance.new("Message", workspace) |
|
|
| Report Abuse |
|
|
|
| 27 Dec 2013 01:10 PM |
Did you try to time that out perfectly so that you answer it 11 months after he asked it? I wish you would have waited a few more hours and done it at exactly the same time he asked it too.
~SDuke524 |
|
|
| Report Abuse |
|
|