|
| 04 May 2013 09:32 AM |
I made a map changer GUI that just changes the Map every 150 Seconds and it only has 2 maps but how would I be able to make it so it teleports all players away from the map just before it changes then teleports it to the new map. My script is here:
map1 = game.Workspace:findFirstChild("Mapn1") map2 = game.Workspace:findFirstChild("Mapn2") time = 150 clone = map1:clone() clone2 = map2:clone() wait() map1:remove() map2:remove() while true do local map = clone:clone() map.Parent = game.Workspace wait(time) map:remove() local map = clone2:clone() map.Parent = game.Workspace wait(time) map:remove() end |
|
|
| Report Abuse |
|
|
|
| 04 May 2013 09:33 AM |
| :Remove() no longer works these days. |
|
|
| Report Abuse |
|
|
1WOOF1
|
  |
| Joined: 03 May 2009 |
| Total Posts: 20682 |
|
|
| 04 May 2013 09:35 AM |
@Wreck,
Pretty sure it does. |
|
|
| Report Abuse |
|
|
| |
|
| |
|
| |
|
| |
|
|
| 04 May 2013 10:03 AM |
| oops not GUI I meant script |
|
|
| Report Abuse |
|
|
| |
|
1WOOF1
|
  |
| Joined: 03 May 2009 |
| Total Posts: 20682 |
|
|
| 04 May 2013 10:15 AM |
| Bumping this often is not necessary, in fact it will make it less likely people will help you.. |
|
|
| Report Abuse |
|
|
| |
|
|
| 04 May 2013 10:28 AM |
To teleport everyone:
for i, v in ipairs(game.Players:GetPlayers()) do torso = v.Character.Torso torso.CFrame = CFrame.new(Vector3.new(0,0,0)) end
Obviously, change (0,0,0) to the point you want them to be teleported to. |
|
|
| Report Abuse |
|
|
|
| 04 May 2013 10:36 AM |
where would I put that in the script?
|
|
|
| Report Abuse |
|
|
|
| 04 May 2013 10:46 AM |
| Right before you Remove() the map. |
|
|
| Report Abuse |
|
|
|
| 04 May 2013 10:49 AM |
so to teleport all players back where do I put it?
|
|
|
| Report Abuse |
|
|
|
| 04 May 2013 10:51 AM |
and when putting it in do I take away the "end"
|
|
|
| Report Abuse |
|
|
|
| 04 May 2013 10:52 AM |
| and I meant teleport them back to the next map so map 2 |
|
|
| Report Abuse |
|
|
|
| 04 May 2013 11:15 AM |
Ok so this works, now I need it to teleport all players back into the map, where would I put it?
map1 = game.Workspace:findFirstChild("Mapn1") map2 = game.Workspace:findFirstChild("Mapn2") time = 10 clone = map1:clone() clone2 = map2:clone() wait() map1:remove() map2:remove() while true do local map = clone:clone() map.Parent = game.Workspace wait(time) for i, v in ipairs(game.Players:GetPlayers()) do torso = v.Character.Torso torso.CFrame = CFrame.new(Vector3.new(43, 7.59, -61)) end map:remove() local map = clone2:clone() map.Parent = game.Workspace wait(time) map:remove() end
|
|
|
| Report Abuse |
|
|
|
| 04 May 2013 12:03 PM |
ok so I want it to go in a loop so like this? Did I put it in the right place?
map1 = game.Workspace:findFirstChild("Mapn1") map2 = game.Workspace:findFirstChild("Mapn2") time = 150 clone = map1:clone() clone2 = map2:clone() while true do----------------------SO LIKE THIS? wait() map1:remove() map2:remove() while true do local map = clone:clone() map.Parent = game.Workspace wait(time) map:remove() local map = clone2:clone() map.Parent = game.Workspace wait(time) map:remove() end
|
|
|
| Report Abuse |
|
|
|
| 04 May 2013 12:15 PM |
ok so where do i put the teleport scripts?
and this works for the player check? #game.Players:GetPlayers()
if it does where would it go?
|
|
|
| Report Abuse |
|
|
|
| 04 May 2013 12:18 PM |
where do I put the while true do? I already have 1 will it work in that position?
map1 = game.Workspace:findFirstChild("Mapn1") map2 = game.Workspace:findFirstChild("Mapn2") time = 150 clone = map1:clone() clone2 = map2:clone() wait() map1:remove() map2:remove() while true do------------------------------------I HAVE ONE HERE local map = clone:clone() map.Parent = game.Workspace wait(time) map:remove() local map = clone2:clone() map.Parent = game.Workspace wait(time) map:remove() end |
|
|
| Report Abuse |
|
|
| |
|