|
| 07 Apr 2012 10:53 PM |
hint = Instance.new("Hint") hint.Parent = Workspace hint.Text = "Loading Game" msg = Instance.new("Message") msg.Parent = Workspace msg.Text = "" set = Workspace.Set
function clearBricks() for i, v in pairs(Workspace:children()) do if v.Name == "build" then v:Remove() end end end
function lockBricks()
set.Parent = game.Lighting for i, v in pairs(Workspace:children()) do if v.Name == "build" then v.Locked = true end end end
function thawZombies() for i, v in pairs(Workspace:children()) do if v.Name == "Zombie" then for i2, v2 in pairs(v:children()) do if v2:IsA("BasePart") then v2.Anchored = false end end end end end
function killZombies() for i, v in pairs(Workspace:children()) do if v.Name == "Zombie" then v:BreakJoints() end end end
function openDoors() for i = 1, 140 do Workspace.Door.CFrame = Workspace.Door.CFrame + Vector3.new(0,.1,0) Workspace.Door2.CFrame = Workspace.Door2.CFrame + Vector3.new(0,.1,0) wait() end end
function closeDoors() for i = 1, 140 do Workspace.Door.CFrame = Workspace.Door.CFrame - Vector3.new(0,.1,0) Workspace.Door2.CFrame = Workspace.Door2.CFrame - Vector3.new(0,.1,0) wait() end end
function round() set.Parent = Workspace set:MakeJoints() msg.Text = "" hint.Text = "New Round: Start Building!" wait(5) for i = 120, 1, -1 do if i ~= 1 then hint.Text = "Zombies Come In: "..i.." Seconds!" else hint.Text = "Zombies Come In: "..i.." Second!" end wait(1) end lockBricks() hint.Text = "Zombies are here!" openDoors() thawZombies() wait(5) for i = 60, 1, -1 do if i ~= 1 then hint.Text = "Survive for "..i.." Seconds!" else hint.Text = "Survive for "..i.." Second!" end wait(1) end hint.Text = "Round is Over! Good job!" killZombies() closeDoors() clearBricks() hint.Text = "Round is Over! Good job!" wait(4) round() end
round() |
|
|
| Report Abuse |
|
|
flamorie
|
  |
| Joined: 04 Feb 2009 |
| Total Posts: 8563 |
|
| |
|
|
| 07 Apr 2012 10:54 PM |
| This script been giving issues but i can't find the problem |
|
|
| Report Abuse |
|
|
flamorie
|
  |
| Joined: 04 Feb 2009 |
| Total Posts: 8563 |
|
|
| 07 Apr 2012 10:56 PM |
Is it running at all? If so where does it break? What's the output? |
|
|
| Report Abuse |
|
|
|
| 07 Apr 2012 10:57 PM |
| The doors open but the zombies doesn't always come out just in some rounds and i can't fiquire out why |
|
|
| Report Abuse |
|
|
flamorie
|
  |
| Joined: 04 Feb 2009 |
| Total Posts: 8563 |
|
|
| 07 Apr 2012 11:03 PM |
| I don't see a problem. NPC's can be glitchy on this game. You may wanna make sure they can get to where they need to go without anything in the way. |
|
|
| Report Abuse |
|
|
|
| 07 Apr 2012 11:03 PM |
| Hmm ok thanks for the help |
|
|
| Report Abuse |
|
|