Advertisement
Dark_AJ1

fun time

Jan 25th, 2019
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 24.63 KB | None | 0 0
  1. --https://github.com/Mokiros/roblox-FE-compatibility
  2. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  3. local Player,game,owner = owner,game
  4. local RealPlayer = Player
  5. do
  6. print("FE Compatibility code V2 by Mokiros")
  7. local RealPlayer = RealPlayer
  8. script.Parent = RealPlayer.Character
  9.  
  10. --Fake event to make stuff like Mouse.KeyDown work
  11. local Disconnect_Function = function(this)
  12. this[1].Functions[this[2]] = nil
  13. end
  14. local Disconnect_Metatable = {__index={disconnect=Disconnect_Function,Disconnect=Disconnect_Function}}
  15. local FakeEvent_Metatable = {__index={
  16. Connect = function(this,f)
  17. local i = tostring(math.random(0,10000))
  18. while this.Functions[i] do
  19. i = tostring(math.random(0,10000))
  20. end
  21. this.Functions[i] = f
  22. return setmetatable({this,i},Disconnect_Metatable)
  23. end
  24. }}
  25. FakeEvent_Metatable.__index.connect = FakeEvent_Metatable.__index.Connect
  26. local function fakeEvent()
  27. return setmetatable({Functions={}},FakeEvent_Metatable)
  28. end
  29.  
  30. --Creating fake input objects with fake variables
  31. local FakeMouse = {Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
  32. FakeMouse.keyUp = FakeMouse.KeyUp
  33. FakeMouse.keyDown = FakeMouse.KeyDown
  34. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  35. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  36. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  37. end}
  38. --Merged 2 functions into one by checking amount of arguments
  39. CAS.UnbindAction = CAS.BindAction
  40.  
  41. --This function will trigger the events that have been :Connect()'ed
  42. local function TriggerEvent(self,ev,...)
  43. for _,f in pairs(self[ev].Functions) do
  44. f(...)
  45. end
  46. end
  47. FakeMouse.TriggerEvent = TriggerEvent
  48. UIS.TriggerEvent = TriggerEvent
  49.  
  50. --Client communication
  51. local Event = Instance.new("RemoteEvent")
  52. Event.Name = "UserInput_Event"
  53. Event.OnServerEvent:Connect(function(plr,io)
  54. if plr~=RealPlayer then return end
  55. FakeMouse.Target = io.Target
  56. FakeMouse.Hit = io.Hit
  57. if not io.isMouse then
  58. local b = io.UserInputState == Enum.UserInputState.Begin
  59. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  60. return FakeMouse:TriggerEvent(b and "Button1Down" or "Button1Up")
  61. end
  62. if io.UserInputType == Enum.UserInputType.MouseButton2 then
  63. return FakeMouse:TriggerEvent(b and "Button2Down" or "Button2Up")
  64. end
  65. for _,t in pairs(CAS.Actions) do
  66. for _,k in pairs(t.Keys) do
  67. if k==io.KeyCode then
  68. t.Function(t.Name,io.UserInputState,io)
  69. end
  70. end
  71. end
  72. FakeMouse:TriggerEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  73. UIS:TriggerEvent(b and "InputBegan" or "InputEnded",io,false)
  74. end
  75. end)
  76. Event.Parent = NLS([==[local Event = script:WaitForChild("UserInput_Event")
  77. local Mouse = owner:GetMouse()
  78. local UIS = game:GetService("UserInputService")
  79. local input = function(io,RobloxHandled)
  80. if RobloxHandled then return end
  81. --Since InputObject is a client-side instance, we create and pass table instead
  82. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
  83. end
  84. UIS.InputBegan:Connect(input)
  85. UIS.InputEnded:Connect(input)
  86.  
  87. local h,t
  88. --Give the server mouse data every second frame, but only if the values changed
  89. --If player is not moving their mouse, client won't fire events
  90. local HB = game:GetService("RunService").Heartbeat
  91. while true do
  92. if h~=Mouse.Hit or t~=Mouse.Target then
  93. h,t=Mouse.Hit,Mouse.Target
  94. Event:FireServer({isMouse=true,Target=t,Hit=h})
  95. end
  96. --Wait 2 frames
  97. for i=1,2 do
  98. HB:Wait()
  99. end
  100. end]==],script)
  101.  
  102. ----Sandboxed game object that allows the usage of client-side methods and services
  103. --Real game object
  104. local RealGame = game
  105.  
  106. --Metatable for fake service
  107. local FakeService_Metatable = {
  108. __index = function(self,k)
  109. local s = rawget(self,"_RealService")
  110. if s then
  111. return typeof(s[k])=="function"
  112. and function(_,...)return s[k](s,...)end or s[k]
  113. end
  114. end,
  115. __newindex = function(self,k,v)
  116. local s = rawget(self,"_RealService")
  117. if s then s[k]=v end
  118. end
  119. }
  120. local function FakeService(t,RealService)
  121. t._RealService = typeof(RealService)=="string" and RealGame:GetService(RealService) or RealService
  122. return setmetatable(t,FakeService_Metatable)
  123. end
  124.  
  125. --Fake game object
  126. local FakeGame = {
  127. GetService = function(self,s)
  128. return rawget(self,s) or RealGame:GetService(s)
  129. end,
  130. Players = FakeService({
  131. LocalPlayer = FakeService({GetMouse=function(self)return FakeMouse end},Player)
  132. },"Players"),
  133. UserInputService = FakeService(UIS,"UserInputService"),
  134. ContextActionService = FakeService(CAS,"ContextActionService"),
  135. RunService = FakeService({
  136. _btrs = {},
  137. RenderStepped = RealGame:GetService("RunService").Heartbeat,
  138. BindToRenderStep = function(self,name,_,fun)
  139. self._btrs[name] = self.Heartbeat:Connect(fun)
  140. end,
  141. UnbindFromRenderStep = function(self,name)
  142. self._btrs[name]:Disconnect()
  143. end,
  144. },"RunService")
  145. }
  146. rawset(FakeGame.Players,"localPlayer",FakeGame.Players.LocalPlayer)
  147. FakeGame.service = FakeGame.GetService
  148. FakeService(FakeGame,game)
  149. --Changing owner to fake player object to support owner:GetMouse()
  150. game,owner = FakeGame,FakeGame.Players.LocalPlayer
  151. end
  152. --------------------------This is an Official script from Duelist--------------------------
  153. ---{-------------------- -------------------}---
  154. ---{-------------------- / \ -------------------}---
  155. ---{-------------------- II -------------------}---
  156. ---{-------------------- II -------------------}---
  157. ---{-------------------- II -------------------}---
  158. ---{-------------------- A========A -------------------}---
  159. ---{-------------------- II -------------------}---
  160. ---{-------------------- II -------------------}---
  161. ---{-------------------- W -------------------}---
  162. --------------------------------------------------------------------------------------------------------------
  163. local plr = game.Players.LocalPlayer
  164. local chr = plr.Character
  165. local maus = plr:GetMouse()
  166. local PGui=plr.PlayerGui
  167. local lleg = chr["Left Leg"]
  168. local rleg = chr["Right Leg"]
  169. local larm = chr["Left Arm"]
  170. local rarm = chr["Right Arm"]
  171. local hed = chr.Head
  172. local rutprt = chr.HumanoidRootPart
  173. local torso = chr.Torso
  174. local otheranims=false
  175. local armmovement=false
  176. local toss=false
  177. local jamp=false
  178. chr.Animate.Disabled=true
  179. local running=false
  180. local tek=0
  181. local ltdb=false
  182. local surfing=true
  183. local rising=false
  184. local cloudanim='Regular'
  185. local dnc=false
  186. local fldb={['w']=false,['a']=false,['s']=false,['d']=false}
  187. local TotalRate=10
  188. local trcolor = {"Cyan","Deep blue","Really blue","Medium blue"}
  189. clepz = {"138151785","131396502","152626854"}
  190.  
  191. coroutine.resume(coroutine.create(function()
  192. for i,x in pairs(chr:GetChildren()) do if x:IsA('Part') then x.Material='SmoothPlastic' elseif x:IsA('Hat') then x.Handle.Material='SmoothPlastic' end end end))
  193.  
  194.  
  195.  
  196.  
  197.  
  198. chr.Humanoid.WalkSpeed=25
  199.  
  200.  
  201. function Lerp(a, b, i)
  202. local com1 = {a.X, a.Y, a.Z, a:toEulerAnglesXYZ()}
  203. local com2 = {b.X, b.Y, b.Z, b:toEulerAnglesXYZ()}
  204. local calx = com1[1] + (com2[1] - com1[1]) * i
  205. local caly = com1[2] + (com2[2] - com1[2]) * i
  206. local calz = com1[3] + (com2[3] - com1[3]) * i
  207. local cala = com1[4] + (com2[4] - com1[4]) * i
  208. local calb = com1[5] + (com2[5] - com1[5]) * i
  209. local calc = com1[6] + (com2[6] - com1[6]) * i
  210. return CFrame.new(calx, caly, calz) * CFrame.Angles(cala, calb, calc)
  211. end
  212.  
  213. function TwnSingleNumber(s,f,m)
  214. local wot=s+(f-s)*m
  215. return wot
  216. end
  217.  
  218. function TwnVector3(q,w,e)
  219. local begin={q.x,q.y,q.z}
  220. local ending={w.x,w.y,w.z}
  221. local bgx=begin[1]+(ending[1]-begin[1])*e
  222. local bgy=begin[2]+(ending[2]-begin[2])*e
  223. local bgz=begin[3]+(ending[3]-begin[3])*e
  224. return Vector3.new(bgx,bgy,bgz)
  225. end
  226.  
  227. newWeld = function(wld, wp0, wp1, wc0x, wc0y, wc0z)
  228. wld = Instance.new("Weld", wp1)
  229. wld.Part0 = wp0
  230. wld.Part1 = wp1
  231. wld.C0 = CFrame.new(wc0x, wc0y, wc0z)
  232. end
  233.  
  234. newWeld(law, torso, larm, -1.5, 0.5, 0)
  235. newWeld(raw, torso, rarm, 1.5, 0.5, 0)
  236. newWeld(llw, torso, lleg, -.5, -2, 0)
  237. newWeld(rlw, torso, rleg, .5, -2, 0)
  238. newWeld(hw, torso, hed, 0, 1.5, 0)
  239. local rutwald=Instance.new('Weld',rutprt)
  240. rutwald.Part0=rutprt
  241. rutwald.Part1=torso
  242. rutwald.Name="RootJoint"
  243. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(10),math.rad(180),0)
  244. larm.Weld.C1 = CFrame.new(0, 0.5, 0)
  245. rarm.Weld.C1 = CFrame.new(0, 0.5, 0)
  246. rleg.Weld.C1=CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),0,0)
  247. lleg.Weld.C1=CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),0,0)
  248.  
  249. local anim = "Idling"
  250. local lastanim = "Idling"
  251. local val = 0
  252. local syne = 0
  253. local num = 0
  254. local runtime = 0
  255.  
  256. local claud=Instance.new('Part',chr)
  257. claud.CanCollide=false
  258. claud.Anchored=false
  259. claud.Name='Claud'
  260. claud.formFactor='Custom'
  261. claud.Locked=true
  262. claud.Material='SmoothPlastic'
  263. claud.BrickColor=BrickColor.new('Light stone grey')
  264. claud.TopSurface=10
  265. claud.BottomSurface=10
  266. claud.LeftSurface=10
  267. claud.RightSurface=10
  268. claud.FrontSurface=10
  269. claud.BackSurface=10
  270. claud:breakJoints()
  271. local emit=Instance.new("ParticleEmitter",claud)
  272. emit.Lifetime=NumberRange.new(1,2)
  273. emit.RotSpeed=NumberRange.new(3,6)
  274. emit.Name='claudmitterpls'
  275. emit.Acceleration=Vector3.new(math.random(-50,50)*.01,1,math.random(-50,50)*.01)
  276. emit.Size=NumberSequence.new(.5,1)
  277. emit.Transparency=NumberSequence.new(1)
  278. emit.Texture="http://www.roblox.com/asset?id=241541739"
  279. local clms=Instance.new('SpecialMesh',claud)
  280. clms.MeshId="http://www.roblox.com/asset/?id=1095708"
  281. clms.TextureId="http://www.roblox.com/asset/?id=298752372"
  282. clms.Scale=Vector3.new(7,2.5,6)
  283. local clwl=Instance.new('Weld',claud)
  284. clwl.Part0=rutprt
  285. clwl.Part1=claud
  286. clwl.C0=CFrame.new(0,0,.85)*CFrame.Angles(math.rad(100),math.rad(90),0)
  287.  
  288.  
  289. maus.KeyUp:connect(function(kei)
  290. if string.byte(kei)==48 and not otheranims then
  291. if surfing then
  292. chr.Humanoid.WalkSpeed=40
  293. elseif not surfing then
  294. chr.Humanoid.WalkSpeed=25
  295. end
  296. end
  297. if kei=='e' then
  298. floating=false
  299. end
  300. if kei=='q' then
  301. lowering=false
  302. end
  303. if kei=='w' then fldb.w=false end
  304. if kei=='a' then fldb.a=false end
  305. if kei=='s' then fldb.s=false end
  306. if kei=='d' then fldb.d=false end
  307. end)
  308.  
  309. chr.Humanoid.Changed:connect(function(c)
  310. if c=='Jump' then
  311. if otheranims or not surfing then
  312. chr.Humanoid.Jump=false
  313. end
  314. end
  315. end)
  316.  
  317. DrawLightning = function(Start,End,Times,Offset,Color,Thickness)
  318. if Start.y>End.y then
  319. local magz = (Start - End).magnitude
  320. local curpos = Start
  321. local trz = {-Offset,Offset}
  322. for i=1,Times do
  323. local li = Instance.new("Part",workspace)
  324. li.TopSurface =10
  325. li.BottomSurface = 10
  326. li.Anchored = true
  327. li.Transparency = 0
  328. li.BrickColor = Color
  329. li.formFactor = "Custom"
  330. li.CanCollide = false
  331. li.Size = Vector3.new(Thickness,Thickness,magz/Times)
  332. local lt=Instance.new("SpotLight",li)
  333. lt.Range=16
  334. lt.Brightness=5
  335. lt.Shadows=true
  336. lt.Angle=45
  337. lt.Face="Top"
  338. lt.Color=li.BrickColor.Color
  339. local ofz = Vector3.new(trz[math.random(1,2)],trz[math.random(1,2)],trz[math.random(1,2)])
  340. local trolpos = CFrame.new(curpos,End)*CFrame.new(0,0,magz/Times).p+ofz
  341. if Times == i then
  342. local magz2 = (curpos - End).magnitude
  343. li.Size = Vector3.new(Thickness,Thickness,magz2)
  344. li.CFrame = CFrame.new(curpos,End)*CFrame.new(0,0,-magz2/2)
  345. else
  346. li.CFrame = CFrame.new(curpos,trolpos)*CFrame.new(0,0,magz/Times/2)
  347. end
  348. curpos = li.CFrame*CFrame.new(0,0,magz/Times/2).p Spawn(function() for i=1,5 do wait() li.Transparency = li.Transparency+.2 end li:Destroy() end)
  349. end
  350. for i,x in pairs(workspace:GetChildren()) do if x:IsA'Model' and x:findFirstChild('Torso') and x:findFirstChild('Head') and x~=chr then
  351. for a,v in pairs(x:GetChildren()) do if v:IsA'Humanoid' then if (x.Torso.CFrame.p-End).magnitude<10 then v.Health=v.Health-30 end end end end end
  352. local so=Instance.new('Sound',claud)
  353. so.SoundId="http://www.roblox.com/asset?id="..clepz[math.random(1,#clepz)]
  354. so.Volume=.2
  355. so:Play''
  356. end
  357. end
  358.  
  359. maus.KeyDown:connect(function(kei)
  360. if string.byte(kei)==48 and not otheranims then
  361. if surfing then
  362. chr.Humanoid.WalkSpeed=80
  363. elseif not surfing then
  364. chr.Humanoid.WalkSpeed=50
  365. end
  366. end
  367. if kei=='r' then
  368. if torso:findFirstChild('CedarClaudVelo') then
  369. torso['CedarClaudVelo']:Destroy()
  370. else
  371. local veloo=Instance.new('BodyVelocity',torso)
  372. veloo.Name='CedarClaudVelo'
  373. veloo.maxForce=Vector3.new(0,math.huge,0)
  374. end
  375. end
  376. if kei=='w' then fldb.w=true end
  377. if kei=='a' then fldb.a=true end
  378. if kei=='s' then fldb.s=true end
  379. if kei=='d' then fldb.d=true end
  380. if kei=='x' then
  381. if not surfing then surfing=true
  382. chr.Humanoid.WalkSpeed=40
  383. elseif surfing then surfing=false
  384. chr.Humanoid.WalkSpeed=25
  385. end
  386. end
  387. if kei=='e' and not floating and not lowering and surfing then
  388. floating=true
  389. end
  390. if kei=='q' and not lowering and not floating and surfing then
  391. lowering=true
  392. end
  393. if kei=='f' and not otheranims and surfing then
  394. dnc=true
  395. anim='Dance'
  396. end
  397. end)
  398.  
  399. maus.Button1Down:connect(function()
  400. if not otheranims and surfing and not ltdb and (torso.CFrame.p-maus.Hit.p).magnitude<100 then
  401. ltdb=true
  402. DrawLightning(claud.CFrame.p,maus.Hit.p,5,.5,BrickColor.new("New Yeller"),.2)
  403. wait()
  404. ltdb=false
  405. end
  406. end)
  407.  
  408. plr.Chatted:connect(function(m)
  409. if m:lower():sub(1,3)=='/e ' then m=m:sub(4)
  410. if m:lower():sub(1,5)=='dance' and not otheranims and surfing then
  411. dnc=true
  412. anim='Dance'
  413. end
  414. end
  415. end)
  416.  
  417. game:service'RunService'.RenderStepped:connect(function()
  418.  
  419. if fldb.w or fldb.a or fldb.s or fldb.d then
  420. nerrrk=chr.Humanoid.WalkSpeed
  421. TotalRate=10
  422. else
  423. TotalRate=0
  424. nerrrk=0
  425. end
  426. chr.Humanoid.CameraOffset=(rutprt.CFrame:toObjectSpace(hed.CFrame)).p+Vector3.new(0,-1.25,0)
  427. syne=syne+.95
  428. if not otheranims then
  429. if (torso.Velocity*Vector3.new(1, 0, 1)).magnitude < 1 and torso.Velocity.y<1 and torso.Velocity.y>-1 and not dnc then
  430. anim="Idling"
  431. puffing=false
  432.  
  433. elseif (rutprt.Velocity*Vector3.new(1, 0, 1)).magnitude > 1 and (rutprt.Velocity*Vector3.new(1, 0, 1)).magnitude < 43 and torso.Velocity.y<1 and torso.Velocity.y>-1 then
  434. anim="Walking"
  435. puffing=true
  436. dnc=false
  437.  
  438. elseif (torso.Velocity*Vector3.new(1, 0, 1)).magnitude > 43 and torso.Velocity.y<1 and torso.Velocity.y>-1 then
  439. anim="Sprinting"
  440. puffing=true
  441. dnc=false
  442.  
  443. elseif torso.Velocity.y>1 and surfing then
  444. anim='Jumping'
  445. puffing=true
  446. dnc=false
  447.  
  448. elseif (torso.Velocity.y < -1) and surfing then
  449. anim='Falling'
  450. puffing=true
  451. dnc=false
  452. end
  453. end
  454.  
  455. if torso:findFirstChild('CedarClaudVelo') then
  456. if floating and surfing then
  457. torso['CedarClaudVelo'].velocity=((rutprt.CFrame*CFrame.new(0,0,-1)).p-rutprt.CFrame.p).unit*nerrrk+Vector3.new(0,30,0)
  458. elseif lowering and surfing then
  459. torso['CedarClaudVelo'].velocity=((rutprt.CFrame*CFrame.new(0,0,-1)).p-rutprt.CFrame.p).unit*nerrrk+Vector3.new(0,-30,0)
  460. else
  461. torso['CedarClaudVelo'].velocity=((rutprt.CFrame*CFrame.new(0,0,-1)).p-rutprt.CFrame.p).unit*nerrrk
  462. end
  463. end
  464.  
  465. if anim=='Idling' and not surfing then
  466. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(.9,1,0)*CFrame.Angles(math.rad(190),math.rad(0),math.rad(-40)),.1)
  467. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-.9,1,0)*CFrame.Angles(math.rad(190),math.rad(-0),math.rad(40)),.1)
  468. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(0,1.45,-.4)*CFrame.Angles(math.rad(-38),0,0),.1)
  469. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.4,-1.7,-.3)*CFrame.Angles(math.rad(15),0,math.rad(-5)),.1)
  470. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.32,-1.9,.1)*CFrame.Angles(math.rad(-5),0,math.rad(10)),.1)
  471. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(0,math.cos(syne/30)/3,0)*CFrame.Angles(math.rad(90),math.rad(180),0),.1)
  472. clwl.C0=Lerp(clwl.C0,CFrame.new(0,math.cos(syne/30)/3+2.25,.5)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(-2.5)),.15)
  473. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(10),math.rad(180),0)
  474. end
  475. if anim=='Walking' and not surfing then
  476. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(1.3,.55,.2)*CFrame.Angles(math.rad(290),math.rad(0),math.rad(-10)),.15)
  477. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-1.3,.55,.2)*CFrame.Angles(math.rad(290),math.rad(-0),math.rad(10)),.15)
  478. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(0,1.45,-.4)*CFrame.Angles(math.rad(-38),0,0),.15)
  479. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.675,-1.8,-.6)*CFrame.Angles(math.rad(40),0,math.rad(10)),.15)
  480. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.675,-1.8,-.6)*CFrame.Angles(math.rad(40),0,math.rad(-10)),.15)
  481. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(0,math.cos(syne/30)/3+1,2.625)*CFrame.Angles(math.rad(50),math.rad(180),0),.15)
  482. clwl.C0=Lerp(clwl.C0,CFrame.new(0,math.cos(syne/30)/3+2.25,.5)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(-5)),.15)
  483. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(10),math.rad(180),0)
  484. end
  485. if anim=='Sprinting' and not surfing then
  486. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(1.3,.5,.15)*CFrame.Angles(math.rad(290),math.rad(0),math.rad(-10)),.15)
  487. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-1.3,.5,.15)*CFrame.Angles(math.rad(290),math.rad(-0),math.rad(10)),.15)
  488. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(0,1.45,-.4)*CFrame.Angles(math.rad(-28),0,0),.15)
  489. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.575,-1.3,-.6)*CFrame.Angles(math.rad(20),0,math.rad(5)),.15)
  490. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.575,-1.3,-.6)*CFrame.Angles(math.rad(20),0,math.rad(-5)),.15)
  491. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(0,math.cos(syne/30)/3+1,2.625)*CFrame.Angles(math.rad(40),math.rad(180),0),.15)
  492. clwl.C0=Lerp(clwl.C0,CFrame.new(0,math.cos(syne/30)/3+2.25,.6)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(-10)),.15)
  493. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(10),math.rad(180),0)
  494. end
  495. if anim=='Idling' and surfing then
  496. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(1.45,.5,0)*CFrame.Angles(math.cos(syne/30)/10,math.rad(0),math.rad(12.5)),.1)
  497. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-1.25,.4,0)*CFrame.Angles(math.cos(syne/30)/10*-1,math.rad(-0),math.rad(-15)),.1)
  498. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(-.15,1.45,0)*CFrame.Angles(math.rad(0),math.rad(85),math.rad(0)),.1)
  499. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.575,-1.9,0)*CFrame.Angles(math.rad(0),0,math.rad(5)),.1)
  500. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.575,-1.9,0)*CFrame.Angles(math.rad(0),0,math.rad(-5)),.1)
  501. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(-3,math.cos(syne/30)/3+4.4,0)*CFrame.Angles(math.rad(0),math.rad(90),0),.1)
  502. clwl.C0=Lerp(clwl.C0,CFrame.new(0,math.cos(syne/30)/3+2.25,-.25)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(-2)),.15)
  503. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(0),math.rad(180),0)
  504. end
  505. if anim=='Walking' and surfing then
  506. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(1.25,.5,0)*CFrame.Angles(math.cos(syne/30)/10,math.rad(0),math.rad(25)),.15)
  507. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-1.25,.4,0)*CFrame.Angles(math.cos(syne/30)/10*-1,math.rad(-0),math.rad(-20)),.15)
  508. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(-.15,1.45,0)*CFrame.Angles(math.rad(0),math.rad(89),math.rad(0)),.15)
  509. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.575,-1.9,0)*CFrame.Angles(math.rad(0),0,math.rad(5)),.15)
  510. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.615,-1.55,-.1)*CFrame.Angles(math.rad(0),0,math.rad(-5)),.15)
  511. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(-3,math.cos(syne/30)/3+4.4,-.25)*CFrame.Angles(math.rad(-5),math.rad(90),0),.15)
  512. clwl.C0=Lerp(clwl.C0,CFrame.new(0,math.cos(syne/30)/3+2.5,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(5)),.15)
  513. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(0),math.rad(180),0)
  514. end
  515. if anim=='Sprinting' and surfing then
  516. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(1.25,.5,0)*CFrame.Angles(math.cos(syne/30)/10,math.rad(0),math.rad(40)),.15)
  517. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-1.25,.4,0)*CFrame.Angles(math.cos(syne/30)/10*-1,math.rad(-30),math.rad(-20)),.15)
  518. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(-.25,1.45,0)*CFrame.Angles(math.rad(0),math.rad(89),math.rad(0)),.15)
  519. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.575,-1.9,0)*CFrame.Angles(math.rad(0),0,math.rad(5)),.15)
  520. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.725,-1.3,-.1)*CFrame.Angles(math.rad(0),0,math.rad(-10)),.15)
  521. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(-3,math.cos(syne/30)/3+2.4,-.5)*CFrame.Angles(math.rad(-15),math.rad(90),0),.15)
  522. clwl.C0=Lerp(clwl.C0,CFrame.new(0,math.cos(syne/30)/3+.5,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(10)),.15)
  523. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(0),math.rad(180),0)
  524. end
  525. if anim=='Jumping' and surfing then
  526. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(1.375,.5,0)*CFrame.Angles(0,math.rad(5),math.rad(48)),.15)
  527. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-1.25,.4,0)*CFrame.Angles(0,math.rad(-20),math.rad(-35)),.15)
  528. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(-.25,1.45,0)*CFrame.Angles(math.rad(0),math.rad(89),math.rad(0)),.15)
  529. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.575,-1.9,0)*CFrame.Angles(math.rad(0),0,math.rad(5)),.15)
  530. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.725,-1.2,-.1)*CFrame.Angles(math.rad(0),0,math.rad(-10)),.15)
  531. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(-3,4,0)*CFrame.Angles(math.rad(-30),math.rad(90),0),.15)
  532. clwl.C0=Lerp(clwl.C0,CFrame.new(0,2.5,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(10)),.15)
  533. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(0),math.rad(180),0)
  534. end
  535. if anim=='Falling' and surfing then
  536. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(1.375,.5,0)*CFrame.Angles(0,math.rad(-20),math.rad(30)),.15)
  537. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-1.25,.25,0)*CFrame.Angles(0,math.rad(5),math.rad(-55)),.15)
  538. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(-.25,1.45,0)*CFrame.Angles(math.rad(0),math.rad(89),math.rad(0)),.15)
  539. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.575,-1.2,-.1)*CFrame.Angles(math.rad(0),0,math.rad(5)),.15)
  540. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.725,-1.9,0)*CFrame.Angles(math.rad(0),0,math.rad(-10)),.15)
  541. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(-3,4,-0)*CFrame.Angles(math.rad(15),math.rad(90),0),.15)
  542. clwl.C0=Lerp(clwl.C0,CFrame.new(0,2.5,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(-20)),.15)
  543. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(0),math.rad(180),0)
  544. end
  545. if anim=='Dance' and surfing and dnc then
  546. rarm.Weld.C0=Lerp(rarm.Weld.C0,CFrame.new(1.2,1,0)*CFrame.Angles(math.rad(190),math.rad(0),math.rad(-10)),.1)
  547. larm.Weld.C0=Lerp(larm.Weld.C0,CFrame.new(-1.2,1,0)*CFrame.Angles(math.rad(190),math.rad(-0),math.rad(10)),.1)
  548. hed.Weld.C0=Lerp(hed.Weld.C0,CFrame.new(0,1.45,-.2)*CFrame.Angles(math.rad(-15),0,0),.1)
  549. rleg.Weld.C0=Lerp(rleg.Weld.C0,CFrame.new(.575,-1.9,-.1)*CFrame.Angles(math.rad(5),0,math.rad(5)),.1)
  550. lleg.Weld.C0=Lerp(lleg.Weld.C0,CFrame.new(-.575,-1.9,-.1)*CFrame.Angles(math.rad(5),0,math.rad(-5)),.1)
  551. rutprt.RootJoint.C0=Lerp(rutprt.RootJoint.C0,CFrame.new(0,2.375+math.cos(syne/30)/10,3)*CFrame.Angles(0,math.rad(180),0),.1)
  552. clwl.C0=Lerp(clwl.C0,CFrame.new(0,math.cos(syne/30)/10+5.8,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(0)),.15)
  553. rutprt.RootJoint.C1=CFrame.new(0,-1,3)*CFrame.Angles(math.rad(10),math.rad(180),0)
  554. end
  555.  
  556.  
  557. emit.Rate=TotalRate
  558. if surfing then
  559. claud.BrickColor=BrickColor.new("Black")
  560. clms.VertexColor=TwnVector3(clms.VertexColor,Vector3.new(.1,.1,.1),.075)
  561. else
  562. claud.BrickColor=BrickColor.new("Institutional white")
  563. clms.VertexColor=TwnVector3(clms.VertexColor,Vector3.new(1,1,1),.075)
  564. end
  565.  
  566. if puffing then
  567. tek=tek+1
  568. else
  569. tek=0
  570. end
  571. if tek>=15 then
  572. tek=0
  573. local cl2=Instance.new('Part',Workspace)
  574. local p1=math.random(10,30)*.1
  575. local p2=math.random(40,60)*.1
  576. local p3=math.random(70,90)*.1
  577. cl2.CanCollide=false
  578. cl2.Anchored=true
  579. cl2.Name='Claud'
  580. cl2.formFactor='Custom'
  581. cl2.BrickColor=claud.BrickColor
  582. cl2.TopSurface=10
  583. cl2.BottomSurface=10
  584. cl2.LeftSurface=10
  585. cl2.RightSurface=10
  586. cl2.FrontSurface=10
  587. cl2.BackSurface=10
  588. game:service'Debris':AddItem(cl2,1)
  589. cl2.CFrame=claud.CFrame*CFrame.new(-3.5,0,math.random(-15,15)*.1)*CFrame.Angles(math.rad(0),0,math.rad(90))
  590. local cl2l=Instance.new('PointLight',cl2)
  591. cl2l.Range=8
  592. cl2l.Color=Color3.new(1,1,1)
  593. cl2l.Brightness=123123
  594. local clms2=Instance.new('SpecialMesh',cl2)
  595. clms2.MeshId="http://www.roblox.com/asset/?id=1095708"
  596. clms2.Scale=Vector3.new(1,2,1.5)
  597. coroutine.wrap(function()
  598. for ttt=0,1.05,.1 do cl2.Transparency=ttt cl2.CFrame=cl2.CFrame*CFrame.Angles(math.rad(p1),math.rad(p2),math.rad(p3)) clms2.Scale=clms2.Scale+Vector3.new(.035,.035,.035) cl2l.Range=cl2l.Range-.5 wait()
  599. end
  600. cl2:Destroy()
  601. end)()
  602. end
  603.  
  604. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement