Godofadmin1337

edsfesdf tower battles

Dec 20th, 2017
142
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.00 KB | None | 0 0
  1. --[[
  2. Made by Lau#0114 & Jethrootje#0289
  3. --]]
  4. local ScreenGui = Instance.new("ScreenGui")
  5. local Frame = Instance.new("Frame")
  6. local upgrade = Instance.new("TextButton")
  7. local towerspawn = Instance.new("TextButton")
  8. local player = Instance.new("TextBox")
  9. local tower = Instance.new("TextBox")
  10. local credits = Instance.new("TextLabel")
  11. ScreenGui.Parent = game.CoreGui
  12. Frame.Parent = ScreenGui
  13. Frame.BackgroundColor3 = Color3.new(1, 1, 1)
  14. Frame.BackgroundTransparency = 0.5
  15. Frame.BorderSizePixel = 3
  16. Frame.Active = true
  17. Frame.Draggable = true
  18. Frame.Position = UDim2.new(0.295620441, 0, 0.234082401, 0)
  19. Frame.Size = UDim2.new(0, 313, 0, 260)
  20.  
  21. upgrade.Name = "upgrade"
  22. upgrade.Parent = Frame
  23. upgrade.BackgroundColor3 = Color3.new(1, 1, 1)
  24. upgrade.BackgroundTransparency = 0.5
  25. upgrade.BorderSizePixel = 0
  26. upgrade.Position = UDim2.new(0.0543131009, 0, 0.161538467, 0)
  27. upgrade.Size = UDim2.new(0, 130, 0, 49)
  28. upgrade.Font = Enum.Font.Cartoon
  29. upgrade.FontSize = Enum.FontSize.Size14
  30. upgrade.Text = "Upgrade Towers"
  31. upgrade.TextSize = 14
  32.  
  33. towerspawn.Name = "towerspawn"
  34. towerspawn.Parent = Frame
  35. towerspawn.BackgroundColor3 = Color3.new(1, 1, 1)
  36. towerspawn.BackgroundTransparency = 0.5
  37. towerspawn.BorderSizePixel = 0
  38. towerspawn.Position = UDim2.new(0.527156591, 0, 0.161538467, 0)
  39. towerspawn.Size = UDim2.new(0, 130, 0, 49)
  40. towerspawn.Font = Enum.Font.Cartoon
  41. towerspawn.FontSize = Enum.FontSize.Size14
  42. towerspawn.Text = "Spawn Tower"
  43. towerspawn.TextSize = 14
  44.  
  45. player.Name = "player"
  46. player.Parent = Frame
  47. player.BackgroundColor3 = Color3.new(1, 1, 1)
  48. player.BackgroundTransparency = 0.5
  49. player.BorderSizePixel = 0
  50. player.Position = UDim2.new(0.0750798732, 0, 0.424999982, 0)
  51. player.Size = UDim2.new(0, 117, 0, 39)
  52. player.Font = Enum.Font.Cartoon
  53. player.FontSize = Enum.FontSize.Size14
  54. player.Text = "Player Name"
  55. player.TextSize = 14
  56.  
  57. tower.Name = "tower"
  58. tower.Parent = Frame
  59. tower.BackgroundColor3 = Color3.new(1, 1, 1)
  60. tower.BackgroundTransparency = 0.5
  61. tower.BorderSizePixel = 0
  62. tower.Position = UDim2.new(0.546325862, 0, 0.424999982, 0)
  63. tower.Size = UDim2.new(0, 117, 0, 39)
  64. tower.Font = Enum.Font.Cartoon
  65. tower.FontSize = Enum.FontSize.Size14
  66. tower.Text = "Tower Name"
  67. tower.TextSize = 14
  68.  
  69. credits.Name = "credits"
  70. credits.Parent = Frame
  71. credits.BackgroundColor3 = Color3.new(1, 1, 1)
  72. credits.BackgroundTransparency = 1
  73. credits.Position = UDim2.new(0.115015969, 0, 0.911538422, 0)
  74. credits.Size = UDim2.new(0, 147, 0, 23)
  75. credits.Font = Enum.Font.Cartoon
  76. credits.FontSize = Enum.FontSize.Size14
  77. credits.Text = "Made by Lau#0114 & Jethrootje#0289"
  78. credits.TextSize = 14
  79.  
  80. towerspawn.MouseButton1Click:connect(function()
  81. game.Workspace.PlacingTower:InvokeServer(tower.text, -25222220)
  82. end)
  83. upgrade.MouseButton1Click:connect(function()
  84. local ws = workspace
  85. local plr = game:GetService('Players')[player.Text]
  86. for i,v in pairs(ws.Towers:GetChildren()) do
  87. if v.Owner.Value == plr and v.Tower.UP1.Value < 4 then
  88. repeat
  89. workspace.HasEnough:InvokeServer('Cash',0)
  90. workspace.Spend:InvokeServer(0)
  91. workspace.UpgradeTower:InvokeServer(v.Name,0)
  92. until v.Tower.UP1.Value >= 4
  93. end
  94. end
  95. end)
  96.  
  97.  
  98. local ScreenGui = Instance.new("ScreenGui")
  99. local TextBox = Instance.new("TextBox")
  100. ScreenGui.Parent = game.CoreGui
  101. TextBox.Archivable = false
  102. TextBox.Parent = ScreenGui
  103. TextBox.BackgroundColor3 = Color3.new(1, 1, 1)
  104. TextBox.BackgroundTransparency = 0.5
  105. TextBox.BorderSizePixel = 3
  106. TextBox.Draggable = true
  107. TextBox.Position = UDim2.new(0.834854007, 0, 0.222868219, 0)
  108. TextBox.Selectable = false
  109. TextBox.Size = UDim2.new(0, 175, 0, 237)
  110. TextBox.ClearTextOnFocus = false
  111. TextBox.Font = Enum.Font.Cartoon
  112. TextBox.FontSize = Enum.FontSize.Size14
  113. TextBox.ShowNativeInput = false
  114. TextBox.Text = "Scout 250\nSniper 450\nFragger 350\nShotgunner 400\nCryo-Gunner 200\nFarm 300\nSoldier 450\nTuber 850\nPatrol 400\nAviator 825\nFlamethrower 750\nCommando 1850\nCommander 600\nRailgunner 2450\nPhaser 3200\nScarecrow 300"
  115. TextBox.TextSize = 14
  116. TextBox:TweenPosition(UDim2.new(0.835,-100,0.5,-100), 'Out', 'Bounce', 1)
Add Comment
Please, Sign In to add comment