SHOW:
|
|
- or go back to the newest paste.
1 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end | |
2 | local Player,Mouse,mouse,UserInputService,ContextActionService = owner | |
3 | local RealPlayer = Player | |
4 | do print("FE Compatibility code by Mokiros");InternalData = {}InternalData.RealOwner = owner;InternalData.RealObjs = {};InternalData.SoundLoudness = {};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()}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;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 t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end,__call=function(self,...)local t=rawget(self,"_RealService")if t then return t(...)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 self[t]end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;x.RunService=v({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")setmetatable(x,{__index=function(self,t)return r:GetService(t)or typeof(r[t])=="function"and function(m,...)return r[t](r,...)end or r[t]end,__newindex=s.__newindex,__call=s.__call})game,owner=x,x.Players.LocalPlayer | |
5 | script.Parent = InternalData.RealOwner.Character | |
6 | local Event = Instance.new("RemoteEvent");Event.Name = "UserInput";InternalData.Event = Event | |
7 | local function createObject (connections, index) | |
8 | local proxy = newproxy (true);local meta = getmetatable (proxy); | |
9 | local runbind = function (self, i, ...) connections[i]:Fire (...); end; | |
10 | while (#connections > 0) do connections[table.remove(connections, 1)] = Instance.new ('BindableEvent');end; | |
11 | meta.__index = function (self, i) | |
12 | if (i == 'TriggerEvent') then return runbind end; | |
13 | return connections[i] and connections[i].Event or index[i]; | |
14 | end; | |
15 | meta.__newindex = index;meta.__metatable = false;return proxy | |
16 | end; | |
17 | local Mouse = createObject({"KeyUp","KeyDown","Button1Down","Button1Up"},{["Target"] = nil;["Hit"] = CFrame.new()}) | |
18 | local UserInputService = createObject({"InputBegan","InputEnded"},{}) | |
19 | local ContextActionService = {Actions={},BindAction = function(self,actionName,Func,touch,...) | |
20 | self.Actions[actionName] = Func and {Name=actionName,Function=Func,Keys={...}} or nil | |
21 | end};ContextActionService.UnBindAction = ContextActionService.BindAction | |
22 | Event.OnServerEvent:Connect(function(FiredBy,Input) | |
23 | if FiredBy ~= InternalData.RealOwner then return end | |
24 | if Input.MouseEvent then | |
25 | Mouse.Target = Input.Target;Mouse.Hit = Input.Hit | |
26 | elseif Input.Sound then | |
27 | if InternalData.SoundLoudness[Input.Sound] then InternalData.SoundLoudness[Input.Sound] = Input.Loudness end | |
28 | else | |
29 | local Begin = Input.UserInputState == Enum.UserInputState.Begin | |
30 | if Input.UserInputType == Enum.UserInputType.MouseButton1 then return Mouse:TriggerEvent(Begin and "Button1Down" or "Button1Up") end | |
31 | for _,Action in pairs(ContextActionService.Actions) do | |
32 | for _,Key in pairs(Action.Keys) do if Key==Input.KeyCode then Action.Function(Action.Name,Input.UserInputState,Input) end end | |
33 | end | |
34 | Mouse:TriggerEvent(Begin and "KeyDown" or "KeyUp",Input.KeyCode.Name:lower());UserInputService:TriggerEvent(Begin and "InputBegan" or "InputEnded",Input,false) | |
35 | end | |
36 | end) | |
37 | InternalData["Mouse"] = Mouse;InternalData["ContextActionService"] = ContextActionService;InternalData["UserInputService"] = UserInputService | |
38 | Event.Parent = NLS([[ | |
39 | local Player = owner; | |
40 | local Sounds = {}; | |
41 | local Event = script:WaitForChild("UserInput"); | |
42 | local UserInputService = game:GetService("UserInputService"); | |
43 | local Mouse = Player:GetMouse(); | |
44 | local Input = function(Input,gameProcessedEvent) | |
45 | if gameProcessedEvent then return end | |
46 | Event:FireServer({KeyCode=Input.KeyCode,UserInputType=Input.UserInputType,UserInputState=Input.UserInputState}) | |
47 | end | |
48 | Event.OnClientEvent:connect(function(Args) | |
49 | if Args[1] == "NewSound" then table.insert(Sounds,Args[2]) end | |
50 | end) | |
51 | UserInputService.InputBegan:Connect(Input);UserInputService.InputEnded:Connect(Input) | |
52 | local Hit,Target | |
53 | while wait(1/30) do | |
54 | for x,Sound in pairs(Sounds) do | |
55 | if Sound.Parent then Event:FireServer({["Sound"]=Sound,["Loudness"]=Sound.PlaybackLoudness}) end | |
56 | end | |
57 | if Hit ~= Mouse.Hit or Target ~= Mouse.Target then | |
58 | Hit = Mouse.Hit;Target = Mouse.Target; | |
59 | Event:FireServer({["MouseEvent"]=true,["Target"]=Target,["Hit"]=Hit}) | |
60 | end | |
61 | end | |
62 | ]],InternalData.RealOwner.Character) | |
63 | end | |
64 | InternalData.NewOwner = setmetatable({},{ | |
65 | __index = function (self,Index) | |
66 | local Type = type(InternalData.RealOwner[Index]) | |
67 | if Type == "function" then | |
68 | if Index:lower() == "getmouse" or Index:lower() == "mouse" then | |
69 | return function (self)return InternalData["Mouse"] end | |
70 | end | |
71 | return function (self,...)return InternalData.RealOwner[Index](InternalData.RealOwner,...) end | |
72 | elseif Index == "FakePlayer" then | |
73 | return true | |
74 | end | |
75 | return InternalData.RealOwner[Index] | |
76 | end; | |
77 | __tostring = function(self) return tostring(InternalData.RealOwner) end | |
78 | }) | |
79 | --LoadLibrary("RbxUtility").Create | |
80 | InternalData.LoadLibrary = LoadLibrary;LoadLibrary = function(Library) | |
81 | if Library == "RbxUtility" then | |
82 | return setmetatable({},{ | |
83 | __tostring = function() return "RbxUtility" end; | |
84 | __index = function(self, Index) | |
85 | if Index:lower() == "create" then | |
86 | return function(Type) | |
87 | return function(Data) | |
88 | Data = Data or {} | |
89 | local Inst = Instance.new(Type) | |
90 | for x,y in pairs(Data) do | |
91 | if InternalData.RealObjs[y] then y = InternalData.RealObjs[y] end | |
92 | if y == owner then y = InternalData.RealOwner end | |
93 | Inst[x] = y | |
94 | end | |
95 | return Inst | |
96 | end | |
97 | end | |
98 | end | |
99 | return InternalData.LoadLibrary(Library)[Index] | |
100 | end | |
101 | }) | |
102 | end | |
103 | return InternalData.LoadLibrary(Library) | |
104 | end | |
105 | InternalData.RealInstance = Instance;Instance = setmetatable({},{ | |
106 | __index = function (self,Index) | |
107 | if Index:lower() == 'new' then | |
108 | return function (Type, Parent) | |
109 | if Parent == owner then Parent = InternalData.RealOwner end | |
110 | if InternalData.RealObjs[Parent] then Parent = InternalData.RealObjs[Parent] end | |
111 | local Real = InternalData.RealInstance.new(Type,Parent) | |
112 | if not Type then return end | |
113 | if Type == "BillboardGui" then | |
114 | local ToReturn = setmetatable({},{ | |
115 | __index = function (self,Index) | |
116 | if type(Real[Index]) == "function" then | |
117 | if Index:lower() == "clone" then | |
118 | return function (self) | |
119 | local Real = Real:Clone() | |
120 | local ToReturn = setmetatable({RealObject = Real},{ | |
121 | __index = function (self,Index) | |
122 | if type(Real[Index]) == "function" then return function (self,...) return Real[Index](Real,...)end end | |
123 | return Real[Index] | |
124 | end; | |
125 | __newindex = function (self,Index,Value) | |
126 | if InternalData.RealObjs[Value] then Value = InternalData.RealObjs[Value] end | |
127 | if Value == owner then Value = InternalData.RealOwner end | |
128 | Real[Index] = Value | |
129 | end; | |
130 | __tostring = function(self) return tostring(Real) end; | |
131 | }) | |
132 | InternalData.RealObjs[ToReturn] = Real;return ToReturn; | |
133 | end | |
134 | end | |
135 | return function (self,...) return Real[Index](Real,...)end | |
136 | end | |
137 | return Real[Index] | |
138 | end; | |
139 | __newindex = function (self,Index,Value) | |
140 | if InternalData.RealObjs[Value] then Value = InternalData.RealObjs[Value] end | |
141 | if Value == owner then Value = InternalData.RealOwner end | |
142 | Real[Index] = Value | |
143 | end; | |
144 | __tostring = function(self) return tostring(Real) end; | |
145 | }) | |
146 | InternalData.RealObjs[ToReturn] = Real;return ToReturn; | |
147 | elseif Type:lower() == "sound" then | |
148 | Real.Parent = owner.Character; | |
149 | local ToReturn = setmetatable({RealObject = Real},{ | |
150 | __index = function (self,Index) | |
151 | if Index:lower() == "playbackloudness" then | |
152 | return InternalData.SoundLoudness[Real] or 0 | |
153 | elseif type(Real[Index]) == "function" then | |
154 | if Index:lower() == "clone" then | |
155 | return function (self) | |
156 | local Real = Real:Clone() | |
157 | local ToReturn = setmetatable({},{ | |
158 | __index = function (self,Index) | |
159 | if type(Real[Index]) == "function" then return function (self,...) return Real[Index](Real,...)end end | |
160 | return Real[Index] | |
161 | end; | |
162 | __newindex = function (self,Index,Value) | |
163 | if InternalData.RealObjs[Value] then Value = InternalData.RealObjs[Value] end | |
164 | if Value == owner then Value = InternalData.RealOwner end | |
165 | Real[Index] = Value | |
166 | end; | |
167 | __tostring = function(self) return tostring(Real) end; | |
168 | }) | |
169 | InternalData.RealObjs[ToReturn] = Real;return ToReturn; | |
170 | end | |
171 | end | |
172 | return function (self,...) return Real[Index](Real,...)end | |
173 | end | |
174 | return Real[Index] | |
175 | end; | |
176 | __newindex = function (self,Index,Value) | |
177 | if InternalData.RealObjs[Value] then Value = InternalData.RealObjs[Value] end | |
178 | if Value == owner then Value = InternalData.RealOwner end | |
179 | Real[Index] = Value | |
180 | end; | |
181 | __tostring = function(self) return tostring(Real) end; | |
182 | }) | |
183 | InternalData.RealObjs[ToReturn] = Real;InternalData.SoundLoudness[Real] = 0;repeat wait() until InternalData.Event.Parent InternalData.Event:FireClient(InternalData.RealOwner,{"NewSound",Real}) return ToReturn; | |
184 | else | |
185 | local ToReturn = setmetatable({RealObject = Real},{ | |
186 | __index = function (self,Index) | |
187 | if type(Real[Index]) == "function" then | |
188 | if Index:lower() == "clone" then | |
189 | return function (self) | |
190 | local Real = Real:Clone() | |
191 | local ToReturn = setmetatable({},{ | |
192 | __index = function (self,Index) | |
193 | if type(Real[Index]) == "function" then return function (self,...) return Real[Index](Real,...)end end | |
194 | return Real[Index] | |
195 | end; | |
196 | __newindex = function (self,Index,Value) | |
197 | if InternalData.RealObjs[Value] then Value = InternalData.RealObjs[Value] end | |
198 | if Value == owner then Value = InternalData.RealOwner end | |
199 | Real[Index] = Value | |
200 | end; | |
201 | __tostring = function(self) return tostring(Real) end; | |
202 | }) | |
203 | InternalData.RealObjs[ToReturn] = Real;return ToReturn; | |
204 | end | |
205 | end | |
206 | return function (self,...) return Real[Index](Real,...)end | |
207 | end | |
208 | return Real[Index] | |
209 | end; | |
210 | __newindex = function (self,Index,Value) | |
211 | if InternalData.RealObjs[Value] then Value = InternalData.RealObjs[Value] end | |
212 | if Value == owner then Value = InternalData.RealOwner end | |
213 | Real[Index] = Value | |
214 | end; | |
215 | __tostring = function(self) return tostring(Real) end; | |
216 | }) | |
217 | InternalData.RealObjs[ToReturn] = Real;return ToReturn; | |
218 | end | |
219 | end | |
220 | end | |
221 | return InternalData.RealInstance[Index] | |
222 | end; | |
223 | __tostring = function(self) return tostring(InternalData.RealInstance) end; | |
224 | }); | |
225 | InternalData.RealGame = game;game = setmetatable({},{ | |
226 | __index = function (self,Index) | |
227 | if InternalData.RealGame[Index] then | |
228 | local Type = type(InternalData.RealGame[Index]) | |
229 | if Type == "function" then | |
230 | if Index:lower() == "getservice" or Index:lower() == "service" then | |
231 | return function (self,Service) | |
232 | local FakeServices = { | |
233 | ["players"] = function() | |
234 | return setmetatable({},{ | |
235 | __index = function (self2,Index2) | |
236 | local RealService = InternalData.RealGame:GetService(Service) | |
237 | local Type2 = type(RealService[Index2]) | |
238 | if Type2 == "function" then | |
239 | return function (self,...) return RealService[Index2](RealService,...)end | |
240 | else | |
241 | if Index2:lower() == "localplayer" then return InternalData.NewOwner end | |
242 | return RealService[Index2] | |
243 | end | |
244 | end; | |
245 | __tostring = function(self) return tostring(InternalData.RealGame:GetService(Service)) end | |
246 | }) | |
247 | end; | |
248 | ["contextactionservice"] = function() return InternalData["ContextActionService"] end; | |
249 | ["userinputservice"] = function() return InternalData["UserInputService"] end; | |
250 | ["debris"] = function() | |
251 | return setmetatable({},{ | |
252 | __index = function(self2,Index2) | |
253 | local RealService = InternalData.RealGame:GetService(Service) | |
254 | local Type2 = type(RealService[Index2]) | |
255 | if Type2 == "function" then | |
256 | if Index2:lower() == "additem" then | |
257 | return function (self,Item,Time) | |
258 | if InternalData.RealObjs[Item] then Item = InternalData.RealObjs[Item] end | |
259 | return RealService:AddItem(Item,Time) | |
260 | end | |
261 | end | |
262 | return function (self,...) return RealService[Index2](RealService,...) end | |
263 | end | |
264 | return RealService[Index2] | |
265 | end; | |
266 | __tostring = function(self) return tostring(InternalData.RealGame:GetService("Debris")) end | |
267 | }) | |
268 | end; | |
269 | ["runservice"] = function() | |
270 | return setmetatable({},{ | |
271 | __index = function(self2,Index2) | |
272 | local RealService = InternalData.RealGame:GetService(Service) | |
273 | local Type2 = type(RealService[Index2]) | |
274 | if Type2 == "function" then | |
275 | return function (self,...) return RealService[Index2](RealService,...) end | |
276 | else | |
277 | local RunServices = { | |
278 | ["bindtorenderstep"] = function() return function (self,Name,Priority,Function) return InternalData.RealGame:GetService("RunService").Stepped:Connect(Function) end end; | |
279 | ["renderstepped"] = function() return RealService["Stepped"] end | |
280 | } | |
281 | if RunServices[Index2:lower()] then return RunServices[Index2:lower()]() end | |
282 | return RealService[Index2] | |
283 | end | |
284 | end; | |
285 | __tostring = function(self) return tostring(InternalData.RealGame:GetService("RunService")) end | |
286 | }) | |
287 | end | |
288 | } | |
289 | if FakeServices[Service:lower()] then return FakeServices[Service:lower()]() end | |
290 | return InternalData.RealGame:GetService(Service) | |
291 | end | |
292 | end | |
293 | return function (self,...) return InternalData.RealGame[Index](InternalData.RealGame,...) end | |
294 | else | |
295 | if game:GetService(Index) then return game:GetService(Index) end | |
296 | return InternalData.RealGame[Index] | |
297 | end | |
298 | end | |
299 | return nil | |
300 | end; | |
301 | __tostring = function(self) return tostring(InternalData.game) end | |
302 | });Game = game;owner = game:GetService("Players").LocalPlayer;script = Instance.new("Script");print("Complete!") | |
303 | ||
304 | -- hastebin.com/raw/dignsxi | |
305 | TorsoColor = BrickColor.new("Royal purple") | |
306 | --------------------------This is an Official script from Duelist-------------------------- | |
307 | ---{-------------------- -------------------}--- | |
308 | ---{-------------------- / \ -------------------}--- | |
309 | ---{-------------------- II -------------------}--- | |
310 | ---{-------------------- II -------------------}--- | |
311 | ---{-------------------- II -------------------}--- | |
312 | ---{-------------------- A========A -------------------}--- | |
313 | ---{-------------------- II -------------------}--- | |
314 | ---{-------------------- II -------------------}--- | |
315 | ---{-------------------- W -------------------}--- | |
316 | -------------------------------------------------------------------------------------------------------------- | |
317 | game:GetService("Lighting").Outlines = false | |
318 | game:GetService("Lighting").TimeOfDay = "00:00:00" | |
319 | game:GetService("Lighting").FogColor = Color3.new(0, 0, 0) | |
320 | game:GetService("Lighting").FogEnd = 160 | |
321 | local char = game.Players.LocalPlayer.Character | |
322 | local torso = char.Torso | |
323 | local hum = char.Humanoid | |
324 | local hed = char.Head | |
325 | local root = char.HumanoidRootPart | |
326 | GroundWave2 = function(target) | |
327 | if TorsoColor == BrickColor.new("Royal purple") then | |
328 | local wave = Instance.new("Part", torso) | |
329 | wave.BrickColor = BrickColor.new("White") | |
330 | wave.Anchored = true | |
331 | wave.CanCollide = false | |
332 | wave.Locked = true | |
333 | wave.Size = Vector3.new(1, 1, 1) | |
334 | wave.TopSurface = "Smooth" | |
335 | wave.BottomSurface = "Smooth" | |
336 | wave.Transparency = 0.35 | |
337 | wave.CFrame = target | |
338 | wave.Material = "Neon" | |
339 | wm = Instance.new("SpecialMesh", wave) | |
340 | wm.MeshType = "Sphere" | |
341 | local wave5 = Instance.new("Part", torso) | |
342 | wave5.BrickColor = BrickColor.new("Really black") | |
343 | wave5.Anchored = true | |
344 | wave5.CanCollide = false | |
345 | wave5.Locked = true | |
346 | wave5.Size = Vector3.new(1, 1, 1) | |
347 | wave5.TopSurface = "Smooth" | |
348 | wave5.BottomSurface = "Smooth" | |
349 | wave5.Transparency = 0.35 | |
350 | wave5.CFrame = target | |
351 | wave5.Material = "Neon" | |
352 | wm5 = Instance.new("SpecialMesh", wave) | |
353 | wm5.MeshType = "Sphere" | |
354 | wm5.Scale = Vector3.new(1,1,1) | |
355 | local wave2 = Instance.new("Part", torso) | |
356 | wave2.BrickColor = BrickColor.new("Really black") | |
357 | wave2.Anchored = true | |
358 | wave2.CanCollide = false | |
359 | wave2.Locked = true | |
360 | wave2.Size = Vector3.new(1, 1, 1) | |
361 | wave2.TopSurface = "Smooth" | |
362 | wave2.BottomSurface = "Smooth" | |
363 | wave2.Transparency = 0.35 | |
364 | wave2.CFrame = target | |
365 | wave2.Material = "Neon" | |
366 | wm2 = Instance.new("SpecialMesh", wave2) | |
367 | wm2.MeshType = "FileMesh" | |
368 | wm2.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
369 | wm2.Scale = Vector3.new(1,1,1) | |
370 | local wave3 = Instance.new("Part", torso) | |
371 | wave3.BrickColor = BrickColor.new("Really black") | |
372 | wave3.Anchored = true | |
373 | wave3.CanCollide = false | |
374 | wave3.Locked = true | |
375 | wave3.Size = Vector3.new(1, 1, 1) | |
376 | wave3.TopSurface = "Smooth" | |
377 | wave3.BottomSurface = "Smooth" | |
378 | wave3.Transparency = 0 | |
379 | wave3.CFrame = target | |
380 | wave3.Material = "Neon" | |
381 | wm3 = Instance.new("SpecialMesh", wave3) | |
382 | wm3.MeshType = "FileMesh" | |
383 | wm3.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
384 | wm3.Scale = Vector3.new(1,1,1) | |
385 | coroutine.wrap(function() | |
386 | for i = 1, 18, 1 do | |
387 | wm.Scale = Vector3.new(2+i*1.2, 2+i*1.2, 2+i*1.2) | |
388 | wm5.Scale = Vector3.new(2+i*1.1, 2+i*1.1, 2+i*1.1) | |
389 | wm2.Scale = Vector3.new(2+i*1.2, 2+i*1.2, 2) | |
390 | wm3.Scale = Vector3.new(2+i*1.2, 2+i*1.2, 2) | |
391 | --wave.Size = wm.Scale | |
392 | wave.CFrame = target | |
393 | wave.Transparency = i/14 | |
394 | --wave.Size | |
395 | wave5.CFrame = target | |
396 | wave5.Transparency = i/14 | |
397 | --wave2.Size = wm2.Scale | |
398 | wave2.CFrame = target | |
399 | wave2.Rotation = Vector3.new(90, 0, 0) | |
400 | wave2.Transparency = i/14 | |
401 | --wave3.Size = wm3.Scale | |
402 | wave3.CFrame = target | |
403 | wave3.Rotation = Vector3.new(90, 0, 0) | |
404 | wave3.Transparency = i/14 | |
405 | wait() | |
406 | end | |
407 | wait() | |
408 | wave:Destroy() | |
409 | wave5:Destroy() | |
410 | wave2:Destroy() | |
411 | wave3:Destroy() | |
412 | end)() | |
413 | elseif TorsoColor == BrickColor.new("Royal purple") then | |
414 | wait() | |
415 | end | |
416 | end | |
417 | GroundWave = function(target) | |
418 | if TorsoColor == BrickColor.new("Royal purple") then | |
419 | local wave = Instance.new("Part", torso) | |
420 | wave.BrickColor = BrickColor.new("Dark red") | |
421 | wave.Anchored = true | |
422 | wave.CanCollide = false | |
423 | wave.Locked = true | |
424 | wave.Size = Vector3.new(1, 1, 1) | |
425 | wave.TopSurface = "Smooth" | |
426 | wave.BottomSurface = "Smooth" | |
427 | wave.Transparency = 0.35 | |
428 | wave.CFrame = target | |
429 | wave.Material = "Neon" | |
430 | wm = Instance.new("SpecialMesh", wave) | |
431 | wm.MeshType = "Sphere" | |
432 | wm.Scale = Vector3.new(1,1,1) | |
433 | local wave2 = Instance.new("Part", torso) | |
434 | wave2.BrickColor = BrickColor.new("Dark red") | |
435 | wave2.Anchored = true | |
436 | wave2.CanCollide = false | |
437 | wave2.Locked = true | |
438 | wave2.Size = Vector3.new(1, 1, 1) | |
439 | wave2.TopSurface = "Smooth" | |
440 | wave2.BottomSurface = "Smooth" | |
441 | wave2.Transparency = 0.35 | |
442 | wave2.CFrame = target | |
443 | wave2.Material = "Neon" | |
444 | wm2 = Instance.new("SpecialMesh", wave2) | |
445 | wm2.MeshType = "FileMesh" | |
446 | wm2.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
447 | wm2.Scale = Vector3.new(1,1,1) | |
448 | local wave3 = Instance.new("Part", torso) | |
449 | wave3.BrickColor = BrickColor.new("Really black") | |
450 | wave3.Anchored = true | |
451 | wave3.CanCollide = false | |
452 | wave3.Locked = true | |
453 | wave3.Size = Vector3.new(1, 1, 1) | |
454 | wave3.TopSurface = "Smooth" | |
455 | wave3.BottomSurface = "Smooth" | |
456 | wave3.Transparency = 0.35 | |
457 | wave3.CFrame = target | |
458 | wave3.Material = "Neon" | |
459 | wm3 = Instance.new("SpecialMesh", wave3) | |
460 | wm3.MeshType = "FileMesh" | |
461 | wm3.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
462 | wm3.Scale = Vector3.new(1,1,1) | |
463 | coroutine.wrap(function() | |
464 | for i = 1, 18, 1 do | |
465 | wm.Scale = Vector3.new(2+i*1.2, 2+i*1.2, 2+i*1.2) | |
466 | wm2.Scale = Vector3.new(2+i*1.2, 2+i*1.2, 2) | |
467 | wm3.Scale = Vector3.new(2+i*1.2, 2+i*1.2, 2) | |
468 | --wave.Size = wm.Scale | |
469 | wave.CFrame = target | |
470 | wave.Transparency = i/14 | |
471 | --wave2.Size = wm2.Scale | |
472 | wave2.CFrame = target | |
473 | wave2.Rotation = Vector3.new(90, 0, 0) | |
474 | wave2.Transparency = i/14 | |
475 | --wave3.Size = wm3.Scale | |
476 | wave3.CFrame = target | |
477 | wave3.Rotation = Vector3.new(90, 0, 0) | |
478 | wave3.Transparency = i/14 | |
479 | wait() | |
480 | end | |
481 | wait() | |
482 | wave:Destroy() | |
483 | wave2:Destroy() | |
484 | wave3:Destroy() | |
485 | end)() | |
486 | elseif TorsoColor == BrickColor.new("Royal purple") then | |
487 | wait() | |
488 | end | |
489 | end | |
490 | local p = game.Players.LocalPlayer | |
491 | local char = p.Character | |
492 | local mouse = p:GetMouse() | |
493 | local larm = char["Left Arm"] | |
494 | local rarm = char["Right Arm"] | |
495 | local lleg = char["Left Leg"] | |
496 | local rleg = char["Right Leg"] | |
497 | local hed = char.Head | |
498 | local torso = char.Torso | |
499 | local hum = char.Humanoid | |
500 | local cam = game.Workspace.CurrentCamera | |
501 | local root = char.HumanoidRootPart | |
502 | local rj = root.RootJoint | |
503 | local deb = false | |
504 | local shot = 0 | |
505 | local stanceToggle = "Idle1" | |
506 | local l = game:GetService("Lighting") | |
507 | local rs = game:GetService("RunService").RenderStepped | |
508 | local hb = game:GetService("RunService").Heartbeat | |
509 | local Stepped = game:GetService("RunService").Stepped | |
510 | hed.face.Texture = "rbxassetid://1471407701" | |
511 | eye2 = Instance.new("Part", workspace) | |
512 | eye2.Anchored = false | |
513 | eye2.Parent = hed | |
514 | eye2.TopSurface = 0 | |
515 | eye2.BrickColor = BrickColor.new("Royal purple") | |
516 | eye2.Material = "Neon" | |
517 | eye2.BottomSurface = 0 | |
518 | eye2m = Instance.new("SpecialMesh", eye2) | |
519 | eye2m.MeshId = "rbxassetid://31309506" | |
520 | eye2m.TextureId = "rbxassetid://31309468" | |
521 | eye2m.Scale = Vector3.new(1.03, 1.05, 1.03) | |
522 | ogsize = eye2m.Scale | |
523 | weld = Instance.new("Weld", hed) | |
524 | weld.Part0 = eye2 | |
525 | weld.Part1 = hed | |
526 | weld.Name = "eye2Weld" | |
527 | weld.C1 = CFrame.new(0,.45,0.05) | |
528 | local shir = Instance.new("Shirt",char) | |
529 | local pan = Instance.new("Pants",char) | |
530 | shir.ShirtTemplate = "http://www.roblox.com/asset/?id=1284266303" | |
531 | pan.PantsTemplate = "http://www.roblox.com/asset/?id=1043362618" | |
532 | spawn(function() | |
533 | while wait() do | |
534 | for i,v in pairs(char:GetChildren()) do | |
535 | if v:IsA('Part') then | |
536 | v.BrickColor = BrickColor.new("White") | |
537 | end | |
538 | end | |
539 | end | |
540 | end) | |
541 | spawn(function() | |
542 | while wait(.9) do | |
543 | GroundWave2(torso.CFrame) | |
544 | end | |
545 | end) | |
546 | fat = Instance.new("BindableEvent", script) | |
547 | fat.Name = "Heartbeat" | |
548 | script:WaitForChild("Heartbeat") | |
549 | frame = 0.033333333333333 | |
550 | tf = 0 | |
551 | allowframeloss = false | |
552 | tossremainder = false | |
553 | lastframe = tick() | |
554 | script.Heartbeat:Fire() | |
555 | game:GetService("RunService").Heartbeat:connect(function(s, p) | |
556 | ||
557 | tf = tf + s | |
558 | if frame <= tf then | |
559 | if allowframeloss then | |
560 | script.Heartbeat:Fire() | |
561 | lastframe = tick() | |
562 | else | |
563 | for i = 1, math.floor(tf / frame) do | |
564 | script.Heartbeat:Fire() | |
565 | end | |
566 | lastframe = tick() | |
567 | end | |
568 | if tossremainder then | |
569 | tf = 0 | |
570 | else | |
571 | tf = tf - frame * math.floor(tf / frame) | |
572 | end | |
573 | end | |
574 | end | |
575 | ) | |
576 | for i,v in pairs(hed:GetChildren()) do | |
577 | if v:IsA("Sound") then | |
578 | v:Destroy() | |
579 | end | |
580 | end | |
581 | Debounces = {CanAttack = true, CanJoke = true, NoIdl = false, RPunch = false, RPunched = false, LPunch = false, LPunched = false, Slashing = false, Slashed = false, ks = false, ks2 = false} | |
582 | weld5 = function(part0, part1, c0, c1) | |
583 | ||
584 | weeld = Instance.new("Weld", part0) | |
585 | weeld.Part0 = part0 | |
586 | weeld.Part1 = part1 | |
587 | weeld.C0 = c0 | |
588 | weeld.C1 = c1 | |
589 | return weeld | |
590 | end | |
591 | ||
592 | NewPart = function(prnt, siz, cf, trans, anc, mat, col) | |
593 | ||
594 | local prt = Instance.new("Part") | |
595 | prt.Parent = prnt | |
596 | prt.Name = "Part" | |
597 | prt.Size = siz | |
598 | prt.CanCollide = false | |
599 | prt.Anchored = anc | |
600 | prt.Locked = true | |
601 | prt.Transparency = trans | |
602 | prt.TopSurface = 10 | |
603 | prt.BottomSurface = 10 | |
604 | prt.FrontSurface = 10 | |
605 | prt.BackSurface = 10 | |
606 | prt.LeftSurface = 10 | |
607 | prt.RightSurface = 10 | |
608 | prt:BreakJoints() | |
609 | if not cf then | |
610 | prt.CFrame = CFrame.new(30, 10, 30) | |
611 | prt.Material = mat | |
612 | prt.BrickColor = BrickColor.new(col) | |
613 | m = Instance.new("SpecialMesh", prt) | |
614 | m.MeshType = 6 | |
615 | return prt | |
616 | end | |
617 | end | |
618 | ||
619 | lerp = function(a, b, t) | |
620 | ||
621 | return a + (b - a) * t | |
622 | end | |
623 | ||
624 | slerp = function(a, b, t) | |
625 | ||
626 | dot = a:Dot(b) | |
627 | if t > 0.5 or not a then | |
628 | do return dot <= 0.99999 and dot >= -0.99999 or b end | |
629 | r = math.acos(dot) | |
630 | do return (a * math.sin((1 - t) * r) + b * math.sin(t * r)) / math.sin(r) end | |
631 | end | |
632 | end | |
633 | ||
634 | matrixInterpolate = function(a, b, t) | |
635 | ||
636 | local ax, ay, az, a00, a01, a02, a10, a11, a12, a20, a21, a22 = a:components() | |
637 | local bx, by, bz, b00, b01, b02, b10, b11, b12, b20, b21, b22 = b:components() | |
638 | local v0 = lerp(Vector3.new(ax, ay, az), Vector3.new(bx, by, bz), t) | |
639 | local v1 = slerp(Vector3.new(a00, a01, a02), Vector3.new(b00, b01, b02), t) | |
640 | local v2 = slerp(Vector3.new(a10, a11, a12), Vector3.new(b10, b11, b12), t) | |
641 | local v3 = slerp(Vector3.new(a20, a21, a22), Vector3.new(b20, b21, b22), t) | |
642 | local t = v1:Dot(v2) | |
643 | if t >= 0 and t ~= 0 and t <= 0 then | |
644 | return CFrame.new() | |
645 | end | |
646 | return CFrame.new(v0.x, v0.y, v0.z, v1.x, v1.y, v1.z, v2.x, v2.y, v2.z, v3.x, v3.y, v3.z) | |
647 | end | |
648 | ||
649 | genWeld = function(a, b) | |
650 | ||
651 | local w = Instance.new("Weld", a) | |
652 | w.Part0 = a | |
653 | w.Part1 = b | |
654 | return w | |
655 | end | |
656 | ||
657 | weld = function(a, b) | |
658 | ||
659 | local weld = Instance.new("Weld") | |
660 | weld.Name = "W" | |
661 | weld.Part0 = a | |
662 | weld.Part1 = b | |
663 | weld.C0 = a.CFrame:inverse() * b.CFrame | |
664 | weld.Parent = a | |
665 | return weld | |
666 | end | |
667 | ||
668 | Lerp = function(c1, c2, al) | |
669 | ||
670 | local com1 = {c1.X, c1.Y, c1.Z, c1:toEulerAnglesXYZ()} | |
671 | local com2 = {c2.X, c2.Y, c2.Z, c2:toEulerAnglesXYZ()} | |
672 | for i,v in pairs(com1) do | |
673 | com1[i] = v + (com2[i] - v) * al | |
674 | end | |
675 | return CFrame.new(com1[1], com1[2], com1[3]) * CFrame.Angles(select(4, unpack(com1))) | |
676 | end | |
677 | ||
678 | newWeld = function(wp0, wp1, wc0x, wc0y, wc0z) | |
679 | ||
680 | local wld = Instance.new("Weld", wp1) | |
681 | wld.Part0 = wp0 | |
682 | wld.Part1 = wp1 | |
683 | wld.C0 = CFrame.new(wc0x, wc0y, wc0z) | |
684 | end | |
685 | ||
686 | newWeld(torso, larm, -1.5, 0.5, 0) | |
687 | larm.Weld.C1 = CFrame.new(0, 0.5, 0) | |
688 | newWeld(torso, rarm, 1.5, 0.5, 0) | |
689 | rarm.Weld.C1 = CFrame.new(0, 0.5, 0) | |
690 | newWeld(torso, hed, 0, 1.5, 0) | |
691 | newWeld(torso, lleg, -0.5, -1, 0) | |
692 | lleg.Weld.C1 = CFrame.new(0, 1, 0) | |
693 | newWeld(torso, rleg, 0.5, -1, 0) | |
694 | rleg.Weld.C1 = CFrame.new(0, 1, 0) | |
695 | newWeld(root, torso, 0, -1, 0) | |
696 | torso.Weld.C1 = CFrame.new(0, -1, 0) | |
697 | z = Instance.new("Sound", char) | |
698 | z.SoundId = "rbxassetid://1001922520" | |
699 | z.Looped = true | |
700 | z.Pitch = 1 | |
701 | z.Volume = 10 | |
702 | wait(0.1) | |
703 | z:Play() | |
704 | New = function(Object, Parent, Name, Data) | |
705 | ||
706 | local Object = Instance.new(Object) | |
707 | if not Data then | |
708 | for Index,Value in pairs({}) do | |
709 | Object[Index] = Value | |
710 | end | |
711 | Object.Parent = Parent | |
712 | Object.Name = Name | |
713 | return Object | |
714 | end | |
715 | end | |
716 | ||
717 | part1 = Instance.new("Part", rarm) | |
718 | part1.Name = "Arbiter" | |
719 | part1.BrickColor = BrickColor.new("Really black") | |
720 | part1.CFrame = rarm.CFrame | |
721 | part1.Material = "Neon" | |
722 | part1.Anchored = false | |
723 | part1.CanCollide = false | |
724 | part1.Locked = true | |
725 | part1.Size = Vector3.new(0.25, 1.05, 5.9) | |
726 | mesh1 = Instance.new("SpecialMesh", part1) | |
727 | mesh1.MeshType = Enum.MeshType.FileMesh | |
728 | mesh1.MeshId = "rbxassetid://971960331" | |
729 | mesh1.TextureId = "http://www.roblox.com/asset/?id=971960686" | |
730 | local cor = Instance.new("Part", rarm) | |
731 | cor.Name = "Thingy" | |
732 | cor.Locked = true | |
733 | cor.TopSurface = 0 | |
734 | cor.BottomSurface = 0 | |
735 | cor.CanCollide = false | |
736 | cor.Size = Vector3.new(0.2, 0.2, 0.2) | |
737 | cor.Transparency = 1 | |
738 | corw = Instance.new("Weld", cor) | |
739 | corw.Part0 = rarm | |
740 | corw.Part1 = cor | |
741 | corw.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)) | |
742 | corw.C1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)) | |
743 | weld1 = Instance.new("Weld", cor) | |
744 | weld1.Part0 = cor | |
745 | weld1.Part1 = part1 | |
746 | weld1.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)) | |
747 | weld1.C1 = CFrame.new(0.25, 1, -0.5) * CFrame.Angles(math.rad(-20), math.rad(30), math.rad(90)) | |
748 | hitb = Instance.new("Part", cor) | |
749 | hitb.Name = "Thingy2" | |
750 | hitb.Locked = true | |
751 | hitb.TopSurface = 0 | |
752 | hitb.BottomSurface = 0 | |
753 | hitb.CanCollide = false | |
754 | hitb.Size = Vector3.new(4, 1, 3.5) | |
755 | hitb.Transparency = 1 | |
756 | weld4 = Instance.new("Weld", cor) | |
757 | weld4.Part0 = hitb | |
758 | weld4.Part1 = cor | |
759 | weld4.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)) | |
760 | weld4.C1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)) | |
761 | local animpose = "Idle1" | |
762 | local lastanimpose = "Idle1" | |
763 | local grab = false | |
764 | local Smooth = 1 | |
765 | local sine = 0 | |
766 | local change = 1 | |
767 | local val = 0 | |
768 | local ffing = false | |
769 | mod4 = Instance.new("Model", char) | |
770 | ptez = {0.7, 0.8, 0.9, 1} | |
771 | FindNearestTorso = function(Position, Distance, SinglePlayer) | |
772 | ||
773 | if SinglePlayer.Torso.CFrame.p - Position.magnitude >= Distance then | |
774 | do return not SinglePlayer end | |
775 | do | |
776 | local List = {} | |
777 | for i,v in pairs(workspace:GetChildren()) do | |
778 | if v:IsA("Model") and v:findFirstChild("Torso") and v ~= char and v.Torso.Position - Position.magnitude <= Distance then | |
779 | table.insert(List, v) | |
780 | end | |
781 | end | |
782 | do return List end | |
783 | -- DECOMPILER ERROR: 3 unprocessed JMP targets | |
784 | end | |
785 | end | |
786 | end | |
787 | ||
788 | Slam = function() | |
789 | ||
790 | local part = Instance.new("Part", mod4) | |
791 | part.Anchored = true | |
792 | part.CanCollide = false | |
793 | part.FormFactor = "Custom" | |
794 | part.Size = Vector3.new(0.2, 0.2, 0.2) | |
795 | part.CFrame = root.CFrame * CFrame.new(0, -2.8, -1.4) * CFrame.Angles(math.rad(90), 0, 0) | |
796 | part.Transparency = 0.7 | |
797 | part.BrickColor = BrickColor.new("Really black") | |
798 | mesh = Instance.new("SpecialMesh", part) | |
799 | mesh.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
800 | mesh.Scale = Vector3.new(3, 3, 3) | |
801 | local part2 = Instance.new("Part", mod4) | |
802 | part2.Anchored = true | |
803 | part2.CanCollide = false | |
804 | part2.FormFactor = "Custom" | |
805 | part2.Size = Vector3.new(0.2, 0.2, 0.2) | |
806 | part2.CFrame = root.CFrame * CFrame.new(0, -2.4, -1.6) | |
807 | part2.Transparency = 0.7 | |
808 | part2.BrickColor = BrickColor.new("Lime green") | |
809 | mesh2 = Instance.new("SpecialMesh", part2) | |
810 | mesh2.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
811 | mesh2.Scale = Vector3.new(3, 1.5, 3) | |
812 | x = Instance.new("Sound", larm) | |
813 | x.SoundId = "http://www.roblox.com/asset/?id=142070127" | |
814 | x.Pitch = ptez[math.random(1, #ptez)] | |
815 | x.Volume = 1 | |
816 | x1 = Instance.new("Sound", larm) | |
817 | x1.SoundId = "http://www.roblox.com/asset/?id=206082327" | |
818 | x1.Pitch = ptez[math.random(1, #ptez)] | |
819 | x1.Volume = 1 | |
820 | x:Play() | |
821 | x1:Play() | |
822 | for i,v in pairs(FindNearestTorso(torso.CFrame.p, 4)) do | |
823 | if v:FindFirstChild("Humanoid") then | |
824 | v.Humanoid.Health = 0 | |
825 | end | |
826 | end | |
827 | coroutine.resume(coroutine.create(function() | |
828 | ||
829 | for i = 0, 0.62, 0.13 do | |
830 | fat.Event:wait() | |
831 | part.CFrame = part.CFrame | |
832 | part.Transparency = i | |
833 | mesh.Scale = mesh.Scale + Vector3.new(0.4, 0.4, 0.4) | |
834 | part2.CFrame = part2.CFrame | |
835 | part2.Transparency = i | |
836 | mesh2.Scale = mesh2.Scale + Vector3.new(0.4, 0.2, 0.4) | |
837 | end | |
838 | part.Parent = nil | |
839 | part2.Parent = nil | |
840 | x:Destroy() | |
841 | end | |
842 | )) | |
843 | end | |
844 | ||
845 | wPart = function(x, y, z, color, tr, cc, an, parent) | |
846 | ||
847 | local wp = Instance.new("WedgePart", parent or Weapon) | |
848 | wp.formFactor = "Custom" | |
849 | wp.Size = Vector3.new(x, y, z) | |
850 | wp.BrickColor = BrickColor.new(color) | |
851 | wp.CanCollide = cc | |
852 | wp.Transparency = tr | |
853 | wp.Anchored = an | |
854 | wp.TopSurface = 0 | |
855 | return wp | |
856 | end | |
857 | ||
858 | Mesh = function(par, num, x, y, z) | |
859 | ||
860 | local msh = _ | |
861 | if num == 1 then | |
862 | msh = Instance.new("CylinderMesh", par) | |
863 | else | |
864 | if num == 2 then | |
865 | msh = Instance.new("SpecialMesh", par) | |
866 | msh.MeshType = 3 | |
867 | else | |
868 | if num == 3 then | |
869 | msh = Instance.new("BlockMesh", par) | |
870 | else | |
871 | if num == 4 then | |
872 | msh = Instance.new("SpecialMesh", par) | |
873 | msh.MeshType = "Torso" | |
874 | else | |
875 | if type(num) == "string" then | |
876 | msh = Instance.new("SpecialMesh", par) | |
877 | msh.MeshId = num | |
878 | end | |
879 | end | |
880 | end | |
881 | end | |
882 | end | |
883 | msh.Scale = Vector3.new(x, y, z) | |
884 | return msh | |
885 | end | |
886 | ||
887 | local CFrameFromTopBack = function(at, top, back) | |
888 | ||
889 | local right = top:Cross(back) | |
890 | return CFrame.new(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z) | |
891 | end | |
892 | ||
893 | Triangle = function(a, b, c) | |
894 | ||
895 | local edg1 = c - a:Dot(b - a.unit) | |
896 | local edg2 = a - b:Dot(c - b.unit) | |
897 | local edg3 = b - c:Dot(a - c.unit) | |
898 | if edg1 <= b - a.magnitude and edg1 >= 0 then | |
899 | a = a | |
900 | else | |
901 | -- DECOMPILER ERROR at PC35: Overwrote pending register: R1 in 'AssignReg' | |
902 | ||
903 | if edg2 <= c - b.magnitude and edg2 >= 0 then | |
904 | a = b | |
905 | else | |
906 | -- DECOMPILER ERROR at PC46: Overwrote pending register: R2 in 'AssignReg' | |
907 | ||
908 | -- DECOMPILER ERROR at PC47: Overwrote pending register: R1 in 'AssignReg' | |
909 | ||
910 | if edg3 <= a - c.magnitude and edg3 >= 0 then | |
911 | a = c | |
912 | else | |
913 | print("unreachable") | |
914 | end | |
915 | end | |
916 | end | |
917 | local len1 = c - a:Dot(b - a.unit) | |
918 | local len2 = b - a.magnitude - len1 | |
919 | local width = a + b - a.unit * len1 - c.magnitude | |
920 | local maincf = CFrameFromTopBack(a, b - a:Cross(c - b).unit, -b - a.unit) | |
921 | local list = {} | |
922 | if len1 > 0.01 then | |
923 | local w1 = wPart(0, 0, 0, "Lime green", 0.5, false, true, char) | |
924 | do | |
925 | local sz = Vector3.new(0.2, width, len1) | |
926 | w1.Size = sz | |
927 | local sp = Mesh(w1, 2, 0, 0, 0) | |
928 | sp.MeshType = "Wedge" | |
929 | sp.Scale = Vector3.new(0, 1, 1) * sz / w1.Size | |
930 | w1:BreakJoints() | |
931 | w1.Anchored = true | |
932 | w1.Transparency = 0.7 | |
933 | Spawn(function() | |
934 | ||
935 | for i = 0, 1, 0.1 do | |
936 | fat.Event:wait() | |
937 | w1.Transparency = w1.Transparency + 0.03 | |
938 | end | |
939 | end | |
940 | ) | |
941 | w1.CFrame = maincf * CFrame.Angles(math.pi, 0, math.pi / 2) * CFrame.new(0, width / 2, len1 / 2) | |
942 | table.insert(list, w1) | |
943 | end | |
944 | end | |
945 | do | |
946 | if len2 > 0.01 then | |
947 | local w2 = wPart(0, 0, 0, "Lime green", 0.5, false, true, char) | |
948 | local sz = Vector3.new(0.2, width, len2) | |
949 | w2.Size = sz | |
950 | local sp = Mesh(w2, 2, 0, 0, 0) | |
951 | sp.MeshType = "Wedge" | |
952 | sp.Scale = Vector3.new(0, 1, 1) * sz / w2.Size | |
953 | w2:BreakJoints() | |
954 | w2.Anchored = true | |
955 | w2.Transparency = 0.7 | |
956 | Spawn(function() | |
957 | ||
958 | for i = 0, 1, 0.1 do | |
959 | fat.Event:wait() | |
960 | w2.Transparency = w2.Transparency + 0.03 | |
961 | end | |
962 | end | |
963 | ) | |
964 | w2.CFrame = maincf * CFrame.Angles(math.pi, math.pi, -math.pi / 2) * CFrame.new(0, width / 2, -len1 - len2 / 2) | |
965 | table.insert(list, w2) | |
966 | end | |
967 | do | |
968 | return unpack(list) | |
969 | end | |
970 | end | |
971 | end | |
972 | ||
973 | trail = function(p, t, h) | |
974 | ||
975 | Spawn(function() | |
976 | ||
977 | local blcf = p.CFrame | |
978 | local scfr = blcf | |
979 | for i = 1, t do | |
980 | local blcf = p.CFrame | |
981 | if scfr and p.Position - scfr.p.magnitude > 0.1 then | |
982 | local a, b = Triangle(scfr * CFrame.new(0, h / 2, 0).p, scfr * CFrame.new(0, -h / 2, 0).p, blcf * CFrame.new(0, h / 2, 0).p) | |
983 | if a then | |
984 | game.Debris:AddItem(a, 1) | |
985 | end | |
986 | if b then | |
987 | game.Debris:AddItem(b, 1) | |
988 | end | |
989 | local a, b = Triangle(blcf * CFrame.new(0, h / 2, 0).p, blcf * CFrame.new(0, -h / 2, 0).p, scfr * CFrame.new(0, -h / 2, 0).p) | |
990 | if a then | |
991 | game.Debris:AddItem(a, 1) | |
992 | end | |
993 | if b then | |
994 | game.Debris:AddItem(b, 1) | |
995 | end | |
996 | scfr = blcf | |
997 | else | |
998 | do | |
999 | do | |
1000 | if not scfr then | |
1001 | scfr = blcf | |
1002 | end | |
1003 | fat.Event:wait() | |
1004 | -- DECOMPILER ERROR at PC120: LeaveBlock: unexpected jumping out DO_STMT | |
1005 | ||
1006 | -- DECOMPILER ERROR at PC120: LeaveBlock: unexpected jumping out IF_ELSE_STMT | |
1007 | ||
1008 | -- DECOMPILER ERROR at PC120: LeaveBlock: unexpected jumping out IF_STMT | |
1009 | ||
1010 | end | |
1011 | end | |
1012 | end | |
1013 | end | |
1014 | scfr = nil | |
1015 | end | |
1016 | ) | |
1017 | end | |
1018 | ||
1019 | rarm.Touched:connect(function(ht) | |
1020 | ||
1021 | hit = ht.Parent | |
1022 | if ht and hit:IsA("Model") and hit:FindFirstChild("Humanoid") and hit.Name ~= p.Name and Debounces.RPunch == true and Debounces.RPunched == false then | |
1023 | Debounces.RPunched = true | |
1024 | hit:FindFirstChild("Humanoid"):TakeDamage(math.random(5, 8)) | |
1025 | if Debounces.ks == true then | |
1026 | z = Instance.new("Sound", hed) | |
1027 | z.SoundId = "rbxassetid://169380525" | |
1028 | z.Pitch = ptz[math.random(1, #ptz)] | |
1029 | z.Volume = 1 | |
1030 | z:Play() | |
1031 | end | |
1032 | wait(0.4) | |
1033 | Debounces.RPunched = false | |
1034 | end | |
1035 | if ht and hit:IsA("Hat") and hit.Parent.Name ~= p.Name and hit.Parent:FindFirstChild("Humanoid") and Debounces.RPunch == true and Debounces.RPunched == false then | |
1036 | Debounces.RPunched = true | |
1037 | hit.Parent:FindFirstChild("Humanoid"):TakeDamage(math.random(5, 8)) | |
1038 | if Debounces.ks == true then | |
1039 | z = Instance.new("Sound", hed) | |
1040 | z.SoundId = "rbxassetid://169380525" | |
1041 | z.Pitch = ptz[math.random(1, #ptz)] | |
1042 | z.Volume = 1 | |
1043 | z:Play() | |
1044 | end | |
1045 | wait(0.4) | |
1046 | Debounces.RPunched = false | |
1047 | end | |
1048 | end | |
1049 | ) | |
1050 | larm.Touched:connect(function(ht) | |
1051 | ||
1052 | hit = ht.Parent | |
1053 | if ht and hit:IsA("Model") and hit:FindFirstChild("Humanoid") and hit.Name ~= p.Name and Debounces.LPunch == true and Debounces.LPunched == false then | |
1054 | Debounces.LPunched = true | |
1055 | hit:FindFirstChild("Humanoid").Health = 0 | |
1056 | hit:FindFirstChild("Torso").Velocity = hit:FindFirstChild("Torso").CFrame.lookVector * -160 | |
1057 | if Debounces.ks2 == true then | |
1058 | z = Instance.new("Sound", hed) | |
1059 | z.SoundId = "rbxassetid://169380525" | |
1060 | z.Pitch = ptz[math.random(1, #ptz)] | |
1061 | z.Volume = 1 | |
1062 | z:Play() | |
1063 | end | |
1064 | wait(0.4) | |
1065 | Debounces.LPunched = false | |
1066 | end | |
1067 | if ht and hit:IsA("Hat") and hit.Parent.Name ~= p.Name and hit.Parent:FindFirstChild("Humanoid") and Debounces.LPunch == true and Debounces.LPunched == false then | |
1068 | Debounces.LPunched = true | |
1069 | hit.Parent:FindFirstChild("Humanoid").Health = 0 | |
1070 | if Debounces.ks2 == true then | |
1071 | z = Instance.new("Sound", hed) | |
1072 | z.SoundId = "rbxassetid://169380525" | |
1073 | z.Pitch = ptz[math.random(1, #ptz)] | |
1074 | z.Volume = 1 | |
1075 | z:Play() | |
1076 | end | |
1077 | wait(0.4) | |
1078 | Debounces.LPunched = false | |
1079 | end | |
1080 | end | |
1081 | ) | |
1082 | local acos = math.acos | |
1083 | local sqrt = math.sqrt | |
1084 | local Vec3 = Vector3.new | |
1085 | local fromAxisAngle = CFrame.fromAxisAngle | |
1086 | local toAxisAngle = function(CFr) | |
1087 | ||
1088 | local X, Y, Z, R00, R01, R02, R10, R11, R12, R20, R21, R22 = CFr:components() | |
1089 | local Angle = math.acos((R00 + R11 + R22 - 1) / 2) | |
1090 | local A = R21 - R12 ^ 2 + R02 - R20 ^ 2 + R10 - R01 ^ 2 | |
1091 | if A ~= 0 or not 1e-05 then | |
1092 | local B = R21 - R12 ^ 2 + R02 - R20 ^ 2 + R10 - R01 ^ 2 | |
1093 | if B ~= 0 or not 1e-05 then | |
1094 | local C = R21 - R12 ^ 2 + R02 - R20 ^ 2 + R10 - R01 ^ 2 | |
1095 | if C ~= 0 or not 1e-05 then | |
1096 | local x = (R21 - R12) / sqrt(A) | |
1097 | local y = (R02 - R20) / sqrt(B) | |
1098 | local z = (R10 - R01) / sqrt(C) | |
1099 | return Vec3(x, y, z), Angle | |
1100 | end | |
1101 | end | |
1102 | end | |
1103 | end | |
1104 | ||
1105 | ApplyTrig = function(Num, Func) | |
1106 | ||
1107 | local Min, Max = Func(0), Func(1) | |
1108 | local i = Func(Num) | |
1109 | return (i - Min) / (Max - Min) | |
1110 | end | |
1111 | ||
1112 | LerpCFrame = function(CFrame1, CFrame2, Num) | |
1113 | ||
1114 | local Vec, Ang = toAxisAngle(CFrame1:inverse() * CFrame2) | |
1115 | return CFrame1 * fromAxisAngle(Vec, Ang * Num) + (CFrame2.p - CFrame1.p) * Num | |
1116 | end | |
1117 | ||
1118 | Crater = function(Torso, Radius) | |
1119 | ||
1120 | Spawn(function() | |
1121 | ||
1122 | local Ray = Ray.new(Torso.Position, Vector3.new(0, -1, 0) * 10) | |
1123 | local Ignore = {} | |
1124 | for i,v in pairs(game:GetService("Players"):GetPlayers()) do | |
1125 | if v.Character ~= nil then | |
1126 | Ignore[#Ignore + 1] = v.Character | |
1127 | end | |
1128 | end | |
1129 | local Hit, Pos, SurfaceNorm = Workspace:FindPartOnRayWithIgnoreList(Ray, Ignore) | |
1130 | if Hit == nil then | |
1131 | return | |
1132 | end | |
1133 | local Parts = {} | |
1134 | for i = 1, 360, 10 do | |
1135 | local P = Instance.new("Part", Torso.Parent) | |
1136 | P.Anchored = true | |
1137 | P.FormFactor = "Custom" | |
1138 | P.BrickColor = Hit.BrickColor | |
1139 | P.Material = Hit.Material | |
1140 | P.TopSurface = "Smooth" | |
1141 | P.BottomSurface = "Smooth" | |
1142 | P.Size = Vector3.new(5, 10, 10) * (math.random(80, 100) / 100) | |
1143 | P.CFrame = (CFrame.new(Pos, Pos + SurfaceNorm) * CFrame.Angles(math.rad(90), 0, 0) - Vector3.new(0, 7, 0)) * CFrame.Angles(math.rad(math.random(-50, 50)), math.rad(math.random(-50, 50)), math.rad(math.random(-50, 50))) | |
1144 | Parts[#Parts + 1] = {P, P.CFrame, (CFrame.new(Pos, Pos + SurfaceNorm) * CFrame.Angles(math.rad(90), 0, 0) - Vector3.new(0, 1, 0)) * CFrame.Angles(0, math.rad(i), 0) * CFrame.new(0, 0, -Radius) * CFrame.Angles(math.rad(math.random(-50, -20)), math.rad(math.random(-15, 15)), math.rad(math.random(-15, 15))), P.Size} | |
1145 | if math.random(0, 5) == 0 then | |
1146 | local P = Instance.new("Part", Torso.Parent) | |
1147 | P.Anchored = true | |
1148 | P.FormFactor = "Custom" | |
1149 | P.BrickColor = Hit.BrickColor | |
1150 | P.Material = Hit.Material | |
1151 | P.TopSurface = "Smooth" | |
1152 | P.BottomSurface = "Smooth" | |
1153 | P.Size = Vector3.new(2, 2, 2) * (math.random(80, 100) / 100) | |
1154 | P.CFrame = (CFrame.new(Pos, Pos + SurfaceNorm) * CFrame.Angles(math.rad(90), 0, 0) - Vector3.new(0, 2.5, 0)) * CFrame.Angles(math.rad(math.random(-50, 50)), math.rad(math.random(-50, 50)), math.rad(math.random(-50, 50))) | |
1155 | Parts[#Parts + 1] = {P, P.CFrame, CFrame.new(Pos, Pos + SurfaceNorm) * CFrame.Angles(math.rad(90), 0, 0) * CFrame.Angles(0, math.rad(i), 0) * CFrame.new(0, 0, -Radius - 8) * CFrame.Angles(math.rad(math.random(-90, 90)), math.rad(math.random(-90, 90)), math.rad(math.random(-90, 90))), P.Size} | |
1156 | end | |
1157 | end | |
1158 | for i = 0, 1, 0.05 do | |
1159 | for i2,v in pairs(Parts) do | |
1160 | v[1].CFrame = LerpCFrame(v[2], v[3], ApplyTrig(i, math.cos)) | |
1161 | end | |
1162 | wait(0.02) | |
1163 | end | |
1164 | for i,v in pairs(Parts) do | |
1165 | if v[1].Size.X > 2.1 then | |
1166 | v[1].CFrame = v[1].CFrame + Vector3.new(0, 2, 0) | |
1167 | end | |
1168 | v[1].Anchored = false | |
1169 | end | |
1170 | for i = 0, 1, 0.05 do | |
1171 | for i2,v in pairs(Parts) do | |
1172 | v[1].Transparency = i | |
1173 | if i == 1 then | |
1174 | v[1]:Destroy() | |
1175 | else | |
1176 | if i >= 0.25 then | |
1177 | v[1].CanCollide = false | |
1178 | end | |
1179 | end | |
1180 | end | |
1181 | wait(0.02) | |
1182 | end | |
1183 | Parts = nil | |
1184 | end | |
1185 | ) | |
1186 | end | |
1187 | ||
1188 | function Dmg() | |
1189 | local partofdeath = hitb | |
1190 | local function CreateRegion3FromLocAndSize(Position, Size) | |
1191 | local SizeOffset = Size/2 | |
1192 | local Point1 = Position - SizeOffset | |
1193 | local Point2 = Position + SizeOffset | |
1194 | return Region3.new(Point1, Point2) | |
1195 | end | |
1196 | local reg = CreateRegion3FromLocAndSize(partofdeath.Position, partofdeath.Size) | |
1197 | for i, v in pairs(game.Workspace:FindPartsInRegion3WithIgnoreList(reg, char:GetChildren(), 100)) do | |
1198 | Spawn(function() | |
1199 | if Debounces.Slashing == true and Debounces.Slashed == false then | |
1200 | Debounces.Slashed = true | |
1201 | ypcall(function() | |
1202 | local humanoid = v.Parent:FindFirstChild("Humanoid") or v.Parent.Parent:FindFirstChild("Humanoid") | |
1203 | GroundWave(v.Parent.Torso.CFrame) | |
1204 | humanoid.Health = humanoid.Health - 928373 | |
1205 | local ex = Instance.new('Explosion',workspace) | |
1206 | ex.Position = v.Parent.Torso.Position | |
1207 | ex.BlastRadius = 0 | |
1208 | end) | |
1209 | wait(.4) | |
1210 | Debounces.Slashed = false | |
1211 | end | |
1212 | end) | |
1213 | end | |
1214 | end | |
1215 | ||
1216 | pts = {0.8, 0.85, 0.9, 0.95, 1, 1.05, 1.1} | |
1217 | ptz = {0.7, 0.8, 0.9, 1, 1.1} | |
1218 | part1.Transparency = 0 | |
1219 | attackone = function() | |
1220 | ||
1221 | for i = 1, 10 do | |
1222 | corw.C0 = Lerp(corw.C0, CFrame.new(-0.5, -1.5, -0.5) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(150)), 0.4) | |
1223 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, -0.5) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(-24)), 0.4) | |
1224 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.3, 0.5, -0.4) * CFrame.Angles(math.rad(120), math.rad(0), math.rad(10)), 0.5) | |
1225 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(80), math.rad(0)), 0.5) | |
1226 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(-24), math.rad(0), math.rad(-20)), 0.3) | |
1227 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(20), math.rad(0)), 0.3) | |
1228 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(0), math.rad(-30), 0), 0.7) | |
1229 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.7) | |
1230 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.7) | |
1231 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(-30), math.rad(0)), 0.7) | |
1232 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0.2) * CFrame.Angles(math.rad(-11), math.rad(0), math.rad(-14)), 0.5) | |
1233 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1234 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.7, -1, -0.3) * CFrame.Angles(math.rad(20), math.rad(-30), math.rad(16)), 0.5) | |
1235 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1236 | if Debounces.on == false then | |
1237 | break | |
1238 | end | |
1239 | fat.Event:wait() | |
1240 | end | |
1241 | end | |
1242 | ||
1243 | attacktwo = function() | |
1244 | ||
1245 | Debounces.Slashing = true | |
1246 | z = Instance.new("Sound", hed) | |
1247 | z.SoundId = "rbxassetid://227194094" | |
1248 | z.Pitch = ptz[math.random(1, #ptz)] | |
1249 | z.Volume = 0.4 | |
1250 | wait(0.01) | |
1251 | z:Play() | |
1252 | for i = 1, 14 do | |
1253 | Dmg() | |
1254 | corw.C0 = Lerp(corw.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)), 0.4) | |
1255 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(28)), 0.4) | |
1256 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.5, 0.4) * CFrame.Angles(math.rad(70), math.rad(0), math.rad(100)), 0.4) | |
1257 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(-90), math.rad(0)), 0.4) | |
1258 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(36), math.rad(0), math.rad(-20)), 0.3) | |
1259 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(20), math.rad(0)), 0.3) | |
1260 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.36) | |
1261 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(10), math.rad(-40), math.rad(0)), 0.36) | |
1262 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, -1) * CFrame.Angles(math.rad(0), math.rad(-40), 0), 0.4) | |
1263 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
1264 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.72, -1, -0.3) * CFrame.Angles(math.rad(14), math.rad(50), math.rad(-15)), 0.5) | |
1265 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1266 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0.2) * CFrame.Angles(math.rad(-12), math.rad(-30), math.rad(16)), 0.5) | |
1267 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1268 | if Debounces.on == false then | |
1269 | break | |
1270 | end | |
1271 | fat.Event:wait() | |
1272 | end | |
1273 | do | |
1274 | Debounces.Slashing = false | |
1275 | end | |
1276 | end | |
1277 | ||
1278 | attackthree = function() | |
1279 | ||
1280 | for i = 1, 10 do | |
1281 | corw.C0 = Lerp(corw.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)), 0.4) | |
1282 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(-24)), 0.4) | |
1283 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.5, 0.4) * CFrame.Angles(math.rad(70), math.rad(0), math.rad(100)), 0.4) | |
1284 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)), 0.4) | |
1285 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(48), math.rad(0), math.rad(-20)), 0.4) | |
1286 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(20), math.rad(0)), 0.4) | |
1287 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.5) | |
1288 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(-10), math.rad(-50), math.rad(0)), 0.5) | |
1289 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, -1.3) * CFrame.Angles(math.rad(0), math.rad(-50), 0), 0.5) | |
1290 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1291 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.72, -1, -0.4) * CFrame.Angles(math.rad(-10), math.rad(50), math.rad(-10)), 0.5) | |
1292 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1293 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.6, -1, 0) * CFrame.Angles(math.rad(-12), math.rad(-30), math.rad(16)), 0.5) | |
1294 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1295 | if Debounces.on == false then | |
1296 | break | |
1297 | end | |
1298 | fat.Event:wait() | |
1299 | end | |
1300 | end | |
1301 | ||
1302 | mouse.KeyDown:connect(function(key) | |
1303 | if key == "e" then | |
1304 | if Debounces.CanAttack == true then | |
1305 | Debounces.CanAttack = false | |
1306 | Debounces.on = true | |
1307 | Debounces.NoIdl = true | |
1308 | for i = 1, 50 do | |
1309 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.55,0)*CFrame.Angles(math.rad(160),math.rad(-6),math.rad(30)), 0.4) | |
1310 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.55,0)*CFrame.Angles(math.rad(10),math.rad(30),math.rad(-15)), 0.2) | |
1311 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(0),math.rad(30),0), 0.2) | |
1312 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-10), math.rad(0)), 0.3) | |
1313 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(20), 0, math.rad(-14)), 0.2) | |
1314 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(-16), 0, math.rad(8)), 0.2) | |
1315 | if Debounces.on == false then break end | |
1316 | rs:wait(2.6) | |
1317 | end | |
1318 | Spawn(function() | |
1319 | local Parts = {} | |
1320 | for Y = -5,5 do | |
1321 | local P = Instance.new("Part",char) | |
1322 | P.Anchored = true | |
1323 | P.FormFactor = "Custom" | |
1324 | P.CanCollide = false | |
1325 | P.Size = Vector3.new(2,4,2) | |
1326 | P.TopSurface = "SmoothNoOutlines" | |
1327 | P.BottomSurface = "SmoothNoOutlines" | |
1328 | P.Material = "Neon" | |
1329 | P.BrickColor = BrickColor.new("Really black") | |
1330 | P.Name = tostring(Y) | |
1331 | local i = (Y+5)/(100) | |
1332 | i = 1-math.cos(math.pi*i-(math.pi/2)) | |
1333 | P.CFrame = char.HumanoidRootPart.CFrame*CFrame.new(0,Y,-2+(i*1.5))*CFrame.Angles(math.rad(Y*5),0,0) | |
1334 | --[[P.Touched:connect(function(ht) | |
1335 | local hit = ht.Parent | |
1336 | if hit:FindFirstChild("Humanoid") then | |
1337 | hit.Humanoid:TakeDamage(math.random(20,50)) | |
1338 | end | |
1339 | end)]]-- | |
1340 | s = Instance.new("Sound",P) | |
1341 | s.SoundId = "rbxassetid://228343271" | |
1342 | s.Volume = 1 | |
1343 | s.Pitch = 0.9 | |
1344 | s:Play() | |
1345 | sa = Instance.new("Sound",P) | |
1346 | sa.SoundId = "rbxassetid://419447292" | |
1347 | sa.Volume = 1 | |
1348 | sa.Pitch = 1 | |
1349 | sa:Play() | |
1350 | P.Touched:connect(function(ht) | |
1351 | hit = ht.Parent | |
1352 | if ht and hit:IsA("Model") then | |
1353 | if hit:FindFirstChild("Humanoid") then | |
1354 | if hit.Name ~= p.Name then | |
1355 | --[[if Debounces.Slashing == true and Debounces.Slashed == false then | |
1356 | Debounces.Slashed = true]]-- | |
1357 | hit:FindFirstChild("Humanoid").Health = 0 | |
1358 | hit:FindFirstChild("Humanoid").PlatformStand = true | |
1359 | wait(1) | |
1360 | --Debounces.Slashed = false | |
1361 | --end | |
1362 | end | |
1363 | end | |
1364 | elseif ht and hit:IsA("Hat") then | |
1365 | if hit.Parent.Name ~= p.Name then | |
1366 | if hit.Parent:FindFirstChild("Humanoid") then | |
1367 | --[[if Debounces.Slashing == true and Debounces.Slashed == false then | |
1368 | Debounces.Slashed = true]]-- | |
1369 | hit.Parent:FindFirstChild("Humanoid").Health = 0 | |
1370 | hit:FindFirstChild("Humanoid").PlatformStand = true | |
1371 | wait(1) | |
1372 | --Debounces.Slashed = false | |
1373 | --end | |
1374 | end | |
1375 | end | |
1376 | end | |
1377 | end) | |
1378 | Parts[#Parts+1] = P | |
1379 | end | |
1380 | local BREAKIT = false | |
1381 | local CParts = {} | |
1382 | local Rocks = {} | |
1383 | local LastPos = nil | |
1384 | for i = 1,70 do | |
1385 | for i2,v in pairs(Parts) do | |
1386 | v.CFrame = v.CFrame*CFrame.new(0,0,-4) | |
1387 | local cf = v.CFrame | |
1388 | v.Size = v.Size+Vector3.new(0.4,0.35,0) | |
1389 | v.CFrame = cf | |
1390 | v.Transparency = v.Transparency+0.02 | |
1391 | if v.Transparency >= 0.975 then BREAKIT = true end | |
1392 | if v.Name == "0" then | |
1393 | local Ignore = {} | |
1394 | for i,v in pairs(game:GetService("Players"):GetPlayers()) do | |
1395 | if v.Character ~= nil then | |
1396 | Ignore[#Ignore+1] = v.Character | |
1397 | end | |
1398 | end | |
1399 | local ray = Ray.new(v.Position+Vector3.new(0,20,0),Vector3.new(0,-200,0)) | |
1400 | local Hit,Pos,SurfaceNorm = Workspace:FindPartOnRayWithIgnoreList(ray,Ignore) | |
1401 | if Hit ~= nil then | |
1402 | if #Rocks == 0 then | |
1403 | for i = 1,5 do | |
1404 | local P = Instance.new("Part",char) | |
1405 | Rocks[#Rocks+1] = P | |
1406 | P.Anchored = true | |
1407 | P.FormFactor = "Custom" | |
1408 | P.BrickColor = Hit.BrickColor | |
1409 | P.Material = Hit.Material | |
1410 | P.TopSurface = "Smooth" | |
1411 | P.BottomSurface = "Smooth" | |
1412 | P.Size = Vector3.new(2,2,2)*(math.random(500,900)/100) | |
1413 | end | |
1414 | end | |
1415 | for i,P in pairs(Rocks) do | |
1416 | P.CFrame = ((CFrame.new(Pos)*(v.CFrame-v.Position))*CFrame.new(math.random(-math.ceil(v.Size.X/2),math.ceil(v.Size.X/2)),0,-math.random(5,8))-Vector3.new(0,0.25,0))*CFrame.Angles(math.rad(math.random(-50,50)),math.rad(math.random(-50,50)),math.rad(math.random(20,50))) | |
1417 | end | |
1418 | local P = Instance.new("Part",char) | |
1419 | CParts[#CParts+1] = {P,tick()} | |
1420 | P.Anchored = true | |
1421 | P.FormFactor = "Custom" | |
1422 | P.BrickColor = Hit.BrickColor | |
1423 | P.Material = Hit.Material | |
1424 | P.TopSurface = "Smooth" | |
1425 | P.BottomSurface = "Smooth" | |
1426 | P.Size = Vector3.new(2,2,2)*(math.random(100,300)/100) | |
1427 | Pos = CFrame.new(Pos)*(v.CFrame-v.Position)*CFrame.new(v.Size.X/2,0,0) | |
1428 | Pos = Pos.p | |
1429 | P.CFrame = ((CFrame.new(Pos,Pos+SurfaceNorm)*CFrame.Angles(math.rad(90),0,0))-Vector3.new(0,0.25,0))*CFrame.Angles(math.rad(math.random(-50,50)),math.rad(math.random(-50,50)),math.rad(math.random(20,50))) | |
1430 | local P = P:Clone() | |
1431 | CParts[#CParts+1] = {P,tick()} | |
1432 | P.Parent = char | |
1433 | Pos = CFrame.new(Pos)*(v.CFrame-v.Position)*CFrame.new(-v.Size.X,0,0) | |
1434 | Pos = Pos.p | |
1435 | P.CFrame = ((CFrame.new(Pos,Pos+SurfaceNorm)*CFrame.Angles(math.rad(90),0,0))-Vector3.new(0,0.25,0))*CFrame.Angles(math.rad(math.random(-50,50)),math.rad(math.random(-50,50)),math.rad(math.random(-50,-20))) | |
1436 | if LastPos ~= nil then | |
1437 | local P = P:Clone() | |
1438 | CParts[#CParts+1] = {P,tick()} | |
1439 | P.Parent = char | |
1440 | P.BrickColor = BrickColor.new("Royal purple") | |
1441 | P.Material = "Neon" | |
1442 | Pos = CFrame.new(Pos)*(v.CFrame-v.Position)*CFrame.new(v.Size.X/2,0,0) | |
1443 | Pos = Pos.p | |
1444 | local CFr = (CFrame.new(Pos)*(v.CFrame-v.Position))-Vector3.new(0,0.4,0) | |
1445 | P.Size = Vector3.new(v.Size.X-0.25,1,(CFr.p-LastPos.p).Magnitude+0.25) | |
1446 | --P.Velocity = Vector3.new(0,-1000,0) | |
1447 | P.CFrame = CFrame.new(CFr.p,LastPos.p)*CFrame.new(0,0,-((CFr.p-LastPos.p).Magnitude+0.25)/2) | |
1448 | end | |
1449 | LastPos = (CFrame.new(Pos)*(v.CFrame-v.Position))-Vector3.new(0,0.4,0) | |
1450 | end | |
1451 | end | |
1452 | end | |
1453 | if BREAKIT then break end | |
1454 | wait(0.002) | |
1455 | end | |
1456 | for i,v in pairs(Rocks) do | |
1457 | CParts[#CParts+1] = {v,tick()} | |
1458 | end | |
1459 | for i,v in pairs(Parts) do | |
1460 | v:Destroy() | |
1461 | end | |
1462 | Parts = nil | |
1463 | while true do | |
1464 | local t = tick() | |
1465 | local p = nil | |
1466 | for i,v in pairs(CParts) do | |
1467 | if t-v[2] > 4 then | |
1468 | v[1].Transparency = v[1].Transparency+0.05 | |
1469 | if v[1].Transparency >= 1 then | |
1470 | v[1]:Destroy() | |
1471 | CParts[i] = nil | |
1472 | end | |
1473 | end | |
1474 | p = v | |
1475 | end | |
1476 | if p == nil then break end | |
1477 | wait(0.002) | |
1478 | end | |
1479 | for i,v in pairs(CParts) do | |
1480 | v:Destroy() | |
1481 | end | |
1482 | CParts = {} | |
1483 | end) | |
1484 | for i = 1, 20 do | |
1485 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.55,0)*CFrame.Angles(math.rad(-40),math.rad(0),math.rad(30)), 0.2) | |
1486 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.55,0)*CFrame.Angles(math.rad(10),math.rad(0),math.rad(20)), 0.2) | |
1487 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(0),math.rad(0),0), 0.2) | |
1488 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(-10), math.rad(0)), 0.4) | |
1489 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(10), 0, math.rad(-8)), 0.2) | |
1490 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(-6), 0, math.rad(8)), 0.2) | |
1491 | if Debounces.on == false then break end | |
1492 | rs:wait(2) | |
1493 | end | |
1494 | if Debounces.CanAttack == false then | |
1495 | Debounces.CanAttack = true | |
1496 | Debounces.on = false | |
1497 | Debounces.NoIdl = false | |
1498 | end | |
1499 | end | |
1500 | end | |
1501 | end) | |
1502 | ||
1503 | attackfour = function() | |
1504 | ||
1505 | Debounces.Slashing = true | |
1506 | z = Instance.new("Sound", hed) | |
1507 | z.SoundId = "rbxassetid://227194094" | |
1508 | z.Pitch = ptz[math.random(1, #ptz)] | |
1509 | z.Volume = 0.4 | |
1510 | wait(0.01) | |
1511 | z:Play() | |
1512 | for i = 1, 14 do | |
1513 | Dmg() | |
1514 | corw.C0 = Lerp(corw.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)), 0.4) | |
1515 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(28)), 0.4) | |
1516 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.2, 0.5, -0.4) * CFrame.Angles(math.rad(70), math.rad(0), math.rad(-60)), 0.4) | |
1517 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(60), math.rad(0)), 0.4) | |
1518 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(-20), math.rad(10), math.rad(-10)), 0.3) | |
1519 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(20), math.rad(0)), 0.3) | |
1520 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.36) | |
1521 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(10), math.rad(50), math.rad(0)), 0.36) | |
1522 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, -1.6) * CFrame.Angles(math.rad(0), math.rad(50), 0), 0.36) | |
1523 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.36) | |
1524 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.6, -1, 0.2) * CFrame.Angles(math.rad(-10), math.rad(-20), math.rad(-16)), 0.5) | |
1525 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1526 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.72, -1, -0.4) * CFrame.Angles(math.rad(14), math.rad(-50), math.rad(14)), 0.5) | |
1527 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1528 | if Debounces.on == false then | |
1529 | break | |
1530 | end | |
1531 | fat.Event:wait() | |
1532 | end | |
1533 | do | |
1534 | Debounces.Slashing = false | |
1535 | end | |
1536 | end | |
1537 | ||
1538 | attackfive = function() | |
1539 | ||
1540 | z = Instance.new("Sound", hed) | |
1541 | z.SoundId = "rbxassetid://" | |
1542 | z.Pitch = 1 | |
1543 | z.Volume = 0.8 | |
1544 | wait(0.01) | |
1545 | z:Play() | |
1546 | for i = 1, 18 do | |
1547 | corw.C0 = Lerp(corw.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)), 0.5) | |
1548 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, 0) * CFrame.Angles(math.rad(-50), math.rad(0), math.rad(0)), 0.5) | |
1549 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.2, 0.7, 0) * CFrame.Angles(math.rad(140), math.rad(0), math.rad(-40)), 0.4) | |
1550 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1551 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.2, 0.7, 0) * CFrame.Angles(math.rad(140), math.rad(0), math.rad(40)), 0.4) | |
1552 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1553 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.4, 0.15) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.5) | |
1554 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(-20), math.rad(0), math.rad(0)), 0.25) | |
1555 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, 2, -1.6) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.5) | |
1556 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-10), math.rad(0), math.rad(0)), 0.5) | |
1557 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, 0) * CFrame.Angles(math.rad(-15), math.rad(20), math.rad(-15)), 0.5) | |
1558 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1559 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(-15), math.rad(-20), math.rad(15)), 0.5) | |
1560 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1561 | if Debounces.on == false then | |
1562 | break | |
1563 | end | |
1564 | fat.Event:wait() | |
1565 | end | |
1566 | do | |
1567 | z = Instance.new("Sound", hed) | |
1568 | z.SoundId = "rbxassetid://227194094" | |
1569 | z.Pitch = 0.6 | |
1570 | z.Volume = 1 | |
1571 | wait(0.01) | |
1572 | z:Play() | |
1573 | Debounces.Slashing = true | |
1574 | for i = 1, 18 do | |
1575 | Dmg() | |
1576 | corw.C0 = Lerp(corw.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-40)), 0.5) | |
1577 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, 0) * CFrame.Angles(math.rad(-20), math.rad(-50), math.rad(0)), 0.5) | |
1578 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.2, 0.4, -0.4) * CFrame.Angles(math.rad(30), math.rad(0), math.rad(-40)), 0.5) | |
1579 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1580 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.2, 0.4, -0.4) * CFrame.Angles(math.rad(30), math.rad(0), math.rad(40)), 0.5) | |
1581 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1582 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.4, -0.15) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.5) | |
1583 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(20), math.rad(0), math.rad(0)), 0.5) | |
1584 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -2, -2) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.3) | |
1585 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1586 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.6, -0.2, -0.48) * CFrame.Angles(math.rad(10), math.rad(0), math.rad(-10)), 0.3) | |
1587 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.3) | |
1588 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.6, -0.9, 0.2) * CFrame.Angles(math.rad(-70), math.rad(0), math.rad(10)), 0.3) | |
1589 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.3) | |
1590 | if Debounces.on == false then | |
1591 | break | |
1592 | end | |
1593 | fat.Event:wait() | |
1594 | end | |
1595 | do | |
1596 | Debounces.Slashing = false | |
1597 | end | |
1598 | end | |
1599 | end | |
1600 | ||
1601 | ComboNum = 0 | |
1602 | mouse.Button1Down:connect(function() | |
1603 | ||
1604 | if Debounces.CanAttack == true then | |
1605 | Debounces.CanAttack = false | |
1606 | Debounces.NoIdl = true | |
1607 | Debounces.on = true | |
1608 | if ComboNum == 0 then | |
1609 | attackone() | |
1610 | else | |
1611 | if ComboNum == 1 then | |
1612 | attacktwo() | |
1613 | else | |
1614 | if ComboNum == 2 then | |
1615 | attackthree() | |
1616 | else | |
1617 | if ComboNum == 3 then | |
1618 | attackfour() | |
1619 | else | |
1620 | if ComboNum == 4 then | |
1621 | attackfive() | |
1622 | end | |
1623 | end | |
1624 | end | |
1625 | end | |
1626 | end | |
1627 | ComboNum = ComboNum + 1 | |
1628 | Debounces.CanAttack = true | |
1629 | Debounces.on = false | |
1630 | wait(0.2) | |
1631 | if Debounces.CanAttack == true then | |
1632 | ComboNum = 0 | |
1633 | Debounces.NoIdl = false | |
1634 | end | |
1635 | end | |
1636 | end | |
1637 | ) | |
1638 | mouse.KeyDown:connect(function(key) | |
1639 | ||
1640 | if string.byte(key) == 52 then | |
1641 | Swing = 2 | |
1642 | char.Humanoid.WalkSpeed = 28 | |
1643 | end | |
1644 | end | |
1645 | ) | |
1646 | mouse.KeyUp:connect(function(key) | |
1647 | ||
1648 | if string.byte(key) == 52 then | |
1649 | Swing = 1 | |
1650 | char.Humanoid.WalkSpeed = 16 | |
1651 | end | |
1652 | end | |
1653 | ) | |
1654 | jump = false | |
1655 | rs:connect(function() | |
1656 | ||
1657 | if char.Humanoid.Jump == true then | |
1658 | jump = true | |
1659 | else | |
1660 | jump = false | |
1661 | end | |
1662 | char.Humanoid.FreeFalling:connect(function(f) | |
1663 | ||
1664 | if f then | |
1665 | ffing = true | |
1666 | else | |
1667 | ffing = false | |
1668 | end | |
1669 | end | |
1670 | ) | |
1671 | sine = sine + change | |
1672 | if jump == true then | |
1673 | animpose = "Jumping" | |
1674 | else | |
1675 | if ffing == true then | |
1676 | animpose = "Freefalling" | |
1677 | else | |
1678 | if (torso.Velocity * Vector3.new(1, 0, 1)).magnitude < 2 then | |
1679 | animpose = "Idle" | |
1680 | else | |
1681 | if (torso.Velocity * Vector3.new(1, 0, 1)).magnitude < 20 then | |
1682 | animpose = "Walking" | |
1683 | else | |
1684 | if (torso.Velocity * Vector3.new(1, 0, 1)).magnitude > 20 then | |
1685 | animpose = "Running" | |
1686 | end | |
1687 | end | |
1688 | end | |
1689 | end | |
1690 | end | |
1691 | RightLeg = CFrame.new(0.5, -1, 0) | |
1692 | LeftLeg = CFrame.new(-0.5, -1, 0) | |
1693 | lefth = (torso.CFrame*LeftLeg) | |
1694 | righth = (torso.CFrame*RightLeg) | |
1695 | ||
1696 | speed = Vector3.new(torso.Velocity.X,0,torso.Velocity.Z) | |
1697 | ||
1698 | TiltOnAxis = (torso.CFrame-torso.CFrame.p):vectorToObjectSpace(speed/100) | |
1699 | ||
1700 | local AngleThetaR = (righth-righth.p):vectorToObjectSpace(speed/100) | |
1701 | local AngleThetaL = (lefth-lefth.p):vectorToObjectSpace(speed/100) | |
1702 | if animpose ~= lastanimpose then | |
1703 | sine = 0 | |
1704 | if Debounces.NoIdl == false then | |
1705 | if stanceToggle == "Idle1" then | |
1706 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.6, 0.2) * CFrame.Angles(math.rad(-12 - 4 * math.cos(sine / 22)), math.rad(-12 - 2 * math.cos(sine / 22)), math.rad(12 + 2 * math.cos(sine / 22))), 0.3) | |
1707 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.6, -0.2) * CFrame.Angles(math.rad(20 + 4 * math.cos(sine / 22)), math.rad(-22 - 2 * math.cos(sine / 22)), math.rad(-15 - 2 * math.cos(sine / 22))), 0.3) | |
1708 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(-12 + 2.5 * math.cos(sine / 22)), math.rad(0), math.rad(0)), 0.2) | |
1709 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-2 + 2 * math.cos(sine / 22)), math.rad(0), 0), 0.2) | |
1710 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, -0.06) * CFrame.Angles(math.rad(0 - 2 * math.cos(sine / 22)), math.rad(5), math.rad(-5)), 0.2) | |
1711 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, -0.06) * CFrame.Angles(math.rad(0 - 2 * math.cos(sine / 22)), math.rad(-5), math.rad(5)), 0.2) | |
1712 | else | |
1713 | if stanceToggle == "Idle2" then | |
1714 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.6, 0.2) * CFrame.Angles(math.rad(-22 - 4 * math.cos(sine / 12)), math.rad(-40 - 2 * math.cos(sine / 12)), math.rad(24 + 2 * math.cos(sine / 12))), 0.3) | |
1715 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.2, 0.6, -0.6) * CFrame.Angles(math.rad(90 + 4 * math.cos(sine / 12)), math.rad(0), math.rad(50 - 2 * math.cos(sine / 12))), 0.3) | |
1716 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(-6 + 2.5 * math.cos(sine / 12)), math.rad(0), math.rad(0)), 0.2) | |
1717 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(-20 + 2 * math.cos(sine / 12)), math.rad(0), 0), 0.2) | |
1718 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -0.4, -1) * CFrame.Angles(math.rad(-7 - 2 * math.cos(sine / 12)), math.rad(7), math.rad(-5)), 0.2) | |
1719 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -0.8, -0.2) * CFrame.Angles(math.rad(-30 - 2 * math.cos(sine / 12)), math.rad(-9), math.rad(5)), 0.2) | |
1720 | end | |
1721 | end | |
1722 | fat.Event:wait() | |
1723 | end | |
1724 | end | |
1725 | lastanimpose = animpose | |
1726 | if Debounces.NoIdl == false then | |
1727 | if animpose == "Idle" then | |
1728 | change = 0.8 | |
1729 | corw.C0 = Lerp(corw.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)), 0.4) | |
1730 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(-26)), 0.4) | |
1731 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.5 + 0.05 * math.sin(sine / 10), 0) * CFrame.Angles(math.rad(30 + 2 * math.sin(sine / 10)), math.rad(-40 - 10 * math.cos(sine / 10)), math.rad(20)), 0.1) | |
1732 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(-20), math.rad(0)), 0.1) | |
1733 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.5 + 0.05 * math.sin(sine / 10), 0.15) * CFrame.Angles(math.rad(20 - 2 * math.sin(sine / 10)), math.rad(0 + 10 * math.cos(sine / 10)), math.rad(-20)), 0.1) | |
1734 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(20), math.rad(0)), 0.1) | |
1735 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.1) | |
1736 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0.15 - 0.05 * math.sin(sine / 10)) * CFrame.Angles(math.rad(15 - 3 * math.sin(sine / 10)), math.rad(0), math.rad(0)), 0.1) | |
1737 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-3 + 3 * math.cos(sine / 10)), math.rad(0), 0), 0.1) | |
1738 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.1) | |
1739 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.6, -1 - 0.01 * math.cos(sine / 10), 0) * CFrame.Angles(math.rad(5 - 5 * math.cos(sine / 5)), math.rad(0), math.rad(-10 + 1.9 * math.cos(sine / 10))), 0.1) | |
1740 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0.3) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.1) | |
1741 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1 + 0.01 * math.cos(sine / 10), 0) * CFrame.Angles(math.rad(-5 - 3 * math.cos(sine / 10)), math.rad(-10), math.rad(12 + 1.9 * math.cos(sine / 10))), 0.1) | |
1742 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.1) | |
1743 | rj.C0 = Lerp(torso.Weld.C0, CFrame.new(0, 2, 0) * CFrame.Angles(math.rad(-3 + 3 * math.cos(sine / 10)), math.rad(0), 0), 0.1) | |
1744 | rj.C1 = Lerp(torso.Weld.C1, CFrame.new(0, 2, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.1) | |
1745 | else | |
1746 | if animpose == "Walking" then | |
1747 | change = 0.8 | |
1748 | corw.C0 = Lerp(corw.C0, CFrame.new(0, -1.5, 0.5) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)), 0.4) | |
1749 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(0)), 0.4) | |
1750 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(20 + 2 * math.cos(sine / 7)), math.rad(0), math.rad(30)), 0.4) | |
1751 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.7) | |
1752 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.5 + 0.05 * math.cos(sine / 2), -math.sin(sine / 4) / 4) * CFrame.Angles(math.sin(sine / 4) / 2.8, -math.sin(sine / 4) / 3, math.rad(-10 - 7 * math.cos(sine / 2)) + root.RotVelocity.Y / 30), 0.4) | |
1753 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.7) | |
1754 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, -0.1 + 0.1 * math.cos(sine / 2)) * CFrame.Angles(math.rad(-10 + 4 * math.cos(sine / 2)), math.rad(0 - 8 * math.cos(sine / 4) / 2.3), math.rad(0)), 0.4) | |
1755 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0) - root.RotVelocity.Y / 10, math.rad(0)), 0.7) | |
1756 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 + 0.12 * math.cos(sine / 2), 0) * CFrame.Angles(math.rad(-4 + 2 * math.cos(sine / 2)), math.rad(0 + 10 * math.cos(sine / 4) / 2.3) + root.RotVelocity.Y / 30, math.rad(0) + root.RotVelocity.Y / 30), 0.4) | |
1757 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.8) | |
1758 | lleg.Weld.C0 = lleg.Weld.C0:lerp(CFrame.new(-0.5, -1 - math.cos(sine / 4) * 0.2, 0 + math.sin(sine / 4) * 0.1) * CFrame.Angles(math.sin(sine / 4) * 3 * AngleThetaL.Z, AngleThetaL.X, math.sin(sine / 4) * 3 * -AngleThetaL.X - root.RotVelocity.Y / 20), 0.8) | |
1759 | lleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.8) | |
1760 | rleg.Weld.C0 = rleg.Weld.C0:lerp(CFrame.new(0.5, -1 + math.cos(sine / 4) * 0.2, 0 - math.sin(sine / 4) * 0.1) * CFrame.Angles(math.sin(sine / 4) * 3 * -AngleThetaR.Z, AngleThetaR.X, math.sin(sine / 4) * 3 * AngleThetaR.X - root.RotVelocity.Y / 20), 0.8) | |
1761 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.8) | |
1762 | else | |
1763 | if animpose == "Running" then | |
1764 | change = 1.1 | |
1765 | corw.C0 = Lerp(corw.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(0), math.rad(90), math.rad(0)), 0.4) | |
1766 | corw.C1 = Lerp(corw.C1, CFrame.new(-2.4, 0, 0) * CFrame.Angles(math.rad(-90), math.rad(0), math.rad(-35)), 0.4) | |
1767 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.4, 0.54, 0) * CFrame.Angles(math.rad(-34), math.rad(-15), math.rad(26)), 0.2) | |
1768 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.36) | |
1769 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.24 + 0.6 * math.cos(sine / 4) / 1.4, 0.54, 0 - 0.8 * math.cos(sine / 4)) * CFrame.Angles(math.rad(6 + 140 * math.cos(sine / 4) / 1.2), math.rad(0), math.rad(20 + 70 * math.cos(sine / 4))), 0.2) | |
1770 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1771 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, -0.2) * CFrame.Angles(math.rad(-8 + 12 * math.cos(sine / 2) / 1.5), math.rad(0 + 12 * math.cos(sine / 4)), math.rad(0)), 0.2) | |
1772 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0) - root.RotVelocity.Y / 10, math.rad(0)), 0.5) | |
1773 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1 + 0.2 * math.cos(sine / 2) / 1.7, 0) * CFrame.Angles(math.rad(-14 + 10 * math.cos(sine / 2) / 1.5), math.rad(0 - 12 * math.cos(sine / 4)) - root.RotVelocity.Y / 10, math.rad(0) + root.RotVelocity.Y / 20), 0.2) | |
1774 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.4) | |
1775 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -0.8 - 0.4 * math.cos(sine / 4) / 2, math.sin(sine / 4) / 2) * CFrame.Angles(math.rad(-10) + -math.sin(sine / 4) / 1.2, math.rad(0 + 12 * math.cos(sine / 4)) + root.RotVelocity.Y / 10, 0), 0.8) | |
1776 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
1777 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -0.8 + 0.4 * math.cos(sine / 4) / 2, -math.sin(sine / 4) / 2) * CFrame.Angles(math.rad(-10) + math.sin(sine / 4) / 1.2, math.rad(0 + 12 * math.cos(sine / 4)) + root.RotVelocity.Y / 10, 0), 0.8) | |
1778 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
1779 | else | |
1780 | if animpose == "Jumping" then | |
1781 | change = 1 | |
1782 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.6, 0) * CFrame.Angles(math.rad(-10), math.rad(0), math.rad(10)), 0.2) | |
1783 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.36) | |
1784 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.6, 0) * CFrame.Angles(math.rad(-10), math.rad(0), math.rad(-10)), 0.2) | |
1785 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1786 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(30), math.rad(0), 0), 0.2) | |
1787 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(1), math.rad(0), 0), 0.2) | |
1788 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.4) | |
1789 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1.1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2) | |
1790 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
1791 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1.1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2) | |
1792 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
1793 | else | |
1794 | if animpose == "Freefalling" then | |
1795 | change = 1 | |
1796 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.6, 0) * CFrame.Angles(math.rad(-40), math.rad(20), math.rad(50)), 0.2) | |
1797 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.36) | |
1798 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.6, 0) * CFrame.Angles(math.rad(110), math.rad(-20), math.rad(-30)), 0.2) | |
1799 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.5) | |
1800 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, 0) * CFrame.Angles(math.rad(10), math.rad(0), 0), 0.2) | |
1801 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-30), math.rad(0), 0), 0.2) | |
1802 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.4) | |
1803 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -0.5, -0.5) * CFrame.Angles(math.rad(-20), math.rad(0), math.rad(0)), 0.2) | |
1804 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
1805 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, 0, 0.5) * CFrame.Angles(math.rad(30), math.rad(0), math.rad(0)), 0.2) | |
1806 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
1807 | end | |
1808 | end | |
1809 | end | |
1810 | end | |
1811 | end | |
1812 | end | |
1813 | end | |
1814 | ) | |
1815 | hum.MaxHealth = math.huge | |
1816 | wait(3) | |
1817 | hum.Health = math.huge |