wamandnj

Untitled

Jun 12th, 2019
409
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 14.33 KB | None | 0 0
  1. local Plr = owner
  2. local char = owner.Character
  3. local plr = owner
  4.  
  5. -- [[ Color Functions ]] --
  6.  
  7. h = math.random(0, 100)
  8. color = Color3.fromHSV(h / 100, 1, 0.9)
  9. lastbeat = 0
  10. lastloud = 0
  11.  
  12. -- [[ Cone ]] --
  13.  
  14. local cone = Instance.new("Part")
  15. cone.Anchored = true
  16. cone.CanCollide = false
  17. cone.Locked = true
  18. cone.Size = Vector3.new(0.5, 0.5, 0.5)
  19. cone.Parent = char
  20. cone.Transparency = 1
  21.  
  22. local conem = Instance.new("SpecialMesh")
  23. conem.MeshType = Enum.MeshType.FileMesh
  24. conem.MeshId = "rbxassetid://120647846"
  25. conem.Scale = Vector3.new(1, 1, 1)
  26. conem.Parent = cone
  27.  
  28.  
  29. --[[ Particles ]]--
  30.  
  31. local partic = Instance.new("ParticleEmitter")
  32. partic.Rate = 50
  33. partic.EmissionDirection = Enum.NormalId.Right
  34. partic.Texture = "rbxassetid://443789987"
  35. partic.LightEmission = 5
  36. partic.LightInfluence = 1
  37. partic.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0, 0), NumberSequenceKeypoint.new(1, 1)})
  38. partic.Parent = cone
  39.  
  40. --[[ Light ]]--
  41.  
  42. local lite = Instance.new("PointLight")
  43. lite.Range = 0
  44. lite.Brightness = 0
  45. lite.Parent = char.HumanoidRootPart
  46.  
  47. --[[ Sound ]]--
  48.  
  49. local sound = Instance.new("Sound")
  50. sound.Parent = char.HumanoidRootPart
  51. sound.Volume = 10
  52. sound.Name = "Music"
  53. sound.Looped = true
  54.  
  55. plr.Chatted:connect(function(msg)
  56. if msg:sub(1, 6):lower()=='visual' then
  57. local val = Instance.new("NumberValue", char)
  58. val.Value = tonumber(msg:sub(7))
  59. local id = val.Value
  60. sound:Stop()
  61. sound.SoundId = 'rbxassetid://'..id
  62. sound:Play()
  63. sound.Looped = true
  64. wait()
  65. elseif msg:sub(1,5):lower()=='pitch' then
  66. local val2 = Instance.new("NumberValue", char)
  67. val2.Value = tonumber(msg:sub(6))
  68. local Pitch = val2.Value
  69. sound.Pitch = Pitch
  70. elseif msg:sub(1,3):lower()=='vol' then
  71. local val3 = Instance.new("NumberValue", char)
  72. val3.Value = tonumber(msg:sub(5))
  73. local Volume = val3.Value
  74. sound.Volume = Volume
  75. end
  76. end)
  77.  
  78. --[[ Remote ]]--
  79.  
  80. local Remote = Instance.new("RemoteEvent", char)
  81. Remote.Name = "Event"
  82. local PlaybackSound = 0
  83.  
  84. --[[ Visual ]]--
  85.  
  86. local spin = 0
  87.  
  88. Remote.OnServerEvent:connect(function(plr, Playback)
  89.  
  90. spin = spin + 0.08 + Playback/10000
  91.  
  92. local beat = math.abs(PlaybackSound - lastloud)
  93. if beat > lastbeat then
  94. lastbeat = beat
  95. else
  96. lastbeat = lastbeat - 10
  97. if lastbeat < 0 then
  98. lastbeat = 0
  99. end
  100. end
  101.  
  102. h = (h + beat / 250) % 100
  103. lastloud = PlaybackSound
  104. color = Color3.fromHSV(h / 100, 5, 0.5 + lastbeat / 50)
  105.  
  106. lite.Range = 10 + Playback/25
  107. lite.Brightness = 5 + Playback/5
  108. lite.Color = lite.Color:lerp(Color3.fromHSV(h / 100, 1, 1), 0.25)
  109.  
  110. cone.CFrame = cone.CFrame:lerp(char.Head.CFrame * CFrame.new(0, 5, 0) * CFrame.Angles(0, spin, 0), 0.25)
  111. cone.Color = cone.Color:lerp(Color3.fromHSV(h / 100, 1, 1), 0.25)
  112.  
  113. conem.Scale = conem.Scale:lerp(Vector3.new(1 + Playback/250, 1 + Playback/250, 1 + Playback/250), 0.25)
  114.  
  115. partic.Speed = NumberRange.new(5 + Playback/1000)
  116. partic.Lifetime = NumberRange.new(5 + Playback/1000)
  117. partic.Drag = 5 - Playback/50
  118. partic.Size = NumberSequence.new({NumberSequenceKeypoint.new(0, 0 + Playback/1000), NumberSequenceKeypoint.new(1, 0.25 + Playback/1000)})
  119. partic.Color = ColorSequence.new(Color3.fromHSV(h / 100, 1, 1), Color3.fromHSV(h / 100, 1, 1))
  120. partic.RotSpeed = NumberRange.new(0 - sound.PlaybackLoudness/-250, 0 + sound.PlaybackLoudness/250)
  121. partic.SpreadAngle = Vector2.new(0 - sound.PlaybackLoudness/-25, 0 + sound.PlaybackLoudness/25)
  122.  
  123. PlaybackSound = Playback
  124.  
  125. end)
  126.  
  127. --[[ Fire Remote ]]--
  128.  
  129. NLS([==[
  130. while wait() do
  131. game:service'Players'.LocalPlayer.Character.Event:FireServer(game:GetService("Players").LocalPlayer.Character.HumanoidRootPart.Music.PlaybackLoudness)
  132. end
  133. ]==], char)
  134.  
  135. --[[ Debounce ]]--
  136.  
  137. function debounce(func)
  138. local isRunning = false
  139. return function(...)
  140. if not isRunning then
  141. isRunning = true
  142.  
  143. func(...)
  144.  
  145. isRunning = false
  146. end
  147. end
  148. end
  149.  
  150. local BillboardGui = Instance.new("BillboardGui")
  151. local TextLabel = Instance.new("TextLabel")
  152.  
  153. local vol = 1
  154. local song = 0
  155. local pitch = 1
  156. local timepos = nil
  157. local mus = Instance.new("Sound",char)
  158. mus:Destroy()
  159.  
  160. BillboardGui.Name = "tag"
  161. BillboardGui.Parent = char.Head
  162. BillboardGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
  163. BillboardGui.AlwaysOnTop = false
  164. BillboardGui.ExtentsOffset = Vector3.new(0, 3, 0)
  165. BillboardGui.LightInfluence = 1
  166. BillboardGui.Size = UDim2.new(0, 200, 0, 50)
  167.  
  168. TextLabel.Parent = BillboardGui
  169. TextLabel.BackgroundColor3 = Color3.new(0, 0, 0)
  170. TextLabel.BackgroundTransparency = 1
  171. TextLabel.Size = UDim2.new(0, 200, 0, 50)
  172. TextLabel.Font = Enum.Font.SourceSans
  173. TextLabel.Text = ".Tame vis."
  174. TextLabel.TextColor3 = Color3.new(126, 255, 240)
  175. TextLabel.TextScaled = true
  176. TextLabel.TextSize = 14
  177. TextLabel.TextWrapped = true
  178.  
  179.  
  180. local hum = char:FindFirstChildOfClass("Humanoid")
  181. local idleanim = Instance.new("Animation")
  182. idleanim.Name = "Roblox Idle Animation"
  183. idleanim.AnimationId = "http://www.roblox.com/asset/?id=180435571"
  184. local idleanimplay = hum:LoadAnimation(idleanim)
  185. idleanimplay:Play()
  186. wait(0.1)
  187. if char:FindFirstChild("Animate") then
  188. char.Animate:Destroy()
  189. end
  190. local remote = Instance.new("RemoteEvent", char)
  191. remote.Name = "ReplicationEvent"
  192. local client = NLS([==[
  193. local mouse = game:GetService("Players").LocalPlayer:GetMouse()
  194. local remote = game:GetService("Players").LocalPlayer.Character:WaitForChild("ReplicationEvent")
  195. spawn(function()
  196. while game:GetService("RunService").Heartbeat:Wait() do
  197. remote = game:GetService("Players").LocalPlayer.Character:WaitForChild("ReplicationEvent")
  198. end
  199. end)
  200. game:GetService("UserInputService").InputBegan:Connect(function(input, isTyping)
  201. if isTyping == false and input.UserInputType == Enum.UserInputType.Keyboard then
  202. remote:FireServer(1, input.KeyCode)
  203. end
  204. end)
  205.  
  206. mouse.Button1Down:Connect(function()
  207. remote:FireServer(2)
  208. end)
  209.  
  210. ]==], char)
  211.  
  212. local RS = char.Torso["Right Shoulder"]
  213. local LS = char.Torso["Left Shoulder"]
  214. local RH = char.Torso["Right Hip"]
  215. local LH = char.Torso["Left Hip"]
  216. local rootj = char.HumanoidRootPart.RootJoint
  217. local normalanim = true
  218. local animpose = "Idle"
  219. local sine = 0
  220. local RSnor = RS.C0
  221. local LSnor = LS.C0
  222. local RHnor = RH.C0
  223. local LHnor = LH.C0
  224. local rootjnor = rootj.C0
  225. local ff = Instance.new("ForceField",char)
  226. ff.Visible = false
  227.  
  228. ---------------------------------
  229. -----------Wrapping up-----------
  230. ---------------------------------
  231.  
  232. while game:GetService("RunService").Heartbeat:Wait() do
  233. hum.Health = 9999999
  234. hum.MaxHealth = 9999999
  235. hum.PlatformStand = false
  236. hum.Sit = false
  237.  
  238. for i,v in pairs(char:GetChildren()) do
  239. if v.ClassName == "Accessory" then
  240. v.Handle.Anchored = false
  241. end
  242.  
  243. if v.ClassName == "Part" then
  244. v.Anchored = false
  245. end
  246. end
  247.  
  248. if normalanim then
  249. sine = sine + 1
  250. end
  251.  
  252. if remote.Parent == char then
  253. remote.Name = "ReplicationEvent"
  254. else
  255. remote = Instance.new("RemoteEvent", char)
  256. end
  257. TorsoVelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude
  258. Velocity = RootPart.Velocity.y
  259. Sine = Sine + Change
  260. local hit, pos = RayCast(RootPart.Position, (CFrame.new(RootPart.Position, RootPart.Position - Vector3.new(0, 1, 0))).lookVector, 4, Character)
  261. if RootPart.Velocity.y > 1 and hit == nil then
  262. Anim = "Jump"
  263. if Attack == false then
  264. Change = 1
  265. PlayAnimationFromTable({
  266. CFrame.new(0, 0, -0, 1, 0, -0, 0, 0.342019022, -0.939693093, 0, 0.939693093, 0.342018992) * CFrame.new(0, 0, 0 + .5 * math.cos(Sine/35)) * CFrame.Angles(.3 + .005 * math.cos(Sine/35), 0, 0),
  267. CFrame.new(0, 1.4785918, -0.211434767, 1, 0, -0, 0, 0.98480767, 0.173649639, -0, -0.173649669, 0.984807611) * CFrame.new(0, 0, 0) * CFrame.Angles(0 + .05 * math.cos(Sine/35), 0, 0),
  268. CFrame.new(0.939720154, 1.23436928, 0.449271917, 0.866025388, 0.500000238, 0, 0.469846785, -0.81379807, 0.342019022, 0.17100957, -0.296197116, -0.939693093) * CFrame.new(0, 0, 0 - .01 * math.cos(Sine/35)) * CFrame.Angles(0, 0, 0),
  269. CFrame.new(-0.804059327, 1.1624434, 0.431921601, 0.866025269, -0.500000238, -1.92716968e-07, -0.492404282, -0.852868617, 0.173646882, -0.0868236423, -0.150382489, -0.984808087) * CFrame.new(0, 0, 0 - .01 * math.cos(Sine/35)) * CFrame.Angles(0, 0, 0),
  270. CFrame.new(0.662806809, -1.42266583, -0.425317377, 0.999114633, -0.0274195503, -0.0319078304, 0.0249254964, 0.996788979, -0.0760965645, 0.0338919051, 0.0752338469, 0.996589839) * CFrame.new(0, 0, 0 - .1 * math.cos(Sine/40)) * CFrame.Angles(0 + .1 * math.cos(Sine/40), 0, 0),
  271. CFrame.new(-0.358216971, -1.62964225, 0.259462059, 0.999541879, -0.0301539842, 0.0025981334, 0.0127545623, 0.497520745, 0.867358446, -0.027446935, -0.866927922, 0.497677386) * CFrame.new(0, 0, 0 - .2 * math.cos(Sine/35)) * CFrame.Angles(0 + .2 * math.cos(Sine/35), 0, 0),
  272. }, .3, false)
  273. MagnitudeDamage(Torso, aoeconstant, 0, 0, 0, "Normal", " ", .8)
  274. end
  275. elseif RootPart.Velocity.y < -1 and hit == nil then
  276. Anim = "Fall"
  277. if Attack == false then
  278. Change = 1
  279. PlayAnimationFromTable({
  280. CFrame.new(0, 0, -0, 1, 0, -0, 0, 0.342019022, -0.939693093, 0, 0.939693093, 0.342018992) * CFrame.new(0, 0, 0 + .5 * math.cos(Sine/35)) * CFrame.Angles(.3 + .005 * math.cos(Sine/35), 0, 0),
  281. CFrame.new(0, 1.4785918, -0.211434767, 1, 0, -0, 0, 0.98480767, 0.173649639, -0, -0.173649669, 0.984807611) * CFrame.new(0, 0, 0) * CFrame.Angles(0 + .05 * math.cos(Sine/35), 0, 0),
  282. CFrame.new(0.939720154, 1.23436928, 0.449271917, 0.866025388, 0.500000238, 0, 0.469846785, -0.81379807, 0.342019022, 0.17100957, -0.296197116, -0.939693093) * CFrame.new(0, 0, 0 - .01 * math.cos(Sine/35)) * CFrame.Angles(0, 0, 0),
  283. CFrame.new(-0.804059327, 1.1624434, 0.431921601, 0.866025269, -0.500000238, -1.92716968e-07, -0.492404282, -0.852868617, 0.173646882, -0.0868236423, -0.150382489, -0.984808087) * CFrame.new(0, 0, 0 - .01 * math.cos(Sine/35)) * CFrame.Angles(0, 0, 0),
  284. CFrame.new(0.662806809, -1.42266583, -0.425317377, 0.999114633, -0.0274195503, -0.0319078304, 0.0249254964, 0.996788979, -0.0760965645, 0.0338919051, 0.0752338469, 0.996589839) * CFrame.new(0, 0, 0 - .1 * math.cos(Sine/40)) * CFrame.Angles(0 + .1 * math.cos(Sine/40), 0, 0),
  285. CFrame.new(-0.358216971, -1.62964225, 0.259462059, 0.999541879, -0.0301539842, 0.0025981334, 0.0127545623, 0.497520745, 0.867358446, -0.027446935, -0.866927922, 0.497677386) * CFrame.new(0, 0, 0 - .2 * math.cos(Sine/35)) * CFrame.Angles(0 + .2 * math.cos(Sine/35), 0, 0),
  286. }, .3, false)
  287. MagnitudeDamage(Torso, aoeconstant, 0, 0, 0, "Normal", " ", .8)
  288. end
  289. elseif TorsoVelocity < 1 and hit ~= nil then
  290. Anim = "Idle"
  291. if Attack == false then
  292. Change = 1
  293. PlayAnimationFromTable({
  294. CFrame.new(0, 0, -0, 1, 0, -0, 0, 0.342019022, -0.939693093, 0, 0.939693093, 0.342018992) * CFrame.new(0, 0, 0 + .5 * math.cos(Sine/35)) * CFrame.Angles(.3 + .005 * math.cos(Sine/35), 0, 0),
  295. CFrame.new(0, 1.4785918, -0.211434767, 1, 0, -0, 0, 0.98480767, 0.173649639, -0, -0.173649669, 0.984807611) * CFrame.new(0, 0, 0) * CFrame.Angles(0 + .1 * math.cos(Sine/35), 0, 0),
  296. CFrame.new(0.939720154, 1.23436928, 0.449271917, 0.866025388, 0.500000238, 0, 0.469846785, -0.81379807, 0.342019022, 0.17100957, -0.296197116, -0.939693093) * CFrame.new(0, 0, 0 - .01 * math.cos(Sine/35)) * CFrame.Angles(0, 0, 0),
  297. CFrame.new(-0.804059327, 1.1624434, 0.431921601, 0.866025269, -0.500000238, -1.92716968e-07, -0.492404282, -0.852868617, 0.173646882, -0.0868236423, -0.150382489, -0.984808087) * CFrame.new(0, 0, 0 - .01 * math.cos(Sine/35)) * CFrame.Angles(0, 0, 0),
  298. CFrame.new(0.662806809, -1.42266583, -0.425317377, 0.999114633, -0.0274195503, -0.0319078304, 0.0249254964, 0.996788979, -0.0760965645, 0.0338919051, 0.0752338469, 0.996589839) * CFrame.new(0, 0, 0 - .1 * math.cos(Sine/40)) * CFrame.Angles(0 + .1 * math.cos(Sine/40), 0, 0),
  299. CFrame.new(-0.358216971, -1.62964225, 0.259462059, 0.999541879, -0.0301539842, 0.0025981334, 0.0127545623, 0.497520745, 0.867358446, -0.027446935, -0.866927922, 0.497677386) * CFrame.new(0, 0, 0 - .2 * math.cos(Sine/35)) * CFrame.Angles(0 + .2 * math.cos(Sine/35), 0, 0),
  300. }, .3, false)
  301. MagnitudeDamage(Torso, aoeconstant, 0, 0, 0, "Normal", " ", .8)
  302. end
  303. elseif TorsoVelocity > 2 and hit ~= nil then
  304. Anim = "Walk"
  305. if Attack == false then
  306. PlayAnimationFromTable({
  307. CFrame.new(0, 0, -0, 1, 0, -0, 0, 0.342019022, -0.939693093, 0, 0.939693093, 0.342018992) * CFrame.new(0, 0, 0 + .5 * math.cos(Sine/35)) * CFrame.Angles(.3 + .005 * math.cos(Sine/35), 0, 0),
  308. CFrame.new(0, 1.4785918, -0.211434767, 1, 0, -0, 0, 0.98480767, 0.173649639, -0, -0.173649669, 0.984807611) * CFrame.new(0, 0, 0) * CFrame.Angles(0 + .05 * math.cos(Sine/35), 0, 0),
  309. CFrame.new(0.939720154, 1.23436928, 0.449271917, 0.866025388, 0.500000238, 0, 0.469846785, -0.81379807, 0.342019022, 0.17100957, -0.296197116, -0.939693093) * CFrame.new(0, 0, 0 - .01 * math.cos(Sine/35)) * CFrame.Angles(0, 0, 0),
  310. CFrame.new(-0.804059327, 1.1624434, 0.431921601, 0.866025269, -0.500000238, -1.92716968e-07, -0.492404282, -0.852868617, 0.173646882, -0.0868236423, -0.150382489, -0.984808087) * CFrame.new(0, 0, 0 - .01 * math.cos(Sine/35)) * CFrame.Angles(0, 0, 0),
  311. CFrame.new(0.662806809, -1.42266583, -0.425317377, 0.999114633, -0.0274195503, -0.0319078304, 0.0249254964, 0.996788979, -0.0760965645, 0.0338919051, 0.0752338469, 0.996589839) * CFrame.new(0, 0, 0 - .1 * math.cos(Sine/40)) * CFrame.Angles(0 + .1 * math.cos(Sine/40), 0, 0),
  312. CFrame.new(-0.358216971, -1.62964225, 0.259462059, 0.999541879, -0.0301539842, 0.0025981334, 0.0127545623, 0.497520745, 0.867358446, -0.027446935, -0.866927922, 0.497677386) * CFrame.new(0, 0, 0 - .2 * math.cos(Sine/35)) * CFrame.Angles(0 + .2 * math.cos(Sine/35), 0, 0),
  313. }, .3, false)
  314. MagnitudeDamage(Torso, aoeconstant, 0, 0, 0, "Normal", " ", .8)
  315. end
  316. end
  317. if mus.Parent == char then
  318. mus.SoundId = "rbxassetid://"..song
  319. timepos = mus.TimePosition
  320. mus.Pitch = pitch
  321. mus.Volume = vol
  322. else
  323. mus = Instance.new("Sound", char)
  324. mus.Playing = true
  325. mus.Looped = true
  326. mus.TimePosition = timepos
  327. end
  328. end
Add Comment
Please, Sign In to add comment