SHOW:
|
|
- or go back to the newest paste.
1 | --[[ | |
2 | ||
3 | --posted to r/avaricious, sent in from an anonymous user | |
4 | -- who goes by the name "WhiIeTrueDo" | |
5 | ||
6 | -- patched by himself (WhiIeTrueDo), as there were some preventions in it | |
7 | -- enjoy! | |
8 | ||
9 | -- r/avaricious | |
10 | ||
11 | Fenrier's Sig Weapon created by: | |
12 | Fenrier: Everything. | |
13 | If you're gonna steal this, then please I ask you. Please don't forum,free model, give | |
14 | away, or anything like that to this script. Thank you very much :) | |
15 | ]] | |
16 | - | Player = game:GetService("Players").asd |
16 | + | Player = game:GetService("Players").LocalPlayer |
17 | Character = Player.Character | |
18 | PlayerGui = Player.PlayerGui | |
19 | Backpack = Player.Backpack | |
20 | Torso = Character.Torso | |
21 | Head = Character.Head | |
22 | Humanoid = Character.Humanoid | |
23 | LeftArm = Character["Left Arm"] | |
24 | LeftLeg = Character["Left Leg"] | |
25 | RightArm = Character["Right Arm"] | |
26 | RightLeg = Character["Right Leg"] | |
27 | LS = Torso["Left Shoulder"] | |
28 | LH = Torso["Left Hip"] | |
29 | RS = Torso["Right Shoulder"] | |
30 | RH = Torso["Right Hip"] | |
31 | it=Instance.new | |
32 | vt=Vector3.new | |
33 | cf=CFrame.new | |
34 | euler=CFrame.fromEulerAnglesXYZ | |
35 | angles=CFrame.Angles | |
36 | attack = false | |
37 | attackdebounce = false | |
38 | attacktype = 1 | |
39 | combo = 0 | |
40 | damage = 3 | |
41 | oridamage = 3 | |
42 | walkdebounce = false | |
43 | sheathed = true | |
44 | act = {key = {}} | |
45 | walking = false | |
46 | hold=false | |
47 | MMouse=nil | |
48 | equipped=false | |
49 | necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0) | |
50 | necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0) | |
51 | con1=nil | |
52 | con2=nil | |
53 | con3=nil | |
54 | mana=400 | |
55 | offset=nil | |
56 | mode="Normal" | |
57 | modechange=false | |
58 | dodging=false | |
59 | --player | |
60 | player = nil | |
61 | --save shoulders | |
62 | RSH, LSH = nil, nil | |
63 | --welds | |
64 | RW, LW = it("Weld"), it("Weld") | |
65 | RW2, LW2 = it("Weld"), it("Weld") | |
66 | --what anim | |
67 | anim = "none" | |
68 | ||
69 | if Character:findFirstChild("Weapon",true) ~= nil then | |
70 | Character:findFirstChild("Weapon",true).Parent = nil | |
71 | end | |
72 | if Player.PlayerGui:findFirstChild("manaGUI",true) ~= nil then | |
73 | Player.PlayerGui:findFirstChild("manaGUI",true).Parent = nil | |
74 | end | |
75 | ||
76 | function part(formfactor,parent,reflectance,transparency,brickcolor,name,size) | |
77 | local fp = it("Part") | |
78 | fp.formFactor = formfactor | |
79 | fp.Parent = parent | |
80 | fp.Reflectance = reflectance | |
81 | fp.Transparency = transparency | |
82 | fp.CanCollide = false | |
83 | fp.BrickColor = brickcolor | |
84 | fp.Name = name | |
85 | fp.Size = size | |
86 | fp.Position = Torso.Position | |
87 | fp.BottomSurface="Smooth" | |
88 | fp.TopSurface="Smooth" | |
89 | fp:BreakJoints() | |
90 | return fp | |
91 | end | |
92 | ||
93 | function mesh(Mesh,part,meshtype,meshid,offset,scale) | |
94 | local mesh = it(Mesh) | |
95 | mesh.Parent = part | |
96 | if Mesh=="SpecialMesh" then | |
97 | mesh.MeshType = meshtype | |
98 | mesh.MeshId = meshid | |
99 | end | |
100 | mesh.Offset=offset | |
101 | mesh.Scale=scale | |
102 | return mesh | |
103 | end | |
104 | ||
105 | function weld(parent,part0,part1,c0) | |
106 | local weld = it("Weld") | |
107 | weld.Parent = parent | |
108 | weld.Part0 = part0 | |
109 | weld.Part1 = part1 | |
110 | weld.C0 = c0 | |
111 | return weld | |
112 | end | |
113 | ||
114 | Ballprt=part(1,nil,0,0.3,BrickColor.new("Black"),"Ball",vt(3,3,3)) | |
115 | Ballmsh=mesh("SpecialMesh",Ballprt,"Sphere","",vt(0,0,0),vt(1,1,1)) | |
116 | Ballwld=weld(Ballprt,Ballprt,Prt4,cf(0,0,0)) | |
117 | ||
118 | local Main=it("Model") | |
119 | Main.Parent=nil | |
120 | Main.Name="Weapon" | |
121 | ||
122 | Prt1=part(1,Main,0,0,BrickColor.new("Black"),"Part1",vt(1,4,1)) | |
123 | Prt2=part(1,Main,0,0,BrickColor.new("Black"),"Part2",vt(1,1,1)) | |
124 | Prt3=part(1,Main,0,0,BrickColor.new("Black"),"Part3",vt(1,1,1)) | |
125 | Prt4=part(1,Main,0,0,BrickColor.new("Black"),"Part4",vt(1,1,1)) | |
126 | Prt5=part(1,Main,0,0,BrickColor.new("Really black"),"Part5",vt(1,1,1)) | |
127 | Prt6=part(1,Main,0,0,BrickColor.new("Black"),"Part6",vt(1,1,1)) | |
128 | Prt7=part(1,Main,0,0,BrickColor.new("Black"),"Part7",vt(1,1,1)) | |
129 | Prt8=part(1,Main,0,0,BrickColor.new("Black"),"Part8",vt(1,1,1)) | |
130 | Prt9=part(1,Main,0,0,BrickColor.new("Black"),"Part9",vt(1,1,1)) | |
131 | Prt10=part(1,Main,0,0,BrickColor.new("Black"),"Part10",vt(1,1,1)) | |
132 | Prt11=part(1,Main,0,0,BrickColor.new("Black"),"Part11",vt(1,1,1)) | |
133 | Prt12=part(1,Main,0,0,BrickColor.new("Navy blue"),"Part12",vt(1,1,1)) | |
134 | Prt13=part(1,Main,0,0,BrickColor.new("Navy blue"),"Part13",vt(1,1,1)) | |
135 | Prt14=part(1,Main,0,0,BrickColor.new("Navy blue"),"Part14",vt(1,1,1)) | |
136 | Prt15=part(1,Main,0,0,BrickColor.new("Navy blue"),"Part15",vt(1,1,1)) | |
137 | Prt16=part(1,Main,0,0,BrickColor.new("Navy blue"),"Part16",vt(1,1,1)) | |
138 | Prt17=part(1,Main,0,0,BrickColor.new("Navy blue"),"Part17",vt(1,1,1)) | |
139 | Prt18=part(1,Main,0,0,BrickColor.new("Black"),"Part18",vt(1,1,1)) | |
140 | Prt19=part(1,Main,0,0,BrickColor.new("Black"),"Part19",vt(1,1,1)) | |
141 | Prt20=part(1,Main,0.5,0,BrickColor.new("Navy blue"),"Part20",vt(1,1,1)) | |
142 | Prt21=part(1,Main,0.5,0,BrickColor.new("Navy blue"),"Part21",vt(1,1,1)) | |
143 | Prt22=part(1,Main,0,0,BrickColor.new("Navy blue"),"Part22",vt(1,1,1)) | |
144 | Prt23=part(1,Main,0,0,BrickColor.new("Black"),"Part23",vt(1,1,1)) | |
145 | ||
146 | Msh1=mesh("BlockMesh",Prt1,"","",vt(0,0,0),vt(1.1,1.2,1.1)) | |
147 | Msh2=mesh("CylinderMesh",Prt2,"","",vt(0,0,0),vt(1.6,1,1.6)) | |
148 | Msh3=mesh("BlockMesh",Prt3,"","",vt(0,0,0),vt(1.4,1,1)) | |
149 | Msh4=mesh("CylinderMesh",Prt4,"","",vt(0,0,0),vt(1.7,2,1.7)) | |
150 | Msh5=mesh("CylinderMesh",Prt5,"","",vt(0,0,0),vt(1.3,2,1.3)) | |
151 | Msh6=mesh("SpecialMesh",Prt6,"Wedge","",vt(0,0,0),vt(0.5,1.4,0.7)) | |
152 | Msh7=mesh("SpecialMesh",Prt7,"Wedge","",vt(0,0,0),vt(0.5,1,1.2)) | |
153 | Msh8=mesh("SpecialMesh",Prt8,"Wedge","",vt(0,0,0),vt(0.5,1.3,0.7)) | |
154 | Msh9=mesh("SpecialMesh",Prt9,"Wedge","",vt(0,0,0),vt(0.5,1,1.2)) | |
155 | Msh10=mesh("SpecialMesh",Prt10,"Wedge","",vt(0,0,0),vt(0.5,1.3,0.7)) | |
156 | Msh11=mesh("SpecialMesh",Prt11,"Wedge","",vt(0,0,0),vt(0.5,1,1.2)) | |
157 | Msh12=mesh("CylinderMesh",Prt12,"","",vt(0,0,0),vt(1.9,0.3,1.9)) | |
158 | Msh13=mesh("SpecialMesh",Prt13,"Wedge","",vt(0,0,0),vt(0.5,0.7,0.7)) | |
159 | Msh14=mesh("SpecialMesh",Prt14,"Wedge","",vt(0,0,0),vt(0.5,0.7,0.7)) | |
160 | Msh15=mesh("SpecialMesh",Prt15,"Wedge","",vt(0,0,0),vt(0.5,0.7,0.7)) | |
161 | Msh16=mesh("BlockMesh",Prt16,"","",vt(0,0,0),vt(2,0.7,0.3)) | |
162 | Msh17=mesh("BlockMesh",Prt17,"","",vt(0,0,0),vt(2,0.7,0.3)) | |
163 | Msh18=mesh("BlockMesh",Prt18,"","",vt(0,0,0),vt(0.4,0.7,1)) | |
164 | Msh19=mesh("BlockMesh",Prt19,"","",vt(0,0,0),vt(0.5,0.5,2)) | |
165 | Msh20=mesh("BlockMesh",Prt20,"","",vt(0,0,0),vt(0.1,0.5,2)) | |
166 | Msh21=mesh("SpecialMesh",Prt21,"Wedge","",vt(0,0,0),vt(0.1,0.5,0.5)) | |
167 | Msh22=mesh("BlockMesh",Prt22,"","",vt(0,0,0),vt(0.6,0.3,1.8)) | |
168 | Msh23=mesh("BlockMesh",Prt23,"","",vt(0,0,0),vt(1,0.6,1)) | |
169 | ||
170 | Wld1=weld(Main,Prt1,RightArm,cf(0,1.8,0)) | |
171 | Wld2=weld(Main,Prt2,Prt1,cf(0,-1,0)*euler(0,0,0)) | |
172 | Wld3=weld(Main,Prt3,Prt2,cf(0,0.3,0)*euler(1.57,0,0)) | |
173 | Wld4=weld(Main,Prt4,Prt1,cf(0,1.4,0)*euler(0,0,0)) | |
174 | Wld5=weld(Main,Prt5,Prt1,cf(0,1.41,0)*euler(0,0,0)) | |
175 | Wld6=weld(Main,Prt6,Prt1,euler(0,-1.57,0)*cf(1,1,0)) | |
176 | Wld7=weld(Main,Prt7,Prt1,euler(1.57,-1.57,0)*cf(1.3,2.2,0)) | |
177 | Wld8=weld(Main,Prt8,Prt1,euler(0,1.57,0)*cf(-1,1,0)) | |
178 | Wld9=weld(Main,Prt9,Prt1,euler(1.57,1.57,0)*cf(-1.3,2.2,0)) | |
179 | Wld10=weld(Main,Prt10,Prt1,euler(0,0,0)*cf(0,1,1)) | |
180 | Wld11=weld(Main,Prt11,Prt1,euler(1.57,0,0)*cf(0,2.2,1.3)) | |
181 | Wld12=weld(Main,Prt12,Prt4,euler(0,0,0)*cf(0,0.7,0)) | |
182 | Wld13=weld(Main,Prt13,Prt1,euler(1.57,-1.57,0)*cf(0.8,0.3,0)) | |
183 | Wld14=weld(Main,Prt14,Prt1,euler(1.57,1.57,0)*cf(-0.8,0.3,0)) | |
184 | Wld15=weld(Main,Prt15,Prt1,euler(1.57,0,0)*cf(0,0.3,0.8)) | |
185 | Wld16=weld(Main,Prt16,Prt4,euler(0,0.785,0)*cf(0,-0.5,0)) | |
186 | Wld17=weld(Main,Prt17,Prt4,euler(0,-0.785,0)*cf(0,-0.5,0)) | |
187 | Wld18=weld(Main,Prt18,Prt4,euler(0.785,0,0)*cf(0,0.5,-0.9)) | |
188 | Wld19=weld(Main,Prt19,Prt18,euler(0.785,0,0)*cf(0,0.4,-0.2)) | |
189 | Wld20=weld(Main,Prt20,Prt19,euler(0,0,0)*cf(0,0.1,0.1)) | |
190 | Wld21=weld(Main,Prt21,Prt20,euler(0,0,3.14)*cf(0,0,1.25)) | |
191 | Wld22=weld(Main,Prt22,Prt19,euler(0,0,0)*cf(0,0,0)) | |
192 | Wld23=weld(Main,Prt23,Prt4,euler(0,0,0)*cf(0,-0.4,-1)) | |
193 | ||
194 | local fengui = it("GuiMain") | |
195 | fengui.Parent = Player.PlayerGui | |
196 | fengui.Name = "manaGUI" | |
197 | local fenframe = it("Frame") | |
198 | fenframe.Parent = fengui | |
199 | fenframe.BackgroundColor3 = Color3.new(255,255,255) | |
200 | fenframe.BackgroundTransparency = 1 | |
201 | fenframe.BorderColor3 = Color3.new(17,17,17) | |
202 | fenframe.Size = UDim2.new(0.0500000007, 0, 0.100000001, 0) | |
203 | local fentext = it("TextLabel") | |
204 | fentext.Parent = fenframe | |
205 | fentext.Text = "Mana("..mana..")" | |
206 | fentext.BackgroundTransparency = 1 | |
207 | fentext.SizeConstraint = "RelativeXY" | |
208 | fentext.TextXAlignment = "Center" | |
209 | fentext.TextYAlignment = "Center" | |
210 | fentext.Position = UDim2.new(0,80,1,200) | |
211 | local fentext2 = it("TextLabel") | |
212 | fentext2.Parent = fenframe | |
213 | fentext2.Text = " " | |
214 | fentext2.BackgroundTransparency = 0 | |
215 | fentext2.BackgroundColor3 = Color3.new(0,0,0) | |
216 | fentext2.SizeConstraint = "RelativeXY" | |
217 | fentext2.TextXAlignment = "Center" | |
218 | fentext2.TextYAlignment = "Center" | |
219 | fentext2.Position = UDim2.new(0,10,1,170) | |
220 | fentext2.Size = UDim2.new(2.79999995,0,0.210000306,0) | |
221 | local fentext3 = it("TextLabel") | |
222 | fentext3.Parent = fenframe | |
223 | fentext3.Text = " " | |
224 | fentext3.BackgroundTransparency = 0 | |
225 | fentext3.BackgroundColor3 = Color3.new(1,1,1) | |
226 | fentext3.SizeConstraint = "RelativeXY" | |
227 | fentext3.TextXAlignment = "Center" | |
228 | fentext3.TextYAlignment = "Center" | |
229 | fentext3.Position = UDim2.new(0,10,1,170) | |
230 | fentext3.Size = UDim2.new(mana*0.007,0,0.400000006,0) | |
231 | ||
232 | local bg = it("BodyGyro") | |
233 | bg.Parent = nil | |
234 | ||
235 | ||
236 | if (script.Parent.className ~= "HopperBin") then | |
237 | Tool = it("HopperBin") | |
238 | Tool.Parent = Backpack | |
239 | Tool.Name = "Rock Shooter" | |
240 | script.Parent = Tool | |
241 | end | |
242 | Bin = script.Parent | |
243 | ||
244 | function unequipweld() | |
245 | Main.Parent=nil | |
246 | end | |
247 | ||
248 | function equipweld() | |
249 | Main.Parent=Character | |
250 | Wld1.Parent=Main | |
251 | end | |
252 | ||
253 | function hideanim() | |
254 | equipped = false | |
255 | bg.Parent=nil | |
256 | unequipweld() | |
257 | for i = 0 , 1 , 0.1 do | |
258 | wait(0) | |
259 | Torso.Neck.C1 = euler(1.57,3.14,0) * cf(0,0,-0.5) | |
260 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,0) | |
261 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
262 | RW.C0 = cf(1.5,0.5,0) * euler(0,0,0) | |
263 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
264 | end | |
265 | Torso.Neck.C0=necko*euler(0,0,0) | |
266 | end | |
267 | ||
268 | function equipanim(mouse) | |
269 | equipped = true | |
270 | for i = 0,1,0.1 do | |
271 | wait() | |
272 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5*i) | |
273 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
274 | RW.C0 = cf(1.5,0.5,0) * euler(3.14*i,0,0) | |
275 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
276 | end | |
277 | for i=0,2,0.05 do | |
278 | wait() | |
279 | MMMAGIC(RightArm,3,3,3,0,-math.random(0,3)-math.random(),0,BrickColor.new("Black")) | |
280 | MMMAGIC(RightArm,3,3,3,0,-math.random(0,3)-math.random(),0,BrickColor.new("Navy blue")) | |
281 | end | |
282 | equipweld() | |
283 | for i = 0,1,0.1 do | |
284 | wait() | |
285 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5) | |
286 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
287 | RW.C0 = cf(1.5,0.5,0) * euler(3.14-1.9*i,0,0) | |
288 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
289 | end | |
290 | for i = 0,1,0.1 do | |
291 | wait() | |
292 | Torso.Neck.C0=necko*euler(0,0,0) | |
293 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5) | |
294 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
295 | RW.C0 = cf(1.5,0.5,0) * euler(1.24,0,0.5*i) | |
296 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
297 | end | |
298 | Stance() | |
299 | end | |
300 | ||
301 | function Stance() | |
302 | coroutine.resume(coroutine.create(function() | |
303 | bg.maxTorque = vt(math.huge,math.huge,math.huge) | |
304 | bg.P = 5000 | |
305 | bg.Parent = Torso | |
306 | while equipped==true and walking==false and attack==false do | |
307 | wait() | |
308 | if modechange==false then | |
309 | Torso.Neck.C0=necko*euler(0,0,1) | |
310 | end | |
311 | local pos4 = vt(MMouse.Hit.p.x,Head.Position.Y,MMouse.Hit.p.z) | |
312 | if mode=="Shoot" then | |
313 | local pos4 = Vector3.new(MMouse.Hit.p.x,Head.Position.Y,MMouse.Hit.p.z) | |
314 | offset=(Torso.Position.y-MMouse.Hit.p.y)/60 | |
315 | mag=(Torso.Position-MMouse.Hit.p).magnitude/80 | |
316 | offset=offset/mag | |
317 | Torso.Neck.C0=necko*euler(0,-offset,-1.57) | |
318 | if dodging==false then | |
319 | bg.cframe = CFrame.new(Head.Position,pos4)*euler(0,1.57,0) | |
320 | bg.Parent = Torso | |
321 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5) | |
322 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
323 | RW.C0 = cf(1.5,0.5,0) * euler(0,0,1.57) | |
324 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
325 | end | |
326 | else | |
327 | if modechange==false then | |
328 | bg.cframe = cf(Torso.Position,pos4)*euler(0,-1,0)*cf(0,0,0) --cf(Torso.Position,MMouse.Hit.p) * | |
329 | end | |
330 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5) | |
331 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
332 | RW.C0 = cf(1.5,0.5,0) * euler(1.24,0,0.5) | |
333 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
334 | end | |
335 | end | |
336 | Torso.Neck.C0=necko*euler(0,0,0) | |
337 | bg.Parent=nil | |
338 | end)) | |
339 | end | |
340 | ||
341 | function Walking() | |
342 | attack=true | |
343 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5) | |
344 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
345 | RW.C0 = cf(1.5,0.5,0) * euler(1.24,0,0.5) | |
346 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
347 | walking=true | |
348 | attack=false | |
349 | end | |
350 | ||
351 | function Mode() | |
352 | modechange=true | |
353 | attack=true | |
354 | if mode=="Normal" then | |
355 | mode="Shoot" | |
356 | Humanoid.WalkSpeed=0 | |
357 | for i = 0,1,0.1 do | |
358 | wait() | |
359 | local pos4 = Vector3.new(MMouse.Hit.p.x,Head.Position.Y,MMouse.Hit.p.z) | |
360 | bg.cframe = CFrame.new(Head.Position,pos4)*euler(0,1.57,0) | |
361 | bg.Parent = Torso | |
362 | Torso.Neck.C0=necko*euler(0,0,1-2.57*i) | |
363 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5) | |
364 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
365 | RW.C0 = cf(1.5,0.5,0) * euler(1.24+0.33*i,0,0.5+1.07*i) | |
366 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
367 | end | |
368 | wait() | |
369 | elseif mode=="Shoot" then | |
370 | mode="Normal" | |
371 | Humanoid.WalkSpeed=16 | |
372 | end | |
373 | attack=false | |
374 | modechange=false | |
375 | Stance() | |
376 | end | |
377 | ||
378 | function DodgeUp() | |
379 | CF=Torso.CFrame*euler(0,-1.57,0) | |
380 | local vel=Instance.new("BodyVelocity") | |
381 | vel.Parent=Torso | |
382 | vel.maxForce=Vector3.new(4e+005,4e+005,4e+005)*1 | |
383 | vel.velocity=CF.lookVector*30 | |
384 | for i=0,1,0.2 do | |
385 | wait() | |
386 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5-0.5*i) | |
387 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
388 | RW.C0 = cf(1.5,0.5,0) * euler(0,0,1.57) | |
389 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
390 | end | |
391 | vel.Parent=nil | |
392 | for i=0,1,0.2 do | |
393 | wait() | |
394 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5-0.5+0.5*i) | |
395 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
396 | RW.C0 = cf(1.5,0.5,0) * euler(0,0,1.57) | |
397 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
398 | end | |
399 | --wait(0.2) | |
400 | end | |
401 | ||
402 | function DodgeLeft() | |
403 | CF=Torso.CFrame*euler(0,0,0) | |
404 | local vel=Instance.new("BodyVelocity") | |
405 | vel.Parent=Torso | |
406 | vel.maxForce=Vector3.new(4e+005,4e+005,4e+005)*1 | |
407 | vel.velocity=CF.lookVector*30 | |
408 | for i=0,1,0.2 do | |
409 | wait() | |
410 | LW.C0 = cf(-1.5,0.5,0) * euler(-0.5*i,0,-0.5) | |
411 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
412 | RW.C0 = cf(1.5,0.5,0) * euler(0,-0.5*i,1.57) | |
413 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
414 | end | |
415 | vel.Parent=nil | |
416 | for i=0,1,0.2 do | |
417 | wait() | |
418 | LW.C0 = cf(-1.5,0.5,0) * euler(-0.5+0.5*i,0,-0.5) | |
419 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
420 | RW.C0 = cf(1.5,0.5,0) * euler(0,-0.5+0.5*i,1.57) | |
421 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
422 | end | |
423 | --wait(0.2) | |
424 | end | |
425 | ||
426 | function DodgeRight() | |
427 | CF=Torso.CFrame*euler(0,1.57,0) | |
428 | local vel=Instance.new("BodyVelocity") | |
429 | vel.Parent=Torso | |
430 | vel.maxForce=Vector3.new(4e+005,4e+005,4e+005)*1 | |
431 | vel.velocity=CF.lookVector*30 | |
432 | for i=0,1,0.2 do | |
433 | wait() | |
434 | LW.C0 = cf(-1.5+0.5*i,0.5,-0.5*i) * euler(0.7*i,0,-0.5+2*i) | |
435 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
436 | RW.C0 = cf(1.5,0.5,0) * euler(0,0,1.57) | |
437 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
438 | end | |
439 | vel.Parent=nil | |
440 | for i=0,1,0.2 do | |
441 | wait() | |
442 | LW.C0 = cf(-1.5+0.5-0.5*i,0.5,-0.5+0.5*i) * euler(0.7-0.7*i,0,-0.5+2-2*i) | |
443 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
444 | RW.C0 = cf(1.5,0.5,0) * euler(0,0,1.57) | |
445 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
446 | end | |
447 | --wait(0.2) | |
448 | end | |
449 | ||
450 | function DodgeDown() | |
451 | CF=Torso.CFrame*euler(0,3.14,0) | |
452 | local vel=Instance.new("BodyVelocity") | |
453 | vel.Parent=Torso | |
454 | vel.maxForce=Vector3.new(4e+005,4e+005,4e+005)*1 | |
455 | vel.velocity=CF.lookVector*30 | |
456 | for i=0,1,0.2 do | |
457 | wait() | |
458 | LW.C0 = cf(-1.5,0.5,0) * euler(0.5*i,0,-0.5) | |
459 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
460 | RW.C0 = cf(1.5,0.5,0) * euler(0,0.5*i,1.57) | |
461 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
462 | end | |
463 | vel.Parent=nil | |
464 | for i=0,1,0.2 do | |
465 | wait() | |
466 | LW.C0 = cf(-1.5,0.5,0) * euler(0.5-0.5*i,0,-0.5) | |
467 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
468 | RW.C0 = cf(1.5,0.5,0) * euler(0,0.5-0.5*i,1.57) | |
469 | RW.C1 = cf(0, 0.5, 0) * euler(offset,1.57,0) | |
470 | end | |
471 | --wait(0.2) | |
472 | end | |
473 | ||
474 | function OverchargeBlast() | |
475 | attack=true | |
476 | for i=0,1,0.1 do | |
477 | wait() | |
478 | local pos4 = vt(MMouse.Hit.p.x,Head.Position.Y,MMouse.Hit.p.z) | |
479 | Torso.Neck.C0=necko*euler(0,0,1-1*i) | |
480 | bg.cframe = cf(Torso.Position,pos4)*euler(0,-1+1*i,0)*cf(0,0,0) | |
481 | bg.Parent = Torso | |
482 | LW.C0 = cf(-1.5+0.8*i,0.5+0.3*i,-0.5*i) * euler(2.8*i,0,-0.5+1.5*i) | |
483 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
484 | RW.C0 = cf(1.5,0.5,0) * euler(1.24+1.26*i,0,0.5-0.5*i) | |
485 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
486 | end | |
487 | wait(0.2) | |
488 | Ballprt.Parent=Main | |
489 | Ballwld.Parent=Main | |
490 | Ballwld.Part0=Ballprt | |
491 | Ballwld.Part1=Prt4 | |
492 | Ballwld.C0=cf(0,3,0) | |
493 | for i=0,1,0.1 do | |
494 | wait() | |
495 | MMMAGIC3(Ballprt.CFrame,1,6,1,0,0,0,BrickColor.new("Black")) | |
496 | EVENMOARMAGIX(Ballprt,1,1,1,0,0,0,0,0,0,BrickColor.new("Black")) | |
497 | local pos4 = vt(MMouse.Hit.p.x,Head.Position.Y,MMouse.Hit.p.z) | |
498 | bg.cframe = cf(Torso.Position,pos4)*euler(0,0,0)*cf(0,0,0) | |
499 | bg.Parent = Torso | |
500 | LW.C0 = cf(-1.5+0.8,0.5+0.3,-0.5) * euler(2.8-1*i,0,1) | |
501 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
502 | RW.C0 = cf(1.5,0.5,0) * euler(2.5-1*i,0,0) | |
503 | RW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
504 | end | |
505 | for i=0,10,0.1 do | |
506 | wait() | |
507 | MMMAGIC3(Ballprt.CFrame,1,6,1,0,0,0,BrickColor.new("Black")) | |
508 | EVENMOARMAGIX(Ballprt,3,3,3,0,0,0,0,0,0,BrickColor.new("Black")) | |
509 | MOREMAGIX(Ballprt,0,2,2,2,BrickColor.new("Navy blue")) | |
510 | local pos4 = vt(MMouse.Hit.p.x,Head.Position.Y,MMouse.Hit.p.z) | |
511 | bg.cframe = cf(Torso.Position,pos4)*euler(0,0,0)*cf(0,0,0) | |
512 | bg.Parent = Torso | |
513 | offset=(Torso.Position.y-MMouse.Hit.p.y)/60 | |
514 | mag=(Torso.Position-MMouse.Hit.p).magnitude/80 | |
515 | offset=offset/mag | |
516 | Torso.Neck.C0=necko*euler(offset,0,0) | |
517 | LW.C0 = cf(-1.5+0.8,0.5+0.3,-0.5) * euler(1.8,0,1) | |
518 | LW.C1 = cf(0, 0.5, 0) * euler(offset,0,0) | |
519 | RW.C0 = cf(1.5,0.5,0) * euler(1.57,0,0) | |
520 | RW.C1 = cf(0, 0.5, 0) * euler(offset,0,0) | |
521 | end | |
522 | Ballwld.Part1=nil | |
523 | Ballprt.Parent=nil | |
524 | wait(0.4) | |
525 | shoottrail3(Prt4,20) | |
526 | wait(1) | |
527 | attack=false | |
528 | end | |
529 | ||
530 | function ss(pitch) | |
531 | ||
532 | local SlashSound = it("Sound") | |
533 | SlashSound.SoundId = "rbxasset://sounds\\swordslash.wav" | |
534 | SlashSound.Parent = workspace | |
535 | SlashSound.Volume = .7 | |
536 | SlashSound.Pitch = pitch | |
537 | SlashSound.PlayOnRemove = true | |
538 | coroutine.resume(coroutine.create(function() | |
539 | wait(0) | |
540 | SlashSound.Parent = nil | |
541 | end)) | |
542 | end | |
543 | function charge(pitch) | |
544 | ||
545 | local SlashSound = it("Sound") | |
546 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=2101137" | |
547 | SlashSound.Parent = workspace | |
548 | SlashSound.Volume = 1 | |
549 | SlashSound.Pitch = pitch | |
550 | SlashSound.PlayOnRemove = true | |
551 | coroutine.resume(coroutine.create(function() | |
552 | wait(0) | |
553 | SlashSound.Parent = nil | |
554 | end)) | |
555 | end | |
556 | function bewm(pitch) | |
557 | ||
558 | local SlashSound = it("Sound") | |
559 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=2248511" | |
560 | SlashSound.Parent = workspace | |
561 | SlashSound.Volume = .7 | |
562 | SlashSound.Pitch = pitch | |
563 | SlashSound.PlayOnRemove = true | |
564 | coroutine.resume(coroutine.create(function() | |
565 | wait(0) | |
566 | SlashSound.Parent = nil | |
567 | end)) | |
568 | end | |
569 | function abscond(pitch) | |
570 | ||
571 | local SlashSound = it("Sound") | |
572 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=2767090" | |
573 | SlashSound.Parent = workspace | |
574 | SlashSound.Volume = 1 | |
575 | SlashSound.Pitch = pitch | |
576 | SlashSound.PlayOnRemove = true | |
577 | coroutine.resume(coroutine.create(function() | |
578 | wait(0) | |
579 | SlashSound.Parent = nil | |
580 | end)) | |
581 | end | |
582 | function distort(pitch) | |
583 | ||
584 | local SlashSound = it("Sound") | |
585 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=2974249" | |
586 | SlashSound.Parent = workspace | |
587 | SlashSound.Volume = 1 | |
588 | SlashSound.Pitch = pitch | |
589 | SlashSound.PlayOnRemove = true | |
590 | coroutine.resume(coroutine.create(function() | |
591 | wait(0) | |
592 | SlashSound.Parent = nil | |
593 | end)) | |
594 | end | |
595 | function fire1(pitch) | |
596 | ||
597 | local SlashSound = it("Sound") | |
598 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=2697431" | |
599 | SlashSound.Parent = workspace | |
600 | SlashSound.Volume = 0.3 | |
601 | SlashSound.Pitch = pitch | |
602 | SlashSound.PlayOnRemove = true | |
603 | coroutine.resume(coroutine.create(function() | |
604 | wait(0) | |
605 | SlashSound.Parent = nil | |
606 | end)) | |
607 | end | |
608 | function fire2(pitch) | |
609 | ||
610 | local SlashSound = it("Sound") | |
611 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=48618802 " | |
612 | SlashSound.Parent = workspace | |
613 | SlashSound.Volume = 0.5 | |
614 | SlashSound.Pitch = pitch | |
615 | SlashSound.PlayOnRemove = true | |
616 | coroutine.resume(coroutine.create(function() | |
617 | wait(0) | |
618 | SlashSound.Parent = nil | |
619 | end)) | |
620 | end | |
621 | function grip(pitch) | |
622 | ||
623 | local SlashSound = it("Sound") | |
624 | SlashSound.SoundId = "rbxasset://sounds/swordslash.wav" | |
625 | SlashSound.Parent = workspace | |
626 | SlashSound.Volume = 1 | |
627 | SlashSound.Pitch = pitch | |
628 | SlashSound.PlayOnRemove = true | |
629 | coroutine.resume(coroutine.create(function() | |
630 | wait(0) | |
631 | SlashSound.Parent = nil | |
632 | end)) | |
633 | end | |
634 | function reload(pitch) | |
635 | ||
636 | local SlashSound = it("Sound") | |
637 | SlashSound.SoundId = "http://www.roblox.com/asset/?id=2697295" | |
638 | SlashSound.Parent = workspace | |
639 | SlashSound.Volume = 1 | |
640 | SlashSound.Pitch = pitch | |
641 | SlashSound.PlayOnRemove = true | |
642 | coroutine.resume(coroutine.create(function() | |
643 | wait(0) | |
644 | SlashSound.Parent = nil | |
645 | end)) | |
646 | end | |
647 | ||
648 | function MMMAGIC(part,x1,y1,z1,x2,y2,z2,color) | |
649 | local msh1 = it("BlockMesh") | |
650 | msh1.Scale = vt(0.5,0.5,0.5) | |
651 | S=it("Part") | |
652 | S.Name="Effect" | |
653 | S.formFactor=0 | |
654 | S.Size=vt(x1,y1,z1) | |
655 | S.BrickColor=color | |
656 | S.Reflectance = 0 | |
657 | S.TopSurface=0 | |
658 | S.BottomSurface=0 | |
659 | S.Transparency=0 | |
660 | S.Anchored=true | |
661 | S.CanCollide=false | |
662 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
663 | S.Parent=workspace | |
664 | msh1.Parent = S | |
665 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0.1,0.1,0.1) Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) Part.Transparency=i*.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
666 | end | |
667 | ||
668 | function MMAGIC(part,x1,y1,z1,x2,y2,z2,color) | |
669 | local msh1 = it("BlockMesh") | |
670 | msh1.Scale = vt(0.5,0.5,0.5) | |
671 | S=it("Part") | |
672 | S.Name="Effect" | |
673 | S.formFactor=0 | |
674 | S.Size=vt(x1,y1,z1) | |
675 | S.BrickColor=color | |
676 | S.Reflectance = 0 | |
677 | S.TopSurface=0 | |
678 | S.BottomSurface=0 | |
679 | S.Transparency=0 | |
680 | S.Anchored=true | |
681 | S.CanCollide=false | |
682 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
683 | S.Parent=Character | |
684 | msh1.Parent = S | |
685 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0.1,0.1,0.1) Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) Part.Transparency=i*.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
686 | end | |
687 | ||
688 | function MMMAGIC2(part,x1,y1,z1,x2,y2,z2,color) | |
689 | local msh1 = it("BlockMesh") | |
690 | msh1.Scale = vt(0.5,0.5,0.5) | |
691 | S=it("Part") | |
692 | S.Name="Effect" | |
693 | S.formFactor=0 | |
694 | S.Size=vt(x1,y1,z1) | |
695 | S.BrickColor=color | |
696 | S.Reflectance = 0 | |
697 | S.TopSurface=0 | |
698 | S.BottomSurface=0 | |
699 | S.Transparency=0 | |
700 | S.Anchored=true | |
701 | S.CanCollide=false | |
702 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
703 | S.Parent=workspace | |
704 | msh1.Parent = S | |
705 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0.1,0.1,0.1) Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) Part.Transparency=i*.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
706 | end | |
707 | ||
708 | function MMMAGIC3(part,x1,y1,z1,x2,y2,z2,color) | |
709 | local msh1 = it("BlockMesh") | |
710 | msh1.Scale = vt(0.5,0.5,0.5) | |
711 | S=it("Part") | |
712 | S.Name="Effect" | |
713 | S.formFactor=0 | |
714 | S.Size=vt(x1,y1,z1) | |
715 | S.BrickColor=color | |
716 | S.Reflectance = 0 | |
717 | S.TopSurface=0 | |
718 | S.BottomSurface=0 | |
719 | S.Transparency=0 | |
720 | S.Anchored=true | |
721 | S.CanCollide=false | |
722 | S.CFrame=part*cf(x2,y2,z2)*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
723 | S.Parent=Character | |
724 | msh1.Parent = S | |
725 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0,0.3,0) Part.Transparency=i*.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
726 | end | |
727 | ||
728 | function UltimaMMMAGIC(part,x1,y1,z1,x2,y2,z2,color) | |
729 | local msh1 = it("BlockMesh") | |
730 | msh1.Scale = vt(x1,y1,z1) | |
731 | S=it("Part") | |
732 | S.Name="Effect" | |
733 | S.formFactor=0 | |
734 | S.Size=vt(1,1,1) | |
735 | S.BrickColor=color | |
736 | S.Reflectance = 0 | |
737 | S.TopSurface=0 | |
738 | S.BottomSurface=0 | |
739 | S.Transparency=0 | |
740 | S.Anchored=true | |
741 | S.CanCollide=false | |
742 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
743 | S.Parent=workspace | |
744 | msh1.Parent = S | |
745 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0.1,0.1,0.1) Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) Part.Transparency=i*.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
746 | end | |
747 | ||
748 | function MOREMAGIX(part,cframe,x,y,z,color) | |
749 | p2=it("Part") | |
750 | p2.Name="Blast" | |
751 | p2.TopSurface=0 | |
752 | p2.BottomSurface=0 | |
753 | p2.CanCollide=false | |
754 | p2.Anchored=true | |
755 | p2.BrickColor=color | |
756 | p2.Size=vt(x,y,z) | |
757 | p2.formFactor="Symmetric" | |
758 | p2.CFrame=part.CFrame*cf(0,cframe,0) | |
759 | p2.Parent=Character | |
760 | m=it("BlockMesh") | |
761 | m.Parent=p2 | |
762 | m.Name="BlastMesh" | |
763 | coroutine.resume(coroutine.create(function(part,dir) for loll=1, 15 do part.BlastMesh.Scale=part.BlastMesh.Scale-vt(.09,.09,.09) part.Transparency=loll/20 part.CFrame=part.CFrame*cf(dir)*euler(math.random(-100,100)/100, math.random(-100,100)/100, math.random(-100,100)/100) wait() end part.Parent=nil end),p2,vt(math.random(-10,10)/10,math.random(-10,10)/10,math.random(-10,10)/10)) | |
764 | end | |
765 | ||
766 | function EVENMOARMAGIX(part,x1,y1,z1,x2,y2,z2,x3,y3,z3,color) | |
767 | local msh1 = it("SpecialMesh") | |
768 | msh1.Scale = vt(0.5,0.5,0.5) | |
769 | msh1.MeshType = "Sphere" | |
770 | S=it("Part") | |
771 | S.Name="Effect" | |
772 | S.formFactor=0 | |
773 | S.Size=vt(x1,y1,z1) | |
774 | S.BrickColor=color | |
775 | S.Reflectance = 0 | |
776 | S.TopSurface=0 | |
777 | S.BottomSurface=0 | |
778 | S.Transparency=0 | |
779 | S.Anchored=true | |
780 | S.CanCollide=false | |
781 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(x3,y3,z3) | |
782 | S.Parent=Character | |
783 | msh1.Parent = S | |
784 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0.15,0.15,0.15) Part.Transparency=i*.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
785 | end | |
786 | ||
787 | function EVENMOARMAGIX2(part,x1,y1,z1,x2,y2,z2,x3,y3,z3,color) | |
788 | local msh1 = it("SpecialMesh") | |
789 | msh1.Scale = vt(0.5,0.5,0.5) | |
790 | msh1.MeshType = "Sphere" | |
791 | S=it("Part") | |
792 | S.Name="Effect" | |
793 | S.formFactor=0 | |
794 | S.Size=vt(x1,y1,z1) | |
795 | S.BrickColor=color | |
796 | S.Reflectance = 0 | |
797 | S.TopSurface=0 | |
798 | S.BottomSurface=0 | |
799 | S.Transparency=0 | |
800 | S.Anchored=true | |
801 | S.CanCollide=false | |
802 | S.CFrame=part | |
803 | S.Parent=workspace | |
804 | msh1.Parent = S | |
805 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 14 do Part.Mesh.Scale = Part.Mesh.Scale + vt(1,1,1) Part.Transparency=Part.Transparency+0.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
806 | end | |
807 | ||
808 | function ChargeEffect(part,x1,y1,z1,x2,y2,z2,x3,y3,z3,color) | |
809 | local msh1 = it("SpecialMesh") | |
810 | msh1.Scale = vt(0.5,0.5,0.5) | |
811 | msh1.MeshType = "Sphere" | |
812 | S=it("Part") | |
813 | S.Name="Effect" | |
814 | S.formFactor=0 | |
815 | S.Size=vt(x1,y1,z1) | |
816 | S.BrickColor=color | |
817 | S.Reflectance = 0 | |
818 | S.TopSurface=0 | |
819 | S.BottomSurface=0 | |
820 | S.Transparency=0 | |
821 | S.Anchored=false | |
822 | S.CanCollide=false | |
823 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(x3,y3,z3) | |
824 | S.Parent=modelzorz | |
825 | msh1.Parent = S | |
826 | coroutine.resume(coroutine.create(function(Part,CF) | |
827 | f=it("BodyPosition") | |
828 | f.P=800 | |
829 | f.D=100 | |
830 | f.maxForce=vt(math.huge,math.huge,math.huge) | |
831 | f.position=part.Position | |
832 | f.Parent=Part | |
833 | for i=0,1,0.1 do | |
834 | wait() | |
835 | Part.Transparency=Part.Transparency+0.1 | |
836 | end | |
837 | Part.Parent=nil | |
838 | end),S,S.CFrame) | |
839 | end | |
840 | ||
841 | function ChargeEffect2(part,x1,y1,z1,x2,y2,z2,x3,y3,z3,color) | |
842 | local msh1 = it("SpecialMesh") | |
843 | msh1.Scale = vt(0.5,0.5,0.5) | |
844 | msh1.MeshType = "Sphere" | |
845 | S=it("Part") | |
846 | S.Name="Effect" | |
847 | S.formFactor=0 | |
848 | S.Size=vt(x1,y1,z1) | |
849 | S.BrickColor=color | |
850 | S.Reflectance = 0 | |
851 | S.TopSurface=0 | |
852 | S.BottomSurface=0 | |
853 | S.Transparency=0 | |
854 | S.Anchored=false | |
855 | S.CanCollide=false | |
856 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(x3,y3,z3) | |
857 | S.Parent=modelzorz | |
858 | msh1.Parent = S | |
859 | coroutine.resume(coroutine.create(function(Part,CF) | |
860 | f=it("BodyPosition") | |
861 | f.P=800 | |
862 | f.D=100 | |
863 | f.maxForce=vt(math.huge,math.huge,math.huge) | |
864 | f.position=part.Position+vt(math.random(-30,30),math.random(-30,30),math.random(-30,30)) | |
865 | f.Parent=Part | |
866 | for i=0,1,0.1 do | |
867 | wait() | |
868 | Part.Transparency=Part.Transparency+0.1 | |
869 | end | |
870 | Part.Parent=nil | |
871 | end),S,S.CFrame) | |
872 | end | |
873 | ||
874 | print("Y U NU GIVE CREDIT.") | |
875 | ||
876 | function WaveEffect(part,x1,y1,z1,x2,y2,z2,x3,y3,z3,color) | |
877 | local msh1 = it("SpecialMesh") | |
878 | msh1.Scale = vt(x1,y1,z1) | |
879 | msh1.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
880 | S=it("Part") | |
881 | S.Name="Effect" | |
882 | S.formFactor=0 | |
883 | S.Size=vt(1,1,1) | |
884 | S.BrickColor=color | |
885 | S.Reflectance = 0 | |
886 | S.TopSurface=0 | |
887 | S.BottomSurface=0 | |
888 | S.Transparency=0 | |
889 | S.Anchored=true | |
890 | S.CanCollide=false | |
891 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(x3,y3,z3) | |
892 | S.Parent=workspace | |
893 | msh1.Parent = S | |
894 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0.3,0.3,0.3) Part.Transparency=i*.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
895 | end | |
896 | ||
897 | function BlastEffect(part,x1,y1,z1,x2,y2,z2,x3,y3,z3,color) | |
898 | local msh1 = it("SpecialMesh") | |
899 | msh1.Scale = vt(x1,y1,z1) | |
900 | msh1.MeshId = "http://www.roblox.com/asset/?id=1323306" | |
901 | S=it("Part") | |
902 | S.Name="Effect" | |
903 | S.formFactor=0 | |
904 | S.Size=vt(1,1,1) | |
905 | S.BrickColor=color | |
906 | S.Reflectance = 0 | |
907 | S.TopSurface=0 | |
908 | S.BottomSurface=0 | |
909 | S.Transparency=0 | |
910 | S.Anchored=true | |
911 | S.CanCollide=false | |
912 | S.CFrame=part.CFrame*cf(x2,y2,z2)*euler(x3,y3,z3) | |
913 | S.Parent=workspace | |
914 | msh1.Parent = S | |
915 | coroutine.resume(coroutine.create(function(Part,CF) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0.5,0.8,0.5) Part.Transparency=i*.1 wait() end Part.Parent=nil end),S,S.CFrame) | |
916 | end | |
917 | ||
918 | function DerpMagic(part,x1,y1,z1,x2,y2,z2,color) | |
919 | local msh1 = it("BlockMesh") | |
920 | msh1.Scale = vt(0.5,0.5,0.5) | |
921 | S=it("Part") | |
922 | S.Name="Effect" | |
923 | S.formFactor=0 | |
924 | S.Size=vt(x1,y1,z1) | |
925 | S.BrickColor=color | |
926 | S.Reflectance = 0 | |
927 | S.TopSurface=0 | |
928 | S.BottomSurface=0 | |
929 | S.Transparency=0 | |
930 | S.Anchored=false | |
931 | S.CanCollide=false | |
932 | S.CFrame=part.CFrame | |
933 | S.Parent=workspace | |
934 | msh1.Parent = S | |
935 | W=it("Weld") | |
936 | W.Parent=S | |
937 | W.Part0=S | |
938 | W.Part1=part | |
939 | W.C0=cf(x2,y2,z2) * euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
940 | W.Parent=nil | |
941 | S.Anchored=true | |
942 | coroutine.resume(coroutine.create(function(Part,Weld) for i=1, 9 do Part.Mesh.Scale = Part.Mesh.Scale + vt(0.1,0.1,0.1) --[[Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))]] Part.Transparency=i*.1 wait() end Part.Parent=nil Weld.Parent=nil end),S,W) | |
943 | end | |
944 | ||
945 | DarkRiftF=function(par) --Thank you turdulator for this :D | |
946 | PWN={} | |
947 | for _,v in pairs(workspace:children()) do | |
948 | if v.className=="Model" and v:FindFirstChild("Humanoid")~=nil then | |
949 | if v.Humanoid.Health>0 and v:FindFirstChild("Torso")~=nil then | |
950 | if v~=Character and (v.Torso.Position-par.Position).magnitude<=25 then | |
951 | table.insert(PWN,v.Torso) | |
952 | end | |
953 | end | |
954 | end | |
955 | end | |
956 | for _,t in pairs(PWN) do | |
957 | Mag=(par.Position-t.Position).magnitude/2 | |
958 | t.Parent.Humanoid:TakeDamage(.6) | |
959 | rl=it("BodyAngularVelocity") | |
960 | rl.P=3000 | |
961 | rl.maxTorque=vt(500000,500000,500000)*5000 | |
962 | rl.angularvelocity=vt(math.random(-20,20),math.random(-20,20),math.random(-20,20))/10 | |
963 | rl.Parent=t | |
964 | game:GetService("Debris"):AddItem(rl,.1) | |
965 | if Mag<=2 then | |
966 | t.Parent.Humanoid:TakeDamage(.3) | |
967 | else | |
968 | vl=it("BodyVelocity") | |
969 | vl.P=3000 | |
970 | vl.maxForce=vt(50000000000,50000000000,50000000000) | |
971 | vl.velocity=(t.Position-par.Position).unit*-(70/(Mag)) | |
972 | vl.Parent=t | |
973 | game:GetService("Debris"):AddItem(vl,.1) | |
974 | end | |
975 | end | |
976 | wait(.08) | |
977 | end | |
978 | ||
979 | DBHit=function(hit,Damage) --credits to turdulator for making this function :D | |
980 | if hit.Parent==nil then | |
981 | return | |
982 | end | |
983 | h=hit.Parent:FindFirstChild("Humanoid") | |
984 | t=hit.Parent:FindFirstChild("Torso") | |
985 | if h~=nil and t~=nil then | |
986 | if h.Parent==Character then | |
987 | return | |
988 | end | |
989 | c=it("ObjectValue") | |
990 | c.Name="creator" | |
991 | c.Value=game.Players.LocalPlayer | |
992 | c.Parent=h | |
993 | game:GetService("Debris"):AddItem(c,.5) | |
994 | if math.random(0,99)+math.random()<=7.8 then | |
995 | CRIT=true | |
996 | Damage=Damage*3 | |
997 | --[[ Knockback=Knockback*2 | |
998 | r=it("BodyAngularVelocity") | |
999 | r.P=3000 | |
1000 | r.maxTorque=vt(500000000,50000000000,500000000)*50000 | |
1001 | r.angularvelocity=vt(math.random(-20,20),math.random(-20,20),math.random(-20,20)) | |
1002 | r.Parent=hit.Parent.Torso]] | |
1003 | s=it("Sound") | |
1004 | s.SoundId="http://www.roblox.com/asset/?id=2801263" | |
1005 | s.Volume=1 | |
1006 | s.Pitch=2 | |
1007 | s.Parent=hit | |
1008 | s.PlayOnRemove=true | |
1009 | s.Parent=nil | |
1010 | ||
1011 | end | |
1012 | h:TakeDamage(Damage) | |
1013 | showDamage(hit.Parent,Damage,.5) | |
1014 | vl=it("BodyVelocity") | |
1015 | vl.P=4500 | |
1016 | vl.maxForce=vt(math.huge,math.huge,math.huge) | |
1017 | -- vl.velocity=vt(Torso.Velocity.x,0,Torso.Velocity.z)*1.05+vt(0,3,0) | |
1018 | vl.velocity=vt(Torso.Velocity.x,0,Torso.Velocity.z)*1.05+vt(0,45,0) | |
1019 | vl.Parent=t | |
1020 | game:GetService("Debris"):AddItem(vl,.2) | |
1021 | rl=it("BodyAngularVelocity") | |
1022 | rl.P=3000 | |
1023 | rl.maxTorque=vt(500000,500000,500000)*50000000000000 | |
1024 | rl.angularvelocity=vt(math.random(-40,40),math.random(-40,40),math.random(-40,40)) | |
1025 | rl.Parent=t | |
1026 | game:GetService("Debris"):AddItem(rl,.2) | |
1027 | else | |
1028 | if hit.CanCollide==false then | |
1029 | return | |
1030 | end | |
1031 | MagicCom:disconnect() | |
1032 | -- DBExplode(DB) | |
1033 | end | |
1034 | end | |
1035 | ||
1036 | DBHit2=function(hit,Damage) --credits to turdulator for making this function :D | |
1037 | if hit.Parent==nil then | |
1038 | return | |
1039 | end | |
1040 | h=hit.Parent:FindFirstChild("Humanoid") | |
1041 | t=hit.Parent:FindFirstChild("Torso") | |
1042 | if h~=nil and t~=nil then | |
1043 | if h.Parent==Character then | |
1044 | return | |
1045 | end | |
1046 | c=it("ObjectValue") | |
1047 | c.Name="creator" | |
1048 | c.Value=game.Players.LocalPlayer | |
1049 | c.Parent=h | |
1050 | game:GetService("Debris"):AddItem(c,.5) | |
1051 | if math.random(0,99)+math.random()<=7.8 then | |
1052 | CRIT=true | |
1053 | Damage=Damage*3 | |
1054 | --[[ Knockback=Knockback*2 | |
1055 | r=it("BodyAngularVelocity") | |
1056 | r.P=3000 | |
1057 | r.maxTorque=vt(500000000,50000000000,500000000)*50000 | |
1058 | r.angularvelocity=vt(math.random(-20,20),math.random(-20,20),math.random(-20,20)) | |
1059 | r.Parent=hit.Parent.Torso]] | |
1060 | s=it("Sound") | |
1061 | s.SoundId="http://www.roblox.com/asset/?id=2801263" | |
1062 | s.Volume=1 | |
1063 | s.Pitch=2 | |
1064 | s.Parent=hit | |
1065 | s.PlayOnRemove=true | |
1066 | s.Parent=nil | |
1067 | ||
1068 | end | |
1069 | h:TakeDamage(Damage) | |
1070 | showDamage(hit.Parent,Damage,.5) | |
1071 | vl=it("BodyVelocity") | |
1072 | vl.P=4500 | |
1073 | vl.maxForce=vt(math.huge,math.huge,math.huge) | |
1074 | -- vl.velocity=vt(Torso.Velocity.x,0,Torso.Velocity.z)*1.05+vt(0,30,0) | |
1075 | vl.velocity=Head.CFrame.lookVector*35+Head.Velocity/1.05 | |
1076 | vl.Parent=t | |
1077 | game:GetService("Debris"):AddItem(vl,.2) | |
1078 | rl=it("BodyAngularVelocity") | |
1079 | rl.P=3000 | |
1080 | rl.maxTorque=vt(500000,500000,500000)*50000000000000 | |
1081 | rl.angularvelocity=vt(math.random(-5,5),math.random(-5,5),math.random(-5,5)) | |
1082 | rl.Parent=t | |
1083 | game:GetService("Debris"):AddItem(rl,.2) | |
1084 | else | |
1085 | if hit.CanCollide==false then | |
1086 | return | |
1087 | end | |
1088 | MagicCom:disconnect() | |
1089 | -- DBExplode(DB) | |
1090 | end | |
1091 | end | |
1092 | ||
1093 | DOHHit=function(hit,Damage,Pos) --credits to turdulator for making this function :D | |
1094 | if hit.Parent==nil then | |
1095 | return | |
1096 | end | |
1097 | h=hit.Parent:FindFirstChild("Humanoid") | |
1098 | t=hit.Parent:FindFirstChild("Torso") | |
1099 | if h~=nil and t~=nil then | |
1100 | if h.Parent==Character then | |
1101 | return | |
1102 | end | |
1103 | c=it("ObjectValue") | |
1104 | c.Name="creator" | |
1105 | c.Value=game.Players.LocalPlayer | |
1106 | c.Parent=h | |
1107 | game:GetService("Debris"):AddItem(c,.5) | |
1108 | if math.random(0,99)+math.random()<=7.8 then | |
1109 | CRIT=true | |
1110 | Damage=Damage*3 | |
1111 | --[[ Knockback=Knockback*2 | |
1112 | r=it("BodyAngularVelocity") | |
1113 | r.P=3000 | |
1114 | r.maxTorque=vt(500000000,50000000000,500000000)*50000 | |
1115 | r.angularvelocity=vt(math.random(-20,20),math.random(-20,20),math.random(-20,20)) | |
1116 | r.Parent=hit.Parent.Torso]] | |
1117 | s=it("Sound") | |
1118 | s.SoundId="http://www.roblox.com/asset/?id=2801263" | |
1119 | s.Volume=1 | |
1120 | s.Pitch=2 | |
1121 | s.Parent=hit | |
1122 | s.PlayOnRemove=true | |
1123 | s.Parent=nil | |
1124 | ||
1125 | end | |
1126 | h:TakeDamage(Damage) | |
1127 | showDamage(hit.Parent,Damage,.5) | |
1128 | vl=it("BodyVelocity") | |
1129 | vl.P=4500 | |
1130 | vl.maxForce=vt(math.huge,math.huge,math.huge) | |
1131 | -- vl.velocity=vt(Torso.Velocity.x,0,Torso.Velocity.z)*1.05+vt(0,60,0) | |
1132 | vl.velocity=Head.CFrame.lookVector+Head.Velocity/1.05 | |
1133 | vl.Parent=t | |
1134 | game:GetService("Debris"):AddItem(vl,.2) | |
1135 | rl=it("BodyAngularVelocity") | |
1136 | rl.P=3000 | |
1137 | rl.maxTorque=vt(500000,500000,500000)*50000000000000 | |
1138 | rl.angularvelocity=vt(math.random(-10,10),math.random(-10,10),math.random(-10,10)) | |
1139 | rl.Parent=t | |
1140 | game:GetService("Debris"):AddItem(rl,.2) | |
1141 | else | |
1142 | if hit.CanCollide==false then | |
1143 | return | |
1144 | end | |
1145 | MagicCom:disconnect() | |
1146 | -- DBExplode(DB) | |
1147 | end | |
1148 | end | |
1149 | ||
1150 | Damagefunc1=function(hit,Damage,Knockback) | |
1151 | if attackdebounce == false then | |
1152 | attackdebounce = true | |
1153 | coroutine.resume(coroutine.create(function() | |
1154 | wait(0.1) | |
1155 | attackdebounce = false | |
1156 | end)) | |
1157 | if hit.Parent==nil then | |
1158 | return | |
1159 | end | |
1160 | CPlayer=Bin | |
1161 | h=hit.Parent:FindFirstChild("Humanoid") | |
1162 | if h~=nil and hit.Parent.Name~="Fenrier" and hit.Parent:FindFirstChild("Torso")~=nil then | |
1163 | Damage=Damage | |
1164 | --[[ if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then | |
1165 | return | |
1166 | end]] | |
1167 | if mana<400 then | |
1168 | mana=mana+math.random(10,20) | |
1169 | else | |
1170 | mana=400 | |
1171 | end | |
1172 | c=it("ObjectValue") | |
1173 | c.Name="creator" | |
1174 | c.Value=game.Players.LocalPlayer | |
1175 | c.Parent=h | |
1176 | game:GetService("Debris"):AddItem(c,.5) | |
1177 | -- print(c.Value) | |
1178 | if math.random(0,99)+math.random()<=7.8 then | |
1179 | CRIT=true | |
1180 | Damage=Damage*2 | |
1181 | --[[ Knockback=Knockback*2 | |
1182 | r=it("BodyAngularVelocity") | |
1183 | r.P=3000 | |
1184 | r.maxTorque=vt(500000000,50000000000,500000000)*50000 | |
1185 | r.angularvelocity=vt(math.random(-20,20),math.random(-20,20),math.random(-20,20)) | |
1186 | r.Parent=hit.Parent.Torso]] | |
1187 | s=it("Sound") | |
1188 | s.SoundId="http://www.roblox.com/asset/?id=2801263" | |
1189 | s.Volume=1 | |
1190 | s.Pitch=2 | |
1191 | s.Parent=hit | |
1192 | s.PlayOnRemove=true | |
1193 | s.Parent=nil | |
1194 | ||
1195 | end | |
1196 | Damage=Damage+math.random(0,10) | |
1197 | -- Blood(hit.CFrame*cf(math.random(-10,10)/10,math.random(-10,10)/10,0),math.floor(Damage/2)) | |
1198 | h:TakeDamage(Damage) | |
1199 | showDamage(hit.Parent,Damage,.5) | |
1200 | vp=it("BodyVelocity") | |
1201 | vp.P=500 | |
1202 | vp.maxForce=vt(math.huge,0,math.huge) | |
1203 | -- vp.velocity=Character.Torso.CFrame.lookVector*Knockback | |
1204 | vp.velocity=Torso.CFrame.lookVector*Knockback+Torso.Velocity/1.05 | |
1205 | if Knockback>0 then | |
1206 | vp.Parent=hit.Parent.Torso | |
1207 | end | |
1208 | game:GetService("Debris"):AddItem(vp,1) | |
1209 | --[[ r=it("BodyAngularVelocity") | |
1210 | r.P=3000 | |
1211 | r.maxTorque=vt(500000000,50000000000,500000000)*50000 | |
1212 | r.angularvelocity=vt(math.random(-20,20),math.random(-20,20),math.random(-20,20)) | |
1213 | r.Parent=hit.Parent.Torso]] | |
1214 | game:GetService("Debris"):AddItem(r,.5) | |
1215 | c=it("ObjectValue") | |
1216 | c.Name="creator" | |
1217 | c.Value=Player | |
1218 | c.Parent=h | |
1219 | game:GetService("Debris"):AddItem(c,.5) | |
1220 | CRIT=false | |
1221 | hitDeb=true | |
1222 | AttackPos=6 | |
1223 | end | |
1224 | end | |
1225 | end | |
1226 | ||
1227 | DOH=function(hit,Damage,Knockback) | |
1228 | if attackdebounce == false then | |
1229 | attackdebounce = true | |
1230 | coroutine.resume(coroutine.create(function() | |
1231 | wait(0.2) | |
1232 | attackdebounce = false | |
1233 | end)) | |
1234 | if hit.Parent==nil then | |
1235 | return | |
1236 | end | |
1237 | CPlayer=Bin | |
1238 | h=hit.Parent:FindFirstChild("Humanoid") | |
1239 | if h~=nil and hit.Parent.Name~="Fenrier" and hit.Parent:FindFirstChild("Torso")~=nil then | |
1240 | Damage=Damage | |
1241 | --[[ if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then | |
1242 | return | |
1243 | end]] | |
1244 | c=it("ObjectValue") | |
1245 | c.Name="creator" | |
1246 | c.Value=game.Players.LocalPlayer | |
1247 | c.Parent=h | |
1248 | game:GetService("Debris"):AddItem(c,.5) | |
1249 | -- print(c.Value) | |
1250 | if math.random(0,99)+math.random()<=7.8 then | |
1251 | CRIT=true | |
1252 | Damage=Damage*3 | |
1253 | --[[ Knockback=Knockback*2 | |
1254 | r=it("BodyAngularVelocity") | |
1255 | r.P=3000 | |
1256 | r.maxTorque=vt(500000000,50000000000,500000000)*50000 | |
1257 | r.angularvelocity=vt(math.random(-20,20),math.random(-20,20),math.random(-20,20)) | |
1258 | r.Parent=hit.Parent.Torso]] | |
1259 | s=it("Sound") | |
1260 | s.SoundId="http://www.roblox.com/asset/?id=2801263" | |
1261 | s.Volume=1 | |
1262 | s.Pitch=2 | |
1263 | s.Parent=hit | |
1264 | s.PlayOnRemove=true | |
1265 | s.Parent=nil | |
1266 | ||
1267 | end | |
1268 | Damage=Damage+math.random(0,10) | |
1269 | -- Blood(hit.CFrame*cf(math.random(-10,10)/10,math.random(-10,10)/10,0),math.floor(Damage/2)) | |
1270 | h:TakeDamage(Damage) | |
1271 | showDamage(hit.Parent,Damage,.5) | |
1272 | vp=it("BodyVelocity") | |
1273 | vp.P=500 | |
1274 | vp.maxForce=vt(math.huge,0,math.huge) | |
1275 | -- vp.velocity=Character.Torso.CFrame.lookVector*Knockback | |
1276 | vp.velocity=Torso.CFrame.lookVector*Knockback+Torso.Velocity/1.05 | |
1277 | if Knockback>0 then | |
1278 | vp.Parent=hit.Parent.Torso | |
1279 | end | |
1280 | game:GetService("Debris"):AddItem(vp,.25) | |
1281 | --[[ r=it("BodyAngularVelocity") | |
1282 | r.P=3000 | |
1283 | r.maxTorque=vt(500000000,50000000000,500000000)*50000 | |
1284 | r.angularvelocity=vt(math.random(-20,20),math.random(-20,20),math.random(-20,20)) | |
1285 | r.Parent=hit.Parent.Torso]] | |
1286 | game:GetService("Debris"):AddItem(r,.5) | |
1287 | c=it("ObjectValue") | |
1288 | c.Name="creator" | |
1289 | c.Value=Player | |
1290 | c.Parent=h | |
1291 | game:GetService("Debris"):AddItem(c,.5) | |
1292 | wait(1) | |
1293 | DOHeffect(hit,20,30,2,0,0) | |
1294 | bewm(workspace,1) | |
1295 | wait(0.1) | |
1296 | DOHeffect(hit,20,30,-2,0.5,0) | |
1297 | bewm(workspace,1) | |
1298 | wait(0.1) | |
1299 | DOHeffect(hit,20,30,2,1,0) | |
1300 | bewm(workspace,1) | |
1301 | wait(0.1) | |
1302 | DOHeffect(hit,20,30,-2,1.5,0) | |
1303 | bewm(workspace,1) | |
1304 | CRIT=false | |
1305 | hitDeb=true | |
1306 | AttackPos=6 | |
1307 | end | |
1308 | end | |
1309 | end | |
1310 | ||
1311 | showDamage=function(Char,Dealt,du) | |
1312 | m=it("Model") | |
1313 | m.Name=tostring(Dealt) | |
1314 | h=it("Humanoid") | |
1315 | h.Health=0 | |
1316 | h.MaxHealth=0 | |
1317 | h.Parent=m | |
1318 | c=it("Part") | |
1319 | c.Transparency=0 | |
1320 | c.BrickColor=BrickColor:Red() | |
1321 | if CRIT==true then | |
1322 | c.BrickColor=BrickColor.new("Really red") | |
1323 | end | |
1324 | c.Name="Head" | |
1325 | c.TopSurface=0 | |
1326 | c.BottomSurface=0 | |
1327 | c.formFactor="Plate" | |
1328 | c.Size=vt(1,.4,1) | |
1329 | ms=it("CylinderMesh") | |
1330 | ms.Bevel=.1 | |
1331 | ms.Scale=vt(.8,.8,.8) | |
1332 | if CRIT==true then | |
1333 | ms.Scale=vt(1.25,1.5,1.25) | |
1334 | ms.Bevel=.2 | |
1335 | end | |
1336 | ms.Parent=c | |
1337 | c.Reflectance=0 | |
1338 | it("BodyGyro").Parent=c | |
1339 | c.Parent=m | |
1340 | c.CFrame=cf(Char["Head"].CFrame.p+vt(0,1.5,0)) | |
1341 | f=it("BodyPosition") | |
1342 | f.P=2000 | |
1343 | f.D=100 | |
1344 | f.maxForce=vt(math.huge,math.huge,math.huge) | |
1345 | f.position=c.Position+vt(0,3,0) | |
1346 | f.Parent=c | |
1347 | game:GetService("Debris"):AddItem(m,.5+du) | |
1348 | c.CanCollide=false | |
1349 | m.Parent=workspace | |
1350 | c.CanCollide=false | |
1351 | end | |
1352 | ||
1353 | function shoottrail2(pos1,Damage) | |
1354 | coroutine.resume(coroutine.create(function() | |
1355 | spread2 = 0 | |
1356 | range2 = 100 | |
1357 | rangepower = 10 | |
1358 | local spreadvector = (vt(math.random(-spread2,spread2),math.random(-spread2,spread2),math.random(-spread2,spread2)) / 100) * (pos1.Position).magnitude/100 | |
1359 | local dir = Head.CFrame.lookVector+spreadvector | |
1360 | --local dir = pos1.CFrame.lookVector+spreadvector | |
1361 | local ammount = 100 | |
1362 | local hit2,pos = rayCast(pos1.Position,dir,10,Main) | |
1363 | local rangepos = range2 | |
1364 | local function drawtrail(From,To) | |
1365 | local effectsmsh = it("SpecialMesh") | |
1366 | local Damg = Damage*2 | |
1367 | effectsmsh.Scale = vt(1,1,1) | |
1368 | effectsmsh.MeshType="Sphere" | |
1369 | effectsmsh.Name = "Mesh" | |
1370 | local effectsg = it("Part") | |
1371 | effectsg.formFactor = 3 | |
1372 | effectsg.CanCollide = false | |
1373 | effectsg.Name = "Eff" | |
1374 | effectsg.Locked = true | |
1375 | effectsg.Anchored = true | |
1376 | effectsg.Size = vt(1,0.4,1) | |
1377 | effectsg.Parent = Main | |
1378 | effectsmsh.Parent = effectsg | |
1379 | effectsg.BrickColor = BrickColor.new("Navy blue") | |
1380 | effectsg.Reflectance = 0.25 | |
1381 | local LP = From | |
1382 | local point1 = To | |
1383 | local mg = (LP - point1).magnitude | |
1384 | effectsmsh.Scale = vt(3,3,3) | |
1385 | effectsg.CFrame = cf((LP+point1)/2,point1) * CFrame.Angles(math.rad(90),0,0) | |
1386 | MMMAGIC(effectsg,4,4,4,0,0,0,BrickColor.new("Black")) | |
1387 | MOREMAGIX(effectsg,0,2,2,2,BrickColor.new("Navy blue")) | |
1388 | coroutine.resume(coroutine.create(function() | |
1389 | --[[for i = 0 , 1 , 0.1 do | |
1390 | wait() | |
1391 | effectsg.Transparency = 1*i | |
1392 | effectsmsh.Scale = vt(1-1*i,mg*5,1-1*i) | |
1393 | end ]] | |
1394 | wait() | |
1395 | effectsg.Transparency = 1 | |
1396 | wait(2) | |
1397 | effectsg.Parent = nil | |
1398 | end)) | |
1399 | end | |
1400 | local newpos = pos1.Position | |
1401 | local inc = rangepower | |
1402 | ammount=100 | |
1403 | local Damg = Damage*2 | |
1404 | local decr = 0 | |
1405 | repeat | |
1406 | wait() | |
1407 | decr = decr + 1 | |
1408 | rangepos = rangepos - 10 | |
1409 | dir = dir | |
1410 | --dir = dir | |
1411 | ammount=ammount-3 | |
1412 | if decr == 2 then | |
1413 | Damg = Damg/2 | |
1414 | decr=0 | |
1415 | end | |
1416 | hit2,pos = rayCast(newpos,dir,inc,Main) | |
1417 | drawtrail(newpos,pos) | |
1418 | newpos = newpos + (dir * inc) | |
1419 | if alt==1 then | |
1420 | inc = 10 | |
1421 | if inc >= 20 then | |
1422 | inc = inc - 10 | |
1423 | end | |
1424 | end | |
1425 | if hit2 ~= nil then | |
1426 | rangepos = 0 | |
1427 | end | |
1428 | until rangepos <= 0 | |
1429 | EVENMOARMAGIX2(cf(newpos),2,2,2,0,0,0,0,0,0,BrickColor.new("Black")) | |
1430 | local c = game.Workspace:GetChildren(); | |
1431 | for i = 1, #c do | |
1432 | local hum = c[i]:findFirstChild("Humanoid") | |
1433 | if hum ~= nil and hum.Health ~= 0 then | |
1434 | local head = c[i]:findFirstChild("Head"); | |
1435 | if head ~= nil then | |
1436 | local targ = head.Position - newpos; | |
1437 | local mag = targ.magnitude; | |
1438 | if mag <= 10 and c[i].Name ~= Player.Name then | |
1439 | attackdebounce=false | |
1440 | Damagefunc1(head,math.floor(Damg),0.1) | |
1441 | end | |
1442 | end | |
1443 | end | |
1444 | end | |
1445 | if hit2 ~= nil then | |
1446 | local effectsmsh = it("SpecialMesh") | |
1447 | effectsmsh.MeshId = "http://www.roblox.com/asset/?id=15887356" | |
1448 | --effectsmsh.Scale = vt(1,1,2.5) | |
1449 | effectsmsh.Scale = vt(3,3,3) | |
1450 | local effectsg = it("Part") | |
1451 | effectsg.formFactor = 3 | |
1452 | effectsg.CanCollide = false | |
1453 | effectsg.Name = "Arrow" | |
1454 | effectsg.Locked = true | |
1455 | effectsg.Transparency = 1 | |
1456 | effectsg.Size = vt(0.2,0.2,0.2) | |
1457 | effectsg.Parent = Main | |
1458 | effectsg.BrickColor = BrickColor.new("Black") | |
1459 | effectsmsh.Parent = effectsg | |
1460 | effectsg.CFrame = cf(newpos,pos) + cf(newpos,pos).lookVector*2.5*2 | |
1461 | coroutine.resume(coroutine.create(function() | |
1462 | wait(0) | |
1463 | effectsg.Parent = nil | |
1464 | end)) | |
1465 | local efwel = it("Weld") | |
1466 | efwel.Parent = effectsg | |
1467 | efwel.Part0 = effectsg | |
1468 | efwel.Part1 = hit2 | |
1469 | efwel.Parent = nil | |
1470 | effectsg.Anchored = true | |
1471 | --local HitPos = effectsg.Position + cf(newpos,pos).lookVector*0.75 | |
1472 | --local HitPos = prt1.Position + cf(newpos,pos).lookVector*0.75 | |
1473 | local HitPos = Prt4.Position + (Head.CFrame.lookVector * .5) | |
1474 | local CJ = cf(HitPos) | |
1475 | local C0 = effectsg.CFrame:inverse() * CJ | |
1476 | local C1 = hit2.CFrame:inverse() * CJ | |
1477 | --efwel.C0 = C0 | |
1478 | --efwel.C1 = C1 | |
1479 | --efwel.Parent = effectsg | |
1480 | if hit2.Parent:FindFirstChild("Humanoid") ~= nil then | |
1481 | hum = hit2.Parent.Humanoid | |
1482 | attackdebounce=false | |
1483 | Damagefunc1(hit2,math.floor(Damg),0.1) | |
1484 | elseif hit2.Parent.Parent ~= nil and hit2.Parent.Parent:FindFirstChild("Humanoid") ~= nil then | |
1485 | hum = hit2.Parent.Parent.Humanoid | |
1486 | attackdebounce=false | |
1487 | Damagefunc1(hum,math.floor(Damg),0.1) | |
1488 | end | |
1489 | end | |
1490 | end)) | |
1491 | end | |
1492 | ||
1493 | function shoottrail3(pos1,Damage) | |
1494 | coroutine.resume(coroutine.create(function() | |
1495 | spread2 = 0 | |
1496 | range2 = 1000 | |
1497 | rangepower = 2 | |
1498 | local spreadvector = (vt(math.random(-spread2,spread2),math.random(-spread2,spread2),math.random(-spread2,spread2)) / 100) * (pos1.Position).magnitude/100 | |
1499 | local dir = Head.CFrame.lookVector+spreadvector | |
1500 | --local dir = pos1.CFrame.lookVector+spreadvector | |
1501 | local ammount = 100 | |
1502 | local hit2,pos = rayCast(pos1.Position,dir,10,Character) | |
1503 | local rangepos = range2 | |
1504 | local function drawtrail(From,To) | |
1505 | local effectsmsh = it("SpecialMesh") | |
1506 | local Damg = Damage*2 | |
1507 | effectsmsh.Scale = vt(1,1,1) | |
1508 | effectsmsh.MeshType="Sphere" | |
1509 | effectsmsh.Name = "Mesh" | |
1510 | local effectsg = it("Part") | |
1511 | effectsg.formFactor = 3 | |
1512 | effectsg.CanCollide = false | |
1513 | effectsg.Name = "Eff" | |
1514 | effectsg.Locked = true | |
1515 | effectsg.Anchored = true | |
1516 | effectsg.Size = vt(1,0.4,1) | |
1517 | effectsg.Parent = Main | |
1518 | effectsmsh.Parent = effectsg | |
1519 | effectsg.BrickColor = BrickColor.new("Black") | |
1520 | effectsg.Reflectance = 0 | |
1521 | effectsg.Transparency=0.3 | |
1522 | local LP = From | |
1523 | local point1 = To | |
1524 | local mg = (LP - point1).magnitude | |
1525 | effectsmsh.Scale = vt(3,3,3) | |
1526 | effectsg.CFrame = cf((LP+point1)/2,point1) * CFrame.Angles(math.rad(90),0,0) | |
1527 | MMMAGIC3(effectsg.CFrame,1,6,1,0,0,0,BrickColor.new("Black")) | |
1528 | EVENMOARMAGIX(effectsg,3,3,3,0,0,0,0,0,0,BrickColor.new("Black")) | |
1529 | MOREMAGIX(effectsg,0,2,2,2,BrickColor.new("Navy blue")) | |
1530 | coroutine.resume(coroutine.create(function() | |
1531 | --[[for i = 0 , 1 , 0.1 do | |
1532 | wait() | |
1533 | effectsg.Transparency = 1*i | |
1534 | effectsmsh.Scale = vt(1-1*i,mg*5,1-1*i) | |
1535 | end ]] | |
1536 | wait() | |
1537 | effectsg.Transparency = 1 | |
1538 | wait(2) | |
1539 | effectsg.Parent = nil | |
1540 | end)) | |
1541 | end | |
1542 | local newpos = pos1.Position | |
1543 | local inc = rangepower | |
1544 | ammount=100 | |
1545 | local Damg = Damage*2 | |
1546 | local decr = 0 | |
1547 | repeat | |
1548 | wait() | |
1549 | decr = decr + 1 | |
1550 | rangepos = rangepos - 10 | |
1551 | dir = dir | |
1552 | --dir = dir | |
1553 | ammount=ammount-3 | |
1554 | hit2,pos = rayCast(newpos,dir,inc,Character) | |
1555 | drawtrail(newpos,pos) | |
1556 | newpos = newpos + (dir * inc) | |
1557 | if alt==1 then | |
1558 | inc = 10 | |
1559 | if inc >= 20 then | |
1560 | inc = inc - 10 | |
1561 | end | |
1562 | end | |
1563 | if hit2 ~= nil then | |
1564 | rangepos = 0 | |
1565 | end | |
1566 | until rangepos <= 0 | |
1567 | EVENMOARMAGIX2(cf(newpos),5,5,5,0,0,0,0,0,0,BrickColor.new("Black")) | |
1568 | local c = game.Workspace:GetChildren(); | |
1569 | for i = 1, #c do | |
1570 | local hum = c[i]:findFirstChild("Humanoid") | |
1571 | if hum ~= nil and hum.Health ~= 0 then | |
1572 | local head = c[i]:findFirstChild("Head"); | |
1573 | if head ~= nil then | |
1574 | local targ = head.Position - newpos; | |
1575 | local mag = targ.magnitude; | |
1576 | if mag <= 30 and c[i].Name ~= Player.Name then | |
1577 | attackdebounce=false | |
1578 | Damagefunc1(head,math.floor(Damg),0.1) | |
1579 | end | |
1580 | end | |
1581 | end | |
1582 | end | |
1583 | if hit2 ~= nil then | |
1584 | print(hit2) | |
1585 | local effectsmsh = it("SpecialMesh") | |
1586 | effectsmsh.MeshId = "http://www.roblox.com/asset/?id=15887356" | |
1587 | --effectsmsh.Scale = vt(1,1,2.5) | |
1588 | effectsmsh.Scale = vt(3,3,3) | |
1589 | local effectsg = it("Part") | |
1590 | effectsg.formFactor = 3 | |
1591 | effectsg.CanCollide = false | |
1592 | effectsg.Name = "Arrow" | |
1593 | effectsg.Locked = true | |
1594 | effectsg.Transparency = 1 | |
1595 | effectsg.Size = vt(0.2,0.2,0.2) | |
1596 | effectsg.Parent = Main | |
1597 | effectsg.BrickColor = BrickColor.new("Black") | |
1598 | effectsmsh.Parent = effectsg | |
1599 | effectsg.CFrame = cf(newpos,pos) + cf(newpos,pos).lookVector*2.5*2 | |
1600 | coroutine.resume(coroutine.create(function() | |
1601 | wait(0) | |
1602 | effectsg.Parent = nil | |
1603 | end)) | |
1604 | local efwel = it("Weld") | |
1605 | efwel.Parent = effectsg | |
1606 | efwel.Part0 = effectsg | |
1607 | efwel.Part1 = hit2 | |
1608 | efwel.Parent = nil | |
1609 | effectsg.Anchored = true | |
1610 | --local HitPos = effectsg.Position + cf(newpos,pos).lookVector*0.75 | |
1611 | --local HitPos = prt1.Position + cf(newpos,pos).lookVector*0.75 | |
1612 | local HitPos = Prt4.Position + (Head.CFrame.lookVector * .5) | |
1613 | local CJ = cf(HitPos) | |
1614 | local C0 = effectsg.CFrame:inverse() * CJ | |
1615 | local C1 = hit2.CFrame:inverse() * CJ | |
1616 | --efwel.C0 = C0 | |
1617 | --efwel.C1 = C1 | |
1618 | --efwel.Parent = effectsg | |
1619 | if hit2.Parent:FindFirstChild("Humanoid") ~= nil then | |
1620 | hum = hit2.Parent.Humanoid | |
1621 | attackdebounce=false | |
1622 | Damagefunc1(hit2,math.floor(Damg),0.1) | |
1623 | elseif hit2.Parent.Parent ~= nil and hit2.Parent.Parent:FindFirstChild("Humanoid") ~= nil then | |
1624 | hum = hit2.Parent.Parent.Humanoid | |
1625 | attackdebounce=false | |
1626 | Damagefunc1(hum,math.floor(Damg),0.1) | |
1627 | end | |
1628 | end | |
1629 | end)) | |
1630 | end | |
1631 | ||
1632 | ||
1633 | function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , Ignore Descendants | |
1634 | return game.Workspace:FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore) | |
1635 | end | |
1636 | ||
1637 | hold = false | |
1638 | ||
1639 | function ob1d(mouse) | |
1640 | if attack == true then return end | |
1641 | hold=true | |
1642 | if mode=="Shoot" then | |
1643 | shoottrail2(Prt4,15) | |
1644 | attack=true | |
1645 | for i=0,1,0.4 do | |
1646 | wait() | |
1647 | Torso.Neck.C0=necko*euler(0,-offset,-1.57) | |
1648 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5) | |
1649 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
1650 | RW.C0 = cf(1.5,0.5,0) * euler(0,0,1.57) | |
1651 | RW.C1 = cf(0, 0.5, 0) * euler(offset-0.3*i,1.57,0) | |
1652 | end | |
1653 | for i=0,1,0.4 do | |
1654 | wait() | |
1655 | Torso.Neck.C0=necko*euler(0,-offset,-1.57) | |
1656 | LW.C0 = cf(-1.5,0.5,0) * euler(0,0,-0.5) | |
1657 | LW.C1 = cf(0, 0.5, 0) * euler(0,0,0) | |
1658 | RW.C0 = cf(1.5,0.5,0) * euler(0,0,1.57) | |
1659 | RW.C1 = cf(0, 0.5, 0) * euler(offset-0.3+0.3*i,1.57,0) | |
1660 | end | |
1661 | attack=false | |
1662 | Stance() | |
1663 | end | |
1664 | end | |
1665 | ||
1666 | function ob1u(mouse) | |
1667 | hold = false | |
1668 | end | |
1669 | ||
1670 | buttonhold = false | |
1671 | ||
1672 | function Key(key,mouse) | |
1673 | if attack == true then return end | |
1674 | if key=="f" then | |
1675 | Mode() | |
1676 | end | |
1677 | if key=="u" then | |
1678 | OverchargeBlast() | |
1679 | end | |
1680 | Stance() | |
1681 | pcall(function() act.key[key:lower()] = true end) | |
1682 | local kk = key:lower() | |
1683 | coroutine.resume(coroutine.create(function() | |
1684 | if kk == "w" or kk == "a" or kk == "s" or kk == "d" then | |
1685 | while act.key["w"] == true or act.key["a"] == true or act.key["s"] == true or act.key["d"] == true do | |
1686 | wait() | |
1687 | end | |
1688 | walking = false | |
1689 | end | |
1690 | end)) | |
1691 | if kk == "w" or kk == "a" or kk == "s" or kk == "d" then | |
1692 | if walking == true then return end | |
1693 | while act.key["w"] == true or act.key["a"] == true or act.key["s"] == true or act.key["d"] == true do | |
1694 | if mode=="Normal" then | |
1695 | Walking() | |
1696 | elseif mode=="Shoot" then | |
1697 | dodging=true | |
1698 | Torso.Neck.C0=necko*euler(0,-offset,-1.57) | |
1699 | if kk=="w" then | |
1700 | DodgeUp() | |
1701 | elseif kk=="a" then | |
1702 | DodgeLeft() | |
1703 | elseif kk=="s" then | |
1704 | DodgeRight() | |
1705 | elseif kk=="d" then | |
1706 | DodgeDown() | |
1707 | end | |
1708 | dodging=false | |
1709 | Stance() | |
1710 | end | |
1711 | wait() | |
1712 | end | |
1713 | walking = false | |
1714 | Stance() | |
1715 | end | |
1716 | end | |
1717 | ||
1718 | function Key2(key,mouse) | |
1719 | pcall(function() act.key[key:lower()] = false end) | |
1720 | end | |
1721 | ||
1722 | function s(mouse) | |
1723 | mouse.Button1Down:connect(function() ob1d(mouse) end) | |
1724 | mouse.Button1Up:connect(function() ob1u(mouse) end) | |
1725 | mouse.KeyDown:connect(function(key) Key(key,mouse) end) | |
1726 | --mouse.KeyDown:connect(key2) | |
1727 | mouse.KeyUp:connect(function(key) Key2(key,mouse) end) | |
1728 | mouse.KeyUp:connect(function(k) act.keydown = false | |
1729 | pcall(function() act.key[k:lower()] = false end) | |
1730 | hold = false | |
1731 | end) | |
1732 | MMouse = mouse | |
1733 | sheathed = false | |
1734 | player = Player | |
1735 | ch = Character | |
1736 | RSH = ch.Torso["Right Shoulder"] | |
1737 | LSH = ch.Torso["Left Shoulder"] | |
1738 | RHP = ch.Torso["Right Hip"] | |
1739 | LHP = ch.Torso["Left Hip"] | |
1740 | -- | |
1741 | RSH.Parent = nil | |
1742 | LSH.Parent = nil | |
1743 | --[[RHP.C0 = cf(-0.5, -1.5, 0) * euler(0,0,0) | |
1744 | RHP.C1 = cf(0, 0.5, 0) | |
1745 | LHP.C0 = cf(0.5, -1.5, 0) * euler(0,0,0) | |
1746 | LHP.C1 = cf(0, 0.5, 0) ]] | |
1747 | -- | |
1748 | RW.Part0 = ch.Torso | |
1749 | RW.C0 = cf(1.5, 0.5, 0) --* euler(1.3, 0, -0.5) | |
1750 | RW.C1 = cf(0, 0.5, 0) | |
1751 | RW.Part1 = ch["Right Arm"] | |
1752 | RW.Parent = ch.Torso | |
1753 | --_G.R = RW | |
1754 | -- | |
1755 | LW.Part0 = ch.Torso | |
1756 | LW.C0 = cf(-1.5, 0.5, 0) --* euler(1.7, 0, 0.8) | |
1757 | LW.C1 = cf(0, 0.5, 0) | |
1758 | LW.Part1 = ch["Left Arm"] | |
1759 | LW.Parent = ch.Torso | |
1760 | --_G.L = LW | |
1761 | -- | |
1762 | --[[RW2.Part0 = ch.Torso | |
1763 | RW2.C0 = cf(0.5, -1.5, 0) --* euler(1.7, 0, 0.8) | |
1764 | RW2.C1 = cf(0, 0.5, 0) | |
1765 | RW2.Part1 = ch["Right Leg"] | |
1766 | RW2.Parent = ch.Torso | |
1767 | --_G.L = LW | |
1768 | -- | |
1769 | LW2.Part0 = ch.Torso | |
1770 | LW2.C0 = cf(-0.5, -1.5, 0) --* euler(1.7, 0, 0.8) | |
1771 | LW2.C1 = cf(0, 0.5, 0) | |
1772 | LW2.Part1 = ch["Left Leg"] | |
1773 | LW2.Parent = ch.Torso | |
1774 | --_G.L = LW | |
1775 | -- ]] | |
1776 | equipanim(mouse) | |
1777 | end | |
1778 | ||
1779 | function ds(mouse) | |
1780 | sheathed = true | |
1781 | guardy = false | |
1782 | walking = nil | |
1783 | Character.Humanoid.WalkSpeed = 16 | |
1784 | Torso.Neck.C1 = euler(1.57,3.14,0) * cf(0,0,-0.5) | |
1785 | --[[RHP.C0 = cf(0.5, -1.5, 0) * euler(0,math.rad(90),0) | |
1786 | RHP.C1 = cf(0, 0, 0) | |
1787 | LHP.C0 = cf(-0.5, -1.5, 0) * euler(0,math.rad(90),0) | |
1788 | LHP.C1 = cf(0, 0, 0) ]] | |
1789 | hideanim() | |
1790 | RW.Parent = nil | |
1791 | LW.Parent = nil | |
1792 | RSH.Parent = player.Character.Torso | |
1793 | LSH.Parent = player.Character.Torso | |
1794 | end | |
1795 | ||
1796 | Bin.Selected:connect(s) | |
1797 | Bin.Deselected:connect(ds) | |
1798 | ||
1799 | increase=0 | |
1800 | --[[while true do | |
1801 | wait() | |
1802 | RH.Part0 = Torso | |
1803 | LH.Part0 = Torso | |
1804 | if mana < 0 then | |
1805 | mana = 0 | |
1806 | end | |
1807 | if mana >= 400 then | |
1808 | mana=400 | |
1809 | end | |
1810 | increase = increase + 1 | |
1811 | if increase == 5 then | |
1812 | if mana < 400 then | |
1813 | mana = mana + 1 | |
1814 | end | |
1815 | increase = 0 | |
1816 | end | |
1817 | fentext3.Size = UDim2.new(mana*0.007,0,0.200000006,0) | |
1818 | fentext.Text = "Dark Energy("..mana..")" | |
1819 | end ]] | |
1820 | -- lego mediafire This acts as a chat filter. Don't ask why I do it. I just do >.> |