Advertisement
lafur

Untitled

Nov 6th, 2018
184
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 27.25 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,Mouse,mouse,UserInputService,ContextActionService = owner
  4. local RealPlayer = Player
  5. do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end --[[
  6. This script is made by
  7. _ __ ___ _ _ __ _ _____ __
  8. | '_ ` _ \| | | |/ _` |/ _ \ \/ /
  9. | | | | | | |_| | (_| | __/> <
  10. |_| |_| |_|\__,_|\__, |\___/_/\_\
  11. |___/
  12. ]]
  13. DEBRIS = game:GetService("Debris")
  14. PLAYERS = game:GetService("Players")
  15. INPUT = game:GetService("UserInputService")
  16. RS = game:GetService("RunService")
  17. PI = math.pi
  18. md=math.rad
  19. bcol=BrickColor.new
  20. numkp=NumberSequenceKeypoint.new
  21. mr=math.random
  22.  
  23. base_damage=10
  24. damage=base_damage
  25.  
  26. cfn,v3n=CFrame.new,Vector3.new
  27. ang=function(x,y,z)return CFrame.Angles(x or 0,y or 0,z or 0)end
  28. player = PLAYERS.LocalPlayer
  29. character = player.Character
  30.  
  31. pcall(function()Workspace:FindFirstChild('riimu',true).sidos:Invoke()end)
  32.  
  33. torso = character.Torso
  34. -- shoulder_r = torso['Right Shoulder']
  35. -- shoulder_l = torso['Right Shoulder']
  36. arm_r = character['Right Arm']
  37. arm_l = character['Left Arm']
  38. leg_r = character['Right Leg']
  39. leg_l = character['Left Leg']
  40. root = character['HumanoidRootPart']
  41. root_p=root
  42. root_j = character['HumanoidRootPart']['RootJoint']
  43. neck = torso['Neck']
  44. chum = character:FindFirstChild'Humanoid' or character:FindFirstChild'Nue_was_here'
  45. head=character.Head
  46.  
  47. function isIn(what,tab)
  48. local res=false
  49. for i,v in next,tab do
  50. if v==what then
  51. res = true
  52. break
  53. end
  54. end
  55. return res
  56. end
  57.  
  58. function l(a1,x,y,z,rx,ry,rz)
  59. local cf
  60. if tostring(a1):find(',') == nil then
  61. cf=a1.CFrame
  62. else cf=a1 end
  63. return cf*CFrame.new(x or 0,y or 0,z or 0)*CFrame.Angles(
  64. rx or 0,ry or 0,yz or 0)
  65. end
  66.  
  67. _1,_2,_3,_4,_5,_6=nil,nil,nil,nil,nil,nil
  68.  
  69. New = function(what)
  70. local obj
  71. if type(what) ~= 'string' then
  72. obj=what:Clone()
  73. else
  74. obj=Instance.new(what)
  75. end
  76. return function(bar)
  77. for arg,val in pairs(bar) do
  78. if arg == "_P" then
  79. obj.Parent = val
  80. elseif arg=="_PP" then
  81. obj.Part0=val[1]
  82. obj.Part1=val[2]
  83. elseif arg=='_F'then
  84. val(obj)
  85. else
  86. if pcall(function()return obj[arg] end) then
  87. obj[arg]=val
  88. end
  89. end
  90. end _4=obj
  91. return obj
  92. end
  93. end
  94.  
  95. Edit = function(what)
  96. return function(args)
  97. for ind,obj in next,what do
  98. for arg,val in next,args do
  99. local child,argu = arg:match"(.+)%.(.+)"
  100. if child and argu then
  101. if pcall(function()return obj[child][argu] end) then
  102. -- print'a'
  103. obj[child][argu]=val
  104. end
  105. else
  106. if arg=='_F'then
  107. val(ind,obj)
  108. elseif pcall(function()return obj[arg]end) then
  109. obj[arg]=val
  110. end
  111. end
  112. end
  113. end
  114. end
  115. end
  116.  
  117. function recurseHum(what)
  118. local res
  119. local p=what
  120. if what:IsA'Humanoid'then
  121. res=what
  122. else
  123. repeat
  124. p=p.Parent
  125. if p then
  126. local hum=p:FindFirstChild'Humanoid'
  127. if hum then
  128. res=hum
  129. break
  130. end
  131. end
  132. until p==nil
  133. end
  134. return res
  135. end
  136.  
  137. set_parent,set_material=nil,nil
  138. set_maxvel,set_anchor=nil,nil
  139.  
  140. set_parent,set_color_set_anchor=nil,nil,nil
  141. Part = function(x,y,z,col,tr)
  142. local p = New"Part"{
  143. _P=set_parent or ears or Main;
  144. BrickColor = bcol(col or set_color or "White");
  145. CanCollide = false;
  146. Transparency = tr or 0;
  147. Size = Vector3.new(x or 0,y or 0,z or 0);
  148. Material = set_material or 'SmoothPlastic';
  149. Anchored = (set_anchor~=nil and set_anchor or false)
  150. }
  151. for _,sur in next,Enum.NormalId:GetEnumItems() do
  152. p[sur.Name..'Surface'] = 10
  153. end
  154. _1 = p
  155. return p
  156. end
  157.  
  158. Weld = function(part0,part1,c0,c1,...) --over-engineered welding function which accepts many things
  159. local ar = {...}
  160. local cframe0,cframe1
  161. local function checkf()local res=true
  162. for i,v in pairs(ar)do
  163. if type(v) ~= 'number' then
  164. res=false
  165. end
  166. end
  167. return res
  168. end
  169. if type(c0) == 'table' then
  170. cframe0 = CFrame.new(c0[1] or 0, c0[2] or 0, c0[3] or 0) * CFrame.Angles(
  171. c0[4] or 0, c0[5] or 0, c0[6] or 0)
  172. elseif type(c0) == 'userdata' then
  173. cframe0 = c0
  174. elseif type(c0) == 'number' and checkf() then
  175. cframe0 = CFrame.new(c0 or 0,c1 or 0,ar[1] or 0) * CFrame.Angles(ar[2] or 0, ar[3] or 0, ar[4] or 0)
  176. end
  177. if type(c1) == 'table' then
  178. cframe1 = CFrame.new(c1[1] or 0, c1[2] or 0, c1[3] or 0) * CFrame.Angles(
  179. c1[4] or 0, c1[5] or 0, c1[6] or 0)
  180. elseif type(c1) == 'userdata' then
  181. cframe1 = c1
  182. elseif type(c1) == 'number' and (not c0 or (c0 and type(c0) == 'table')) then
  183. cframe1 = CFrame.new(c1 or 0, ar[1] or 0, ar[2] or 0) * CFrame.Angles(ar[3] or 0, ar[4] or 0, ar[5] or 0)
  184. end
  185. for i,v in pairs(ar)do
  186. if type(v) == 'table' then
  187. cframe1 = CFrame.new(v[1] or 0, v[2] or 0, v[3] or 0) * CFrame.new(v[4] or 0, v[5] or 0, v[6] or 0)
  188. elseif type(v) == 'userdata' then
  189. cframe1 = v
  190. end
  191. end
  192.  
  193. cframe0,cframe1 = cframe1,cframe0
  194. part0.Position=part1.Position
  195. local weld = Instance.new("Motor")
  196. weld.Part0 = part0
  197. weld.Part1 = part1
  198. weld.C0 = cframe0 or CFrame.new()
  199. weld.C1 = cframe1 or CFrame.new()
  200. weld.MaxVelocity = set_maxvel or .1
  201. weld.Parent = part0
  202. _2=weld
  203. return weld
  204. end
  205.  
  206. mesh_ids = {
  207. spikeball = "rbxassetid://24388358";
  208. spike = "rbxassetid://1033714";
  209. ring = "rbxassetid://3270017";
  210. coil = 'rbxassetid://16606212';
  211. diamond = 'rbxassetid://9756362';
  212. rock = 'rbxassetid://1290033';
  213. gear = 'rbxassetid://156292343';
  214. crown = 'rbxassetid://20329976';
  215. orb = 'rbxassetid://34795798';
  216. }
  217. mesh_texs = {
  218. rock = 'rbxassetid://1290030';
  219. }
  220. mesh_scales={
  221. diamond = v3n(0.75, 0.75, 0.75);
  222. spikeball = v3n(1.05, 1.05, 1.05);
  223. spike = v3n(0.5, 1.5, 0.5);
  224. gear = v3n(1.25,1.25,18);
  225. ring = v3n(1, 1, 0.6);
  226. coil = v3n(0.5, 0.5, 0.3);
  227. crown = v3n(0.6, 0.6, 0.6);
  228. orb = v3n(1, 1, 1);
  229. }
  230. mesh_offsets={
  231. crown = v3n(0,.15,0);
  232. }
  233.  
  234. function bindMesh(mesh,Size)
  235. local mesh_name
  236. local size=Size or mesh.Parent.Size
  237. for name,id in next,mesh_ids do
  238. if mesh.MeshId==id then
  239. mesh_name=name
  240. end
  241. end
  242.  
  243. if not mesh_name then return end
  244. local mesh=mesh
  245. local con
  246. con=mesh.Parent.Changed:connect(function()
  247. local siz=mesh.Parent.Size
  248. mesh.Scale=siz*mesh_scales[mesh_name]
  249. if mesh_offsets[mesh_name] then
  250. mesh.Offset=siz*mesh_offsets[mesh_name]
  251. end
  252. end)
  253. return con
  254. end
  255.  
  256. Mesh = function(parent,id,sx,sy,sz)
  257. local name = ( (id == 'cyl' and 'CylinderMesh') or (id == 'bl' and 'BlockMesh') or 'SpecialMesh')
  258. local mesh = Instance.new(name)
  259. if id == 's' then
  260. mesh.MeshType = Enum.MeshType.Sphere
  261. elseif id == 'w' then
  262. mesh.MeshType = Enum.MeshType.Wedge
  263. elseif string.find(id,"://") ~= nil then
  264. mesh.MeshId = id
  265. end
  266. mesh.Scale = Vector3.new(sx or 1, sy or 1, sz or 1)
  267. mesh.Parent = parent
  268. _3=mesh
  269. return mesh
  270. end
  271.  
  272. splat_bg = {
  273. normal='rbxassetid://35376649';
  274. bleed='rbxassetid://151907072';
  275. sleep='rbxassetid://69247215';
  276. wind='rbxassetid://442325811';
  277. }
  278.  
  279. udim=function(a,b,c,d)
  280. if type(a)=='string'then
  281. x,y=tostring(a):match('([%+%d%.%-%/%*]+),([%+%d%.%-%/%*]+)')
  282. return UDim2.new(x or 0,x2 or 0,y or 0,y2 or 0)
  283. else
  284. return UDim2.new(a or 0,c or 0,b or 0,d or 0)
  285. end end
  286.  
  287. pcall(function()character.Mace:Destroy()end)
  288. Main=New"Model"{_P=character;Name='Mace'}
  289.  
  290.  
  291. boolt=.5
  292. addition_func = nil
  293.  
  294. hit_snd = New"Sound"{_P=hdl;SoundId='rbxassetid://166423137'}
  295.  
  296. function findHum(pos,rad,hum2)
  297. local hums={}
  298. function check(a)
  299. local res=false
  300. for i,ho in pairs(hums)do
  301. if a==ho then res=true end
  302. end
  303. return res
  304. end
  305. for i,v in pairs(Workspace:children())do
  306. if v:IsA'Model'and v~=Char and v~=(hum2 or Char) then
  307. for i,q in pairs(v:children())do
  308. if q:IsA'Humanoid' and q.Parent:FindFirstChild'Torso'and(q.Torso.Position-pos).magnitude < rad then
  309. if not check(q)then
  310. table.insert(hums,q)
  311. end
  312. end
  313. end
  314. end
  315. end
  316. return hums
  317. end
  318.  
  319. function checkY(p1,p2,range,range2)
  320. local function checko()
  321. return ( (l(p1).X>l(p2).X-range2 and l(p1).X<l(p2).X+range2) and (l(p1).Z>l(p2).Z-range2 and l(p1).Z<l(p2).Z+range2) )
  322. end
  323. if range2 then
  324. return (l(p1).Y > l(p2).Y-range and l(p2).Y < l(p2).Y+range) and checko()
  325. else
  326. return (l(p1).Y > l(p2).Y-range and l(p2).Y < l(p2).Y+range)
  327. end
  328. end
  329.  
  330. function display_splat(human,text,bgimg,style,speed,height)
  331. local bbg = New"BillboardGui"{_P=Main;Adornee=human.Torso;
  332. Size=udim'2,2';ExtentsOffset=v3n(0,3,0)}
  333. local mfr = New"Frame"{_P=bbg;Size=udim'1,1'}
  334. local image_lab = New"ImageLabel"{_P=mfr;Size=udim'1,1';Image=(bgimg or splat_bg.normal)}
  335. local text_lab = New"TextLabel"{_P=mfr;Size=udim'1,1';Text=text;TextScaled=true;
  336. TextColor3=Color3.new(1,1,1);
  337. }
  338. Edit{mfr,text_lab,image_lab}{BackgroundTransparency=1}
  339. Spawn(function()
  340. if style=='expand' then
  341. mfr:TweenSizeAndPosition(udim'4,4',udim'-2,-3','Out','Quad',speed or 1,false,function()
  342. mfr:Destroy()
  343. end)
  344. else
  345. mfr:TweenPosition(udim(mr(-.25,.25),mr(-.75,-1.25)-(height or 0)),'Out','Quad',speed or 1,false,function()
  346. mfr:Destroy()
  347. end)
  348. end
  349. for i=0,speed or 1,.1 do
  350. Edit{image_lab;text_lab}{ImageTransparency=i;TextTransparency=i}
  351. wait()
  352. end
  353. end)
  354. end
  355. function dodam(hum,amount,...)
  356. hum:TakeDamage(amount)
  357. display_splat(hum,amount,...)
  358. end
  359.  
  360. set_splat_img=nil
  361. function blow(hit,dam,dur,dis_snd,callback,hoo,...)
  362.  
  363. local damage=dam or damage
  364. local f1,f2=tostring(damage):match("(%d+)_(.+)")
  365. damage=f1 or damage
  366. local callback = callback or addition_func or nil
  367. -- if not hit.Parent then return end
  368. local human = hit.Parent:FindFirstChild'Humanoid'
  369. if human and human.Health > 0 and human.Parent~=character and attacking then
  370. local found_tag = human:FindFirstChild'damage_tag'
  371. if not found_tag then
  372. if not dis_snd then
  373. local s=New(hit_snd){_P=human.Torso}s:Play()
  374. end
  375. DEBRIS:AddItem(s,1)
  376. local tag = New"NumberValue"{_P=human;Name='damage_tag';Value=damage}
  377. display_splat(human,f2 or damage,hoo or set_splat_img,...)
  378. if callback ~= nil then callback(human,hit) end
  379. DEBRIS:AddItem(tag,(dur or boolt))
  380. if type(damage)~='string'then human:TakeDamage(damage)end
  381. end
  382. end
  383. end
  384.  
  385. function hideAllParts(wut,an)
  386. local parts={}
  387. local function hide(object,anchor)
  388. if object:IsA("BasePart") or object:IsA("Decal") then
  389. local tr=object.Transparency
  390. local t={o=object,t=tr}
  391. object.Transparency = 1
  392. if object:IsA'BasePart' then
  393. t.a=object.Anchored
  394.  
  395. if anchor==nil then
  396. object.Anchored=true
  397. else
  398. if anchor == 1 then
  399. object.Anchored=true
  400. else
  401. object.Anchored=false
  402. end
  403. end
  404.  
  405. t.c=object.CanCollide
  406. object.CanCollide=false
  407. end
  408.  
  409. table.insert(parts,t)
  410. end
  411. for _, child in ipairs(object:GetChildren()) do
  412. hide(child,an)
  413. end
  414. end
  415. hide(wut,an)
  416. -- for i,v in pairs(Char:children())do
  417. -- pcall(function()print(v.Anchored)end)end
  418. return function()
  419. for i,v in ipairs(parts) do
  420. v.o.Transparency = v.t
  421. if v.o:IsA'BasePart'then
  422. if v.a~=nil then
  423. v.o.Anchored=v.a
  424. end
  425. if v.c~=nil then
  426. v.o.CanCollide=v.c
  427. end
  428. end
  429. end
  430. end
  431. end
  432.  
  433. function addJoint(name,weld,c0,c1)
  434. local t= {}
  435. t.w=weld
  436. t.n_c0 = c0 or weld.C0
  437. t.n_c1 = c1 or weld.C1
  438. t._desired=weld.C0
  439. t._old=cfn()
  440. t.spd=.1
  441. t.l=0
  442. local active=false
  443. function t:get()
  444. return setmetatable({},{__newindex=function(t,i,v)
  445. if i=='d' and self.l == 0 then
  446. self.d = v
  447. elseif i == 's' then self.spd=v end end})
  448. end
  449. function t:activate()
  450. local s=shldrs[name]
  451. s.Parent=nil
  452. self.w.Parent=torso
  453. end
  454. function t:deactivate()
  455. local s=shldrs[name]
  456. s.Parent=torso
  457. s.Part0=torso
  458. s.Part1=torso
  459. self.w.Parent=nil
  460. end
  461.  
  462. function t:update()
  463. self.w.C0 = self.w.C0:lerp(self._desired,self.spd)
  464. end
  465.  
  466. setmetatable(t,{__newindex=function(ta,i,v)
  467. if i=='d' then
  468. ta._desired = ta.n_c0 * v
  469. ta._old = v
  470. end end})
  471.  
  472. Joints[name]=t
  473. getfenv(0)[name]=Joints[name]
  474. end
  475. Joints={}
  476. addJoint('rw',New"Weld"{_P = torso;_PP={torso;arm_r};
  477. C0=cfn(1,0.5,0); C1=cfn(-.5,0.5,0)})
  478. rw.spd=.3
  479.  
  480. --Build--
  481. set_color='Steel blue'
  482. hdl=Part(.5,1.75,.5)Mesh(hdl,'cyl')
  483. hw=Weld(hdl,arm_r,0,-1,-.25,-PI/2)
  484.  
  485. spring=Part(.5,1.75,.5,'Black')
  486. Weld(spring,hdl,cfn()*ang(PI/2))
  487. Mesh(spring,mesh_ids.coil).Scale=mesh_scales.coil*v3n(.6,.6,1.75)
  488.  
  489. spring=Part(.5,1.75,.5,'Black')
  490. Weld(spring,hdl,cfn()*ang(PI/2,PI))
  491. Mesh(spring,mesh_ids.coil).Scale=mesh_scales.coil*v3n(.6,.6,1.75)
  492.  
  493. spike=Part(.5,.5,.5)
  494. Weld(spike,hdl,0,1.75/2+.275)
  495. Mesh(spike,mesh_ids.spike).Scale=mesh_scales.spike*spike.Size
  496.  
  497. ball=Part(2,2,2,'Black')
  498. Weld(ball,spike,0,1)
  499. ball_msh=Mesh(ball,mesh_ids.spikeball)
  500. ball_msh.Scale=mesh_scales.spikeball*ball.Size
  501.  
  502. ball2=Part(.1,.1,.1,'Cyan',.5)
  503. Weld(ball2,spike,0,1)
  504. Mesh(ball2,mesh_ids.spikeball).Scale=ball_msh.Scale*1.01
  505.  
  506.  
  507. dia=Part(.5,2,.5,'Storm blue')
  508. Weld(dia,hdl,0,-1.75/2)
  509. Mesh(dia,mesh_ids.diamond).Scale=mesh_scales.diamond*dia.Size
  510. -- New"SelectionBox"{_P=_1;Adornee=_1}
  511.  
  512. dia2=Part(1,1,1,'Black')_1.Size=dia.Size
  513. Weld(_1,hdl,0,-1.75/2,0,0,md'45')
  514. Mesh(_1,mesh_ids.diamond).Scale=mesh_scales.diamond*dia.Size
  515.  
  516. ball_dmg_con = ball.Touched:connect(blow)
  517. dia_dmg_con = dia.Touched:connect(blow)
  518. --/Build--
  519. addJoint('hw',hw)
  520. hw.spd=.3
  521.  
  522. anim_con=RS.Stepped:connect(function()
  523. for i,v in pairs(Joints) do
  524. v.w.C0 = v.w.C0:lerp(v._desired,v.spd)
  525. end
  526. end)
  527.  
  528. rw.d=ang(PI/2)
  529.  
  530. function freeze(a)local orig,orig2=a.WalkSpeed,a.JumpPower
  531. a.WalkSpeed=0 a.JumpPower=0
  532. return function()a.WalkSpeed=orig
  533. a.JumpPower=orig2 end end
  534.  
  535. --Moves--
  536. slash_snd = New"Sound"{_P=hdl;SoundId='rbxasset://sounds/swordslash.wav';
  537. Pitch=1.25}
  538. slash2_snd = New"Sound"{_P=hdl;SoundId='rbxasset://sounds/swordlunge.wav'}
  539. spin_snd = New"Sound"{_P=hdl;SoundId='rbxassetid://158475221'}
  540. lunge_snd = New"Sound"{_P=hdl;SoundId='rbxassetid://231731980';Pitch=.5}
  541. spike_snd = New"Sound"{_P=hdl;SoundId='rbxassetid://158037267'}
  542. spike_snd_cl = New(spike_snd){_P=hdl}
  543. beam_snd = New"Sound"{_P=hdl;SoundId='rbxassetid://184742298';Pitch=1.15}
  544. slash3_snd = New"Sound"{_P=hdl;SoundId='rbxassetid://220833976'}
  545. Slash = function()
  546. rw.d=ang(md'-15')
  547. slash_snd:Play()
  548. wait'.25'
  549. rw.d=ang(md'90')
  550. end
  551. Slash2 = function()
  552. slash2_snd:Play()
  553. local a=ang(md'90',0,md'-35')*ang(0,PI/2-md'25')
  554. rw.d=a
  555. wait'.15'
  556. rw.d=a*ang(md'-170')
  557. wait'.25'
  558. rw.d=ang(md'90')
  559. end
  560. Slash3 = function()
  561. addition_func=function(hum)
  562. Spawn(function()
  563. local pt=tick()
  564. repeat
  565. pcall(function()hum.PlatformStand=true end)
  566. wait()
  567. until (tick()-pt)>2
  568. pcall(function()hum.PlatformStand=false end)
  569. end)
  570. end
  571. damage=base_damage*1.5
  572. rw.d=ang(md'130',md'15')
  573. hw.d=ang(0,0,-PI)wait'.25'
  574. slash3_snd:Play()
  575. rw.d=ang(md'80',md'-35')
  576. hw.d=ang(md'25',0,PI)
  577. wait'.4'
  578. addition_func=nil
  579. -- rw.d=ang(PI/2)
  580. -- hw.d=cfn()
  581. end
  582. Slash4 = function()
  583. -- Slash()
  584. addition_func=function(hum)
  585. Spawn(function()wait'.15'
  586. display_splat(hum,'BLEED',splat_bg.bleed,'expand',2,2)
  587. end)
  588. for i=1,30 do
  589. if hum then
  590. local blood=Part(.3,.1,.3,'Really red')
  591. blood.CFrame=l(hum.Torso)
  592. blood.Velocity=v3n(mr(-5,5),10,mr(-5,5))
  593. DEBRIS:AddItem(blood,.5)
  594. pcall(function()hum.Health=hum.Health-base_damage*.01 end) end
  595. wait()
  596. end
  597. end
  598.  
  599. damage=base_damage*2
  600. rw.d=rw._old*ang(md'120')
  601. local o=ang(md'80',md'-35')
  602.  
  603. -- for a=0,1,.1 do
  604. -- hw.d=o*ang(0,0,PI*3*a)
  605. -- wait()
  606. -- end
  607. rw.d=o*ang(md'75')
  608. hw.d=cfn()wait'.25'
  609. slash3_snd:Play()
  610. rw.d=ang(md'85',md'-35',0)
  611. hw.d=cfn(0,1,0)*ang(md'-25',0,md'-15')
  612. wait'1'
  613. addition_func=nil
  614. end
  615.  
  616. wind_snd=New"Sound"{_P=hdl;SoundId='rbxassetid://224339308';Pitch=3}
  617. Spin = function()
  618. addition_func=function(hum)
  619. pcall(function()hum.PlatformStand=true wait(.1)hum.PlatformStand=false end)
  620. hum.Torso.Velocity=cfn(l(torso).p,v3n(l(hum.Torso).X,l(torso).Y,l(hum.Torso).Z)).lookVector*100
  621. end
  622. rw.d=ang(0,0,md'75')
  623. hw.d=cfn(0,-.5,0)*ang(PI/2)*ang(md'65')
  624.  
  625.  
  626. local bv=New"BodyAngularVelocity"{_P=root_p;maxTorque=v3n(1,1,1)*9e+009;
  627. angularvelocity=v3n(0,1,0)*PI*4}
  628.  
  629. --Trailing--
  630. local pt=tick()
  631. local rot=0
  632. local r=Part(10,3,10,'Cyan',.75)r.Anchored=true
  633. local mesh=Mesh(r,mesh_ids.crown)_3.Scale=mesh_scales.crown*r.Size
  634. _3.Offset=mesh_offsets.crown*r.Size
  635. local r2=New(r){_P=Main;Transparency=.85}_4.Mesh.Scale=mesh.Scale*1.1
  636. local r3=New(r){_P=Main;Transparency=.95}_4.Mesh.Scale=mesh.Scale*1.25
  637.  
  638. local function onHit(hit)
  639. blow(hit,'GUST',0.1,true,function(hum)
  640. New"BodyAngularVelocity"{_P=hum.Torso;MaxTorque=v3n(0,1,0)*9e+009;P=100;
  641. angularvelocity=v3n(0,1,0)*(PI*10)}
  642. DEBRIS:AddItem(_4,1)
  643. New(wind_snd){_P=hum.Torso}:Play()
  644. DEBRIS:AddItem(_4,1)
  645. end,splat_bg.wind,'expand')
  646. end
  647. -- r.Touched:connect(onHit)
  648. -- r2.Touched:connect(onHit)
  649. -- r3.Touched:connect(onHit)
  650.  
  651. Edit{r,r2,r3}{CFrame=l(torso,0,-2)}
  652. local pt=tick()
  653. Spawn(function()
  654. while bv.Parent~=nil do
  655. ---Spin em around---
  656. if (tick()-pt)>.1 then
  657. for _,hum in next,findHum(torso.Position,10) do
  658. if checkY(hum.Torso,torso,2) then
  659. onHit(hum.Torso)
  660. end
  661. end pt=tick()
  662. end
  663.  
  664. rot=rot+md'10'
  665. local st_cf=l(ball)
  666. RS.Stepped:wait()
  667. local en_cf=l(ball)
  668. local mag=(st_cf.p-en_cf.p).magnitude
  669. local cyl=Part(1,1,1)_1.Anchored=true _1.Material='Neon'
  670. local msh=Mesh(cyl,'cyl',1,mag,1)
  671. msh.Scale=v3n(1,mag,1)
  672. local bsca=msh.Scale
  673. cyl.CFrame=(cfn(st_cf.p,en_cf.p)*cfn(0,0,-mag/2))*ang(PI/2)
  674. r.CFrame=l(cfn(torso.Position),0,-2,0,0,rot)
  675. r2.CFrame=l(cfn(torso.Position),0,-2,0,0,-rot)
  676. r3.CFrame=l(cfn(torso.Position),0,-2,0,0,rot)
  677. Spawn(function()
  678. for i=0,1,.25 do
  679. cyl.Transparency=.5+i*.5
  680. msh.Scale=bsca+(v3n(1,0,1)*i)
  681. wait()
  682. end cyl:destroy()
  683. end)
  684. end
  685. for i,v in next,{r,r2,r3}do v:Destroy()end
  686. end)
  687. ---------------
  688.  
  689. spin_snd:Play()
  690. wait(1.5)
  691. bv:Destroy()
  692. hw.d=cfn()
  693. rw.d=ang(PI/2)
  694. addition_func=nil
  695. end
  696. Lunge = function()
  697.  
  698. addition_func=function(hum,hit)
  699.  
  700. local cr1=Part(1,1,1,'New Yeller',.5)
  701. local cr2=Part(1,1,1,'New Yeller',.5)
  702. Edit{cr1,cr2}{Material='Neon';Anchored=true}
  703. local msh=Mesh(cr1,'s')
  704. local msh2=Mesh(cr2,'s')
  705.  
  706. local contactp=ball.CFrame:toObjectSpace(hit.CFrame)
  707. contactp=ball.CFrame*contactp
  708. local cc=cfn(contactp.p,v3n(l(ball).X,contactp.Y,l(ball).Z))
  709. -- local cc=contactp
  710. cr1.CFrame=cc*ang(PI/2,md'45')
  711. cr2.CFrame=cc*ang(PI/2,md'-45')
  712.  
  713. Spawn(function()
  714. for i=0,1,.1 do
  715. Edit{cr1,cr2,msh,msh2}{Scale=v3n(1,1,30)*i;
  716. Transparency=.5+i*.5}
  717. wait()
  718. end
  719. cr1:Destroy() cr2:Destroy()
  720. end)
  721. local stopper=New"BodyPosition"{_P=hum.Torso;
  722. MaxForce=v3n(1,1,1)*9e+009;position=hum.Torso.Position}
  723. DEBRIS:AddItem(stopper,.25)
  724. end
  725. lunge_snd:Play()
  726.  
  727. --Effect--
  728.  
  729. local bv=New"BodyVelocity"{_P=torso;velocity=torso.CFrame.lookVector*50;
  730. MaxForce=v3n(1,1,1)*9e+009}
  731.  
  732. rw.d=ang(md'-45')
  733. hw.d=ang(md'-45')
  734. local pt=tick()
  735. repeat --Circle effects
  736. local ring=Part(1,1,1,'White',.5)_1.Anchored=true
  737. local msh=Mesh(_1,mesh_ids.ring)_3.Scale=v3n(0,0,0)
  738. local crown=Part(1,1,1,'White',.5)_1.Anchored=true
  739. local msh2=Mesh(_1,mesh_ids.crown)_3.Scale=v3n(0,0,0)
  740.  
  741. local cf=l(torso,0,0,-3)
  742. local cf2=l(torso,0,0,-7,PI/2)
  743. ring.CFrame=cf crown.CFrame=cf2
  744. Spawn(function()
  745. for i=0,1,.1 do
  746. Edit{ring,crown}{Transparency=.5+i*.5}
  747. Edit{msh}{Scale=v3n(i*10,i*10,1)}
  748. Edit{msh2}{Scale=v3n(i*11,i*11,i*11);Offset=v3n(0,.15*(i*11),0)}
  749. wait()
  750. end ring:Destroy()crown:Destroy()
  751. end)
  752. wait()
  753. until (tick()-pt)>.25
  754. rw.d=ang(md'45')*ang(0,md'25')
  755. hw.d=ang(md'45')
  756. bv:Destroy()
  757. addition_func=nil
  758. wait'.35'
  759. hw.d=cfn()rw.d=ang(PI/2)
  760. end
  761. inject_snd = New"Sound"{_P=hdl;SoundId='rbxassetid://214755019';Volume=1;}
  762. Spike = function()
  763. local behind=false
  764. rw.d=cfn(0,.65,0)*ang(md'170',0,md'45')*ang(0,md'-25')
  765. spike_snd:Play()
  766. dia_dmg_con:disconnect()
  767. ball_dmg_con:disconnect()
  768. wait'.5'
  769. --Make victim fall--
  770. local con
  771. set_splat_img=splat_bg.sleep
  772. slp_con=dia.Touched:connect(function(hit)
  773.  
  774. blow(hit,'5_IMMOB',nil,true,function(hum)
  775. if not hum.Parent:FindFirstChild'Torso'then return end
  776.  
  777. local chead=hum.Parent:FindFirstChild'Head'
  778. if chead then
  779. vec1=chead.CFrame.lookVector
  780. vec2=head.CFrame.lookVector
  781. dot=vec1:Dot(vec2)
  782. if dot>0 then
  783. hum:TakeDamage(base_damage*2)
  784. -- dodam(hum,base_damage*2,set_splat_img,'expand')
  785. end
  786. end
  787.  
  788. -- display_splat(hum,'SLEEP',splat_bg.sleep)
  789. local found_poison = hum.Torso:FindFirstChild'Sleep'
  790. if not found_sleep then
  791. inject_snd:Play() hit_snd:Stop()
  792. local sleep = New"BodyGyro"{_P=hum.Torso;
  793. Name='Sleep';MaxTorque=v3n(1,1,1)*9e+009;P=10000;
  794. cframe=cfn(l(hum.Torso).p)*ang(PI/2,0,PI/2)}
  795. DEBRIS:AddItem(sleep,3)
  796. end
  797. end)
  798.  
  799. end)
  800. ----------------------
  801. spike_snd_cl:Play()
  802. rw.d=rw._old*ang(md'-85')
  803. hw.d=cfn(0,.5,0)*ang(md'-15')
  804. wait'.5'
  805. set_splat_img=sleep
  806. slp_con:disconnect()
  807. dia_dmg_con=dia.Touched:connect(blow)
  808. ball_dmg_con = ball.Touched:connect(blow)
  809. -- damage=base_damage
  810. hw.d=cfn()
  811. rw.d=ang(PI/2)
  812. end
  813. Beam = function()
  814. local dismis={}
  815. local obj,pos=Workspace:FindPartOnRayWithIgnoreList(Ray.new(l(torso,0,0,-4).p,v3n(0,-5,0)),dismis)
  816. local hummi=nil
  817. repeat
  818. obj,pos=Workspace:FindPartOnRayWithIgnoreList(Ray.new(l(torso,0,0,-4).p,v3n(0,-5,0)),dismis)
  819. if obj and pos then
  820. hummi=recurseHum(obj)
  821. if hummi then
  822. table.insert(dismis,obj)
  823. end end
  824. until hummi==nil
  825. if not obj and pos then return end
  826. beam_snd:Play()
  827. rw.d=ang(md'140')
  828. hw.d=cfn(0,0,.25)*ang(md'35')
  829. local thaw=freeze(chum)
  830. local rings={}
  831. for i=1,0,-.05 do
  832. local ring = Part(i*5,i*5,4,'New Yeller')_1.Anchored=true
  833. ring.CFrame=cfn(pos)*ang(PI/2)
  834. -- ring.Touched:connect(function(hit)end)
  835. Mesh(ring,mesh_ids.ring)
  836. _3.Scale=mesh_scales.ring*_1.Size
  837. table.insert(rings,ring)
  838. end
  839. for o=0,1,.1 do
  840. for i,v in pairs(rings)do
  841. v.CFrame=cfn(pos+v3n(0,-.4+o*(i),0))*ang(PI/2)
  842.  
  843. end
  844.  
  845. ---Make em suffer...
  846. for _,hum in next,findHum(l(torso,0,0,-4).p,30) do
  847. if checkY(hum.Torso,torso,10,4) then
  848. blow(hum.Torso,base_damage*.25,.1,false)
  849. end
  850. end
  851. wait()
  852. end
  853. for o=1,0,-.1 do
  854. for i,v in pairs(rings)do
  855. v.CFrame=cfn(pos+v3n(0,-.4+o*(i),0))*ang(PI/2)
  856.  
  857. end
  858. ---Make em suffer...
  859. for _,hum in next,findHum(l(torso,0,0,-4).p,30) do
  860. if checkY(hum.Torso,torso,10,4) then
  861. blow(hum.Torso,base_damage*.25,.1,false)
  862. end
  863. end
  864. wait()
  865. end thaw()
  866. for _,v in pairs(rings)do v:Destroy()end
  867. hw.d=cfn()
  868. rw.d=ang(PI/2)
  869. end
  870.  
  871. unhide=nil
  872. prtem=New"ParticleEmitter"{_P=nil;
  873. Size=NumberSequence.new{numkp(0,1);numkp(1,7)};
  874. Transparency=NumberSequence.new{numkp(0,0);numkp(1,1)};
  875. Color=ColorSequence.new(bcol'Cyan'.Color,bcol'White'.Color);
  876. Lifetime=NumberRange.new(3);
  877. VelocitySpread=180;
  878. Rate=150;
  879. Texture='rbxassetid://133619974';
  880. }
  881. hide_snd = New"Sound"{_P=hdl;SoundId='http://www.roblox.com/Asset/?id=16433289'}
  882. Hide = function()
  883. if unhide == nil then
  884. hide_snd:Play()
  885. unhide = hideAllParts(character,false)
  886. local p=Part(1,1,1,'',1)p.Anchored=true
  887. p.CFrame=l(torso)
  888. local prt=New(prtem){_P=p}
  889. prt:Emit(10)wait(.1)prt.Rate=0
  890. DEBRIS:AddItem(p,2)
  891. else
  892. unhide()
  893. unhide=nil
  894. end
  895. end
  896.  
  897. -- Lunge()
  898. Mouse=player:GetMouse()
  899.  
  900. pt=0
  901. double=false
  902. mouse_con1=Mouse.KeyDown:connect(function(key)
  903. if isIn(key,{'f','q','e','c','z'}) then
  904. if attacking then return end
  905. attacking=true
  906. if unhide == nil then
  907. if key=='f'then
  908. Spin()
  909. elseif key=='q' then
  910. Lunge()
  911. elseif key=='e' then
  912. Spike()
  913. elseif key=='z' then
  914. Beam()
  915. elseif key=='r'then
  916. Slash4()
  917. end
  918. end
  919. if key=='c' then
  920. Hide()
  921. end
  922. attacking=false
  923. end
  924. end)
  925. local combo=0
  926. mouse_con2=Mouse.Button1Down:connect(function()
  927. if attacking or unhide~=nil then return end
  928. attacking=true
  929. if (tick()-pt) <.2 then
  930. combo=combo+1
  931. else combo=0 end
  932. if combo==1 then
  933. Slash2()
  934. elseif combo==2 then
  935. Slash3()
  936. elseif combo==3 then
  937. Slash4()
  938. combo=0
  939. else
  940. Slash()
  941. end
  942. hw.d=cfn()rw.d=ang(PI/2)
  943. damage=base_damage
  944. attacking=false
  945. pt=tick()
  946. end)
  947.  
  948. --Maeking sure it wont go insane--
  949. New"BindableFunction"{_P=script;Name='sidos'}.OnInvoke=function()
  950. mouse_con1:disconnect()
  951. mouse_con2:disconnect()
  952. anim_con:disconnect()
  953. end
  954. script.Name='riimu'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement