EsTLation

Thing

May 18th, 2019
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.58 KB | None | 0 0
  1. --Made by EssTL if you need help message me on Discord Est#4200, Please dont remove :)
  2.  
  3. local Player = game.Players.LocalPlayer
  4.  
  5. local Mouse = Player:GetMouse()
  6.  
  7. --images--
  8. local Background = script.Parent.Background
  9. local Image = script.Parent.Image
  10. local ButtonClickS = script.Parent["Button Click"]
  11. local DanceGUI = script.Parent.DanceGUI
  12. local GUIPosition = "IN"
  13. local Debounce = true
  14. local Anim
  15. local Buttons = DanceGUI.ScrollingFrame
  16. local SpeedInput = script.Parent.DanceGUI["Animation Speed"]
  17. --images end--
  18.  
  19. game:GetService("UserInputService").InputBegan:connect(function(inputObject,Processed)
  20. if not Processed then
  21. if inputObject.KeyCode == Enum.KeyCode.E then
  22. if GUIPosition == "IN" then
  23. if Debounce == true then
  24. Debounce = false
  25. GUIPosition = "OUT"
  26. Background.ImageColor3 = Color3.fromRGB(130,130,130)
  27. ButtonClickS:Play()
  28. DanceGUI:TweenPosition(UDim2.new(0.918, 0,0.323, 0), "In", "Quad", 0.3, false, nil)
  29. wait(0.5)
  30. Background.ImageColor3 = Color3.fromRGB(95,95,95)
  31. end
  32. else
  33. if Debounce == true then
  34. Debounce = false
  35. GUIPosition = "IN"
  36. Background.ImageColor3 = Color3.fromRGB(130,130,130)
  37. ButtonClickS:Play()
  38. DanceGUI:TweenPosition(UDim2.new(1.2, 0,0.323, 0), "Out", "Quad", 0.3, false, nil)
  39. wait(0.5)
  40. Background.ImageColor3 = Color3.fromRGB(95,95,95)
  41. end
  42. end
  43. wait(1)
  44. Debounce = true
  45. end
  46. end
  47. end)
  48.  
  49. script.Parent.OpenClose.MouseButton1Down:Connect(function()
  50. if GUIPosition == "IN" then
  51. if Debounce == true then
  52. Debounce = false
  53. GUIPosition = "OUT"
  54. Background.ImageColor3 = Color3.fromRGB(130,130,130)
  55. ButtonClickS:Play()
  56. DanceGUI:TweenPosition(UDim2.new(0.918, 0,0.323, 0), "In", "Quad", 0.3, false, nil)
  57. wait(0.5)
  58. Background.ImageColor3 = Color3.fromRGB(95,95,95)
  59. end
  60. else
  61. if Debounce == true then
  62. Debounce = false
  63. GUIPosition = "IN"
  64. Background.ImageColor3 = Color3.fromRGB(130,130,130)
  65. ButtonClickS:Play()
  66. DanceGUI:TweenPosition(UDim2.new(1.2, 0,0.323, 0), "Out", "Quad", 0.3, false, nil)
  67. wait(0.5)
  68. Background.ImageColor3 = Color3.fromRGB(95,95,95)
  69. end
  70. end
  71. wait(1)
  72. Debounce = true
  73. end)
  74.  
  75. --GUI Stuff--
  76. DanceGUI:TweenPosition(UDim2.new(1.2,0,0.323,0), "Out", "Quad", 1, false, nil)
  77. --function
  78. function PlayAnimation(AnimID)
  79. if Player.Character ~= nil and Player.Character.Humanoid ~= nil then
  80. local id = AnimID
  81. local OldAnimation = Player.Character:FindFirstChild("AnimationThing")
  82. if Anim ~= nil then
  83. Anim:Stop()
  84. end
  85. if OldAnimation ~= nil then
  86. if OldAnimation.AnimationId == id then
  87. OldAnimation:Destroy()
  88. return
  89. end
  90. OldAnimation:Destroy()
  91. end
  92. local Animation = Instance.new("Animation",Player.Character)
  93. Animation.Name = "AnimationThing"
  94. Animation.AnimationId=id
  95. Anim = Player.Character.Humanoid:LoadAnimation(Animation)
  96. Anim:Play()
  97. end
  98. end
  99. --function--- ADD NEW ANIMATIONS HERE------
  100. Buttons.Animation1.MouseButton1Down:Connect(function()
  101. PlayAnimation(Buttons.Animation1.Anim.AnimationId)
  102. print("Playing Animation 1")
  103. ButtonClickS:Play()
  104. end)
  105.  
  106. Buttons.Animation2.MouseButton1Down:Connect(function()
  107. PlayAnimation(Buttons.Animation2.Anim.AnimationId)
  108. print("Playing Animation 2")
  109. ButtonClickS:Play()
  110. end)
  111.  
  112. Buttons.Animation3.MouseButton1Down:Connect(function()
  113. PlayAnimation(Buttons.Animation3.Anim.AnimationId)
  114. print("Playing Animation 3")
  115. ButtonClickS:Play()
  116. end)
  117.  
  118. Buttons.Animation4.MouseButton1Down:Connect(function()
  119. PlayAnimation(Buttons.Animation4.Anim.AnimationId)
  120. print("Playing Animation 4")
  121. ButtonClickS:Play()
  122. end)
  123.  
  124. -- animation speed stuff-----
  125.  
  126. SpeedInput.FocusLost:Connect(function(enterPressed)
  127. if enterPressed then
  128. local SpeedNumber = tonumber(SpeedInput.Text)
  129. if SpeedNumber <= 2.5 then
  130. Anim:AdjustSpeed(SpeedNumber)
  131. else
  132. Anim:AdjustSpeed(2.5)
  133. end
  134. end
  135. end)
  136. -- Radio Script Server --
  137. wait(0.3)
  138.  
  139. local Tool = script.Parent
  140. local Handle = Tool:WaitForChild("Handle")
  141. local Remote = script.Parent:WaitForChild("Rad")
  142. local Remote2 = script.Parent:WaitForChild("Rad2")
  143. local Player = script.Parent.Parent.Parent
  144. local Character = Player.Character
  145. local Torso = Character:WaitForChild("Torso")
  146. local Playing = false
  147.  
  148. local db1
  149. local db2
  150.  
  151. local SavedTarget
  152.  
  153. local SprintHit = Instance.new("RemoteEvent", Character)
  154. SprintHit.Name = "SprintAttack"
  155.  
  156. Tool.Unequipped:Connect(function()
  157. if Playing == true then
  158. local Model = Tool.Handle:Clone()
  159. db1 = Model
  160. Model.Parent = Character
  161. local Weld = Instance.new("Weld", Character.Torso)
  162. db2 = Weld
  163. Weld.Part0 = Character.Torso
  164. Weld.Part1 = Model
  165. Weld.C0 = CFrame.new(0,0.3,0.7) * CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(180),320)
  166. Handle.Sound.Volume = 0
  167. end
  168. end)
  169.  
  170. Tool.Equipped:Connect(function()
  171. if db1 then
  172. db1:Destroy()
  173. end
  174. if db2 then
  175. db2:Destroy()
  176. end
  177. Handle.Sound.Volume = 1
  178. end)
  179.  
  180. Sound = script.Parent.Handle.Sound
  181.  
  182. Remote.OnServerEvent:connect(function(Playerr, Mode, ID)
  183. Playing = true
  184. Sound:Stop()
  185. Sound.SoundId = "rbxassetid://"..ID
  186. Sound:Play()
  187. end)
  188.  
  189. Remote2.OnServerEvent:connect(function(Playerr, Mode, ID)
  190. Playing = false
  191. Sound:Stop()
  192. end)
  193. -- Radio Script local --
  194.  
  195. wait(0.3)
  196.  
  197. local tool = script.Parent
  198. local Player = game.Players.LocalPlayer
  199. local Humanoid = Player.Character:WaitForChild("Humanoid")
  200. local RadioGUI = Player.PlayerGui:WaitForChild("Radio")
  201. local ToggleButton = RadioGUI.Frame.Button
  202. local ToggleButton2 = RadioGUI.Frame.Button2
  203. local Input = RadioGUI.Frame.Insert
  204. local Remote = script.Parent:WaitForChild("Rad")
  205. local Remote2 = script.Parent:WaitForChild("Rad2")
  206. local Render = game:GetService("RunService").RenderStepped
  207.  
  208. local Rirea
  209. local Ranim = script.Parent.Handle.a
  210.  
  211. tool.Equipped:Connect(function()
  212. Rirea = Humanoid:LoadAnimation(Ranim)
  213. Rirea.Priority = Enum.AnimationPriority.Action
  214. Rirea:Play()
  215. RadioGUI.Frame.Visible = true
  216. end)
  217.  
  218. tool.Unequipped:Connect(function()
  219. if Rirea then
  220. Rirea:Stop()
  221. end
  222. RadioGUI.Frame.Visible = false
  223. end)
  224.  
  225. ToggleButton.MouseButton1Down:connect(function()
  226. Remote:FireServer("Start", tonumber(Input.Text))
  227. end)
  228.  
  229. ToggleButton2.MouseButton1Down:connect(function()
  230. Remote2:FireServer()
  231. end)
  232.  
  233. Render:Connect(function()
  234. local rb = Player.Character:FindFirstChild("Handle")
  235. if rb then
  236. local m = rb:FindFirstChild("Mesh")
  237. if m then
  238. local n = Player.Character.Handle.Sound.PlaybackLoudness / 70
  239. if n < 3.5 then
  240. n = 3.5
  241. end
  242. if n > 4 then
  243. n = 4.5
  244. end
  245. if n > 6 then
  246. n = 6
  247. end
  248. m.Scale = Vector3.new(n,n,4)
  249. end
  250. end
  251. end)
  252.  
  253. -- i have a lot other things but im to lazy to load them up
Advertisement
Add Comment
Please, Sign In to add comment