Advertisement
Ma1e

Untitled

Oct 17th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 21.58 KB | None | 0 0
  1. StatusValue = Instance.new("StringValue", game.ReplicatedStorage)
  2. StatusValue.Name = "StatusValue"
  3. local Hint = Instance.new("Hint", game.Workspace)
  4. local Value = Instance.new("IntValue", Hint)
  5. Hint.Text = StatusValue.Value
  6. StatusValue.Changed:connect(function()
  7. Hint.Text = StatusValue.Value
  8. end)
  9. Hint.Changed:connect(function()
  10. if game.Workspace:FindFirstChild("Message") then
  11. else
  12. local Hint = Instance.new("Hint", game.Workspace)
  13. local Value = Instance.new("IntValue", Hint)
  14. Hint.Text = StatusValue.Value
  15. StatusValue.Changed:connect(function()
  16. Hint.Text = StatusValue.Value
  17. end)
  18. end
  19. end)
  20. game.Lighting.GlobalShadows = false
  21. game.Lighting.Ambient = Color3.new(.5,.5,.5)
  22.  
  23. game.Workspace.ChildAdded:connect(function(rope)
  24. if rope.className == "Model" then
  25. if rope:FindFirstChildOfClass("Humanoid") then
  26. local Attachment1 = Instance.new("Attachment", rope.Head)
  27. Attachment1.Name = 'Attachment1'
  28. local Rope = Instance.new("RopeConstraint", rope.Head)
  29. Rope.Name = "Rope"
  30. Rope.Attachment0 = Attachment1
  31. Rope.Visible = true
  32. Rope.Color = BrickColor.new("Pearl")
  33. Rope.Length = 100
  34. end
  35. end
  36. end)
  37.  
  38. local linkedsword = game:service("InsertService"):LoadAsset(tonumber(125013769))
  39. for a,g in pairs(linkedsword:children()) do if g:IsA("Tool") or g:IsA("HopperBin") then g.Parent = game.ReplicatedStorage end end
  40. linkedsword:Destroy()
  41.  
  42. game.Players.PlayerAdded:connect(function(obj)
  43.  
  44. local stats = Instance.new("Folder", obj)
  45. stats.Name = "leaderstats"
  46.  
  47. local Wins = Instance.new("IntValue", stats)
  48. Wins.Name = "Wins"
  49. Wins.Value = 0
  50.  
  51. local Team = Instance.new("StringValue", obj)
  52. Team.Name = "T"
  53. Team.Value = "Players"
  54.  
  55. local Alive = Instance.new("StringValue", obj)
  56. Alive.Name = "Alive"
  57. Alive.Value = "No"
  58. obj.CharacterAdded:connect(function(character)
  59. character:WaitForChild("Humanoid").Died:connect(function()
  60. local tag = character.Humanoid:FindFirstChild("creator")
  61. if tag ~= nil then
  62. if tag.Value ~= nil then
  63. if obj.Alive.Value == "Yes" then
  64. if obj.T.Value == "Red" then
  65. game.ReplicatedStorage.red.Value = game.ReplicatedStorage.red.Value - 1
  66. obj.Alive.Value = "No"
  67. elseif obj.T.Value == "Blue" then
  68. game.ReplicatedStorage.blue.Value = game.ReplicatedStorage.blue.Value - 1
  69. obj.Alive.Value = "No"
  70. end
  71. if obj.T.Value == "Players" then
  72. game.ReplicatedStorage["PlayersAlive"].Value = game.ReplicatedStorage["PlayersAlive"].Value - 1
  73. obj.Alive.Value = "No"
  74. end
  75.  
  76. end
  77. end
  78. end
  79. end)
  80. end)
  81. end)
  82.  
  83. for _,obj in pairs(game.Players:GetChildren()) do
  84.  
  85. local stats = Instance.new("Folder", obj)
  86. stats.Name = "leaderstats"
  87.  
  88. local Wins = Instance.new("IntValue", stats)
  89. Wins.Name = "Wins"
  90. Wins.Value = 0
  91.  
  92. local Team = Instance.new("StringValue", obj)
  93. Team.Name = "T"
  94. Team.Value = "Players"
  95.  
  96. local Alive = Instance.new("StringValue", obj)
  97. Alive.Name = "Alive"
  98. Alive.Value = "No"
  99.  
  100. obj.CharacterAdded:connect(function(character)
  101. character:WaitForChild("Humanoid").Died:connect(function()
  102. local tag = character.Humanoid:FindFirstChild("creator")
  103. if tag ~= nil then
  104. if tag.Value ~= nil then
  105. if obj.Alive.Value == "Yes" then
  106. if obj.T.Value == "Red" then
  107. game.ReplicatedStorage.red.Value = game.ReplicatedStorage.red.Value - 1
  108. obj.Alive.Value = "No"
  109. elseif obj.T.Value == "Blue" then
  110. game.ReplicatedStorage.blue.Value = game.ReplicatedStorage.blue.Value - 1
  111. obj.Alive.Value = "No"
  112. end
  113. if obj.T.Value == "Players" then
  114. game.ReplicatedStorage["PlayersAlive"].Value = game.ReplicatedStorage["PlayersAlive"].Value - 1
  115. obj.Alive.Value = "No"
  116. end
  117.  
  118. end
  119. end
  120. end
  121. end)
  122. end)
  123. end
  124.  
  125. game.Players.PlayerRemoving:connect(function(plr)
  126. if plr.Alive.Value == "Yes" then
  127. if plr.T.Value == "Red" then
  128. game.ReplicatedStorage.red.Value = game.ReplicatedStorage.red.Value - 1
  129. elseif plr.T.Value == "Blue" then
  130. game.ReplicatedStorage.blue.Value = game.ReplicatedStorage.blue.Value - 1
  131. if game.ReplicatedStorage["PlayersAlive"].Value > 0 then
  132. game.ReplicatedStorage["PlayersAlive"].Value = game.ReplicatedStorage["PlayersAlive"].Value - 1
  133. end
  134. end
  135. end
  136. end)
  137. -------------------------------------------
  138. GameValue = Instance.new("IntValue", game.ReplicatedStorage)
  139. GameValue.Name = "Game"
  140. GameValue.Value = 0
  141.  
  142. PlayersAlive = Instance.new("IntValue", game.ReplicatedStorage)
  143. PlayersAlive.Name = "PlayersAlive"
  144. PlayersAlive.Value = 0
  145. -------------------------------------------MAP1
  146. Map = Instance.new("Model", game.Workspace)
  147. Map.Name = "Regular Map"
  148.  
  149. Part = Instance.new("Part", Map)
  150. Part.BrickColor = BrickColor.new("Black")
  151. Part.Orientation = Vector3.new(0, -180, -90)
  152. Part.Material = "SmoothPlastic"
  153. Part.Anchored = true
  154. Part.Size = Vector3.new(5, 190, 185)
  155. Part.Position = Vector3.new(-14.5, 56.1, 45.5)
  156. Part.Shape = "Cylinder"
  157. Part.TopSurface = "Smooth"
  158. Part.BottomSurface = "Smooth"
  159.  
  160. Tele = Instance.new("Part", Map)
  161. Tele.Transparency = 1
  162. Tele.Name = "Tele"
  163. Tele.Anchored = true
  164. Tele.CanCollide = false
  165. Tele.Size = Vector3.new(121, 1, 130.6)
  166. Tele.Position = Vector3.new(-16.5, 75, 45.5)
  167.  
  168. Map.Parent = game.ServerStorage
  169. -------------------------------------------MAP2
  170. Map2 = Instance.new("Model", game.Workspace)
  171. Map2.Name = "Tree Land"
  172.  
  173. Part = Instance.new("Part", Map2)
  174. Part.BrickColor = BrickColor.new("Bright green")
  175. Part.Orientation = Vector3.new(0, -180, -90)
  176. Part.Material = "Grass"
  177. Part.Anchored = true
  178. Part.Size = Vector3.new(5, 190, 185)
  179. Part.Position = Vector3.new(-14.5, 56.1, 45.5)
  180. Part.Shape = "Cylinder"
  181. Part.TopSurface = "Smooth"
  182. Part.BottomSurface = "Smooth"
  183.  
  184. Wood1 = Instance.new("Part", Map2)
  185. Wood1.BrickColor = BrickColor.new("Brown")
  186. Wood1.Material = "Wood"
  187. Wood1.Anchored = true
  188. Wood1.Size = Vector3.new(2, 10, 2)
  189. Wood1.Position = Vector3.new(6.4, 63.6, 6.7)
  190. Wood1.TopSurface = "Smooth"
  191. Wood1.BottomSurface = "Smooth"
  192.  
  193. Grass1 = Instance.new("Part", Map2)
  194. Grass1.BrickColor = BrickColor.new("Bright green")
  195. Grass1.Material = "Grass"
  196. Grass1.Anchored = true
  197. Grass1.Size = Vector3.new(6,6,6)
  198. Grass1.Position = Vector3.new(6.4, 71.6, 6.7)
  199. Grass1.TopSurface = "Smooth"
  200. Grass1.BottomSurface = "Smooth"
  201.  
  202. Wood2 = Instance.new("Part", Map2)
  203. Wood2.BrickColor = BrickColor.new("Brown")
  204. Wood2.Material = "Wood"
  205. Wood2.Anchored = true
  206. Wood2.Size = Vector3.new(2, 10, 2)
  207. Wood2.Position = Vector3.new(-43.6, 63.6, 36.7)
  208. Wood2.TopSurface = "Smooth"
  209. Wood2.BottomSurface = "Smooth"
  210.  
  211. Grass2 = Instance.new("Part", Map2)
  212. Grass2.BrickColor = BrickColor.new("Bright green")
  213. Grass2.Material = "Grass"
  214. Grass2.Anchored = true
  215. Grass2.Size = Vector3.new(6,6,6)
  216. Grass2.Position = Vector3.new(-43.6, 71.6, 36.7)
  217. Grass2.TopSurface = "Smooth"
  218. Grass2.BottomSurface = "Smooth"
  219.  
  220. Wood3 = Instance.new("Part", Map2)
  221. Wood3.BrickColor = BrickColor.new("Brown")
  222. Wood3.Material = "Wood"
  223. Wood3.Anchored = true
  224. Wood3.Size = Vector3.new(2, 10, 2)
  225. Wood3.Position = Vector3.new(-73.6, 63.6, 86.7)
  226. Wood3.TopSurface = "Smooth"
  227. Wood3.BottomSurface = "Smooth"
  228.  
  229. Grass3 = Instance.new("Part", Map2)
  230. Grass3.BrickColor = BrickColor.new("Bright green")
  231. Grass3.Material = "Grass"
  232. Grass3.Anchored = true
  233. Grass3.Size = Vector3.new(6,6,6)
  234. Grass3.Position = Vector3.new(-73.6, 71.6, 86.7)
  235. Grass3.TopSurface = "Smooth"
  236. Grass3.BottomSurface = "Smooth"
  237.  
  238. Wood4 = Instance.new("Part", Map2)
  239. Wood4.BrickColor = BrickColor.new("Brown")
  240. Wood4.Material = "Wood"
  241. Wood4.Anchored = true
  242. Wood4.Size = Vector3.new(2, 10, 2)
  243. Wood4.Position = Vector3.new(6.4, 63.6, 76.7)
  244. Wood4.TopSurface = "Smooth"
  245. Wood4.BottomSurface = "Smooth"
  246.  
  247. Grass4 = Instance.new("Part", Map2)
  248. Grass4.BrickColor = BrickColor.new("Bright green")
  249. Grass4.Material = "Grass"
  250. Grass4.Anchored = true
  251. Grass4.Size = Vector3.new(6,6,6)
  252. Grass4.Position = Vector3.new(6.4, 71.6, 76.7)
  253. Grass4.TopSurface = "Smooth"
  254. Grass4.BottomSurface = "Smooth"
  255.  
  256. Wood5 = Instance.new("Part", Map2)
  257. Wood5.BrickColor = BrickColor.new("Brown")
  258. Wood5.Material = "Wood"
  259. Wood5.Anchored = true
  260. Wood5.Size = Vector3.new(2, 10, 2)
  261. Wood5.Position = Vector3.new(46.4, 63.6, 56.7)
  262. Wood5.TopSurface = "Smooth"
  263. Wood5.BottomSurface = "Smooth"
  264.  
  265. Grass5 = Instance.new("Part", Map2)
  266. Grass5.BrickColor = BrickColor.new("Bright green")
  267. Grass5.Material = "Grass"
  268. Grass5.Anchored = true
  269. Grass5.Size = Vector3.new(6,6,6)
  270. Grass5.Position = Vector3.new(46.4, 71.6, 56.7)
  271. Grass5.TopSurface = "Smooth"
  272. Grass5.BottomSurface = "Smooth"
  273.  
  274. Wood6 = Instance.new("Part", Map2)
  275. Wood6.BrickColor = BrickColor.new("Brown")
  276. Wood6.Material = "Wood"
  277. Wood6.Anchored = true
  278. Wood6.Size = Vector3.new(2, 10, 2)
  279. Wood6.Position = Vector3.new(-13.6, 63.6, 116.7)
  280. Wood6.TopSurface = "Smooth"
  281. Wood6.BottomSurface = "Smooth"
  282.  
  283. Grass6 = Instance.new("Part", Map2)
  284. Grass6.BrickColor = BrickColor.new("Bright green")
  285. Grass6.Material = "Grass"
  286. Grass6.Anchored = true
  287. Grass6.Size = Vector3.new(6,6,6)
  288. Grass6.Position = Vector3.new(-13.6, 71.6, 116.7)
  289. Grass6.TopSurface = "Smooth"
  290. Grass6.BottomSurface = "Smooth"
  291.  
  292. Wood7 = Instance.new("Part", Map2)
  293. Wood7.BrickColor = BrickColor.new("Brown")
  294. Wood7.Material = "Wood"
  295. Wood7.Anchored = true
  296. Wood7.Size = Vector3.new(2, 10, 2)
  297. Wood7.Position = Vector3.new(-43.6, 63.6, -13.3)
  298. Wood7.TopSurface = "Smooth"
  299. Wood7.BottomSurface = "Smooth"
  300.  
  301. Grass7 = Instance.new("Part", Map2)
  302. Grass7.BrickColor = BrickColor.new("Bright green")
  303. Grass7.Material = "Grass"
  304. Grass7.Anchored = true
  305. Grass7.Size = Vector3.new(6,6,6)
  306. Grass7.Position = Vector3.new(-43.6, 71.6, -13.3)
  307. Grass7.TopSurface = "Smooth"
  308. Grass7.BottomSurface = "Smooth"
  309.  
  310. Tele = Instance.new("Part", Map2)
  311. Tele.Transparency = 1
  312. Tele.Name = "Tele"
  313. Tele.Anchored = true
  314. Tele.CanCollide = false
  315. Tele.Size = Vector3.new(121, 1, 130.6)
  316. Tele.Position = Vector3.new(-16.5, 76, 45.5)
  317.  
  318. Map2.Parent = game.ServerStorage
  319. -------------------------------------------MAP3
  320. Map3 = Instance.new("Model", game.Workspace)
  321. Map3.Name = "Pyramid"
  322.  
  323. Part = Instance.new("Part", Map3)
  324. Part.BrickColor = BrickColor.new("Pastel brown")
  325. Part.Orientation = Vector3.new(0, -180, -90)
  326. Part.Material = "Sand"
  327. Part.Anchored = true
  328. Part.Size = Vector3.new(5, 190, 185)
  329. Part.Position = Vector3.new(-14.5, 56.1, 45.5)
  330. Part.Shape = "Cylinder"
  331. Part.TopSurface = "Smooth"
  332. Part.BottomSurface = "Smooth"
  333.  
  334. Wedge1 = Instance.new("CornerWedgePart", Map3)
  335. Wedge1.BrickColor = BrickColor.new("Pastel brown")
  336. Wedge1.Material = "Concrete"
  337. Wedge1.Anchored = true
  338. Wedge1.Orientation = Vector3.new(0,0,0)
  339. Wedge1.Size = Vector3.new(30, 30, 30)
  340. Wedge1.Position = Vector3.new(-29.501, 73.6, 60.501)
  341. Wedge1.TopSurface = "Smooth"
  342. Wedge1.BottomSurface = "Smooth"
  343.  
  344. Wedge2 = Instance.new("CornerWedgePart", Map3)
  345. Wedge2.BrickColor = BrickColor.new("Pastel brown")
  346. Wedge2.Material = "Concrete"
  347. Wedge2.Anchored = true
  348. Wedge2.Orientation = Vector3.new(0,90,0)
  349. Wedge2.Size = Vector3.new(30, 30, 30)
  350. Wedge2.Position = Vector3.new(0.501, 73.6, 60.501)
  351. Wedge2.TopSurface = "Smooth"
  352. Wedge2.BottomSurface = "Smooth"
  353.  
  354. Wedge3 = Instance.new("CornerWedgePart", Map3)
  355. Wedge3.BrickColor = BrickColor.new("Pastel brown")
  356. Wedge3.Material = "Concrete"
  357. Wedge3.Anchored = true
  358. Wedge3.Orientation = Vector3.new(0,180,0)
  359. Wedge3.Size = Vector3.new(30, 30, 30)
  360. Wedge3.Position = Vector3.new(0.501, 73.6, 30.499)
  361. Wedge3.TopSurface = "Smooth"
  362. Wedge3.BottomSurface = "Smooth"
  363.  
  364. Wedge4 = Instance.new("CornerWedgePart", Map3)
  365. Wedge4.BrickColor = BrickColor.new("Pastel brown")
  366. Wedge4.Material = "Concrete"
  367. Wedge4.Anchored = true
  368. Wedge4.Orientation = Vector3.new(0,-90,0)
  369. Wedge4.Size = Vector3.new(30, 30, 30)
  370. Wedge4.Position = Vector3.new(-29.501, 73.6, 30.499)
  371. Wedge4.TopSurface = "Smooth"
  372. Wedge4.BottomSurface = "Smooth"
  373.  
  374. Tele = Instance.new("Part", Map3)
  375. Tele.Transparency = 1
  376. Tele.Name = "Tele"
  377. Tele.Anchored = true
  378. Tele.CanCollide = false
  379. Tele.Size = Vector3.new(121, 1, 130.6)
  380. Tele.Position = Vector3.new(-16.5, 100, 45.5)
  381.  
  382. Map3.Parent = game.ServerStorage
  383. -------------------------------------------
  384. RopeAttachment = Instance.new("Part", game.ReplicatedStorage)
  385. RopeAttachment.Name = "RopeAttachment"
  386. RopeAttachment.Anchored = true
  387. RopeAttachment.BrickColor = BrickColor.new("Pearl")
  388. RopeAttachment.Material = "SmoothPlastic"
  389. RopeAttachment.Size = Vector3.new(1,1,1)
  390. RopeAttachment.Position = Vector3.new(-14.5, 106.1, 45.5)
  391. RopeAttachment.Shape = "Ball"
  392. RopeAttachment.TopSurface = "Smooth"
  393. RopeAttachment.BottomSurface = "Smooth"
  394.  
  395. Attachment2 = Instance.new("Attachment", RopeAttachment)
  396. Attachment2.Name = 'Attachment2'
  397.  
  398. SpawnLocation = Instance.new("SpawnLocation", game.Workspace)
  399. SpawnLocation.Name = "MinigameSpawn"
  400. SpawnLocation.CanCollide = false
  401. SpawnLocation.Anchored = true
  402. SpawnLocation.Position = Vector3.new(0,0,0)
  403. ------------------------------------------------------------------------------------
  404. wait(5)
  405. for _,obj in pairs(game.Players:GetChildren()) do
  406. if obj.Character:FindFirstChild("Humanoid") then
  407. obj.Character.Humanoid.Health = 0
  408. end
  409. end
  410. wait(10)
  411. ------------------------------------------------------------------------------------
  412.  
  413. while true do
  414. local replicatedstorage = game:GetService("ReplicatedStorage")
  415. local status = replicatedstorage:WaitForChild("StatusValue")
  416. while game.ReplicatedStorage.Game.Value == 0 do
  417. if game.Workspace:FindFirstChild("Message") then
  418. else
  419. local Hint = Instance.new("Hint", game.Workspace)
  420. local Value = Instance.new("IntValue", Hint)
  421. Hint.Text = StatusValue.Value
  422. StatusValue.Changed:connect(function()
  423. Hint.Text = StatusValue.Value
  424. end)
  425. end
  426. if game.Workspace:FindFirstChild("MinigameSpawn") then
  427. else
  428. SpawnLocation = Instance.new("SpawnLocation", game.Workspace)
  429. SpawnLocation.Name = "MinigameSpawn"
  430. SpawnLocation.CanCollide = false
  431. SpawnLocation.Anchored = true
  432. SpawnLocation.Position = Vector3.new(0,0,0)
  433. end
  434. RopeAttachment.Position = Vector3.new(-14.5, 106.1, 45.5)
  435. for i = 10,0,-1 do
  436. if i == 10 then
  437. status.Value = "Intermission: ||||||||||"
  438. elseif i == 9 then
  439. status.Value = "Intermission: |||||||||"
  440. elseif i == 8 then
  441. status.Value = "Intermission: ||||||||"
  442. elseif i == 7 then
  443. status.Value = "Intermission: |||||||"
  444. elseif i == 6 then
  445. status.Value = "Intermission: ||||||"
  446. elseif i == 5 then
  447. status.Value = "Intermission: |||||"
  448. elseif i == 4 then
  449. status.Value = "Intermission: ||||"
  450. elseif i == 3 then
  451. status.Value = "Intermission: |||"
  452. elseif i == 2 then
  453. status.Value = "Intermission: ||"
  454. elseif i == 1 then
  455. status.Value = "Intermission: |"
  456. elseif i == 0 then
  457. status.Value = "Intermission: "
  458. end
  459.  
  460. wait(1)
  461. end -- End of Intermission timer
  462. maps1 = game:GetService('ServerStorage'):GetChildren()
  463. chosenmap1 = maps1[math.random(1, #maps1)]
  464. map1 = chosenmap1:Clone()
  465. status.Value = "Choosing Map."
  466. wait(.5)
  467. status.Value = "Choosing Map.."
  468. wait(.5)
  469. status.Value = "Choosing Map..."
  470. wait(.5)
  471. status.Value = map1.Name.." has been chosen!"--
  472. wait(2)
  473. status.Value = "Survive to win!"
  474. map1.Parent = game.Workspace
  475. wait(2)
  476. game.ReplicatedStorage.PlayersAlive.Value = 0
  477. for _,obj in pairs(game.Players:GetChildren()) do
  478. obj.Alive.Value = "Yes"
  479. cc = map1:GetChildren()
  480. local PlayersAlive = game.ReplicatedStorage.PlayersAlive
  481. PlayersAlive.Value = PlayersAlive.Value + 1
  482. teles = {}
  483. for nuum, obbj in pairs(cc) do
  484. if obbj.Name == "Tele" then
  485. table.insert (teles, obbj)
  486. end
  487. end
  488. wait()
  489. tele = teles[math.random(1,#teles)]
  490. x1 = tele.Position.X-(tele.Size.X/2)
  491. x2 = tele.Position.X+(tele.Size.X/2)
  492. z1 = tele.Position.Z-(tele.Size.Z/2)
  493. z2 = tele.Position.Z+(tele.Size.Z/2)
  494. obj.Character.Head.CFrame = CFrame.new(math.random(x1,x2),tele.Position.Y+5,math.random(z1,z2))
  495. if obj.Character:FindFirstChild("Humanoid") then
  496. if obj.character.Humanoid.WalkSpeed >= 0 then
  497. obj.Character.Humanoid.WalkSpeed = 0
  498. end
  499. end
  500. RopeClone = RopeAttachment:Clone()
  501. RopeClone.Parent = game.Workspace
  502. obj.Character.Head.Rope.Attachment1 = game.Workspace.RopeAttachment.Attachment2
  503. end
  504. status.Value = "The game begins in: |||"
  505. wait(1)
  506. status.Value = "The game begins in: ||"
  507. wait(1)
  508. status.Value = "The game begins in: |"
  509. wait(1)
  510. status.Value = "Fight!"
  511. for _,obj in pairs(game.Players:GetChildren()) do
  512. SwordClone = game.ReplicatedStorage.LinkedSword:Clone()
  513. SwordClone.Parent = obj.Backpack
  514. if obj.Character:FindFirstChild("Humanoid") then
  515. obj.Character.Humanoid.WalkSpeed = 100
  516. end
  517. end
  518. wait(1)
  519.  
  520. for c = 30, 0, -1 do
  521. if c == 30 then
  522. status.Value = "Game in Progress: ||||||||||||||||||||||||||||||"
  523. elseif c == 29 then
  524. status.Value = "Game in Progress: |||||||||||||||||||||||||||||"
  525. elseif c == 28 then
  526. status.Value = "Game in Progress: ||||||||||||||||||||||||||||"
  527. elseif c == 27 then
  528. status.Value = "Game in Progress: |||||||||||||||||||||||||||"
  529. elseif c == 26 then
  530. status.Value = "Game in Progress: ||||||||||||||||||||||||||"
  531. elseif c == 25 then
  532. status.Value = "Game in Progress: |||||||||||||||||||||||||"
  533. elseif c == 24 then
  534. status.Value = "Game in Progress: ||||||||||||||||||||||||"
  535. elseif c == 23 then
  536. status.Value = "Game in Progress: |||||||||||||||||||||||"
  537. elseif c == 22 then
  538. status.Value = "Game in Progress: ||||||||||||||||||||||"
  539. elseif c == 21 then
  540. status.Value = "Game in Progress: |||||||||||||||||||||"
  541. elseif c == 20 then
  542. status.Value = "Game in Progress: ||||||||||||||||||||"
  543. elseif c == 19 then
  544. status.Value = "Game in Progress: |||||||||||||||||||"
  545. elseif c == 18 then
  546. status.Value = "Game in Progress: ||||||||||||||||||"
  547. elseif c == 17 then
  548. status.Value = "Game in Progress: |||||||||||||||||"
  549. elseif c == 16 then
  550. status.Value = "Game in Progress: ||||||||||||||||"
  551. elseif c == 15 then
  552. status.Value = "Game in Progress: |||||||||||||||"
  553. elseif c == 14 then
  554. status.Value = "Game in Progress: ||||||||||||||"
  555. elseif c == 13 then
  556. status.Value = "Game in Progress: |||||||||||||"
  557. elseif c == 12 then
  558. status.Value = "Game in Progress: ||||||||||||"
  559. elseif c == 11 then
  560. status.Value = "Game in Progress: |||||||||||"
  561. elseif c == 10 then
  562. status.Value = "Game in Progress: ||||||||||"
  563. elseif c == 9 then
  564. status.Value = "Game in Progress: |||||||||"
  565. elseif c == 8 then
  566. status.Value = "Game in Progress: ||||||||"
  567. elseif c == 7 then
  568. status.Value = "Game in Progress: |||||||"
  569. elseif c == 6 then
  570. status.Value = "Game in Progress: ||||||"
  571. elseif c == 5 then
  572. status.Value = "Game in Progress: |||||"
  573. elseif c == 4 then
  574. status.Value = "Game in Progress: ||||"
  575. elseif c == 3 then
  576. status.Value = "Game in Progress: |||"
  577. elseif c == 2 then
  578. status.Value = "Game in Progress: ||"
  579. elseif c == 1 then
  580. status.Value = "Game in Progress: |"
  581. elseif c == 0 then
  582. status.Value = "Game in Progress: "
  583. end
  584.  
  585. wait(1)
  586. local PlayersAlive = game.ReplicatedStorage.PlayersAlive
  587. if PlayersAlive.Value == 1 then
  588. game.ReplicatedStorage.Game.Value = 1
  589. break
  590. end
  591. if PlayersAlive.Value == 0 then
  592. game.ReplicatedStorage.Game.Value = 3
  593. break
  594. end
  595. if c == 0 then
  596. game.ReplicatedStorage.Game.Value = 2
  597. end
  598. end
  599. end
  600. if game.ReplicatedStorage.Game.Value == 1 then
  601. for _,obj in pairs(game.Players:GetChildren()) do
  602. if obj.Alive.Value == "Yes" then
  603. status.Value = obj.Name.." Won!"
  604. end
  605. end
  606. wait(2)
  607. status.Value = "They will recieve 1 win!"
  608. wait(2)
  609. for _,obj in pairs(game.Players:GetChildren()) do
  610. if obj.Alive.Value == "Yes" then
  611. for _,tool in pairs(obj.Backpack:GetChildren()) do
  612. tool:Remove()
  613. end
  614. for _,tool in pairs(obj.Character:GetChildren()) do
  615. if tool.className == "Tool" then
  616. tool:Remove()
  617. end
  618. end
  619. obj.leaderstats.Wins.Value = obj.leaderstats.Wins.Value + 1
  620. if game.Workspace:FindFirstChild("RopeAttachment") then
  621. if obj.Character.Head.Rope.Attachment1 == game.Workspace.RopeAttachment.Attachment2 then
  622. obj.Character.Head.Rope.Attachment1 = nil
  623. end
  624. end
  625. end
  626. end
  627. end
  628. if game.ReplicatedStorage.Game.Value == 2 then
  629. status.Value = "Multiple players won!"
  630. wait(2)
  631. status.Value = "They will recieve a win!"
  632. wait(2)
  633. for _,obj in pairs(game.Players:GetChildren()) do
  634. if obj.Alive.Value == "Yes" then
  635. for _,tool in pairs(obj.Backpack:GetChildren()) do
  636. tool:Remove()
  637. end
  638. for _,tool in pairs(obj.Character:GetChildren()) do
  639. if tool.className == "Tool" then
  640. tool:Remove()
  641. end
  642. end
  643. obj.leaderstats.Wins.Value = obj.leaderstats.Wins.Value + 1
  644. if game.Workspace:FindFirstChild("RopeAttachment") then
  645. if obj.Character.Head.Rope.Attachment1 == game.Workspace.RopeAttachment.Attachment2 then
  646. obj.Character.Head.Rope.Attachment1 = nil
  647. end
  648. end
  649. end
  650. end
  651. end
  652. if game.ReplicatedStorage.Game.Value == 3 then
  653. status.Value = "Nobody Won!"
  654. wait(2)
  655. status.Value = "Nobody recieves cash or wins!"
  656. wait(2)
  657. for _,obj in pairs(game.Players:GetChildren()) do
  658. if obj.Alive.Value == "Yes" then
  659. if game.Workspace:FindFirstChild("RopeAttachment") then
  660. if obj.Character.Head.Rope.Attachment1 == game.Workspace.RopeAttachment.Attachment2 then
  661. obj.Character.Head.Rope.Attachment1 = nil
  662. for _,tool in pairs(obj.Backpack:GetChildren()) do
  663. tool:Remove()
  664. end
  665. for _,tool in pairs(obj.Character:GetChildren()) do
  666. if tool.className == "Tool" then
  667. tool:Remove()
  668. end
  669. end
  670. end
  671. end
  672. end
  673. end
  674. end
  675. for _,obj in pairs(game.Players:GetChildren()) do
  676. obj.Alive.Value = "No"
  677. obj.T.Value = "Players"
  678. if obj.Character:FindFirstChild("Humanoid") then
  679. if obj.Character.Humanoid.WalkSpeed == 100 then
  680. obj.Character.Humanoid.WalkSpeed = 16
  681. end
  682. end
  683. end
  684. game.ReplicatedStorage.PlayersAlive.Value = 0
  685. game.ReplicatedStorage.Game.Value = 0
  686. if game.Workspace:FindFirstChild("RopeAttachment") then
  687. RopeClone:Destroy()
  688. end
  689. if game.Workspace:FindFirstChild("Regular Map") or game.Workspace:FindFirstChild("Pyramid") or game.Workspace:FindFirstChild("Tree Land") then
  690. map1:Destroy()--
  691. end
  692. end--End of loop
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement