|
| 11 Apr 2013 08:00 PM |
On my first place, click the button at the end.
--awesome404's Course Completion Script 2.0 Win = Workspace.Course1.WinBrick Course1 = Workspace.Course1 Course2 = game.Lighting.Course2 KIllbrick = Workspace.Course1.Killbrick Door = Workspace.MainDoor
function onClick(Win) Win:Destroy() local m = Instance.new("Message", Workspace) m.Text = "Someone has won this course." wait(3) m.Text = "Loading next course." wait(.5) m.Text = "Loading next course.." wait(.5) m.Text = "Loading next course..." Course1:remove() Course2:Clone().Parent = Workspace wait(.5) m.Text = "Course loaded." wait(2) m:Destroy() wait(1) Door.Transparency = .2 wait(.1) Door.Transparency = .4 wait(.1) Door.Transparency = .6 wait(.1) Door.Transparency = .8 wait(.1) Door.Transparency = 1 Door.CanCollide = false wait(7) -- Gives players seven seconds to enter course Door.CanCollide = true Door.Transparency = .8 wait(.1) Door.Transparency = .6 wait(.1) Door.Transparency = .4 wait(.1) Door.Transparency = .2 wait(.1) Door.Transparency = 0 end
Win.ClickDetector.MouseClick:connect(onClick) |
|
|
| Report Abuse |
|
|
dnic1997
|
  |
| Joined: 08 May 2010 |
| Total Posts: 309 |
|
|
| 11 Apr 2013 08:04 PM |
What do you mean by "Player gets removed from game"? If you mean, you want all of the players to respawn, then here:
Win = Workspace.Course1.WinBrick Course1 = Workspace.Course1 Course2 = game.Lighting.Course2 KIllbrick = Workspace.Course1.Killbrick Door = Workspace.MainDoor
function onClick(Win) Win:Destroy() local m = Instance.new("Message", Workspace) m.Text = "Someone has won this course." wait(3) m.Text = "Loading next course." wait(.5) m.Text = "Loading next course.." wait(.5) m.Text = "Loading next course..." Course1:remove() Course2:Clone().Parent = Workspace for i,v in pairs(game.Players:GetPlayers()) do v:LoadCharacter() end wait(.5) m.Text = "Course loaded." wait(2) m:Destroy() wait(1) Door.Transparency = .2 wait(.1) Door.Transparency = .4 wait(.1) Door.Transparency = .6 wait(.1) Door.Transparency = .8 wait(.1) Door.Transparency = 1 Door.CanCollide = false wait(7) -- Gives players seven seconds to enter course Door.CanCollide = true Door.Transparency = .8 wait(.1) Door.Transparency = .6 wait(.1) Door.Transparency = .4 wait(.1) Door.Transparency = .2 wait(.1) Door.Transparency = 0 end
Win.ClickDetector.MouseClick:connect(onClick)
|
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 08:05 PM |
| Click the button at the end of the level, the player gets removed FROM THE GAME |
|
|
| Report Abuse |
|
|
dnic1997
|
  |
| Joined: 08 May 2010 |
| Total Posts: 309 |
|
|
| 11 Apr 2013 08:07 PM |
| So you want them to be kicked or are they being kicked without you wanting to be kicked? |
|
|
| Report Abuse |
|
|
| |
|
dnic1997
|
  |
| Joined: 08 May 2010 |
| Total Posts: 309 |
|
|
| 11 Apr 2013 08:09 PM |
| The latter, what is "The latter"? |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 08:10 PM |
| I don't want them to be kicked |
|
|
| Report Abuse |
|
|
dnic1997
|
  |
| Joined: 08 May 2010 |
| Total Posts: 309 |
|
|
| 11 Apr 2013 08:12 PM |
| Well, in this script, it doesn't have the players being kicked. |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 08:13 PM |
I know :( It must be when Course1 gets removed. |
|
|
| Report Abuse |
|
|
|
| 11 Apr 2013 08:15 PM |
Fixed it, by removing the line:
Win:Destroy() |
|
|
| Report Abuse |
|
|