SHOW:
|
|
- or go back to the newest paste.
1 | - | Player = game:GetService("Players").buttmyhead |
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 | ||
7 | Player = game:GetService("Players").lolfarmer | |
8 | Character = Player.Character | |
9 | PlayerGui = Player.PlayerGui | |
10 | Backpack = Player.Backpack | |
11 | Torso = Character.Torso | |
12 | Head = Character.Head | |
13 | LeftArm = Character["Left Arm"] | |
14 | LeftLeg = Character["Left Leg"] | |
15 | RightArm = Character["Right Arm"] | |
16 | RightLeg = Character["Right Leg"] | |
17 | LS = Torso["Left Shoulder"] | |
18 | LH = Torso["Left Hip"] | |
19 | RS = Torso["Right Shoulder"] | |
20 | RH = Torso["Right Hip"] | |
21 | ModelName = "Weapon" | |
22 | ToolName = "Yamato" | |
23 | attack = false | |
24 | attacktype = 1 | |
25 | mindamage = 153333333333333333333333333333666666663333333333 | |
26 | maxdamage = 253333333333333333333333336666666666666 | |
27 | crtmaxdamage = 45333333333333333333333333333333 | |
28 | omindamage = 15333333333333333333333333366666666666666666 | |
29 | omaxdamage = 2533333333333333333366666666666666666666666 | |
30 | ocrtmaxdamage = 4533333333333333333333333333333366666666 | |
31 | crtrate = 1266666666666666666666666666666666666 | |
32 | fireboost = 3333333333333333333333333333333333333333333332 | |
33 | iceboost = 66666666666666666666666666666666666666666666666 | |
34 | darkboost = 666666666666666666666666666666666666666666666666666 | |
35 | Mode = "None" | |
36 | ssh = false | |
37 | atktypez = 1 | |
38 | Hitdeb = 0 | |
39 | ammo = 1 | |
40 | MMouse = nil | |
41 | point = false | |
42 | offset = 0 | |
43 | radv = 90 | |
44 | ---------------------------- | |
45 | --Customize | |
46 | DarkFire = true | |
47 | MaxFT = 40 | |
48 | ||
49 | ||
50 | ||
51 | --------------------------------------------------------------------------------------------------------------------------------------- | |
52 | if Character:findFirstChild("EquippedVal",true) ~= nil then | |
53 | Character:findFirstChild("EquippedVal",true).Parent = nil | |
54 | end | |
55 | ev = Instance.new("BoolValue") | |
56 | ev.Parent = Character | |
57 | ev.Name = "EquippedVal" | |
58 | ev.Value = false | |
59 | --player | |
60 | player = nil | |
61 | --welds | |
62 | RW, LW , RWL, LWL = Instance.new("Weld"), Instance.new("Weld"), Instance.new("Weld"), Instance.new("Weld") | |
63 | --what anim | |
64 | anim = "none" | |
65 | --other var | |
66 | player = Player | |
67 | ch = Character | |
68 | --save shoulders | |
69 | AoETrue = {} | |
70 | RSH, LSH , RHL, LHL = ch.Torso["Right Shoulder"], ch.Torso["Left Shoulder"] , ch.Torso["Right Hip"] , ch.Torso["Left Hip"] | |
71 | ||
72 | function RWFunc() | |
73 | RW.Part1 = ch["Right Arm"] | |
74 | RSH.Part1 = nil | |
75 | end | |
76 | function LWFunc() | |
77 | LW.Part1 = ch["Left Arm"] | |
78 | LSH.Part1 = nil | |
79 | end | |
80 | function RWLFunc() | |
81 | RWL.Part1 = ch["Right Leg"] | |
82 | RHL.Part1 = nil | |
83 | ch["Right Leg"].Name = "RightLeg" | |
84 | RightLeg.CanCollide = false | |
85 | end | |
86 | function LWLFunc() | |
87 | LWL.Part1 = ch["Left Leg"] | |
88 | LHL.Part1 = nil | |
89 | ch["Left Leg"].Name = "LeftLeg" | |
90 | LeftLeg.CanCollide = true | |
91 | end | |
92 | function RWLRem() | |
93 | RightLeg.Name = "Right Leg" | |
94 | RWL.Part1 = nil | |
95 | RHL.Part1 = ch["Right Leg"] | |
96 | RightLeg.CanCollide = false | |
97 | end | |
98 | function LWLRem() | |
99 | LeftLeg.Name = "Left Leg" | |
100 | LWL.Part1 = nil | |
101 | LHL.Part1 = ch["Left Leg"] | |
102 | LeftLeg.CanCollide = false | |
103 | end | |
104 | function RWRem() | |
105 | RW.Part1 = nil | |
106 | RSH.Part1 = ch["Right Arm"] | |
107 | end | |
108 | function LWRem() | |
109 | LW.Part1 = nil | |
110 | LSH.Part1 = ch["Left Arm"] | |
111 | end | |
112 | ||
113 | ||
114 | if Character:findFirstChild(ModelName,true) ~= nil then | |
115 | Character:findFirstChild(ModelName,true).Parent = nil | |
116 | RHL.Part1 = ch["Right Leg"] | |
117 | LHL.Part1 = ch["Left Leg"] | |
118 | RSH.Part1 = ch["Right Arm"] | |
119 | LSH.Part1 = ch["Left Arm"] | |
120 | end | |
121 | ||
122 | ||
123 | ||
124 | local swordholder = Instance.new("Model") | |
125 | swordholder.Name = ModelName | |
126 | swordholder.Parent = Character | |
127 | --derp | |
128 | RW.Part0 = ch.Torso | |
129 | RW.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.fromEulerAnglesXYZ(0, 0, 0) | |
130 | RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.fromEulerAnglesXYZ(0, 0, 0) | |
131 | RW.Parent = swordholder | |
132 | -- | |
133 | LW.Part0 = ch.Torso | |
134 | LW.C0 = CFrame.new(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8) | |
135 | LW.C1 = CFrame.new(0, 0.5, 0) | |
136 | LW.Parent = swordholder | |
137 | -- | |
138 | RWL.Part0 = ch.Torso | |
139 | RWL.C0 = CFrame.new(1, -1, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5) | |
140 | RWL.C1 = CFrame.new(0.5, 1, 0) | |
141 | RWL.Parent = swordholder | |
142 | -- | |
143 | LWL.Part0 = ch.Torso | |
144 | LWL.C0 = CFrame.new(-1, -1, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8) | |
145 | LWL.C1 = CFrame.new(-0.5, 1, 0) | |
146 | LWL.Parent = swordholder | |
147 | handlecolor = BrickColor.new("Really black") | |
148 | scndryclr = BrickColor.new("Bright violet") | |
149 | firepri = BrickColor.new("Bright red") | |
150 | icepri = BrickColor.new("Bright blue") | |
151 | local msh1 = Instance.new("CylinderMesh") | |
152 | msh1.Scale = Vector3.new(1,1,1) | |
153 | local msh2 = Instance.new("BlockMesh") | |
154 | msh2.Scale = Vector3.new(1,1,1) | |
155 | -- | |
156 | local msh3 = Instance.new("BlockMesh") | |
157 | msh3.Scale = Vector3.new(1,1,1) | |
158 | local msh3a = Instance.new("SpecialMesh") | |
159 | msh3a.Scale = Vector3.new(1,1,1) | |
160 | msh3a.MeshType = "Wedge" | |
161 | local msh4 = Instance.new("BlockMesh") | |
162 | msh4.Scale = Vector3.new(1,1,1) | |
163 | local msh4a = Instance.new("SpecialMesh") | |
164 | msh4a.Scale = Vector3.new(1,1,1) | |
165 | msh4a.MeshType = "Wedge" | |
166 | -- | |
167 | local msh5 = Instance.new("SpecialMesh") | |
168 | msh5.Scale = Vector3.new(1,1,2) | |
169 | msh5.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
170 | local msh6 = Instance.new("BlockMesh") | |
171 | msh6.Scale = Vector3.new(1,1,0.5) | |
172 | local msh7 = Instance.new("BlockMesh") | |
173 | msh7.Scale = Vector3.new(1,1,1) | |
174 | local msh8 = Instance.new("BlockMesh") | |
175 | msh8.Scale = Vector3.new(0.5,1,1) | |
176 | local prt1 = Instance.new("Part") | |
177 | prt1.formFactor = 3 | |
178 | prt1.CanCollide = false | |
179 | prt1.Name = "Handle" | |
180 | prt1.Locked = true | |
181 | prt1.Size = Vector3.new(0.2,1.5,0.2) | |
182 | prt1.Parent = swordholder | |
183 | msh1.Parent = prt1 | |
184 | prt1.BrickColor = handlecolor | |
185 | local prt2 = Instance.new("Part") | |
186 | prt2.formFactor = 3 | |
187 | prt2.CanCollide = false | |
188 | prt2.Name = "HandleTop" | |
189 | prt2.Locked = true | |
190 | prt2.Size = Vector3.new(1.6,0.2,0.5) | |
191 | prt2.Parent = swordholder | |
192 | msh2.Parent = prt2 | |
193 | prt2.BrickColor = scndryclr | |
194 | --- | |
195 | local prt3 = Instance.new("Part") | |
196 | prt3.formFactor = 3 | |
197 | prt3.CanCollide = false | |
198 | prt3.Name = "FlameBlade" | |
199 | prt3.Locked = true | |
200 | prt3.Size = Vector3.new(0.4,3,0.2) | |
201 | prt3.Parent = swordholder | |
202 | msh3.Parent = prt3 | |
203 | prt3.BrickColor = firepri | |
204 | prt3.Reflectance = 0 | |
205 | local prt3a = Instance.new("Part") | |
206 | prt3a.formFactor = 3 | |
207 | prt3a.CanCollide = false | |
208 | prt3a.Name = "FlameBladeP1" | |
209 | prt3a.Locked = true | |
210 | prt3a.Size = Vector3.new(0.2,1,0.4) | |
211 | prt3a.Parent = swordholder | |
212 | msh3a.Parent = prt3a | |
213 | prt3a.BrickColor = firepri | |
214 | prt3a.Reflectance = 0 | |
215 | -- | |
216 | local prt4 = Instance.new("Part") | |
217 | prt4.formFactor = 3 | |
218 | prt4.CanCollide = false | |
219 | prt4.Name = "FrostBlade" | |
220 | prt4.Locked = true | |
221 | prt4.Size = Vector3.new(0.4,3,0.2) | |
222 | prt4.Parent = swordholder | |
223 | msh4.Parent = prt4 | |
224 | prt4.BrickColor = icepri | |
225 | prt4.Reflectance = 0.5 | |
226 | local prt4a = Instance.new("Part") | |
227 | prt4a.formFactor = 3 | |
228 | prt4a.CanCollide = false | |
229 | prt4a.Name = "FrostBladeP1" | |
230 | prt4a.Locked = true | |
231 | prt4a.Size = Vector3.new(0.2,1,0.4) | |
232 | prt4a.Parent = swordholder | |
233 | msh4a.Parent = prt4a | |
234 | prt4a.BrickColor = icepri | |
235 | prt4a.Reflectance = 0.5 | |
236 | -- | |
237 | local prt5 = Instance.new("Part") | |
238 | prt5.formFactor = 3 | |
239 | prt5.CanCollide = false | |
240 | prt5.Name = "HandleRing" | |
241 | prt5.Locked = true | |
242 | prt5.Size = Vector3.new(1,1,0.2) | |
243 | prt5.Parent = swordholder | |
244 | msh5.Parent = prt5 | |
245 | prt5.BrickColor = scndryclr | |
246 | prt5.Reflectance = 0 | |
247 | local DFlame = Instance.new("Fire") | |
248 | DFlame.Parent = prt5 | |
249 | DFlame.Color = Color3.new(0.5,0,0.5) | |
250 | DFlame.SecondaryColor = Color3.new(0.5,0,0.5) | |
251 | DFlame.Heat = 25 | |
252 | DFlame.Size = 1 | |
253 | DFlame.Enabled = DarkFire | |
254 | local prt6 = Instance.new("Part") | |
255 | prt6.formFactor = 3 | |
256 | prt6.CanCollide = false | |
257 | prt6.Name = "HandleP1" | |
258 | prt6.Locked = true | |
259 | prt6.Size = Vector3.new(0.2,1.5,0.2) | |
260 | prt6.Parent = swordholder | |
261 | msh6.Parent = prt6 | |
262 | prt6.BrickColor = scndryclr | |
263 | prt6.Reflectance = 0 | |
264 | local prt7 = Instance.new("Part") | |
265 | prt7.formFactor = 3 | |
266 | prt7.CanCollide = false | |
267 | prt7.Name = "HandleP2" | |
268 | prt7.Locked = true | |
269 | prt7.Size = Vector3.new(0.7,0.2,0.2) | |
270 | prt7.Parent = swordholder | |
271 | msh7.Parent = prt7 | |
272 | prt7.BrickColor = scndryclr | |
273 | prt7.Reflectance = 0 | |
274 | local prt8 = Instance.new("Part") | |
275 | prt8.formFactor = 3 | |
276 | prt8.CanCollide = false | |
277 | prt8.Name = "DarkBlade" | |
278 | prt8.Locked = true | |
279 | prt8.Size = Vector3.new(0.2,4,0.2) | |
280 | prt8.Parent = swordholder | |
281 | msh8.Parent = prt8 | |
282 | prt8.BrickColor = handlecolor | |
283 | prt8.Transparency = 1 | |
284 | local hitbox = Instance.new("Part") | |
285 | hitbox.formFactor = 3 | |
286 | hitbox.CanCollide = false | |
287 | hitbox.Name = "Hitbox" | |
288 | hitbox.Locked = true | |
289 | hitbox.Size = Vector3.new(1,4,0.2) | |
290 | hitbox.Parent = swordholder | |
291 | hitbox.Transparency = 1 | |
292 | local hbw = Instance.new("Weld") | |
293 | hbw.Parent = hitbox | |
294 | hbw.Part0 = hitbox | |
295 | hbw.Part1 = prt1 | |
296 | hbw.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
297 | hbw.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,0) * CFrame.new(0, -2.95, 0) | |
298 | ||
299 | local w1 = Instance.new("Weld") | |
300 | w1.Parent = prt1 | |
301 | w1.Part0 = prt1 | |
302 | local w2 = Instance.new("Weld") | |
303 | w2.Parent = prt2 | |
304 | w2.Part0 = prt2 | |
305 | w2.Part1 = prt1 | |
306 | w2.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
307 | w2.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,0) * CFrame.new(0, -0.85, 0) | |
308 | -- | |
309 | local w3 = Instance.new("Weld") | |
310 | w3.Parent = prt3 | |
311 | w3.Part0 = prt3 | |
312 | w3.Part1 = prt1 | |
313 | w3.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
314 | w3.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,0) * CFrame.new(0.25, -2.45, 0) | |
315 | local w3a = Instance.new("Weld") | |
316 | w3a.Parent = prt3a | |
317 | w3a.Part0 = prt3a | |
318 | w3a.Part1 = prt1 | |
319 | w3a.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
320 | w3a.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(-90),0) * CFrame.new(0.25, -4.45, 0) | |
321 | local w4 = Instance.new("Weld") | |
322 | w4.Parent = prt4 | |
323 | w4.Part0 = prt4 | |
324 | w4.Part1 = prt1 | |
325 | w4.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
326 | w4.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,0) * CFrame.new(-0.25, -2.45, 0) | |
327 | local w4a = Instance.new("Weld") | |
328 | w4a.Parent = prt4a | |
329 | w4a.Part0 = prt4a | |
330 | w4a.Part1 = prt1 | |
331 | w4a.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
332 | w4a.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(90),0) * CFrame.new(-0.25, -4.45, 0) | |
333 | -- | |
334 | local w5 = Instance.new("Weld") | |
335 | w5.Parent = prt5 | |
336 | w5.Part0 = prt5 | |
337 | w5.Part1 = prt1 | |
338 | w5.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
339 | w5.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,0) * CFrame.new(-0, -0.85, 0) | |
340 | local w6 = Instance.new("Weld") | |
341 | w6.Parent = prt6 | |
342 | w6.Part0 = prt6 | |
343 | w6.Part1 = prt1 | |
344 | w6.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
345 | w6.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,0) * CFrame.new(-0.5, -0, 0) | |
346 | local w7 = Instance.new("Weld") | |
347 | w7.Parent = prt7 | |
348 | w7.Part0 = prt7 | |
349 | w7.Part1 = prt1 | |
350 | w7.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
351 | w7.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,0) * CFrame.new(-0.25, 0.75, 0) | |
352 | local w8 = Instance.new("Weld") | |
353 | w8.Parent = prt8 | |
354 | w8.Part0 = prt8 | |
355 | w8.Part1 = prt1 | |
356 | w8.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0, 0) | |
357 | w8.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,0) * CFrame.new(0, -2.95, 0) | |
358 | for ringi = 0 , math.rad(350) , math.rad(50) do | |
359 | local ringm = Instance.new("BlockMesh") | |
360 | ringm.Scale = Vector3.new(1,1.5,1) | |
361 | local ringp = Instance.new("Part") | |
362 | ringp.formFactor = 3 | |
363 | ringp.CanCollide = false | |
364 | ringp.Name = "HandleRingP"..ringi | |
365 | ringp.Locked = true | |
366 | ringp.Size = Vector3.new(0.2,0.2,0.2) | |
367 | ringp.Parent = swordholder | |
368 | ringm.Parent = ringp | |
369 | ringp.BrickColor = scndryclr | |
370 | ringp.Reflectance = 0.1 | |
371 | local ringw = Instance.new("Weld") | |
372 | ringw.Parent = ringp | |
373 | ringw.Part0 = ringp | |
374 | ringw.Part1 = prt5 | |
375 | ringw.C1 = CFrame.fromEulerAnglesXYZ(math.rad(90), -ringi, 0) * CFrame.new(0, 0 , 0) | |
376 | ringw.C0 = CFrame.fromEulerAnglesXYZ(0, 0,0) * CFrame.new(-msh5.Scale.x/1.625, 0, 0) --* CFrame.new(-0.6, 0, 0) ---msh5.Scale.z/3.25 | |
377 | end | |
378 | ||
379 | local Objects = {} | |
380 | function getAllObjects(obj) | |
381 | for a,v in pairs(obj:GetChildren()) do | |
382 | if v:IsA("BasePart") then | |
383 | table.insert(Objects,v) | |
384 | end | |
385 | if #v:GetChildren() > 0 then | |
386 | getAllObjects(v) | |
387 | end | |
388 | end | |
389 | end | |
390 | getAllObjects(Workspace) | |
391 | function Raycast(Start,End,Range) | |
392 | -- | |
393 | for ii = 0 , #Objects do | |
394 | table.remove(Objects,ii) | |
395 | end | |
396 | getAllObjects(Workspace) | |
397 | local MA = math.abs | |
398 | local CF = CFrame.new(Start,End) | |
399 | local CP = Start | |
400 | for i = 1, Range do--(Start - End).magnitude do | |
401 | for b,v in pairs(Objects) do | |
402 | if v.Parent ~= nil then | |
403 | local pos = Start + (CF.lookVector*i) | |
404 | local dist = v.CFrame:pointToObjectSpace(pos) | |
405 | if MA(dist.x) < v.Size.x/2 and MA(dist.y) < v.Size.y/2 and MA(dist.z) < v.Size.z/2 then | |
406 | if v.Parent ~= Character or v.Parent ~= swordholder or v.Parent.Parent ~= Character then | |
407 | return v,Start,pos | |
408 | end | |
409 | end | |
410 | end | |
411 | end | |
412 | end | |
413 | return nil,Start,End | |
414 | end | |
415 | local RAP = Instance.new("Part") | |
416 | RAP.formFactor = 0 | |
417 | RAP.CanCollide = false | |
418 | RAP.Name = "RAPart" | |
419 | RAP.Locked = true | |
420 | RAP.Size = Vector3.new(1,1,1) | |
421 | RAP.Parent = swordholder | |
422 | RAP.Transparency = 1 | |
423 | local w = Instance.new("Weld") | |
424 | w.Parent = RAP | |
425 | w.Part0 = RAP | |
426 | w.Part1 = RightArm | |
427 | w.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
428 | w.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0, 0) * CFrame.new(0, 1, 0) | |
429 | ||
430 | function unequipweld() | |
431 | w1.Part1 = Torso | |
432 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), math.rad(0)) * CFrame.new(0, 0,0) | |
433 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(180), math.rad(-150)) * CFrame.new(-1, -1.5, -0.6) | |
434 | end | |
435 | unequipweld() | |
436 | ||
437 | function equipweld() | |
438 | w1.Part1 = RAP | |
439 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
440 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
441 | end | |
442 | ||
443 | function ss(parent,p) --Slash | |
444 | local SlashSound = Instance.new("Sound") | |
445 | SlashSound.SoundId = "rbxasset://sounds\\swordslash.wav" | |
446 | SlashSound.Parent = parent | |
447 | SlashSound.Volume = .7 | |
448 | SlashSound.Pitch = p | |
449 | SlashSound.PlayOnRemove = true | |
450 | coroutine.resume(coroutine.create(function() | |
451 | wait() | |
452 | SlashSound.Parent = nil | |
453 | end)) | |
454 | end | |
455 | function uss(parent,p) --unsheath | |
456 | local SlashSound = Instance.new("Sound") | |
457 | SlashSound.SoundId = "rbxasset://sounds\\unsheath.wav" | |
458 | SlashSound.Parent = parent | |
459 | SlashSound.Volume = .7 | |
460 | SlashSound.Pitch = p | |
461 | SlashSound.PlayOnRemove = true | |
462 | coroutine.resume(coroutine.create(function() | |
463 | wait() | |
464 | SlashSound.Parent = nil | |
465 | end)) | |
466 | end | |
467 | function cs(parent,p) --Magic Charge | |
468 | local SlashSound = Instance.new("Sound") | |
469 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=2101137" | |
470 | SlashSound.Parent = parent | |
471 | SlashSound.Volume = .7 | |
472 | SlashSound.Pitch = p | |
473 | SlashSound.PlayOnRemove = true | |
474 | coroutine.resume(coroutine.create(function() | |
475 | wait() | |
476 | SlashSound.Parent = nil | |
477 | end)) | |
478 | end | |
479 | function ls(parent,p) --Lazer Sound | |
480 | local SlashSound = Instance.new("Sound") | |
481 | SlashSound.SoundId = "http://www.roblox.com/asset?id=1369158" | |
482 | SlashSound.Parent = parent | |
483 | SlashSound.Volume = .7 | |
484 | SlashSound.Pitch = p | |
485 | SlashSound.PlayOnRemove = true | |
486 | coroutine.resume(coroutine.create(function() | |
487 | wait() | |
488 | SlashSound.Parent = nil | |
489 | end)) | |
490 | end | |
491 | function is(parent,p) --Ice Sound | |
492 | local SlashSound = Instance.new("Sound") | |
493 | local rndm = math.random(1,3) | |
494 | if rndm == 1 then | |
495 | SlashSound.SoundId = "rbxasset://sounds\\ice.ogg" | |
496 | elseif rndm == 2 then | |
497 | SlashSound.SoundId = "rbxasset://sounds\\ice2.ogg" | |
498 | elseif rndm == 3 then | |
499 | SlashSound.SoundId = "rbxasset://sounds\\ice3.ogg" | |
500 | end | |
501 | SlashSound.Parent = parent | |
502 | SlashSound.Volume = .7 | |
503 | SlashSound.Pitch = p | |
504 | SlashSound.PlayOnRemove = true | |
505 | coroutine.resume(coroutine.create(function() | |
506 | wait() | |
507 | SlashSound.Parent = nil | |
508 | end)) | |
509 | end | |
510 | function fs(parent,p) --Fire Sound | |
511 | local SlashSound = Instance.new("Sound") | |
512 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=31758982" | |
513 | SlashSound.Parent = parent | |
514 | SlashSound.Volume = .7 | |
515 | SlashSound.Pitch = p | |
516 | SlashSound.PlayOnRemove = true | |
517 | coroutine.resume(coroutine.create(function() | |
518 | wait() | |
519 | SlashSound.Parent = nil | |
520 | end)) | |
521 | end | |
522 | function bs(parent,p) --Boom Sound | |
523 | local SlashSound = Instance.new("Sound") | |
524 | SlashSound.SoundId = "rbxasset://sounds/Rocket shot.wav" | |
525 | SlashSound.Parent = parent | |
526 | SlashSound.Volume = .7 | |
527 | SlashSound.Pitch = p | |
528 | SlashSound.PlayOnRemove = true | |
529 | coroutine.resume(coroutine.create(function() | |
530 | wait() | |
531 | SlashSound.Parent = nil | |
532 | end)) | |
533 | end | |
534 | -- | |
535 | ||
536 | ||
537 | function hideanim() | |
538 | attack = true | |
539 | for i = 0 , 1 , 0.2 do | |
540 | wait() | |
541 | RW.C0 = CFrame.new(1+0.5*i,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80+67*i), math.rad(45), math.rad(-45+90*i)) | |
542 | LW.C0 = CFrame.new(-1-0.5*i,0.5,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80-80*i),math.rad(-45+45*i),math.rad(45-45*i)) | |
543 | end | |
544 | LWRem() | |
545 | for i = 0 , 1 , 0.15 do | |
546 | wait() | |
547 | RW.C0 = CFrame.new(1.5,0.5+0.5*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(147+103*i), math.rad(45), math.rad(45-35*i)) | |
548 | end | |
549 | unequipweld() | |
550 | wait(0.1) | |
551 | for i = 0 , 1 , 0.1 do | |
552 | wait() | |
553 | RW.C0 = CFrame.new(1.5,1-0.5*i,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(250-250*i), math.rad(45-45*i), math.rad(10-10*i)) | |
554 | end | |
555 | RWRem() | |
556 | attack = false | |
557 | end | |
558 | ||
559 | function equipanim() | |
560 | attack = true | |
561 | RWFunc() | |
562 | for i = 0 , 1 , 0.1 do | |
563 | wait() | |
564 | RW.C0 = CFrame.new(1.5,0.5,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(250*i), math.rad(45*i), math.rad(-10*i)) | |
565 | end | |
566 | equipweld() | |
567 | uss(Head,1) | |
568 | for i = 0 , 1 , 0.2 do | |
569 | wait() | |
570 | RW.C0 = CFrame.new(1.5,0.5+0.5*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(250-102.5*i), math.rad(45), math.rad(-10+27.5*i)) | |
571 | end | |
572 | for i = 0 , 1 , 0.15 do | |
573 | wait() | |
574 | RW.C0 = CFrame.new(1.5,1-0.5*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(147-67*i), math.rad(45), math.rad(17.5+27.5*i)) | |
575 | end | |
576 | LWFunc() | |
577 | for i = 0 , 1 , 0.1 do | |
578 | wait() | |
579 | RW.C0 = CFrame.new(1.5-0.5*i,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80), math.rad(45), math.rad(45-90*i)) | |
580 | LW.C0 = CFrame.new(-1.5+0.5*i,0.5,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80*i),math.rad(-45*i),math.rad(45*i)) | |
581 | end | |
582 | attack = false | |
583 | end | |
584 | ||
585 | if (script.Parent.className ~= "HopperBin") then | |
586 | Tool = Instance.new("HopperBin") | |
587 | Tool.Parent = Backpack | |
588 | Tool.Name = ToolName | |
589 | script.Parent = Tool | |
590 | end | |
591 | Bin = script.Parent | |
592 | ||
593 | function damagesplat(dmg,hit,critornot,healornot) | |
594 | local OffsetX = -2.5 | |
595 | local OffsetY = 5 | |
596 | local OffsetZ = 0 | |
597 | local bill = Instance.new("BillboardGui") | |
598 | bill.Size = UDim2.new(1,0,1,0) | |
599 | bill.Adornee = hit | |
600 | bill.StudsOffset = Vector3.new(OffsetX,OffsetY,OffsetZ) | |
601 | bill.Parent = hit.Parent | |
602 | bill.Name = "DamageSplat" | |
603 | local tex = Instance.new("TextLabel") | |
604 | tex.Size = UDim2.new(5,0,2.5,0) | |
605 | tex.Parent = bill | |
606 | tex.Text = dmg | |
607 | tex.BackgroundTransparency = 1 | |
608 | tex.ZIndex = 4 | |
609 | tex.FontSize = "Size24" | |
610 | local tex2 = Instance.new("ImageLabel") | |
611 | tex2.Size = UDim2.new(1,0,1,0) | |
612 | tex2.Parent = tex | |
613 | tex2.BackgroundTransparency = 1 | |
614 | tex2.Image = "http://www.roblox.com/asset/?id=42611276" | |
615 | if critornot == true then | |
616 | tex.TextColor3 = Color3.new(1,0.2,0.2) | |
617 | elseif critornot == false then | |
618 | tex.TextColor3 = Color3.new(0,0,0) | |
619 | end | |
620 | if healornot == true then | |
621 | tex.TextColor3 = Color3.new(0.2,0.5,0.5) | |
622 | end | |
623 | coroutine.resume(coroutine.create(function() | |
624 | wait(0.25) | |
625 | for i = 0 , 1 , 0.075 do | |
626 | wait() | |
627 | bill.StudsOffset = Vector3.new(OffsetX,OffsetY+5*i,OffsetZ) | |
628 | tex.TextTransparency = 1*i | |
629 | end | |
630 | bill.Parent = nil | |
631 | end)) | |
632 | end | |
633 | function FireEff(Part,Time,Color1,Color2,Color3) | |
634 | local Firee = Part | |
635 | local Spawn = Part | |
636 | local colors = {} | |
637 | if Color1 ~= nil then | |
638 | table.insert(colors,BrickColor.new(Color1)) | |
639 | end | |
640 | if Color2 ~= nil then | |
641 | table.insert(colors,BrickColor.new(Color2)) | |
642 | end | |
643 | if Color3 ~= nil then | |
644 | table.insert(colors,BrickColor.new(Color3)) | |
645 | end | |
646 | if Color4 ~= nil then | |
647 | table.insert(colors,BrickColor.new(Color4)) | |
648 | end | |
649 | local Embers = {} | |
650 | local modelz = Instance.new("Model",Firee) | |
651 | modelz.Name = "FireHolder" | |
652 | for X = 1, 3 do | |
653 | local f = Instance.new("Part") | |
654 | f.Parent = nil | |
655 | f.BrickColor = colors[math.random(1, # colors)] | |
656 | f.Size = Vector3.new(1,1,1) | |
657 | f.formFactor = 1 | |
658 | f.Anchored = true | |
659 | f.Locked = true | |
660 | f.CanCollide = false | |
661 | f.Transparency = 0.5 | |
662 | f.Name = "Fire" | |
663 | f.TopSurface = 0 | |
664 | f.BottomSurface = 0 | |
665 | table.insert(Embers, f) | |
666 | end | |
667 | local R = 0 | |
668 | coroutine.resume(coroutine.create(function () | |
669 | repeat | |
670 | wait() | |
671 | R = R + 1 | |
672 | for X = 1, # Embers do | |
673 | Embers[X].Parent = modelz | |
674 | local FM = math.fmod(R + X, # Embers) | |
675 | if FM == 1 then | |
676 | RandPos = Vector3.new(math.random(-Spawn.Size.x * 5, Spawn.Size.x * 5) / 10, Spawn.Size.y / 2, math.random(-Spawn.Size.x * 5, Spawn.Size.x * 5) / 10) | |
677 | RandDir = Vector3.new(math.random(-100,100), math.random(-100,100), math.random(-100,100)) | |
678 | Embers[X].CFrame = CFrame.new(Spawn.Position + RandPos, Spawn.Position + RandPos + RandDir) | |
679 | else | |
680 | Embers[X].CFrame = CFrame.new(Embers[X].Position + Vector3.new(0,0.5,0), Embers[X].Position + Vector3.new(0,0.5,0) + Embers[X].CFrame.lookVector) | |
681 | end | |
682 | end | |
683 | until R == Time | |
684 | for i = 0 ,1 , 0.1 do | |
685 | wait(0.2) | |
686 | for X = 1, # Embers do | |
687 | Embers[X].Transparency = 0.5+0.5*i | |
688 | end | |
689 | end | |
690 | for X = 1, # Embers do | |
691 | Embers[X].Parent = nil | |
692 | end | |
693 | end)) | |
694 | end | |
695 | ||
696 | function OT(hit) --Normal Damage | |
697 | if Hitdeb == 1 then return end | |
698 | if hit.Parent == nil then return end | |
699 | local hum = hit.Parent:findFirstChild("Humanoid") | |
700 | if hum ~= nil and hum ~= Character.Humanoid then | |
701 | local critrandomizer = math.random(1,crtrate) | |
702 | if critrandomizer ~= 1 then | |
703 | local rndmdamage = math.random(mindamage,maxdamage) | |
704 | damagesplat(rndmdamage,hit,false) | |
705 | hum:TakeDamage(rndmdamage) | |
706 | elseif critrandomizer == 1 then | |
707 | local rndmdamage = math.random(maxdamage,crtmaxdamage) | |
708 | damagesplat(rndmdamage,hit,true) | |
709 | hum:TakeDamage(rndmdamage) | |
710 | end | |
711 | Hitdeb = 1 | |
712 | end | |
713 | end | |
714 | ||
715 | function OTND(part) --No Debounce Damage | |
716 | coroutine.resume(coroutine.create(function() | |
717 | local dd = false | |
718 | while part.Parent ~= nil and not dd do | |
719 | wait() | |
720 | local c = game.Workspace:GetChildren(); | |
721 | for i = 1, #c do | |
722 | local hum = c[i]:findFirstChild("Humanoid") | |
723 | if hum ~= nil and hum.Health ~= 0 then | |
724 | local head = c[i]:findFirstChild("Torso"); | |
725 | if head ~= nil then | |
726 | local targ = head.Position - part.Position; ------------------------------------------------Local | |
727 | local mag = targ.magnitude; | |
728 | if mag <= 5 and c[i].Name ~= Player.Name then | |
729 | dd = true | |
730 | local rndmdamage = math.random(1,7+5*math.random()) + fireboost | |
731 | damagesplat(rndmdamage,head,false) | |
732 | hum:TakeDamage(rndmdamage) | |
733 | FireEff(head,150,"Bright red","Bright orange","Cool yellow") | |
734 | part.Parent = nil | |
735 | ||
736 | end | |
737 | end | |
738 | end | |
739 | end | |
740 | end | |
741 | end)) | |
742 | end | |
743 | ||
744 | function AoE(p,magnitude,damage,critornot) | |
745 | local c = game.Workspace:GetChildren(); | |
746 | for i = 1, #c do | |
747 | local hum = c[i]:findFirstChild("Humanoid") | |
748 | if hum ~= nil and hum.Health ~= 0 then | |
749 | local head = c[i]:findFirstChild("Head"); | |
750 | if head ~= nil then | |
751 | local targ = head.Position - p; | |
752 | local mag = targ.magnitude; | |
753 | if mag <= magnitude and c[i].Name ~= Character.Name then | |
754 | local foundd = false | |
755 | for ii = 1 , #AoETrue do | |
756 | if AoETrue[ii] == c[i].Name then | |
757 | --delay(1,function() table.remove(AoETrue,ii) end) | |
758 | --blast(2.5,0.5,"Bright red",prt2,false) | |
759 | foundd = true | |
760 | end | |
761 | end | |
762 | if foundd then | |
763 | end | |
764 | -- | |
765 | if not foundd then | |
766 | hum:TakeDamage(damage) | |
767 | damagesplat(damage,head,critornot) | |
768 | table.insert(AoETrue,c[i].Name) | |
769 | --blast(2.5,0.5,"Bright red",prt2) | |
770 | end | |
771 | end | |
772 | end | |
773 | end | |
774 | end | |
775 | end | |
776 | function AoEP(p,magnitude,damage,critornot) | |
777 | local c = game.Workspace:GetChildren(); | |
778 | for i = 1, #c do | |
779 | local hum = c[i]:findFirstChild("Humanoid") | |
780 | if hum ~= nil and hum.Health ~= 0 then | |
781 | local head = c[i]:findFirstChild("Head"); | |
782 | if head ~= nil then | |
783 | local targ = head.Position - p; | |
784 | local mag = targ.magnitude; | |
785 | if mag <= magnitude and c[i].Name ~= Character.Name then | |
786 | local foundd = false | |
787 | for ii = 1 , #AoETrue do | |
788 | if AoETrue[ii] == c[i].Name then | |
789 | --delay(1,function() table.remove(AoETrue,ii) end) | |
790 | --blast(2.5,0.5,"Bright red",prt2,false) | |
791 | foundd = true | |
792 | end | |
793 | end | |
794 | if foundd then | |
795 | end | |
796 | -- | |
797 | if not foundd then | |
798 | hum:TakeDamage(damage) | |
799 | damagesplat(damage,head,critornot) | |
800 | c[i].Humanoid.Sit = true | |
801 | coroutine.resume(coroutine.create(function() | |
802 | local bp = Instance.new("BodyVelocity",c[i].Torso) | |
803 | bp.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
804 | bp.P = bp.P*2 | |
805 | bp.velocity = CFrame.new(c[i].Torso.Position , p).lookVector * 150 + Vector3.new(0,25,0) | |
806 | coroutine.resume(coroutine.create(function() | |
807 | for i=1, | |
808 | bp.velocity.y/3 do | |
809 | bp.velocity = bp.velocity+Vector3.new(0,-4.25,0) | |
810 | wait() | |
811 | end | |
812 | bp.Parent = nil | |
813 | end)) | |
814 | c[i].Torso.RotVelocity = CFrame.new(c[i].Torso.Position , p).lookVector * 25 | |
815 | wait(0.4) c[i].Humanoid.Sit = false end)) | |
816 | table.insert(AoETrue,c[i].Name) | |
817 | end | |
818 | end | |
819 | end | |
820 | end | |
821 | end | |
822 | end | |
823 | -- | |
824 | ||
825 | local LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
826 | function effect(Color,Ref,LP,P1,returnn) | |
827 | local effectsmsh = Instance.new("BlockMesh") | |
828 | effectsmsh.Scale = Vector3.new(0.5,1,0.5) | |
829 | effectsmsh.Name = "Mesh" | |
830 | local effectsg = Instance.new("Part") | |
831 | effectsg.formFactor = 3 | |
832 | effectsg.CanCollide = false | |
833 | effectsg.Name = "Eff" | |
834 | effectsg.Locked = true | |
835 | effectsg.Anchored = true | |
836 | effectsg.Size = Vector3.new(0.2,1,0.2) | |
837 | effectsg.Parent = swordholder | |
838 | effectsmsh.Parent = effectsg | |
839 | effectsg.BrickColor = BrickColor.new(Color) | |
840 | effectsg.Reflectance = Ref | |
841 | local point1 = P1 | |
842 | local mg = (LP.p - point1.p).magnitude | |
843 | effectsg.Size = Vector3.new(0.2,mg,0.2) | |
844 | effectsg.CFrame = CFrame.new((LP.p+point1.p)/2,point1.p) * CFrame.Angles(math.rad(90),0,0) | |
845 | if returnn then return effectsg end | |
846 | coroutine.resume(coroutine.create(function() | |
847 | if not returnn then | |
848 | for i = 0 , 1 , 0.1 do | |
849 | wait() | |
850 | effectsg.Transparency = 1*i | |
851 | end | |
852 | wait() | |
853 | effectsg.Parent = nil | |
854 | end | |
855 | end)) | |
856 | end | |
857 | ||
858 | con = nil | |
859 | function dmgcnnct(p) | |
860 | con = p.Touched:connect(OT) | |
861 | end | |
862 | function dmgdc() | |
863 | if con ~= nil then | |
864 | con:disconnect() | |
865 | Hitdeb = 0 | |
866 | end | |
867 | end | |
868 | function atktype(s,e) | |
869 | coroutine.resume(coroutine.create(function () | |
870 | attacktype = e | |
871 | wait(0.5) | |
872 | repeat wait() until attack | |
873 | attacktype = s | |
874 | end)) | |
875 | end | |
876 | ||
877 | hold = false | |
878 | function Combo1a() | |
879 | attack=true | |
880 | for i = 0 , 1 , 0.1 do | |
881 | wait() | |
882 | RW.C0 = CFrame.new(1-0.5*i,0.5,-0.5-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80+10*i), math.rad(45+45*i), math.rad(-45+45*i)) | |
883 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(-45*i), math.rad(10*i), math.rad(0)) | |
884 | LW.C0 = CFrame.new(-1,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80+10*i),math.rad(-45+45*i),math.rad(45-20*i)) | |
885 | end | |
886 | dmgcnnct(hitbox) | |
887 | ss(Head,1.5) | |
888 | for i = 0 , 1 , 0.2 do | |
889 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
890 | wait() | |
891 | RW.C0 = CFrame.new(0.5+1*i,0.5,-1+1*i) * CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(90), math.rad(0)) | |
892 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(-45+135*i), math.rad(10+35*i), math.rad(0)) | |
893 | LW.C0 = CFrame.new(-1+1*i,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(0),math.rad(25+65*i)) | |
894 | effect("Bright blue",0.2,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0)) | |
895 | end | |
896 | dmgdc() | |
897 | for i = 0 , 1 , 0.2 do | |
898 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
899 | wait() | |
900 | RW.C0 = CFrame.new(1.5,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(90), math.rad(0)) | |
901 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90+20*i), math.rad(45+5*i), math.rad(0)) | |
902 | LW.C0 = CFrame.new(-0.25*i,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(0),math.rad(90+10*i)) | |
903 | effect("Bright blue",0.2,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0)) | |
904 | end | |
905 | attacktype = 2 | |
906 | coroutine.resume(coroutine.create(function () | |
907 | wait(0.25) | |
908 | attacktype = 1 | |
909 | end)) | |
910 | attack=false | |
911 | wait(0.15) | |
912 | wait() | |
913 | for i = 0 , 1 , 0.1 do | |
914 | if not attack then | |
915 | wait() | |
916 | RW.C0 = CFrame.new(1.5-0.5*i,0.5,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(90-10*i), math.rad(90-45*i), math.rad(-45*i)) | |
917 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(110-110*i), math.rad(50-50*i), math.rad(0)) | |
918 | LW.C0 = CFrame.new(-0.25-0.75*i,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(90-10*i),math.rad(-45*i),math.rad(100-55*i)) | |
919 | end | |
920 | end | |
921 | ||
922 | end | |
923 | function Combo1b() | |
924 | attack=true | |
925 | for i = 0 , 1 , 0.1 do | |
926 | wait() | |
927 | RW.C0 = CFrame.new(1.5-0.5*i,0.5,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(90), math.rad(0)) | |
928 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(110-155*i), math.rad(50-40*i), math.rad(0)) | |
929 | LW.C0 = CFrame.new(-0.25-0.75*i,0.5,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(0),math.rad(100-50*i)) | |
930 | end | |
931 | ||
932 | cs(Head,1.5) | |
933 | local tempmod = Instance.new("Model",swordholder) | |
934 | for l = 1 , 20 do | |
935 | local meshz = Instance.new("SpecialMesh") | |
936 | meshz.Scale = Vector3.new(0.5,0.5,0.5) | |
937 | meshz.MeshType = "Sphere" | |
938 | local shellz = Instance.new("Part") | |
939 | meshz.Parent = shellz | |
940 | shellz.Anchored = false | |
941 | shellz.formFactor = 0 | |
942 | shellz.Size = Vector3.new(1,1,1) | |
943 | shellz.CFrame = hitbox.CFrame * CFrame.new(math.random(-5,5),math.random(-5,5),math.random(-5,5)) | |
944 | shellz.Parent = tempmod | |
945 | shellz.Transparency = 0.5 | |
946 | shellz.BrickColor = BrickColor.new("Bright violet") | |
947 | shellz.CanCollide = false | |
948 | shellz.Reflectance = 0.25 | |
949 | local bv = Instance.new("BodyPosition") | |
950 | bv.Parent = shellz | |
951 | bv.maxForce = Vector3.new(200000,200000,200000) | |
952 | bv.position = shellz.Position | |
953 | coroutine.resume(coroutine.create(function() | |
954 | for i = 0 , 1 , 0.025 do | |
955 | wait() | |
956 | shellz.Transparency = 1-1*i | |
957 | end | |
958 | shellz.Transparency = 0 | |
959 | end)) | |
960 | coroutine.resume(coroutine.create(function() | |
961 | wait(0.05) | |
962 | bv.position = hitbox.Position | |
963 | for i = 1 , 20 do | |
964 | wait(0.1) | |
965 | bv.position = shell.Position | |
966 | end | |
967 | shellz.Parent = nil | |
968 | end)) | |
969 | wait(0.01) | |
970 | end | |
971 | coroutine.resume(coroutine.create(function () | |
972 | wait(0.25) | |
973 | tempmod.Parent = nil | |
974 | end)) | |
975 | for i = 0 , 1 , 0.2 do | |
976 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
977 | wait() | |
978 | RW.C0 = CFrame.new(1-0.5*i,0.5,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(90), math.rad(0)) | |
979 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(-45+135*i), math.rad(10), math.rad(0)) | |
980 | LW.C0 = CFrame.new(-1+1.5*i,0.5,-1*i) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(0),math.rad(50+40*i)) | |
981 | effect("Really red",0,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0)) | |
982 | end | |
983 | local gyro = Instance.new("BodyGyro") | |
984 | gyro.maxTorque = Vector3.new(math.huge,math.huge,math.huge) | |
985 | gyro.P = gyro.P + 10000 | |
986 | local CF = Torso.CFrame | |
987 | gyro.cframe = CF | |
988 | gyro.Parent = Torso | |
989 | dmgcnnct(hitbox) | |
990 | ss(Head,1) | |
991 | for i = 0 , 1 , 0.1 do | |
992 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
993 | wait() | |
994 | gyro.cframe = CF * CFrame.Angles(0,math.rad(-360*i),0) | |
995 | effect("Really red",0,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0)) | |
996 | end | |
997 | ss(Head,1) | |
998 | Hitdeb = 0 | |
999 | for i = 0 , 1 , 0.1 do | |
1000 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1001 | wait() | |
1002 | gyro.cframe = CF * CFrame.Angles(0,math.rad(-360*i),0) | |
1003 | effect("Really red",0,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0)) | |
1004 | end | |
1005 | dmgdc() | |
1006 | attacktype = 3 | |
1007 | coroutine.resume(coroutine.create(function () | |
1008 | wait(0.5) | |
1009 | attacktype = 1 | |
1010 | end)) | |
1011 | wait(0.15) | |
1012 | wait() | |
1013 | gyro.Parent = nil | |
1014 | attack=false | |
1015 | for i = 0 , 1 , 0.1 do | |
1016 | if not attack then | |
1017 | wait() | |
1018 | RW.C0 = CFrame.new(0.5+0.5*i,0.5,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(90-10*i), math.rad(90-45*i), math.rad(-45*i)) | |
1019 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90-90*i), math.rad(10-10*i), math.rad(0)) | |
1020 | LW.C0 = CFrame.new(0.5-1.5*i,0.5,-1+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(90-10*i),math.rad(-45*i),math.rad(50-5*i)) | |
1021 | end | |
1022 | end | |
1023 | end | |
1024 | ||
1025 | function Combo1c() | |
1026 | attack=true | |
1027 | local bp = Instance.new("BodyPosition") | |
1028 | bp.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
1029 | bp.P = bp.P + 10000 | |
1030 | local CF = Torso.CFrame | |
1031 | bp.position = CF.p | |
1032 | bp.Parent = Torso | |
1033 | RWLFunc() | |
1034 | LWLFunc() | |
1035 | for zz = 1 , 2 do | |
1036 | local mesh = Instance.new("SpecialMesh") | |
1037 | mesh.MeshType = "FileMesh" | |
1038 | mesh.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
1039 | mesh.Scale = Vector3.new(10,5,10) * Vector3.new(0.01,0.01,0.01) | |
1040 | local shell = Instance.new("Part") | |
1041 | mesh.Parent = shell | |
1042 | shell.Anchored = true | |
1043 | shell.formFactor = 1 | |
1044 | shell.Size = Vector3.new(1,1,1) | |
1045 | shell.CFrame = Torso.CFrame * CFrame.Angles(0,0.5*zz,0) + Vector3.new(0,-2.5,0) -- + shellspawn.CFrame.lookVector * 2 | |
1046 | shell.Parent = swordholder | |
1047 | shell.Transparency = 0 | |
1048 | shell.BrickColor = BrickColor.new("White") | |
1049 | shell.CanCollide = false | |
1050 | coroutine.resume(coroutine.create(function() | |
1051 | for i = 0 , 1 , 0.05 do | |
1052 | wait() | |
1053 | mesh.Scale = Vector3.new(10,5,10) * Vector3.new(i,1,i) | |
1054 | shell.Transparency = 1*i | |
1055 | end | |
1056 | shell.Transparency = 1 | |
1057 | shell.Parent = nil | |
1058 | end)) | |
1059 | end | |
1060 | for i = 0 , 1 , 0.1 do | |
1061 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1062 | wait() | |
1063 | RW.C0 = CFrame.new(0.5+0.5*i,0.5+1*i,0) * CFrame.fromEulerAnglesXYZ(math.rad(90+100*i), math.rad(90-90*i), math.rad(-45*i)) | |
1064 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90-90*i), math.rad(10-10*i), math.rad(0)) | |
1065 | LW.C0 = CFrame.new(0.5-1.5*i,0.5+1*i,-1+1*i) * CFrame.fromEulerAnglesXYZ(math.rad(90+100*i),math.rad(0),math.rad(50-5*i)) | |
1066 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
1067 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90-45*i)) * CFrame.new(0, 0, 0.2) | |
1068 | bp.position = CF.p + Vector3.new(0,10,0) | |
1069 | RWL.C0 = CFrame.new(1, -1, 0) * CFrame.fromEulerAnglesXYZ(math.rad(-20*i), math.rad(0), math.rad(0)) | |
1070 | LWL.C0 = CFrame.new(-1, -1, 0) * CFrame.fromEulerAnglesXYZ(math.rad(-20*i), math.rad(0), math.rad(0)) | |
1071 | prt8.Transparency = 1-1*i | |
1072 | effect("Really black",0,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0)) | |
1073 | end | |
1074 | cs(Head,1.5) | |
1075 | coroutine.resume(coroutine.create(function () | |
1076 | local tempmod = Instance.new("Model",swordholder) | |
1077 | for l = 1 , 20 do | |
1078 | local meshz = Instance.new("SpecialMesh") | |
1079 | meshz.Scale = Vector3.new(1.5,1.5,1.5) | |
1080 | meshz.MeshType = "Sphere" | |
1081 | local shellz = Instance.new("Part") | |
1082 | meshz.Parent = shellz | |
1083 | shellz.Anchored = false | |
1084 | shellz.formFactor = 0 | |
1085 | shellz.Size = Vector3.new(1,1,1) | |
1086 | shellz.CFrame = hitbox.CFrame * CFrame.new(math.random(-15,15),math.random(-15,15),math.random(-15,15)) | |
1087 | shellz.Parent = tempmod | |
1088 | shellz.Transparency = 0.5 | |
1089 | shellz.BrickColor = BrickColor.new("Really black") | |
1090 | shellz.CanCollide = false | |
1091 | shellz.Reflectance = 0 | |
1092 | local bv = Instance.new("BodyPosition") | |
1093 | bv.Parent = shellz | |
1094 | bv.maxForce = Vector3.new(200000,200000,200000) | |
1095 | bv.position = shellz.Position | |
1096 | local hx = false | |
1097 | coroutine.resume(coroutine.create(function() | |
1098 | for i = 0 , 1 , 0.05 do | |
1099 | wait() | |
1100 | shellz.Transparency = 1-1*i | |
1101 | end | |
1102 | shellz.Transparency = 0 | |
1103 | end)) | |
1104 | coroutine.resume(coroutine.create(function() | |
1105 | wait(0.05) | |
1106 | bv.position = hitbox.Position | |
1107 | for i = 1 , 20 do | |
1108 | wait(0.1) | |
1109 | bv.position = shell.Position | |
1110 | end | |
1111 | shellz.Parent = nil | |
1112 | end)) | |
1113 | wait(0.01) | |
1114 | end | |
1115 | coroutine.resume(coroutine.create(function () | |
1116 | repeat wait() until hx | |
1117 | tempmod.Parent = nil | |
1118 | end)) | |
1119 | end)) | |
1120 | for i = 0 , 1 , 0.1 do | |
1121 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1122 | wait() | |
1123 | RW.C0 = CFrame.new(1,1.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(190+20*i), math.rad(0), math.rad(-45)) | |
1124 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1125 | LW.C0 = CFrame.new(-1,1.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(190+20*i),math.rad(0),math.rad(45)) | |
1126 | effect("Really black",0,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0)) | |
1127 | end | |
1128 | for i = 0 , 1 , 0.1 do | |
1129 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1130 | wait() | |
1131 | RW.C0 = CFrame.new(1,1.5-1*i,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(210-130*i), math.rad(0), math.rad(-45)) | |
1132 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1133 | LW.C0 = CFrame.new(-1,1.5-1*i,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(210-130*i),math.rad(0),math.rad(45)) | |
1134 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
1135 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180*i), math.rad(45)) * CFrame.new(0, 0, 0.2) | |
1136 | bp.position = CF.p + CF.lookVector * 2.5 + Vector3.new(0,-1,0) | |
1137 | RWL.C0 = CFrame.new(1, -1+1*i, -1*i) * CFrame.fromEulerAnglesXYZ(math.rad(-20+20*i), math.rad(0), math.rad(0)) | |
1138 | LWL.C0 = CFrame.new(-1, -1+1*i, -1*i) * CFrame.fromEulerAnglesXYZ(math.rad(-20+20*i), math.rad(0), math.rad(0)) | |
1139 | effect("Really black",0,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0)) | |
1140 | end | |
1141 | hx = true | |
1142 | wait(0.1) | |
1143 | local Hit,A, B = Raycast(hitbox.Position + Vector3.new(0,3,0) + Torso.CFrame.lookVector * 1 ,hitbox.Position + Vector3.new(0,3,0) + Torso.CFrame.lookVector * 101 ,100) | |
1144 | local effectsmsh = Instance.new("CylinderMesh") | |
1145 | effectsmsh.Scale = Vector3.new(1,1,1) | |
1146 | local effectsg = Instance.new("Part") | |
1147 | effectsg.formFactor = 3 | |
1148 | effectsg.CanCollide = false | |
1149 | effectsg.Name = "LAZOR" | |
1150 | effectsg.Locked = true | |
1151 | effectsg.Anchored = true | |
1152 | effectsg.Parent = swordholder | |
1153 | effectsmsh.Parent = effectsg | |
1154 | effectsg.BrickColor = BrickColor.new("Black") | |
1155 | effectsg.Reflectance = 0.5 | |
1156 | local point1 = B | |
1157 | local point0 = A | |
1158 | for zz = 1 , 5 do | |
1159 | local mesh = Instance.new("SpecialMesh") | |
1160 | mesh.MeshType = "FileMesh" | |
1161 | mesh.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
1162 | mesh.Scale = Vector3.new(10,5,10) * Vector3.new(0.01,0.01,0.01) | |
1163 | local shell = Instance.new("Part") | |
1164 | mesh.Parent = shell | |
1165 | shell.Anchored = true | |
1166 | shell.formFactor = 1 | |
1167 | shell.Size = Vector3.new(1,1,1) | |
1168 | shell.CFrame = CFrame.new((point0+point1)/2,point1) + CFrame.new((point0+point1)/2,point1).lookVector * (((point0)-(point1)).magnitude /-2) + Torso.CFrame.lookVector * 2 | |
1169 | shell.CFrame = shell.CFrame * CFrame.Angles(math.rad(-90),0.5*zz,0) | |
1170 | shell.Parent = swordholder | |
1171 | shell.Transparency = 0 | |
1172 | if math.fmod(zz,2) == 0 then | |
1173 | shell.BrickColor = BrickColor.new("Really black") | |
1174 | else | |
1175 | shell.BrickColor = BrickColor.new("Bright violet") | |
1176 | end | |
1177 | shell.CanCollide = false | |
1178 | coroutine.resume(coroutine.create(function() | |
1179 | for i = 0 , 1 , 0.01 do | |
1180 | wait() | |
1181 | mesh.Scale = Vector3.new(10,5,10) * Vector3.new(i,1,i) | |
1182 | shell.Transparency = 1*i | |
1183 | end | |
1184 | shell.Transparency = 1 | |
1185 | shell.Parent = nil | |
1186 | end)) | |
1187 | end | |
1188 | for zz = 1 , 1 do | |
1189 | local mesh = Instance.new("SpecialMesh") | |
1190 | mesh.MeshType = "Sphere" | |
1191 | mesh.Scale = Vector3.new(20,15,10) * Vector3.new(0.01,0.01,0.01) | |
1192 | local shell = Instance.new("Part") | |
1193 | mesh.Parent = shell | |
1194 | shell.Anchored = true | |
1195 | shell.formFactor = 1 | |
1196 | shell.Size = Vector3.new(1,1,1) | |
1197 | shell.CFrame = CFrame.new((point0+point1)/2,point1) + CFrame.new((point0+point1)/2,point1).lookVector * (((point0)-(point1)).magnitude /-2) + Torso.CFrame.lookVector * 10 | |
1198 | shell.CFrame = shell.CFrame * CFrame.Angles(math.rad(-90),0,0) | |
1199 | shell.Parent = swordholder | |
1200 | shell.Transparency = 0 | |
1201 | shell.BrickColor = BrickColor.new("Bright violet") | |
1202 | shell.CanCollide = false | |
1203 | coroutine.resume(coroutine.create(function() | |
1204 | for i = 0 , 1 , 0.02 do | |
1205 | wait() | |
1206 | mesh.Scale = Vector3.new(10,15,15) * Vector3.new(i,1,i) | |
1207 | shell.CFrame = shell.CFrame * CFrame.Angles(0,i,0) | |
1208 | shell.Transparency = 1-1*i | |
1209 | end | |
1210 | for i = 0 , 1 , 0.05 do | |
1211 | wait() | |
1212 | shell.CFrame = shell.CFrame * CFrame.Angles(0,i,0) | |
1213 | shell.Transparency = 1*i | |
1214 | end | |
1215 | shell.Transparency = 1 | |
1216 | shell.Parent = nil | |
1217 | end)) | |
1218 | end | |
1219 | for zz = 1 , 1 do | |
1220 | local mesh = Instance.new("CylinderMesh") | |
1221 | mesh.Scale = Vector3.new(20,0.5,10) * Vector3.new(0.01,0.01,0.01) | |
1222 | local shell = Instance.new("Part") | |
1223 | mesh.Parent = shell | |
1224 | shell.Anchored = true | |
1225 | shell.formFactor = 1 | |
1226 | shell.Size = Vector3.new(1,1,1) | |
1227 | shell.CFrame = CFrame.new((point0+point1)/2,point1) + CFrame.new((point0+point1)/2,point1).lookVector * (((point0)-(point1)).magnitude /-2) + Torso.CFrame.lookVector * -0.5 | |
1228 | shell.CFrame = shell.CFrame * CFrame.Angles(math.rad(-90),0,0) | |
1229 | shell.Parent = swordholder | |
1230 | shell.Transparency = 0 | |
1231 | shell.BrickColor = BrickColor.new("Bright violet") | |
1232 | shell.CanCollide = false | |
1233 | coroutine.resume(coroutine.create(function() | |
1234 | for i = 0 , 1 , 0.02 do | |
1235 | wait() | |
1236 | mesh.Scale = Vector3.new(20,0.5,20) * Vector3.new(i,1,i) | |
1237 | shell.Transparency = 1-1*i | |
1238 | end | |
1239 | for i = 0 , 1 , 0.02 do | |
1240 | wait() | |
1241 | shell.Transparency = 1*i | |
1242 | end | |
1243 | shell.Transparency = 1 | |
1244 | shell.Parent = nil | |
1245 | end)) | |
1246 | end | |
1247 | for zz = 1 , 10 do | |
1248 | local mesh = Instance.new("SpecialMesh") | |
1249 | mesh.MeshType = "FileMesh" | |
1250 | mesh.MeshId = "http://www.roblox.com/Asset/?id=9756362" | |
1251 | mesh.Scale = Vector3.new(5,5,5) * Vector3.new(0.01,0.01,0.01) | |
1252 | local shell = Instance.new("Part") | |
1253 | mesh.Parent = shell | |
1254 | shell.Anchored = true | |
1255 | shell.formFactor = 1 | |
1256 | shell.Size = Vector3.new(1,1,1) | |
1257 | shell.CFrame = CFrame.new((point0+point1)/2,point1) + CFrame.new((point0+point1)/2,point1).lookVector * (((point0)-(point1)).magnitude /2) | |
1258 | shell.CFrame = shell.CFrame * CFrame.Angles(math.rad(-90)+2*math.random(),2*math.random(),2*math.random()) | |
1259 | shell.Parent = swordholder | |
1260 | shell.Transparency = 0 | |
1261 | if math.fmod(zz,2) == 0 then | |
1262 | shell.BrickColor = BrickColor.new("Really black") | |
1263 | else | |
1264 | shell.BrickColor = BrickColor.new("Bright violet") | |
1265 | end | |
1266 | shell.CanCollide = false | |
1267 | coroutine.resume(coroutine.create(function() | |
1268 | for i = 0 , 1 , 0.01 do | |
1269 | wait() | |
1270 | mesh.Scale = Vector3.new(25,25,25) * Vector3.new(i,i,i) | |
1271 | shell.Transparency = 1*i | |
1272 | end | |
1273 | shell.Transparency = 1 | |
1274 | shell.Parent = nil | |
1275 | end)) | |
1276 | end | |
1277 | coroutine.resume(coroutine.create(function() | |
1278 | effectsg.Transparency = 1 | |
1279 | for i = 0 , 1 , 0.1 do | |
1280 | wait() | |
1281 | effectsg.Transparency = 1-1*i | |
1282 | end | |
1283 | wait(2) | |
1284 | for i = 0 , 1 , 0.1 do | |
1285 | wait() | |
1286 | effectsg.Transparency = 1*i | |
1287 | end | |
1288 | effectsg.Parent = nil | |
1289 | end)) | |
1290 | local mg = 100 | |
1291 | if Hit ~= nil then | |
1292 | mg = (point0-point1).magnitude | |
1293 | elseif Hit == nil then | |
1294 | mg = 100 | |
1295 | end | |
1296 | ls(Head,0.5) | |
1297 | ls(Head,0.75) | |
1298 | cs(Head,0.25) | |
1299 | ls(Head,1) | |
1300 | ls(Head,3) | |
1301 | cs(Head,0.15) | |
1302 | for mgg = 0 , 1,0.1 do | |
1303 | wait() | |
1304 | effectsg.Size = Vector3.new(5,(mg*mgg)+0.2,5) | |
1305 | local durr = CFrame.new((point0+(point1))/2,(point1)) | |
1306 | effectsg.CFrame = CFrame.new((point0+(point1-durr.lookVector * (mg*(1-mgg))))/2,(point1)) * CFrame.Angles(math.rad(90),0,0) | |
1307 | end | |
1308 | local critrandomizer = math.random(1,crtrate) | |
1309 | if critrandomizer ~= 1 then | |
1310 | local rndmdamage = math.random(mindamage+30,maxdamage+30) | |
1311 | AoEP((CFrame.new((point0+point1)/2,point1) + CFrame.new((point0+point1)/2,point1).lookVector * (((point0)-(point1)).magnitude /2)).p,15,rndmdamage+darkboost,false) | |
1312 | elseif critrandomizer == 1 then | |
1313 | local rndmdamage = math.random(maxdamage+30,crtmaxdamage+30) | |
1314 | AoEP((CFrame.new((point0+point1)/2,point1) + CFrame.new((point0+point1)/2,point1).lookVector * (((point0)-(point1)).magnitude /2)).p,15,rndmdamage+darkboost,true) | |
1315 | end | |
1316 | bp.Parent = nil | |
1317 | for i = 0 , 1 , 0.1 do | |
1318 | wait() | |
1319 | RW.C0 = CFrame.new(1,1-0.5*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80), math.rad(90-45*i), math.rad(-45)) | |
1320 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1321 | LW.C0 = CFrame.new(-1,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80),math.rad(-45*i),math.rad(45)) | |
1322 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
1323 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180-180*i), math.rad(45+45*i)) * CFrame.new(0, 0, 0.2) | |
1324 | RWL.C0 = CFrame.new(1, -1*i, -1+1*i) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1325 | LWL.C0 = CFrame.new(-1, -1*i, -1+1*i) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1326 | prt8.Transparency = 1*i | |
1327 | end | |
1328 | for ii = 1 , #AoETrue do | |
1329 | table.remove(AoETrue,#AoETrue) | |
1330 | end | |
1331 | RWLRem() | |
1332 | LWLRem() | |
1333 | attack = false | |
1334 | attacktype = 1 | |
1335 | end | |
1336 | function BlizzardSword() | |
1337 | attack=true | |
1338 | for i = 0 , 1 , 0.2 do | |
1339 | wait() | |
1340 | RW.C0 = CFrame.new(1,0.5+1*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80+55*i), math.rad(45-45*i), math.rad(-45)) | |
1341 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1342 | LW.C0 = CFrame.new(-1,0.5+1*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80+55*i),math.rad(-45+45*i),math.rad(45)) | |
1343 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1344 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90-45*i)) * CFrame.new(0, 0, 0.2) | |
1345 | end | |
1346 | local wssave = Character.Humanoid.WalkSpeed | |
1347 | Character.Humanoid.WalkSpeed = 0 | |
1348 | ss(Head,1.5) | |
1349 | local efftab = {} | |
1350 | for i = 0 , 1 , 0.2 do | |
1351 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1352 | wait() | |
1353 | RW.C0 = CFrame.new(1,1.5-1.5*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(135-135*i), math.rad(0), math.rad(-45)) | |
1354 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1355 | LW.C0 = CFrame.new(-1,1.5-1.5*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(135-135*i),math.rad(0),math.rad(45)) | |
1356 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1357 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(45)) * CFrame.new(0, 0, 0.2) | |
1358 | local eff = effect("Bright blue",0.2,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0),true) | |
1359 | table.insert(efftab,eff) | |
1360 | end | |
1361 | local trspos = Torso.Position | |
1362 | Character.Humanoid.WalkSpeed = wssave | |
1363 | for _,efff in pairs(efftab) do | |
1364 | wait() | |
1365 | coroutine.resume(coroutine.create(function() | |
1366 | for i = 0 , 1 , 0.15 do | |
1367 | wait() | |
1368 | efff.Transparency = 1*i | |
1369 | end | |
1370 | wait() | |
1371 | efff.Transparency = 1 | |
1372 | end)) | |
1373 | end | |
1374 | for io,eff in pairs(efftab) do | |
1375 | wait() | |
1376 | for zz = 1 , 1 do | |
1377 | local mesh = Instance.new("CylinderMesh") | |
1378 | mesh.Scale = Vector3.new(0.1,0.5,0.1) | |
1379 | local shell = Instance.new("Part") | |
1380 | mesh.Parent = shell | |
1381 | shell.Anchored = true | |
1382 | shell.formFactor = 1 | |
1383 | shell.Size = Vector3.new(1,1,1) | |
1384 | local dur = CFrame.new(trspos,eff.Position) | |
1385 | local CF1 = dur * CFrame.Angles(math.rad(90),0,0) * CFrame.new(0,-6,0) | |
1386 | shell.CFrame = CF1 | |
1387 | shell.Parent = eff | |
1388 | shell.Transparency = 1 | |
1389 | shell.Reflectance = 0.25 | |
1390 | shell.BrickColor = BrickColor.new("Bright blue") | |
1391 | shell.CanCollide = false | |
1392 | is(shell,0.5) | |
1393 | coroutine.resume(coroutine.create(function() | |
1394 | for i = 0 , 1 , 0.1 do | |
1395 | wait() | |
1396 | shell.Transparency = 1-1*i | |
1397 | mesh.Scale = Vector3.new(0.1+4.9*i,0.5,0.1+4.9*i) | |
1398 | end | |
1399 | wait(0.25) | |
1400 | for i = 0 , 1 , 0.1 do | |
1401 | wait() | |
1402 | shell.Transparency = 1*i | |
1403 | mesh.Scale = Vector3.new(5-5*i,0.5-0.5*i,5-5*i) | |
1404 | end | |
1405 | shell.Parent = nil | |
1406 | end)) | |
1407 | end | |
1408 | end | |
1409 | for io,eff in pairs(efftab) do | |
1410 | wait() | |
1411 | for zz = 1 , 1 do | |
1412 | local mesh = Instance.new("SpecialMesh") | |
1413 | mesh.MeshType = "FileMesh" | |
1414 | mesh.Scale = Vector3.new(5,2,1) | |
1415 | mesh.MeshId = "rbxasset://fonts/sword.mesh" | |
1416 | local shell = Instance.new("Part") | |
1417 | mesh.Parent = shell | |
1418 | shell.Anchored = true | |
1419 | shell.formFactor = 1 | |
1420 | shell.Size = Vector3.new(2,2,5) | |
1421 | local dur = CFrame.new(trspos,eff.Position) | |
1422 | local CF1 = dur * CFrame.Angles(math.rad(180),0,0) * CFrame.new(0,0,6.5)* CFrame.Angles(0,0,math.rad(90)) | |
1423 | shell.CFrame = CF1 | |
1424 | shell.Parent = eff | |
1425 | shell.Transparency = 1 | |
1426 | shell.Reflectance = 0.25 | |
1427 | shell.BrickColor = BrickColor.new("Bright blue") | |
1428 | shell.CanCollide = false | |
1429 | local hitd = 0 | |
1430 | coroutine.resume(coroutine.create(function() | |
1431 | local dd = false | |
1432 | while shell.Parent ~= nil and not dd do | |
1433 | wait() | |
1434 | local c = game.Workspace:GetChildren(); | |
1435 | for i = 1, #c do | |
1436 | local hum = c[i]:findFirstChild("Humanoid") | |
1437 | if hum ~= nil and hum.Health ~= 0 then | |
1438 | local head = c[i]:findFirstChild("Torso"); | |
1439 | if head ~= nil then | |
1440 | local targ = head.Position - shell.Position; | |
1441 | local mag = targ.magnitude; | |
1442 | if mag <= 3 and c[i].Name ~= Player.Name then | |
1443 | dd = true | |
1444 | local critrandomizer = math.random(1,crtrate) | |
1445 | if critrandomizer ~= 1 then | |
1446 | local rndmdamage = math.random(mindamage+iceboost,maxdamage+iceboost) | |
1447 | damagesplat(rndmdamage,head,false) | |
1448 | hum:TakeDamage(rndmdamage) | |
1449 | elseif critrandomizer == 1 then | |
1450 | local rndmdamage = math.random(maxdamage+iceboost,crtmaxdamage+iceboost) | |
1451 | damagesplat(rndmdamage,head,true) | |
1452 | hum:TakeDamage(rndmdamage) | |
1453 | end | |
1454 | end | |
1455 | end | |
1456 | end | |
1457 | end | |
1458 | end | |
1459 | end)) | |
1460 | coroutine.resume(coroutine.create(function() | |
1461 | uss(eff,1) | |
1462 | ||
1463 | for i = 0 , 1 , 0.1 do | |
1464 | wait() | |
1465 | shell.Transparency = 1-1*i | |
1466 | CF1 = dur * CFrame.Angles(math.rad(180),0,0) * CFrame.new(0,0,6.5+2*i)* CFrame.Angles(0,0,math.rad(90)) | |
1467 | shell.CFrame = CF1 | |
1468 | mesh.Scale = Vector3.new(5,2,1+0.5*i) | |
1469 | end | |
1470 | wait(0.25) | |
1471 | ss(eff,2) | |
1472 | for i = 0 , 1 , 0.1 do | |
1473 | wait() | |
1474 | shell.Transparency = 1*i | |
1475 | CF1 = dur * CFrame.Angles(math.rad(180),0,0) * CFrame.new(0,0,8.5+25*i)* CFrame.Angles(0,0,math.rad(90)) | |
1476 | shell.CFrame = CF1 | |
1477 | mesh.Scale = Vector3.new(5-5*i,2-2*i,1.5-1.5*i*i) | |
1478 | end | |
1479 | shell.Parent = nil | |
1480 | end)) | |
1481 | end | |
1482 | end | |
1483 | coroutine.resume(coroutine.create(function() | |
1484 | wait(1.5) | |
1485 | for _,eff in pairs(efftab) do | |
1486 | wait() | |
1487 | eff.Parent = nil | |
1488 | end end)) | |
1489 | for i = 0 , 1 , 0.1 do | |
1490 | wait() | |
1491 | RW.C0 = CFrame.new(1,0.5*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80*i), math.rad(45*i), math.rad(-45)) | |
1492 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1493 | LW.C0 = CFrame.new(-1,0.5*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80*i),math.rad(-45*i),math.rad(45)) | |
1494 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1495 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(45+45*i)) * CFrame.new(0, 0, 0.2) | |
1496 | end | |
1497 | attack=false | |
1498 | end | |
1499 | local FTCount = 0 | |
1500 | function FlameTrail() | |
1501 | attack=true | |
1502 | for i = 0 , 1 , 0.15 do | |
1503 | wait() | |
1504 | RW.C0 = CFrame.new(1-0.5*i,0.5,-0.5-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80+10*i), math.rad(45+45*i), math.rad(-45+55*i)) | |
1505 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(-45*i), math.rad(0), math.rad(0)) | |
1506 | LW.C0 = CFrame.new(-1+0.5*i,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80),math.rad(-45),math.rad(45+20*i)) | |
1507 | end | |
1508 | wait(0.1) | |
1509 | ss(Head,1.5) | |
1510 | fs(Head,0.5+1.5*math.random()) | |
1511 | local efftab = {} | |
1512 | RW.C0 = CFrame.new(0.5,0.5,-1) * CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(90), math.rad(10)) | |
1513 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(-45), math.rad(0), math.rad(0)) | |
1514 | LW.C0 = CFrame.new(-0.5,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80),math.rad(-45),math.rad(65)) | |
1515 | dmgcnnct(hitbox) | |
1516 | for i = 0 , 1 , 0.15 do | |
1517 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1518 | wait() | |
1519 | RW.C0 = CFrame.new(0.5+1*i,0.5,-1+1*i) * CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(90), math.rad(10)) | |
1520 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(-45+135*i*i), math.rad(0), math.rad(0)) | |
1521 | LW.C0 = CFrame.new(-0.5-1*i,0.5,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80+20*i),math.rad(-45),math.rad(65-155*i)) | |
1522 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1523 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180*i), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1524 | if FTCount <= MaxFT then | |
1525 | local eff = effect("Bright red",0.2,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0),true) | |
1526 | eff.Transparency = 1 | |
1527 | table.insert(efftab,eff) | |
1528 | FTCount = FTCount + 1 | |
1529 | OTND(eff) | |
1530 | coroutine.resume(coroutine.create(function() | |
1531 | for i = 0 , 1 , 0.15 do | |
1532 | wait() | |
1533 | eff.Transparency = 1-0.5*i | |
1534 | end | |
1535 | wait() | |
1536 | eff.Transparency = 0.5 | |
1537 | end)) | |
1538 | end | |
1539 | end | |
1540 | local rndmneg = math.random(1,2) | |
1541 | if rndmneg == 1 then | |
1542 | rndmdec1 = 13 * math.random() | |
1543 | else | |
1544 | rndmdec1 = -13 * math.random() | |
1545 | end | |
1546 | for i = 0 , 1 , 0.1 do | |
1547 | wait() | |
1548 | RW.C0 = CFrame.new(1.5,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90-rndmdec1*i), math.rad(90), math.rad(10-(rndmdec1*2)*i)) | |
1549 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90+20*i), math.rad(0), math.rad(0)) | |
1550 | LW.C0 = CFrame.new(-1.5,0.5,-0) * CFrame.fromEulerAnglesXYZ(math.rad(100),math.rad(-45),math.rad(-90)) | |
1551 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1552 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1553 | end | |
1554 | ss(Head,1.5) | |
1555 | fs(Head,0.5+1.5*math.random()) | |
1556 | Hitdeb = 0 | |
1557 | for i = 0 , 1 , 0.15 do | |
1558 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1559 | wait() | |
1560 | RW.C0 = CFrame.new(1.5-1.5*i,0.5,-1*i) * CFrame.fromEulerAnglesXYZ(math.rad(90-rndmdec1), math.rad(90), math.rad(10-(rndmdec1*2))) | |
1561 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(110-200*i), math.rad(0), math.rad(0)) | |
1562 | LW.C0 = CFrame.new(-1.5+1*i,0.5,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(100-80*i),math.rad(-45),math.rad(-90+135*i)) | |
1563 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1564 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180-180*i), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1565 | if FTCount <= MaxFT then | |
1566 | local eff = effect("Bright red",0.2,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0),true) | |
1567 | eff.Transparency = 1 | |
1568 | table.insert(efftab,eff) | |
1569 | FTCount = FTCount + 1 | |
1570 | OTND(eff) | |
1571 | coroutine.resume(coroutine.create(function() | |
1572 | for i = 0 , 1 , 0.15 do | |
1573 | wait() | |
1574 | eff.Transparency = 1-0.5*i | |
1575 | end | |
1576 | wait() | |
1577 | eff.Transparency = 0.5 | |
1578 | end)) | |
1579 | end | |
1580 | end | |
1581 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1582 | for i = 0 , 1 , 0.2 do | |
1583 | wait() | |
1584 | local rndmd = rndmdec1-rndmdec1*i | |
1585 | RW.C0 = CFrame.new(0,0.5,-1) * CFrame.fromEulerAnglesXYZ(math.rad((90-rndmd)), math.rad(90), math.rad((10-(rndmd*2))-20*i)) | |
1586 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(-90-10*i), math.rad(0), math.rad(0)) | |
1587 | LW.C0 = CFrame.new(-0.5,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80),math.rad(-45),math.rad(45)) | |
1588 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1589 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1590 | end | |
1591 | for i = 0 , 1 , 0.1 do | |
1592 | wait() | |
1593 | RW.C0 = CFrame.new(1*i,0.5,-1) * CFrame.fromEulerAnglesXYZ(math.rad(90-20*i), math.rad(90-90*i), math.rad(-10-35*i)) | |
1594 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(-100+100*i), math.rad(0), math.rad(0)) | |
1595 | LW.C0 = CFrame.new(-0.5-0.5*i,0.5,-0.5-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80-10*i),math.rad(-45+45*i),math.rad(45)) | |
1596 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1597 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180*i), math.rad(90-45*i)) * CFrame.new(0, 0, 0.2) | |
1598 | end | |
1599 | ss(Head,1.5) | |
1600 | fs(Head,0.5+1.5*math.random()) | |
1601 | wait(0.1) | |
1602 | Hitdeb = 0 | |
1603 | for i = 0 , 1 , 0.2 do | |
1604 | LastPoint = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1605 | wait() | |
1606 | RW.C0 = CFrame.new(1,0.5+1*i,-1) * CFrame.fromEulerAnglesXYZ(math.rad(70+65*i), math.rad(0), math.rad(-45)) | |
1607 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1608 | LW.C0 = CFrame.new(-1,0.5+1*i,-1) * CFrame.fromEulerAnglesXYZ(math.rad(70+65*i),math.rad(0),math.rad(45)) | |
1609 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1610 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180-180*i), math.rad(45)) * CFrame.new(0, 0, 0.2) | |
1611 | if FTCount <= MaxFT then | |
1612 | local eff = effect("Bright red",0.2,LastPoint,hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0),true) | |
1613 | eff.Transparency = 1 | |
1614 | table.insert(efftab,eff) | |
1615 | FTCount = FTCount + 1 | |
1616 | OTND(eff) | |
1617 | coroutine.resume(coroutine.create(function() | |
1618 | for i = 0 , 1 , 0.15 do | |
1619 | wait() | |
1620 | eff.Transparency = 1-0.5*i | |
1621 | end | |
1622 | wait() | |
1623 | eff.Transparency = 0.5 | |
1624 | end)) | |
1625 | end | |
1626 | end | |
1627 | coroutine.resume(coroutine.create(function() | |
1628 | wait(5) | |
1629 | for _,eff in pairs(efftab) do | |
1630 | wait() | |
1631 | eff.Parent = nil | |
1632 | FTCount = FTCount - 1 | |
1633 | end end)) | |
1634 | for i = 0 , 1 , 0.1 do | |
1635 | wait() | |
1636 | RW.C0 = CFrame.new(1,1.5-1*i,-1+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(135-55*i), math.rad(45*i), math.rad(-45)) | |
1637 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1638 | LW.C0 = CFrame.new(-1,1.5-1*i,-1+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(135-55*i),math.rad(-45*i),math.rad(45)) | |
1639 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), 0) * CFrame.new(0, 0,0) | |
1640 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(45+45*i)) * CFrame.new(0, 0, 0.2) | |
1641 | end | |
1642 | dmgdc() | |
1643 | attack=false | |
1644 | end | |
1645 | ||
1646 | ||
1647 | function LifeDrain() | |
1648 | attack=true | |
1649 | for i = 0 , 1 , 0.1 do | |
1650 | wait() | |
1651 | RW.C0 = CFrame.new(1,0.5,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80+55*i), math.rad(45), math.rad(-45+90*i)) | |
1652 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(90*i), math.rad(0)) | |
1653 | LW.C0 = CFrame.new(-1+1.25*i,0.5+0.25*i,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80+25*i),math.rad(-45+90*i),math.rad(45+25*i)) | |
1654 | LW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(90*i), math.rad(0)) | |
1655 | w1.C1 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0, 0) * CFrame.new(0, 0,0) | |
1656 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1657 | end | |
1658 | ------ | |
1659 | local nrmag = 50 | |
1660 | local nrprsn = nil | |
1661 | wait() | |
1662 | -- | |
1663 | local c = game.Workspace:GetChildren(); | |
1664 | for i = 1, #c do | |
1665 | local hum = c[i]:findFirstChild("Humanoid") | |
1666 | if hum ~= nil and hum.Health ~= 0 then | |
1667 | local head = c[i]:findFirstChild("Torso"); | |
1668 | if head ~= nil then | |
1669 | local targ = head.Position - Torso.Position; | |
1670 | local mag = targ.magnitude; | |
1671 | if mag <= 50 and c[i].Name ~= Player.Name then | |
1672 | if mag < nrmag then | |
1673 | nrmag = mag | |
1674 | nrprsn = c[i] | |
1675 | end | |
1676 | end end end end | |
1677 | -- | |
1678 | if nrprsn == nil then | |
1679 | attack = false | |
1680 | return end | |
1681 | local C = 0 | |
1682 | local bp = Instance.new("BodyPosition") | |
1683 | local bg = Instance.new("BodyGyro") | |
1684 | bp.Parent = Torso | |
1685 | bp.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
1686 | bp.P = bp.P + 10000 | |
1687 | local CF = nrprsn.Torso.CFrame | |
1688 | bp.position = CF.p + CFrame.new(Torso.Position,CF.p).lookVector * -3 | |
1689 | bg.Parent = Torso | |
1690 | bg.maxTorque = Vector3.new(math.huge,math.huge,math.huge) | |
1691 | bg.P = bg.P + 100000 | |
1692 | bg.cframe = CFrame.new(Torso.Position,CF.p) * CFrame.Angles(math.rad(0),0,0) | |
1693 | ss(Head,2) | |
1694 | wait(0.1) | |
1695 | local FirstP = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1696 | local LastP = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1697 | for i = 0 , 1 , 0.2 do | |
1698 | wait() | |
1699 | C = C + 1 | |
1700 | RW.C0 = CFrame.new(1-1*i,0.5,-1*i) * CFrame.fromEulerAnglesXYZ(math.rad(135-90*i), math.rad(45), math.rad(45-135*i)) | |
1701 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(90), math.rad(0)) | |
1702 | LW.C0 = CFrame.new(0.25-1.75*i,0.75-0.25*i,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(105-60*i),math.rad(45),math.rad(70-125*i)) | |
1703 | LW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(90), math.rad(0)) | |
1704 | w1.C1 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0, 0) * CFrame.new(0, 0,0) | |
1705 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(90*i), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1706 | if C == 3 then | |
1707 | bp.P = bp.P + 10000 | |
1708 | bp.position = CF.p + CFrame.new(Torso.Position,CF.p).lookVector * 6 | |
1709 | bg.cframe = CFrame.new(Torso.Position,CF.p) * CFrame.Angles(math.rad(-45),0,0) | |
1710 | end | |
1711 | if C == 2 then | |
1712 | FirstP = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1713 | elseif C == 5 then | |
1714 | LastP = hitbox.CFrame * CFrame.new(0,hitbox.Size.y/2,0) | |
1715 | end | |
1716 | end | |
1717 | local effectsmsh = Instance.new("SpecialMesh") | |
1718 | effectsmsh.Scale = Vector3.new(5,1,5) | |
1719 | effectsmsh.MeshType = "Sphere" | |
1720 | local effectsg = Instance.new("Part") | |
1721 | effectsg.formFactor = 3 | |
1722 | effectsg.CanCollide = false | |
1723 | effectsg.Name = "Eff" | |
1724 | effectsg.Locked = true | |
1725 | effectsg.Anchored = true | |
1726 | effectsg.Size = Vector3.new(0.2,1,0.2) | |
1727 | effectsg.Parent = swordholder | |
1728 | effectsmsh.Parent = effectsg | |
1729 | effectsg.BrickColor = BrickColor.new("White") | |
1730 | effectsg.Reflectance = Ref | |
1731 | local point1 = FirstP | |
1732 | local LP = LastP | |
1733 | local mg = (LP.p - point1.p).magnitude | |
1734 | effectsg.Size = Vector3.new(0.2,mg,0.2) | |
1735 | effectsg.CFrame = CFrame.new((LP.p+point1.p)/2,point1.p) * CFrame.Angles(math.rad(90),0,0) | |
1736 | if returnn then return effectsg end | |
1737 | coroutine.resume(coroutine.create(function() | |
1738 | if not returnn then | |
1739 | for i = 0 , 1 , 0.1 do | |
1740 | wait() | |
1741 | effectsg.Transparency = 1*i | |
1742 | end | |
1743 | wait() | |
1744 | effectsg.Parent = nil | |
1745 | end | |
1746 | end)) | |
1747 | local critrandomizer = math.random(1,crtrate) | |
1748 | local rndmdamage = 0 | |
1749 | if critrandomizer ~= 1 then | |
1750 | rndmdamage = math.random(mindamage,maxdamage) | |
1751 | damagesplat(rndmdamage,nrprsn.Head,false) | |
1752 | nrprsn.Humanoid:TakeDamage(rndmdamage) | |
1753 | elseif critrandomizer == 1 then | |
1754 | rndmdamage = math.random(maxdamage,crtmaxdamage) | |
1755 | damagesplat(rndmdamage,nrprsn.Head,true) | |
1756 | nrprsn.Humanoid:TakeDamage(rndmdamage) | |
1757 | end | |
1758 | local tempmod = Instance.new("Model",Workspace) | |
1759 | for l = 1 , rndmdamage/5 do | |
1760 | local meshz = Instance.new("SpecialMesh") | |
1761 | meshz.Scale = Vector3.new(1.5,1.5,1.5) | |
1762 | meshz.MeshType = "Sphere" | |
1763 | local shellz = Instance.new("Part") | |
1764 | meshz.Parent = shellz | |
1765 | shellz.Anchored = false | |
1766 | shellz.formFactor = 0 | |
1767 | shellz.Size = Vector3.new(1,1,1) | |
1768 | shellz.CFrame = hitbox.CFrame | |
1769 | shellz.Parent = tempmod | |
1770 | shellz.Transparency = 0.5 | |
1771 | shellz.BrickColor = BrickColor.new("White") | |
1772 | shellz.CanCollide = false | |
1773 | shellz.Reflectance = 0 | |
1774 | local bv = Instance.new("BodyPosition") | |
1775 | bv.Parent = shellz | |
1776 | bv.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
1777 | bv.P = bv.P + 10000 | |
1778 | bv.position = shellz.Position + Vector3.new(math.random(-25,25),math.random(-2.5,7.5),math.random(-25,25)) | |
1779 | coroutine.resume(coroutine.create(function() | |
1780 | wait(3) | |
1781 | bv.maxForce = Vector3.new(0,math.huge,0) | |
1782 | coroutine.resume(coroutine.create(function() | |
1783 | local dd = false | |
1784 | while shellz.Transparency ~= 1 and not dd do | |
1785 | wait(0.1) | |
1786 | local cc = game.Workspace:GetChildren(); | |
1787 | for i = 1, #c do | |
1788 | local hum = cc[i]:findFirstChild("Humanoid") | |
1789 | if hum ~= nil and hum.Health ~= 0 then | |
1790 | local head = cc[i]:findFirstChild("Head"); | |
1791 | if head ~= nil then | |
1792 | local targ = head.Position - shellz.Position; | |
1793 | local mag = targ.magnitude; | |
1794 | if mag <= 5 then | |
1795 | dd = true | |
1796 | damagesplat(5+darkboost,head,false) | |
1797 | hum.Health = hum.Health + 5 + darkboost | |
1798 | for i = 0 , 1 , 0.05 do | |
1799 | wait() | |
1800 | shellz.Transparency = 1*i | |
1801 | end | |
1802 | shellz.Parent = nil | |
1803 | end | |
1804 | end | |
1805 | end | |
1806 | end | |
1807 | end | |
1808 | end)) | |
1809 | ||
1810 | end)) | |
1811 | local hx = false | |
1812 | coroutine.resume(coroutine.create(function() | |
1813 | for i = 0 , 1 , 0.05 do | |
1814 | wait() | |
1815 | shellz.Transparency = 1-1*i | |
1816 | end | |
1817 | shellz.Transparency = 0 | |
1818 | end)) | |
1819 | coroutine.resume(coroutine.create(function() | |
1820 | wait(60) | |
1821 | for ii,shellz in pairs(tempmod:GetChildren()) do | |
1822 | for i = 0 , 1 , 0.1 do | |
1823 | wait() | |
1824 | shellz.Transparency = 1*i | |
1825 | end | |
1826 | shellz.Parent = nil | |
1827 | end | |
1828 | tempmod.Parent = nil | |
1829 | end)) | |
1830 | end | |
1831 | wait(0.5) | |
1832 | ---- | |
1833 | RW.C0 = CFrame.new(1,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80), math.rad(45), math.rad(-45)) | |
1834 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1835 | LW.C0 = CFrame.new(-1,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80),math.rad(-45),math.rad(45)) | |
1836 | LW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1837 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
1838 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1839 | attack=false | |
1840 | bp.Parent = nil bg.Parent = nil | |
1841 | end | |
1842 | ||
1843 | ||
1844 | --TEST | |
1845 | ||
1846 | hammer = Torso | |
1847 | ||
1848 | function doDamage(hit) | |
1849 | local humanoid = hit.Parent:findFirstChild("Humanoid") | |
1850 | local hum = Player.Character:findFirstChild("Humanoid") -- non-nil if tool held by a character | |
1851 | if humanoid~=nil and humanoid ~= hum and hum ~= nil then | |
1852 | local foundd = false | |
1853 | for ii = 1 , #AoETrue do | |
1854 | if AoETrue[ii] == hit.Parent.Name then | |
1855 | foundd = true | |
1856 | end | |
1857 | end | |
1858 | if foundd then | |
1859 | end | |
1860 | -- | |
1861 | if not foundd then | |
1862 | humanoid:TakeDamage(5) | |
1863 | if Mode == "Fire" then | |
1864 | end | |
1865 | damagesplat(5,humanoid.Parent.Torso,false) | |
1866 | table.insert(AoETrue,hit.Parent) | |
1867 | end | |
1868 | ||
1869 | if humanoid.Health <= 0 then | |
1870 | local c = hit.CFrame | |
1871 | hit.CFrame = CFrame.new(hit.Position) | |
1872 | hit.CFrame = c | |
1873 | end | |
1874 | delay(1, function() end) | |
1875 | else | |
1876 | local c = hit.CFrame hit.CFrame = CFrame.new(hit.Position) hit.CFrame = c | |
1877 | end | |
1878 | end | |
1879 | function bewm(obj, pos, notme) | |
1880 | if (obj ~= notme) then | |
1881 | if (obj.className == "Part") or (obj.className == "Seat") then | |
1882 | if (not obj.Anchored) and (((pos - obj.Position) * Vector3.new(1, 0, 1)).magnitude < 24) and (pos.y <= obj.Position.y + 2) and (pos.y >= obj.Position.y - 2) then | |
1883 | delay((pos - obj.Position).magnitude / 24, function() obj.Velocity = ((obj.Position - pos).unit + Vector3.new(0, 0.5, 0)) * 96 + obj.Velocity obj.RotVelocity = obj.RotVelocity + Vector3.new(obj.Position.z - pos.z, 0, pos.x - obj.Position.x).unit * 40 doDamage(obj) end) | |
1884 | end | |
1885 | elseif (obj.className == "Model") or (obj.className == "Hat") or (obj.className == "Tool") or (obj == workspace) then | |
1886 | local list = obj:GetChildren() | |
1887 | for x = 1, #list do | |
1888 | bewm(list[x], pos, notme) | |
1889 | end | |
1890 | end | |
1891 | end | |
1892 | end | |
1893 | ||
1894 | function attackr() | |
1895 | local shockRing = Instance.new("Part") | |
1896 | shockRing.formFactor = 2 | |
1897 | shockRing.Size = Vector3.new(1, 0.4, 1) | |
1898 | shockRing.Anchored = true | |
1899 | shockRing.Locked = true | |
1900 | shockRing.CanCollide = false | |
1901 | shockRing.archivable = false | |
1902 | shockRing.TopSurface = 0 | |
1903 | shockRing.BottomSurface = 0 | |
1904 | shockRing.Transparency = 0 | |
1905 | if Mode == "Fire" then | |
1906 | shockRing.BrickColor = BrickColor.new("Really red") | |
1907 | elseif Mode == "Dark" then | |
1908 | shockRing.BrickColor = BrickColor.new("Bright violet") | |
1909 | elseif Mode == "Ice" then | |
1910 | shockRing.BrickColor = BrickColor.new("Bright blue") | |
1911 | shockRing.Reflectance = 0.2 | |
1912 | end | |
1913 | local decal = Instance.new("CylinderMesh") | |
1914 | decal.Parent = shockRing | |
1915 | decal.Scale = Vector3.new(1,0.1,1) | |
1916 | wait(0.2) | |
1917 | local pos = hammer.CFrame * (Vector3.new(0, -2.5, 0)) | |
1918 | bewm(game.Workspace, pos, Player.Character) | |
1919 | shockRing.CFrame = CFrame.new(pos) | |
1920 | for x = 0, 1 , 0.0625 do | |
1921 | delay((x*16) / 30, function() shockRing.Parent = nil shockRing.Size = Vector3.new(0, 0.4, 0) + Vector3.new(3.2, 0, 3.2) * (x*16) shockRing.Transparency = 1*x shockRing.Parent = Player.Character end) | |
1922 | end | |
1923 | delay(1, function() | |
1924 | shockRing.Parent = nil | |
1925 | for ii = 1 , #AoETrue do | |
1926 | table.remove(AoETrue,#AoETrue) | |
1927 | end end) | |
1928 | end | |
1929 | local modemodel = Instance.new("Model",swordholder) | |
1930 | local mrdychng = false | |
1931 | function FireMode() | |
1932 | attack=true | |
1933 | Mode = "Fire" | |
1934 | fireboost = 5 | |
1935 | mrdychng = true | |
1936 | for i = 0 , 1 , 0.1 do | |
1937 | wait() | |
1938 | RW.C0 = CFrame.new(1+0.5*i,0.5+1*i,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80+55*i), math.rad(45-45*i), math.rad(-45+45*i)) | |
1939 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1940 | LW.C0 = CFrame.new(-1+1*i,0.5+1*i,-0.5-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80-80*i),math.rad(-45+45*i),math.rad(45+65*i)) | |
1941 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
1942 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180*i), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1943 | end | |
1944 | cs(Head,1.5) | |
1945 | local tempmod = Instance.new("Model",swordholder) | |
1946 | for l = 1 , 20 do | |
1947 | local meshz = Instance.new("SpecialMesh") | |
1948 | meshz.Scale = Vector3.new(0.5,0.5,0.5) | |
1949 | meshz.MeshType = "Sphere" | |
1950 | local shellz = Instance.new("Part") | |
1951 | meshz.Parent = shellz | |
1952 | shellz.Anchored = false | |
1953 | shellz.formFactor = 0 | |
1954 | shellz.Size = Vector3.new(1,1,1) | |
1955 | shellz.CFrame = hitbox.CFrame * CFrame.new(math.random(-5,5),math.random(-5,5),math.random(-5,5)) | |
1956 | shellz.Parent = tempmod | |
1957 | shellz.Transparency = 0.5 | |
1958 | shellz.BrickColor = BrickColor.new("Really red") | |
1959 | shellz.CanCollide = false | |
1960 | shellz.Reflectance = 0 | |
1961 | local bv = Instance.new("BodyPosition") | |
1962 | bv.Parent = shellz | |
1963 | bv.maxForce = Vector3.new(200000,200000,200000) | |
1964 | bv.position = shellz.Position | |
1965 | coroutine.resume(coroutine.create(function() | |
1966 | for i = 0 , 1 , 0.025 do | |
1967 | wait() | |
1968 | shellz.Transparency = 1-1*i | |
1969 | end | |
1970 | shellz.Transparency = 0 | |
1971 | end)) | |
1972 | coroutine.resume(coroutine.create(function() | |
1973 | wait(0.05) | |
1974 | bv.position = hitbox.Position | |
1975 | for i = 1 , 20 do | |
1976 | wait(0.1) | |
1977 | bv.position = shell.Position | |
1978 | end | |
1979 | shellz.Parent = nil | |
1980 | end)) | |
1981 | wait(0.01) | |
1982 | end | |
1983 | coroutine.resume(coroutine.create(function () | |
1984 | wait(0.25) | |
1985 | tempmod.Parent = nil | |
1986 | end)) | |
1987 | for i = 0 , 1 , 0.2 do | |
1988 | wait() | |
1989 | RW.C0 = CFrame.new(1.5,1.5-1*i,0) * CFrame.fromEulerAnglesXYZ(math.rad(135-45*i), math.rad(0), math.rad(0)) | |
1990 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
1991 | LW.C0 = CFrame.new(0,1.5-1*i,-1) * CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(0),math.rad(110-45*i)) | |
1992 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
1993 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
1994 | end | |
1995 | bs(Head,0.75) | |
1996 | attackr() | |
1997 | for zz = 1 , 1 do | |
1998 | local mesh = Instance.new("SpecialMesh") | |
1999 | mesh.MeshType = "FileMesh" | |
2000 | mesh.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
2001 | mesh.Scale = Vector3.new(10,5,10) * Vector3.new(0.01,0.01,0.01) | |
2002 | local shell = Instance.new("Part") | |
2003 | mesh.Parent = shell | |
2004 | shell.Anchored = true | |
2005 | shell.formFactor = 1 | |
2006 | shell.Size = Vector3.new(1,1,1) | |
2007 | shell.CFrame = Torso.CFrame * CFrame.new(0,-1.5,0) | |
2008 | shell.Parent = swordholder | |
2009 | shell.Transparency = 0 | |
2010 | shell.BrickColor = BrickColor.new("Really red") | |
2011 | shell.CanCollide = false | |
2012 | coroutine.resume(coroutine.create(function() | |
2013 | for i = 0 , 1 , 0.075 do | |
2014 | wait() | |
2015 | mesh.Scale = Vector3.new(20,5,20) * Vector3.new(i,1,i) | |
2016 | shell.Transparency = 1*i | |
2017 | end | |
2018 | shell.Transparency = 1 | |
2019 | shell.Parent = nil | |
2020 | end)) | |
2021 | end | |
2022 | for zz = 1 , 1 do | |
2023 | local mesh = Instance.new("SpecialMesh") | |
2024 | mesh.MeshType = "FileMesh" | |
2025 | mesh.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
2026 | mesh.Scale = Vector3.new(10,20,10) * Vector3.new(0.01,0.01,0.01) | |
2027 | local shell = Instance.new("Part") | |
2028 | mesh.Parent = shell | |
2029 | shell.Anchored = true | |
2030 | shell.formFactor = 1 | |
2031 | shell.Size = Vector3.new(1,1,1) | |
2032 | shell.CFrame = Torso.CFrame * CFrame.new(0,1,0) | |
2033 | shell.Parent = swordholder | |
2034 | shell.Transparency = 0 | |
2035 | shell.BrickColor = BrickColor.new("Really red") | |
2036 | shell.CanCollide = false | |
2037 | coroutine.resume(coroutine.create(function() | |
2038 | for i = 0 , 1 , 0.05 do | |
2039 | wait() | |
2040 | mesh.Scale = Vector3.new(10,20,10) * Vector3.new(i,1,i) | |
2041 | shell.Transparency = 1*i | |
2042 | end | |
2043 | shell.Transparency = 1 | |
2044 | shell.Parent = nil | |
2045 | end)) | |
2046 | end | |
2047 | for zz = 1 , 3 do | |
2048 | local mesh = Instance.new("SpecialMesh") | |
2049 | mesh.MeshType = "Sphere" | |
2050 | mesh.Scale = Vector3.new(5*zz,5*zz,5*zz) * Vector3.new(0.01,0.01,0.01) | |
2051 | local shell = Instance.new("Part") | |
2052 | mesh.Parent = shell | |
2053 | shell.Anchored = true | |
2054 | shell.formFactor = 3 | |
2055 | shell.Size = Vector3.new(1,1,1) | |
2056 | shell.CFrame = Torso.CFrame * CFrame.new(0,-1,0) | |
2057 | shell.Parent = swordholder | |
2058 | shell.Transparency = 0 | |
2059 | if math.fmod(zz,2) == 1 then | |
2060 | shell.BrickColor = BrickColor.new("Bright orange") | |
2061 | elseif math.fmod(zz,2) == 0.5 then | |
2062 | shell.BrickColor = BrickColor.new("Bright red") | |
2063 | else | |
2064 | shell.BrickColor = BrickColor.new("Bright yellow") | |
2065 | end | |
2066 | shell.CanCollide = false | |
2067 | coroutine.resume(coroutine.create(function() | |
2068 | for i = 0 , 1 , 0.025 do | |
2069 | wait() | |
2070 | mesh.Scale = Vector3.new(10*zz,10*zz,10*zz) * Vector3.new(i,i,i) | |
2071 | shell.Transparency = 1*i | |
2072 | end | |
2073 | shell.Transparency = 1 | |
2074 | shell.Parent = nil | |
2075 | end)) | |
2076 | end | |
2077 | ||
2078 | ||
2079 | for ii,z in pairs(modemodel:GetChildren()) do | |
2080 | z.Parent = nil | |
2081 | end | |
2082 | ||
2083 | local wing1m = Instance.new("BlockMesh") | |
2084 | wing1m.Scale = Vector3.new(1,1,1) | |
2085 | local wing1p = Instance.new("Part") | |
2086 | wing1p.formFactor = 3 | |
2087 | wing1p.CanCollide = false | |
2088 | wing1p.Name = "FlameWingP1" | |
2089 | wing1p.Locked = true | |
2090 | wing1p.Size = Vector3.new(0.2,0.2,0.2) | |
2091 | wing1p.Parent = modemodel | |
2092 | wing1m.Parent = wing1p | |
2093 | wing1p.BrickColor = BrickColor.new("Bright red") | |
2094 | wing1p.Transparency = 1 | |
2095 | local wing1w = Instance.new("Weld") | |
2096 | wing1w.Parent = wing1p | |
2097 | wing1w.Part0 = wing1p | |
2098 | wing1w.Part1 = Torso | |
2099 | wing1w.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0 , 0) | |
2100 | wing1w.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,math.rad(0)) * CFrame.new(-1, 0, 0) | |
2101 | local wing2m = Instance.new("BlockMesh") | |
2102 | wing2m.Scale = Vector3.new(1,1,1) | |
2103 | local wing2p = Instance.new("Part") | |
2104 | wing2p.formFactor = 3 | |
2105 | wing2p.CanCollide = false | |
2106 | wing2p.Name = "FlameWingP2" | |
2107 | wing2p.Locked = true | |
2108 | wing2p.Size = Vector3.new(0.2,0.2,0.2) | |
2109 | wing2p.Parent = modemodel | |
2110 | wing2m.Parent = wing2p | |
2111 | wing2p.BrickColor = BrickColor.new("Bright red") | |
2112 | wing2p.Transparency = 1 | |
2113 | local wing2w = Instance.new("Weld") | |
2114 | wing2w.Parent = wing2p | |
2115 | wing2w.Part0 = wing2p | |
2116 | wing2w.Part1 = Torso | |
2117 | wing2w.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0 , 0) | |
2118 | wing2w.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,math.rad(0)) * CFrame.new(1, 0, 0) | |
2119 | coroutine.resume(coroutine.create(function() | |
2120 | for ringi = math.rad(-20) , math.rad(130) , math.rad(10) do | |
2121 | wait(0.1) | |
2122 | local ringm = Instance.new("BlockMesh") | |
2123 | ringm.Scale = Vector3.new(1,1,1) | |
2124 | local ringp = Instance.new("Part") | |
2125 | ringp.formFactor = 3 | |
2126 | ringp.CanCollide = false | |
2127 | ringp.Name = "FlameWing"..ringi | |
2128 | ringp.Locked = true | |
2129 | ringp.Size = Vector3.new(0.2,2,0.8) | |
2130 | ringp.Parent = modemodel | |
2131 | ringm.Parent = ringp | |
2132 | ringp.BrickColor = BrickColor.new("Bright red") | |
2133 | ringp.Reflectance = 0.1 | |
2134 | ringp.Transparency = 1 | |
2135 | local ringw = Instance.new("Weld") | |
2136 | ringw.Parent = ringp | |
2137 | ringw.Part0 = ringp | |
2138 | ringw.Part1 = wing1p | |
2139 | ringw.C1 = CFrame.fromEulerAnglesXYZ(ringi, 0, 0) * CFrame.new(0, ringp.Size.y/4 , 0) | |
2140 | ringw.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,math.rad(45)) * CFrame.new(0, -1, 0) --* CFrame.new(-0.6, 0, 0) ---msh5.Scale.x/1.625 | |
2141 | coroutine.resume(coroutine.create(function() | |
2142 | for i = 0 , 1 , 0.025 do | |
2143 | wait() | |
2144 | ringp.Transparency = 1-1*i | |
2145 | end | |
2146 | ringp.Transparency = 0 | |
2147 | end)) | |
2148 | end end)) | |
2149 | coroutine.resume(coroutine.create(function() | |
2150 | for ringi = math.rad(-20) , math.rad(130) , math.rad(10) do | |
2151 | wait(0.1) | |
2152 | local ringm = Instance.new("BlockMesh") | |
2153 | ringm.Scale = Vector3.new(1,1,1) | |
2154 | local ringp = Instance.new("Part") | |
2155 | ringp.formFactor = 3 | |
2156 | ringp.CanCollide = false | |
2157 | ringp.Name = "FlameWing2_"..ringi | |
2158 | ringp.Locked = true | |
2159 | ringp.Size = Vector3.new(0.2,2,0.8) | |
2160 | ringp.Parent = modemodel | |
2161 | ringm.Parent = ringp | |
2162 | ringp.BrickColor = BrickColor.new("Bright red") | |
2163 | ringp.Reflectance = 0.1 | |
2164 | ringp.Transparency = 1 | |
2165 | local ringw = Instance.new("Weld") | |
2166 | ringw.Parent = ringp | |
2167 | ringw.Part0 = ringp | |
2168 | ringw.Part1 = wing2p | |
2169 | ringw.C1 = CFrame.fromEulerAnglesXYZ(ringi+math.rad(0), 0, 0) * CFrame.new(-0, ringp.Size.y/4 , 0) | |
2170 | ringw.C0 = CFrame.fromEulerAnglesXYZ(0, 0,math.rad(-45)) * CFrame.new(-0, -1, 0) | |
2171 | coroutine.resume(coroutine.create(function() | |
2172 | for i = 0 , 1 , 0.025 do | |
2173 | wait() | |
2174 | ringp.Transparency = 1-1*i | |
2175 | end | |
2176 | ringp.Transparency = 0 | |
2177 | end)) | |
2178 | end end)) | |
2179 | local wingp1m = Instance.new("SpecialMesh") | |
2180 | wingp1m.Scale = Vector3.new(1,1,1) | |
2181 | wingp1m.MeshType = "Sphere" | |
2182 | local wingp1p = Instance.new("Part") | |
2183 | wingp1p.formFactor = 3 | |
2184 | wingp1p.CanCollide = false | |
2185 | wingp1p.Name = "FlameOrb" | |
2186 | wingp1p.Locked = true | |
2187 | wingp1p.Size = Vector3.new(1,1,1) | |
2188 | wingp1p.Parent = modemodel | |
2189 | wingp1m.Parent = wingp1p | |
2190 | wingp1p.Reflectance = 0.2 | |
2191 | wingp1p.BrickColor = BrickColor.new("Bright red") | |
2192 | local wingp1w = Instance.new("Weld") | |
2193 | wingp1w.Parent = wingp1p | |
2194 | wingp1w.Part0 = wingp1p | |
2195 | wingp1w.Part1 = Torso | |
2196 | wingp1w.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0 , 0) | |
2197 | wingp1w.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0,math.rad(0)) * CFrame.new(0, -0.5, 0.5) | |
2198 | coroutine.resume(coroutine.create(function() | |
2199 | for i = 0 , 1 , 0.025 do | |
2200 | wait() | |
2201 | wingp1p.Transparency = 1-1*i | |
2202 | end | |
2203 | wingp1p.Transparency = 0 | |
2204 | end)) | |
2205 | local Firee = modemodel | |
2206 | local Spawn = wingp1p | |
2207 | local colors = {BrickColor.new("Bright red"),BrickColor.new("Bright yellow"),BrickColor.new("Bright orange")} | |
2208 | local Embers = {} | |
2209 | local modelz = Instance.new("Model",Firee) | |
2210 | modelz.Name = "FireHolder" | |
2211 | for X = 1, 15 do | |
2212 | local f = Instance.new("Part") | |
2213 | f.Parent = nil | |
2214 | f.BrickColor = colors[math.random(1, # colors)] | |
2215 | f.Size = Vector3.new(1,1,1) | |
2216 | f.formFactor = 3 | |
2217 | f.Anchored = true | |
2218 | f.Locked = true | |
2219 | f.CanCollide = false | |
2220 | f.Transparency = 0.5 | |
2221 | f.Name = "Fire" | |
2222 | f.TopSurface = 0 | |
2223 | f.BottomSurface = 0 | |
2224 | Instance.new("BlockMesh",f) | |
2225 | table.insert(Embers, f) | |
2226 | end | |
2227 | local R = 0 | |
2228 | coroutine.resume(coroutine.create(function () | |
2229 | repeat | |
2230 | wait() | |
2231 | R = R + 1 | |
2232 | for X = 1, # Embers do | |
2233 | Embers[X].Parent = modelz | |
2234 | local FM = math.fmod(R + X, # Embers) | |
2235 | if FM == 1 then | |
2236 | RandPos = Vector3.new(math.random(-Spawn.Size.x * 5, Spawn.Size.x * 5) / 10, Spawn.Size.y / 2, math.random(-Spawn.Size.x * 5, Spawn.Size.x * 5) / 10) | |
2237 | RandDir = Vector3.new(math.random(-100,100), math.random(-100,100), math.random(-100,100)) | |
2238 | Embers[X].CFrame = CFrame.new(Spawn.Position + RandPos, (Spawn.Position * rndm) + RandPos + RandDir) | |
2239 | Embers[X].Mesh.Scale = Vector3.new(1,1,1) | |
2240 | else | |
2241 | Embers[X].CFrame = Embers[X].CFrame + Embers[X].CFrame.lookVector*0.5 | |
2242 | Embers[X].Mesh.Scale = Embers[X].Mesh.Scale - Vector3.new(0.1,0.1,0.1) | |
2243 | end | |
2244 | end | |
2245 | until wingp1p.Parent == nil | |
2246 | for i = 0 ,1 , 0.1 do | |
2247 | wait(0.2) | |
2248 | for X = 1, # Embers do | |
2249 | Embers[X].Transparency = 0.5+0.5*i | |
2250 | end | |
2251 | end | |
2252 | for X = 1, # Embers do | |
2253 | Embers[X].Parent = nil | |
2254 | end | |
2255 | end)) | |
2256 | for ii = 1 , #AoETrue do | |
2257 | table.remove(AoETrue,#AoETrue) | |
2258 | end | |
2259 | wait(0.25) | |
2260 | for i = 0 , 1 , 0.1 do | |
2261 | wait() | |
2262 | RW.C0 = CFrame.new(1.5,0.5+0.5*i,0) * CFrame.fromEulerAnglesXYZ(math.rad(90+25*i), math.rad(0), math.rad(0)) | |
2263 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
2264 | LW.C0 = CFrame.new(0,0.5+0.5*i,-1) * CFrame.fromEulerAnglesXYZ(math.rad(0),math.rad(0),math.rad(65+25*i)) | |
2265 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
2266 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
2267 | end | |
2268 | for i = 0 , 1 , 0.1 do | |
2269 | wait() | |
2270 | RW.C0 = CFrame.new(1.5,1-0.5*i,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(115-35*i), math.rad(45*i), math.rad(-45*i)) | |
2271 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
2272 | LW.C0 = CFrame.new(-1*i,1-0.5*i,-1+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80*i),math.rad(0),math.rad(90-45*i)) | |
2273 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
2274 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(180-180*i), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
2275 | end | |
2276 | RW.C0 = CFrame.new(1,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80), math.rad(45), math.rad(-45)) | |
2277 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
2278 | LW.C0 = CFrame.new(-1,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80),math.rad(-45),math.rad(45)) | |
2279 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
2280 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
2281 | attack=false | |
2282 | wait(1.5) | |
2283 | mrdychng = false | |
2284 | end | |
2285 | function NeutralMode() | |
2286 | attack=true | |
2287 | Mode = "None" | |
2288 | fireboost = 0 | |
2289 | iceboost = 0 | |
2290 | darkboost = 0 | |
2291 | ss(Head,1) | |
2292 | cs(Head,2) | |
2293 | mrdychng = true | |
2294 | for i = 0 , 1 , 0.2 do | |
2295 | wait() | |
2296 | RW.C0 = CFrame.new(1+0.5*i,0.5,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80+10*i), math.rad(45), math.rad(-45+45*i)) | |
2297 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(100*i), math.rad(0), math.rad(0)) | |
2298 | LW.C0 = CFrame.new(-1-0.5*i,0.5,-0.5+0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(80+10*i),math.rad(-45),math.rad(45-45*i)) | |
2299 | LW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(100*i), math.rad(0), math.rad(0)) | |
2300 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
2301 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(70*i), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
2302 | end | |
2303 | coroutine.resume(coroutine.create(function() | |
2304 | for ii,z in pairs(modemodel:GetChildren()) do | |
2305 | if string.sub(z.Name,0,string.len(z.Name)-1) ~= "FlameWingP" then | |
2306 | wait() | |
2307 | coroutine.resume(coroutine.create(function() | |
2308 | for i = 0 , 1 , 0.1 do | |
2309 | wait() | |
2310 | z.Transparency = (1-z.Transparency)*i | |
2311 | end | |
2312 | z.Parent = nil | |
2313 | end)) | |
2314 | end | |
2315 | end | |
2316 | wait(0.5) | |
2317 | for ii,z in pairs(modemodel:GetChildren()) do | |
2318 | wait() | |
2319 | z.Parent = nil | |
2320 | end | |
2321 | end)) | |
2322 | for i = 0 , 1 , 0.1 do | |
2323 | wait() | |
2324 | RW.C0 = CFrame.new(1.5,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(45), math.rad(0)) | |
2325 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(100+20*i), math.rad(0), math.rad(0)) | |
2326 | LW.C0 = CFrame.new(-1.5,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(90),math.rad(-45),math.rad(0)) | |
2327 | LW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(100+20*i), math.rad(0), math.rad(0)) | |
2328 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
2329 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(70+20*i), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
2330 | end | |
2331 | ||
2332 | wait(0.25) | |
2333 | for i = 0 , 1 , 0.1 do | |
2334 | wait() | |
2335 | RW.C0 = CFrame.new(1.5-0.5*i,0.5,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(90-10*i), math.rad(45), math.rad(-45*i)) | |
2336 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(120-120*i), math.rad(0), math.rad(0)) | |
2337 | LW.C0 = CFrame.new(-1.5+0.5*i,0.5,-0.5*i) * CFrame.fromEulerAnglesXYZ(math.rad(90-10*i),math.rad(-45),math.rad(45*i)) | |
2338 | LW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(120-120*i), math.rad(0), math.rad(0)) | |
2339 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
2340 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(90-90*i), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
2341 | end | |
2342 | RW.C0 = CFrame.new(1,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80), math.rad(45), math.rad(-45)) | |
2343 | RW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
2344 | LW.C0 = CFrame.new(-1,0.5,-0.5) * CFrame.fromEulerAnglesXYZ(math.rad(80),math.rad(-45),math.rad(45)) | |
2345 | LW.C1 = CFrame.new(0,0.5,0) * CFrame.fromEulerAnglesXYZ(math.rad(0), math.rad(0), math.rad(0)) | |
2346 | w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0) | |
2347 | w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(90), math.rad(0), math.rad(90)) * CFrame.new(0, 0, 0.2) | |
2348 | attack=false | |
2349 | wait(0.5) | |
2350 | mrdychng = false | |
2351 | end | |
2352 | ||
2353 | function ob1d(mouse) | |
2354 | hold = true | |
2355 | if attack == true then return end | |
2356 | end | |
2357 | function ob1u(mouse) | |
2358 | end | |
2359 | buttonhold = false | |
2360 | function key(key) | |
2361 | if attack == true then return end | |
2362 | if key == "q" then | |
2363 | if attacktype == 1 then | |
2364 | Combo1a() | |
2365 | elseif attacktype == 2 then | |
2366 | Combo1b() | |
2367 | elseif attacktype == 3 then | |
2368 | Combo1c() | |
2369 | end | |
2370 | end | |
2371 | if key == "e" then | |
2372 | if attacktype == 1 then | |
2373 | BlizzardSword() | |
2374 | end | |
2375 | end | |
2376 | if key == "r" then | |
2377 | FlameTrail() | |
2378 | end | |
2379 | if key == "t" then | |
2380 | LifeDrain() | |
2381 | end | |
2382 | if Mode == "None" and not mrdychng then | |
2383 | if key == "z" then | |
2384 | FireMode() | |
2385 | end | |
2386 | elseif not mrdychng then | |
2387 | if key == "z" or key == "x" or key == "c" then | |
2388 | NeutralMode() | |
2389 | end | |
2390 | end | |
2391 | end | |
2392 | ||
2393 | function key2(key) | |
2394 | end | |
2395 | function s(mouse) | |
2396 | repeat wait() until not attack | |
2397 | while ev.Value ~= false do | |
2398 | wait(0.1) | |
2399 | end | |
2400 | MMouse = mouse | |
2401 | mouse.Button1Down:connect(function() ob1d(mouse) end) | |
2402 | mouse.Button1Up:connect(function() ob1u(mouse) end) | |
2403 | mouse.KeyDown:connect(key) | |
2404 | mouse.KeyUp:connect(key2) | |
2405 | equipanim() | |
2406 | ev.Value = true | |
2407 | --[[ | |
2408 | script.Parent = Bin.Parent | |
2409 | Bin:remove()]] | |
2410 | end | |
2411 | function ds(mouse) | |
2412 | repeat wait() until not attack | |
2413 | while ev.Value == false do | |
2414 | wait(0.1) | |
2415 | end | |
2416 | ||
2417 | hideanim() | |
2418 | wait(0.1) | |
2419 | ev.Value = false | |
2420 | end | |
2421 | Bin.Selected:connect(s) | |
2422 | Bin.Deselected:connect(ds) | |
2423 | ||
2424 | ||
2425 | --lego |