SHOW:
|
|
- or go back to the newest paste.
1 | --usage | |
2 | ||
3 | local FEService = loadstring(game:HttpGetAsync("https://raw.githubusercontent.com/WhyGitHubb/FEService/main/main.lua"))() | |
4 | ||
5 | ||
6 | FEService:FullNetwork() | |
7 | ||
8 | print(game.Players.LocalPlayer.SimulationRadius) | |
9 | --[[ | |
10 | Paid: | |
11 | https://www.roblox.com/catalog/14255556501/Extra-Right-White-Arm | |
12 | https://www.roblox.com/catalog/14255554762/Extra-Left-White-Arm | |
13 | https://www.roblox.com/catalog/14768693948/White-Extended-Right-Arm | |
14 | https://www.roblox.com/catalog/14768701869/White-Extended-Left-Arm | |
15 | https://www.roblox.com/catalog/14255528083/Torso-Extension | |
16 | or | |
17 | https://www.roblox.com/catalog/13779879140/Black-Fluffy-Fur-Body | |
18 | (ANYTHING CAN BE USED FOR THE TORSO SUCH AS A VEST.) | |
19 | ||
20 | Paid (2): | |
21 | https://www.roblox.com/catalog/11159410305/Rectangle-Head-For-Headless | |
22 | https://www.roblox.com/catalog/11263254795/Dummy-Head-For-Headless | |
23 | https://www.roblox.com/catalog/12344545199/Extra-Left-hand-moving-Blocky-white | |
24 | https://www.roblox.com/catalog/12344591101/Extra-Right-hand-moving-Blocky-white | |
25 | https://www.roblox.com/catalog/14255528083/Torso-Extension | |
26 | or | |
27 | https://www.roblox.com/catalog/13779879140/Black-Fluffy-Fur-Body | |
28 | (ANYTHING CAN BE USED FOR THE TORSO SUCH AS A VEST.) | |
29 | ||
30 | Free: | |
31 | https://www.roblox.com/catalog/3033908130/International-Fedora-France | |
32 | https://www.roblox.com/catalog/3033910400/International-Fedora-Germany | |
33 | https://www.roblox.com/catalog/3409612660/International-Fedora-USA | |
34 | https://www.roblox.com/catalog/3398308134/International-Fedora-Canada | |
35 | https://www.roblox.com/catalog/4819740796/Robox | |
36 | ||
37 | Weapons: | |
38 | https://www.roblox.com/catalog/13760686814/Classic-MARKA-17M-Valkan-Left | |
39 | ]]-- | |
40 | ||
41 | game:GetService("StarterGui"):SetCore("SendNotification", { | |
42 | Title = "Melon's (FE) Scripts"; | |
43 | Text = "Have fun!"; | |
44 | Icon = "rbxthumb://type=Asset&id=13446503788&w=150&h=150"}) | |
45 | Duration = 16; | |
46 | ||
47 | if not game:IsLoaded() then | |
48 | game.Loaded:Wait() | |
49 | end | |
50 | ||
51 | local function FindInstance(Parent, ClassName, Name) | |
52 | for _, Instance in pairs(Parent:GetChildren()) do | |
53 | if Instance:IsA(ClassName) and Instance.Name == Name then | |
54 | return Instance | |
55 | end | |
56 | end | |
57 | end | |
58 | ||
59 | local function WaitForClass(Parent, ClassName) | |
60 | local Instance = Parent:FindFirstChildOfClass(ClassName) | |
61 | ||
62 | while not Instance and Parent do | |
63 | Parent.ChildAdded:Wait() | |
64 | Instance = Parent:FindFirstChildOfClass(ClassName) | |
65 | end | |
66 | ||
67 | return Instance | |
68 | end | |
69 | ||
70 | local function WaitForClassOfName(Parent, ...) | |
71 | local Instance = FindInstance(Parent, ...) | |
72 | ||
73 | while not Instance and Parent do | |
74 | Parent.ChildAdded:Wait() | |
75 | Instance = FindInstance(Parent, ...) | |
76 | end | |
77 | ||
78 | return Instance | |
79 | end | |
80 | ||
81 | local Fling = { } | |
82 | local Aligns = { } | |
83 | local Blacklist = { } | |
84 | local Accessories = { } | |
85 | local Attachments = { } | |
86 | ||
87 | local Instancenew = Instance.new | |
88 | ||
89 | local taskwait = task.wait | |
90 | local taskspawn = task.spawn | |
91 | local taskdefer = task.defer | |
92 | ||
93 | local mathabs = math.abs | |
94 | local mathcos = math.cos | |
95 | local mathrandom = math.random | |
96 | ||
97 | local stringmatch = string.match | |
98 | ||
99 | local osclock = os.clock | |
100 | ||
101 | local tableinsert = table.insert | |
102 | local tableclear = table.clear | |
103 | local tablefind = table.find | |
104 | ||
105 | local CFramenew = CFrame.new | |
106 | local CFrameAngles = CFrame.Angles | |
107 | local CFrameidentity = CFrame.identity | |
108 | ||
109 | local Vector3new = Vector3.new | |
110 | local Vector3zero = Vector3.zero | |
111 | ||
112 | local Sleep = CFrameidentity | |
113 | local Velocity = Vector3new(0, 16384, 0) | |
114 | local Angular = 0 | |
115 | local Linear = 0 | |
116 | ||
117 | local Workspace = game:FindFirstChildOfClass("Workspace") | |
118 | local CurrentCamera = Workspace.CurrentCamera | |
119 | ||
120 | local Players = game:FindFirstChildOfClass("Players") | |
121 | ||
122 | local LocalPlayer = Players.LocalPlayer | |
123 | local Mouse = LocalPlayer:GetMouse() | |
124 | ||
125 | local PostSimulation = game:FindFirstChildOfClass("RunService").PostSimulation | |
126 | ||
127 | local Character = LocalPlayer.Character | |
128 | local CharacterClone = Instancenew("Model") | |
129 | ||
130 | local StarterGui = game:FindFirstChildOfClass("StarterGui") | |
131 | local BindableEvent = Instancenew("BindableEvent") | |
132 | ||
133 | local UserInputService = game:FindFirstChildOfClass("UserInputService") | |
134 | local UserInputType = Enum.UserInputType | |
135 | ||
136 | local MouseButton1 = UserInputType.MouseButton1 | |
137 | local Touch = UserInputType.Touch | |
138 | ||
139 | local InputBegan = UserInputService.InputBegan:Connect(function(Input, GameProcessed) | |
140 | local Type = Input.UserInputType | |
141 | ||
142 | if not GameProcessed and ( Type == MouseButton1 or Type == Touch ) then | |
143 | local Target = Mouse.Target | |
144 | if Target and not Target.Anchored and not Target:IsDescendantOf(CharacterClone) and not Target:IsDescendantOf(Character) and not tablefind(Fling, Target) then | |
145 | local Parent = Target.Parent | |
146 | ||
147 | if Parent:IsA("Model") and Parent ~= Character and Parent:FindFirstChildOfClass("Humanoid") then | |
148 | local HumanoidRootPart = FindInstance(Parent, "BasePart", "HumanoidRootPart") or FindInstance(Parent, "BasePart", "Torso") or FindInstance(Parent, "BasePart", "Head") | |
149 | ||
150 | if HumanoidRootPart and not tablefind(Fling, HumanoidRootPart) then | |
151 | tableinsert(Fling, HumanoidRootPart) | |
152 | return | |
153 | end | |
154 | end | |
155 | ||
156 | tableinsert(Fling, Target) | |
157 | end | |
158 | end | |
159 | end) | |
160 | ||
161 | local function Part(Name, Size) | |
162 | local Part = Instancenew("Part") | |
163 | Part.Name = Name | |
164 | Part.Size = Size | |
165 | Part.Transparency = 1 | |
166 | Part.Parent = CharacterClone | |
167 | ||
168 | return Part | |
169 | end | |
170 | ||
171 | local function Motor6D(Name, Part0, Part1, C0, C1) | |
172 | local Motor6D = Instancenew("Motor6D") | |
173 | Motor6D.Name = Name | |
174 | Motor6D.Part0 = Part0 | |
175 | Motor6D.Part1 = Part1 | |
176 | Motor6D.C0 = C0 | |
177 | Motor6D.C1 = C1 | |
178 | Motor6D.Parent = Part0 | |
179 | ||
180 | return Motor6D | |
181 | end | |
182 | ||
183 | local function Attachment(Name, CFrame, Parent) | |
184 | local Attachment = Instancenew("Attachment") | |
185 | Attachment.Name = Name | |
186 | Attachment.CFrame = CFrame | |
187 | Attachment.Parent = Parent | |
188 | ||
189 | tableinsert(Attachments, Attachment) | |
190 | return Attachment | |
191 | end | |
192 | ||
193 | local LimbSize = Vector3new(1, 2, 1) | |
194 | local TorsoSize = Vector3new(2, 2, 1) | |
195 | ||
196 | local Head = Part("Head", Vector3new(2, 1, 1)) | |
197 | local Torso = Part("Torso", TorsoSize) | |
198 | local LeftArm = Part("Left Arm", LimbSize) | |
199 | local RightArm = Part("Right Arm", LimbSize) | |
200 | local LeftLeg = Part("Left Leg", LimbSize) | |
201 | local RightLeg = Part("Right Leg", LimbSize) | |
202 | local HumanoidRootPart = Part("HumanoidRootPart", TorsoSize) | |
203 | ||
204 | local FakeRA = Instance.new("Part") | |
205 | FakeRA.Size = Vector3.new(1,2,1) | |
206 | FakeRA.Transparency = 1 | |
207 | FakeRA.BrickColor = BrickColor.new("Institutional White") | |
208 | FakeRA.Parent = RightArm | |
209 | ||
210 | local FRAW = Instance.new("Weld") | |
211 | FRAW.Part0 = RightArm | |
212 | FRAW.Part1 = FakeRA | |
213 | FRAW.C0 = CFrame.new(0, 0, 0) | |
214 | FRAW.Parent = RightArm | |
215 | ||
216 | local FakeLA = Instance.new("Part") | |
217 | FakeLA.Size = Vector3.new(1,2,1) | |
218 | FakeLA.Transparency = 1 | |
219 | FakeLA.BrickColor = BrickColor.new("Institutional White") | |
220 | FakeLA.Parent = LeftArm | |
221 | ||
222 | local FLAW = Instance.new("Weld") | |
223 | FLAW.Part0 = LeftArm | |
224 | FLAW.Part1 = FakeLA | |
225 | FLAW.C0 = CFrame.new(0, 0, 0) | |
226 | FLAW.Parent = LeftArm | |
227 | ||
228 | local Part = nil | |
229 | ||
230 | if Character then | |
231 | Part = FindInstance(Character, "BasePart", "HumanoidRootPart") or FindInstance(Character, "BasePart", "Head") or FindInstance(Character, "BasePart", "Torso") or FindInstance(Character, "BasePart", "UpperTorso") | |
232 | end | |
233 | ||
234 | if Part then | |
235 | HumanoidRootPart.CFrame = Part.CFrame | |
236 | else | |
237 | local SpawnLocations = { } | |
238 | ||
239 | for _, SpawnLocation in pairs(Workspace:GetDescendants()) do | |
240 | if SpawnLocation:IsA("SpawnLocation") then | |
241 | tableinsert(SpawnLocations, SpawnLocation) | |
242 | end | |
243 | end | |
244 | ||
245 | local Amount = # SpawnLocations | |
246 | ||
247 | if Amount > 0 then | |
248 | local SpawnLocation = SpawnLocations[mathrandom(1, Amount)] | |
249 | HumanoidRootPart.CFrame = SpawnLocation.CFrame * CFramenew(0, SpawnLocation.Size.Y / 2 + 3, 0) | |
250 | else | |
251 | HumanoidRootPart.CFrame = CFrameidentity | |
252 | end | |
253 | end | |
254 | ||
255 | local face = Instancenew("Decal") | |
256 | face.Name = "face" | |
257 | face.Parent = Head | |
258 | ||
259 | local AccessoryTable = { | |
260 | -- Paid -- | |
261 | { Mesh = "14241018198", Texture = "14251599953", Instance = Torso }, | |
262 | { Mesh = "14255522247", Texture = "14255543546", Instance = RightArm, CFrame = CFrameAngles(0, 1.57, 1.57) }, | |
263 | { Mesh = "14255522247", Texture = "14255543546", Instance = LeftArm, CFrame = CFrameAngles(0, - 1.57, 1.57) }, | |
264 | { Mesh = "14768684979", Texture = "14768683674", Instance = RightLeg, CFrame = CFrameAngles(0, - 1.57, 1.57) }, | |
265 | { Mesh = "14768684979", Texture = "14768683674", Instance = LeftLeg, CFrame = CFrameAngles(0, 1.57, 1.57) }, | |
266 | ||
267 | -- Paid (2) -- | |
268 | { Mesh = "14241018198", Texture = "14251599953", Instance = Torso }, | |
269 | { Mesh = "12344206657", Texture = "12344206675", Instance = RightArm, CFrame = CFrameAngles(-115, 0, 0) }, | |
270 | { Mesh = "12344207333", Texture = "12344207341", Instance = LeftArm, CFrame = CFrameAngles(-115, 0, 0) }, | |
271 | { Mesh = "11159370334", Texture = "11159284657", Instance = RightLeg, CFrame = CFrameAngles(0, - 1.57, 1.57) }, | |
272 | { Mesh = "11263221350", Texture = "11263219250", Instance = LeftLeg, CFrame = CFrameAngles(0, 1.57, 1.57) }, | |
273 | ||
274 | -- Free -- | |
275 | { Mesh = "4819720316", Texture = "4819722776", Instance = Torso, CFrame = CFrameAngles(0, 0, 105) }, | |
276 | { Mesh = "3030546036", Texture = "3033903209", Instance = RightArm, CFrame = CFrameAngles(-90, 0, -89.5) }, | |
277 | { Mesh = "3030546036", Texture = "3360978739", Instance = LeftArm, CFrame = CFrameAngles(-90, 0, 89.5) }, | |
278 | { Mesh = "3030546036", Texture = "3409604993", Instance = RightLeg, CFrame = CFrameAngles(-90, 0, -89.5) }, | |
279 | { Mesh = "3030546036", Texture = "3033898741", Instance = LeftLeg, CFrame = CFrameAngles(-90, 0, 89.5) }, | |
280 | ||
281 | -- Temporary -- | |
282 | { Mesh = "14833036921", Texture = "14833036785", Instance = FakeRA, CFrame = CFramenew(0,-2.35, -0.80) * CFrameAngles(1.85, 0, 3.15) }, | |
283 | } | |
284 | ||
285 | for _, Table in pairs(AccessoryTable) do | |
286 | if type(Table.Mesh) ~= "string" then | |
287 | Table.Mesh = "" | |
288 | end | |
289 | if type(Table.Texture) ~= "string" then | |
290 | Table.Texture = "" | |
291 | end | |
292 | end | |
293 | ||
294 | Motor6D("Right Shoulder", Torso, RightArm, CFramenew(1, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0), CFramenew(-0.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)) | |
295 | Motor6D("Left Shoulder", Torso, LeftArm, CFramenew(-1, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0), CFramenew(0.5, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)) | |
296 | Motor6D("Right Hip", Torso, RightLeg, CFramenew(1, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0), CFramenew(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)) | |
297 | Motor6D("Left Hip", Torso, LeftLeg, CFramenew(-1, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0), CFramenew(-0.5, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)) | |
298 | Motor6D("Neck", Torso, Head, CFramenew(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0), CFramenew(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)) | |
299 | Motor6D("RootJoint", HumanoidRootPart, Torso, CFramenew(0, 0, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0), CFramenew(0, 0, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)) | |
300 | ||
301 | Attachment("HairAttachment", CFramenew(0, 0.600000024, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), Head) | |
302 | Attachment("HatAttachment", CFramenew(0, 0.600000024, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), Head) | |
303 | Attachment("FaceFrontAttachment", CFramenew(0, 0, -0.600000024, 1, 0, 0, 0, 1, 0, 0, 0, 1), Head) | |
304 | Attachment("FaceCenterAttachment", CFramenew(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), Head) | |
305 | Attachment("NeckAttachment", CFramenew(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), Torso) | |
306 | Attachment("BodyFrontAttachment", CFramenew(0, 0, -0.5, 1, 0, 0, 0, 1, 0, 0, 0, 1), Torso) | |
307 | Attachment("BodyBackAttachment", CFramenew(0, 0, 0.5, 1, 0, 0, 0, 1, 0, 0, 0, 1), Torso) | |
308 | Attachment("LeftCollarAttachment", CFramenew(-1, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), Torso) | |
309 | Attachment("RightCollarAttachment", CFramenew(1, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), Torso) | |
310 | Attachment("WaistFrontAttachment", CFramenew(0, -1, -0.5, 1, 0, 0, 0, 1, 0, 0, 0, 1), Torso) | |
311 | Attachment("WaistCenterAttachment", CFramenew(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), Torso) | |
312 | Attachment("WaistBackAttachment", CFramenew(0, -1, 0.5, 1, 0, 0, 0, 1, 0, 0, 0, 1), Torso) | |
313 | Attachment("LeftShoulderAttachment", CFramenew(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), LeftArm) | |
314 | Attachment("LeftGripAttachment", CFramenew(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), LeftArm) | |
315 | Attachment("RightShoulderAttachment", CFramenew(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), RightArm) | |
316 | Attachment("RightGripAttachment", CFramenew(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), RightArm) | |
317 | Attachment("LeftFootAttachment", CFramenew(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), LeftLeg) | |
318 | Attachment("RightFootAttachment", CFramenew(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), RightLeg) | |
319 | Attachment("RootAttachment", CFramenew(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), HumanoidRootPart) | |
320 | ||
321 | local Humanoid = Instancenew("Humanoid", CharacterClone) | |
322 | Instancenew("Animator", Humanoid) | |
323 | ||
324 | Instancenew("LocalScript", CharacterClone).Name = "Animate" | |
325 | ||
326 | CharacterClone.PrimaryPart = Head | |
327 | CharacterClone.Parent = Workspace | |
328 | ||
329 | local function DescendantAdded(Instance) | |
330 | if Instance:IsA("Accessory") then | |
331 | taskspawn(function() | |
332 | local Handle = WaitForClassOfName(Instance, "BasePart", "Handle") | |
333 | local Attachment = WaitForClass(Handle, "Attachment") | |
334 | ||
335 | local Clone = Instance:Clone() | |
336 | ||
337 | local CloneHandle = FindInstance(Clone, "BasePart", "Handle") | |
338 | CloneHandle.Transparency = 1 | |
339 | CloneHandle:BreakJoints() | |
340 | ||
341 | local AccessoryWeld = Instancenew("Weld") | |
342 | AccessoryWeld.Name = "AccessoryWeld" | |
343 | AccessoryWeld.Part0 = CloneHandle | |
344 | AccessoryWeld.C0 = Attachment.CFrame | |
345 | ||
346 | local Name = Attachment.Name | |
347 | ||
348 | for _, TableAttachment in pairs(Attachments) do | |
349 | if TableAttachment.Name == Name then | |
350 | AccessoryWeld.Part1 = TableAttachment.Parent | |
351 | AccessoryWeld.C1 = TableAttachment.CFrame | |
352 | end | |
353 | end | |
354 | ||
355 | AccessoryWeld.Parent = CloneHandle | |
356 | Clone.Parent = CharacterClone | |
357 | ||
358 | tableinsert(Accessories, Clone) | |
359 | ||
360 | local IsAMeshPart = CloneHandle:IsA("MeshPart") | |
361 | local Mesh = IsAMeshPart and CloneHandle or WaitForClass(CloneHandle, "SpecialMesh") | |
362 | local Id = IsAMeshPart and "TextureID" or "TextureId" | |
363 | ||
364 | for _, Table in pairs(AccessoryTable) do | |
365 | local Instance = Table.Instance | |
366 | ||
367 | if Instance then | |
368 | if stringmatch(Mesh.MeshId, Table.Mesh) and stringmatch(Mesh[Id], Table.Texture) and not tablefind(Blacklist, Instance) then | |
369 | tableinsert(Blacklist, Instance) | |
370 | tableinsert(Aligns, { Handle, Instance, Table.CFrame or CFrameidentity }) | |
371 | return | |
372 | end | |
373 | end | |
374 | end | |
375 | ||
376 | tableinsert(Aligns, { Handle, CloneHandle, CFrameidentity }) | |
377 | end) | |
378 | elseif Instance:IsA("JointInstance") then | |
379 | taskspawn(function() | |
380 | taskwait() | |
381 | Instance:Destroy() | |
382 | end) | |
383 | end | |
384 | end | |
385 | ||
386 | local function CharacterAdded(Character) | |
387 | if Character ~= CharacterClone then | |
388 | PostSimulation:Wait() | |
389 | ||
390 | local Backpack = LocalPlayer:FindFirstChildOfClass("Backpack") | |
391 | ||
392 | if Backpack then | |
393 | Backpack:ClearAllChildren() | |
394 | end | |
395 | ||
396 | tableclear(Aligns) | |
397 | tableclear(Blacklist) | |
398 | ||
399 | for _, Accessory in pairs(Accessories) do | |
400 | Accessory:Destroy() | |
401 | end | |
402 | ||
403 | local CurrentCameraCFrame = CurrentCamera.CFrame | |
404 | ||
405 | LocalPlayer.Character = CharacterClone | |
406 | CurrentCamera.CameraSubject = CharacterClone.Head | |
407 | ||
408 | taskspawn(function() | |
409 | CurrentCamera:GetPropertyChangedSignal("CFrame"):Wait() | |
410 | CurrentCamera.CFrame = CurrentCameraCFrame | |
411 | end) | |
412 | ||
413 | local CharacterHumanoidRootPart = WaitForClassOfName(Character, "BasePart", "HumanoidRootPart") | |
414 | ||
415 | for Index, Value in pairs(Fling) do | |
416 | local BasePart = nil | |
417 | ||
418 | if typeof(Value) == "Instance" then | |
419 | if Value:IsA("BasePart") then | |
420 | BasePart = Value | |
421 | elseif Value:IsA("Humanoid") then | |
422 | local Model = Value.Parent | |
423 | ||
424 | if Model ~= Character and Model:IsA("Model") then | |
425 | BasePart = FindInstance(Model, "BasePart", "HumanoidRootPart") or FindInstance(Model, "BasePart", "Head") or Model:FindFirstChildOfClass("BasePart") | |
426 | end | |
427 | elseif Value:IsA("Model") and Value ~= Character then | |
428 | BasePart = FindInstance(Value, "BasePart", "HumanoidRootPart") or FindInstance(Value, "BasePart", "Head") or Value:FindFirstChildOfClass("BasePart") | |
429 | end | |
430 | end | |
431 | ||
432 | if BasePart then | |
433 | local clock = osclock() | |
434 | ||
435 | while CharacterHumanoidRootPart and BasePart and osclock() - clock <= 1 and BasePart.AssemblyLinearVelocity.Magnitude <= 60 do | |
436 | CharacterHumanoidRootPart.AssemblyAngularVelocity = Velocity | |
437 | CharacterHumanoidRootPart.AssemblyLinearVelocity = Velocity | |
438 | ||
439 | CharacterHumanoidRootPart.CFrame = BasePart.CFrame + Vector3new(0, - 1, 0) | |
440 | PostSimulation:Wait() | |
441 | end | |
442 | end | |
443 | end | |
444 | ||
445 | tableclear(Fling) | |
446 | ||
447 | if CharacterHumanoidRootPart then | |
448 | CharacterHumanoidRootPart.AssemblyAngularVelocity = Vector3zero | |
449 | CharacterHumanoidRootPart.AssemblyLinearVelocity = Vector3zero | |
450 | ||
451 | CharacterHumanoidRootPart.CFrame = CFramenew(HumanoidRootPart.Position + Vector3new(mathrandom(- 32, 32), 0, mathrandom(- 32, 32))) | |
452 | PostSimulation:Wait() | |
453 | end | |
454 | ||
455 | Character:BreakJoints() | |
456 | ||
457 | for _, Instance in pairs(Character:GetDescendants()) do | |
458 | DescendantAdded(Instance) | |
459 | end | |
460 | ||
461 | Character.DescendantAdded:Connect(DescendantAdded) | |
462 | end | |
463 | end | |
464 | ||
465 | local function Align(Part0, Part1, CFrame) | |
466 | if Part0.ReceiveAge == 0 and not Part0.Anchored and # Part0:GetJoints() == 0 then | |
467 | Part0.AssemblyAngularVelocity = Vector3new(0, Angular, 0) | |
468 | ||
469 | local Part1CFrame = Part1.CFrame | |
470 | local LinearVelocity = Part1.AssemblyLinearVelocity * Linear | |
471 | local Magnitude = LinearVelocity.Magnitude < Linear | |
472 | ||
473 | if Magnitude then | |
474 | local LookVector = Part1CFrame.LookVector * Linear | |
475 | Part0.AssemblyLinearVelocity = Vector3new(LookVector.X, Linear, LookVector.Z) | |
476 | else | |
477 | Part0.AssemblyLinearVelocity = Vector3new(LinearVelocity.X, Linear, LinearVelocity.Z) | |
478 | end | |
479 | ||
480 | Part0.CFrame = Part1CFrame * ( Magnitude and Sleep or CFrameidentity ) * CFrame | |
481 | end | |
482 | end | |
483 | ||
484 | if Character then | |
485 | CharacterAdded(Character) | |
486 | end | |
487 | ||
488 | local Added = LocalPlayer.CharacterAdded:Connect(CharacterAdded) | |
489 | ||
490 | local Connection = game:FindFirstChildOfClass("RunService").PostSimulation:Connect(function() | |
491 | local osclock = osclock() | |
492 | local Axis = 0.004 * mathcos(osclock * 17.5) | |
493 | ||
494 | Sleep = CFramenew(0, Axis, 0) | |
495 | Angular = mathcos(osclock) | |
496 | Linear = 26 | |
497 | ||
498 | for _, Table in pairs(Aligns) do | |
499 | Align(Table[1], Table[2], Table[3]) | |
500 | end | |
501 | ||
502 | if sethiddenproperty then | |
503 | sethiddenproperty(LocalPlayer, "SimulationRadius", 10000000) | |
504 | end | |
505 | ||
506 | StarterGui:SetCore("ResetButtonCallback", BindableEvent) -- This is if it gets overriden, just like in MyWorld testing place. | |
507 | end) | |
508 | ||
509 | local function Event() | |
510 | CharacterClone:Destroy() | |
511 | end | |
512 | ||
513 | BindableEvent.Event:Connect(Event) | |
514 | ||
515 | CharacterClone:GetPropertyChangedSignal("Parent"):Connect(function() | |
516 | if not CharacterClone.Parent then | |
517 | Added:Disconnect() | |
518 | Connection:Disconnect() | |
519 | ||
520 | CharacterClone:Destroy() | |
521 | ||
522 | if BindableEvent then | |
523 | BindableEvent:Destroy() | |
524 | end | |
525 | ||
526 | StarterGui:SetCore("ResetButtonCallback", true) | |
527 | end | |
528 | end) | |
529 | ||
530 | BindableEvent:GetPropertyChangedSignal("Parent"):Connect(Event) | |
531 | ||
532 | - | print[[ |
532 | + | wait(0.2) |
533 | - | Vaporwave Vibe Thing By Godcat567 |
533 | + | |
534 | Player = game.Players.LocalPlayer | |
535 | - | This was based off of a mode from powertommm's banisher switcher |
535 | + | PlayerGui = Player.PlayerGui |
536 | Cam = workspace.CurrentCamera | |
537 | - | Visualiser Commands: .id [insert music id here] |
537 | + | Backpack = Player.Backpack |
538 | - | .vol [insert volume number here] |
538 | + | Character = Player.Character |
539 | - | .pit [insert pitch number here] |
539 | + | Humanoid = Character.Humanoid |
540 | - | ]] |
540 | + | RootPart = Character["HumanoidRootPart"] |
541 | Torso = Character["Torso"] | |
542 | - | --Source Code Might Be Used From Others Credits To Their Creators |
542 | + | Head = Character["Head"] |
543 | RightArm = Character["Right Arm"] | |
544 | - | wait(1/60) |
544 | + | |
545 | RightLeg = Character["Right Leg"] | |
546 | - | --[[ Defining Variables ]] |
546 | + | |
547 | RootJoint = RootPart["RootJoint"] | |
548 | - | Plr = game.Players.LocalPlayer |
548 | + | Neck = Torso["Neck"] |
549 | - | PlrGui = Plr.PlayerGui |
549 | + | |
550 | - | Character = Plr.Character |
550 | + | |
551 | RightHip = Torso["Right Hip"] | |
552 | LeftHip = Torso["Left Hip"] | |
553 | Character.Archivable = true | |
554 | ||
555 | - | RootPart = Character.HumanoidRootPart |
555 | + | IT = Instance.new |
556 | - | Torso = Character.Torso |
556 | + | CF = CFrame.new |
557 | - | Head = Character.Head |
557 | + | VT = Vector3.new |
558 | - | Humanoid = Character:FindFirstChildOfClass('Humanoid') |
558 | + | RAD = math.rad |
559 | C3 = Color3.new | |
560 | - | --[[ Joint Setup ]] |
560 | + | UD2 = UDim2.new |
561 | BRICKC = BrickColor.new | |
562 | - | Neck = Torso.Neck |
562 | + | ANGLES = CFrame.Angles |
563 | - | RootJoint = RootPart.RootJoint |
563 | + | EULER = CFrame.fromEulerAnglesXYZ |
564 | COS = math.cos | |
565 | ACOS = math.acos | |
566 | SIN = math.sin | |
567 | ASIN = math.asin | |
568 | - | --Tail = Character["Black Cyber Critter Tail"].Handle.AccessoryWeld |
568 | + | ABS = math.abs |
569 | MRANDOM = math.random | |
570 | - | EulerRootCF = CFrame.fromEulerAnglesXYZ(-1.57,0,3.14) --CFrame.Angles(math.rad(-90),0,math.rad(180)) |
570 | + | FLOOR = math.floor |
571 | - | NeckCF = CFrame.new(0,1,0)*CFrame.Angles(math.rad(-90),math.rad(0),math.rad(180)) |
571 | + | local CHOICE = MRANDOM(1,5) |
572 | - | RightShoulderCF = CFrame.new(-0.5,0,0)*CFrame.Angles(0,math.rad(90),0) |
572 | + | --//=================================\\ |
573 | - | LeftShoulderCF = CFrame.new(0.5,0,0)*CFrame.Angles(0,math.rad(-90),0) |
573 | + | --|| USEFUL VALUES |
574 | - | --TailCF = CFrame.new(0,-.75,.5)*CFrame.fromEulerAnglesXYZ(-3.14,0,3.14) |
574 | + | --\\=================================// |
575 | ||
576 | - | DefaultWelds = { |
576 | + | Animation_Speed = 3 |
577 | - | C0 = { |
577 | + | Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60) |
578 | - | RJC0 = CFrame.fromEulerAnglesXYZ(-1.57,0,3.14)*CFrame.new(0,0,0), |
578 | + | local Speed = 20 |
579 | - | NKC0 = CFrame.new(0,1,0)*CFrame.Angles(math.rad(-90),math.rad(0),math.rad(180)), |
579 | + | local SIZE = 1 |
580 | - | RSC0 = CFrame.new(1,0.5,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(0)), |
580 | + | local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) |
581 | - | LSC0 = CFrame.new(-1,0.5,0)*CFrame.Angles(math.rad(0),math.rad(-90),math.rad(0)), |
581 | + | local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) |
582 | - | RHC0 = CFrame.new(1,-1,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(0)), |
582 | + | local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) |
583 | - | LHC0 = CFrame.new(-1,-1,0)*CFrame.Angles(math.rad(0),math.rad(-90),math.rad(0)), |
583 | + | local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) |
584 | - | }, |
584 | + | local DAMAGEMULTIPLIER = "inf" |
585 | - | C1 = { |
585 | + | local ANIM = "Idle" |
586 | - | RJC1 = CFrame.fromEulerAnglesXYZ(-1.57,0,3.14)*CFrame.new(0,0,0), |
586 | + | local ATTACK = false |
587 | - | NKC1 = CFrame.new(0,-0.5,0)*CFrame.Angles(math.rad(-90),math.rad(0),math.rad(180)), |
587 | + | local EQUIPPED = false |
588 | - | RSC1 = CFrame.new(-0.5,0.5,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(0)), |
588 | + | local HOLD = false |
589 | - | LSC1 = CFrame.new(0.5,0.5,0)*CFrame.Angles(math.rad(0),math.rad(-90),math.rad(0)), |
589 | + | local COMBO = 1 |
590 | - | RHC1 = CFrame.new(0.5,1,0)*CFrame.Angles(math.rad(0),math.rad(90),math.rad(0)), |
590 | + | local Rooted = false |
591 | - | LHC1 = CFrame.new(-0.5,1,0)*CFrame.Angles(math.rad(0),math.rad(-90),math.rad(0)), |
591 | + | local SINE = 0 |
592 | local KEYHOLD = false | |
593 | - | }, |
593 | + | local CHANGE = 2 / Animation_Speed |
594 | local WALKINGANIM = false | |
595 | - | --Default welds for anybody who does NOT know cframe |
595 | + | local VALUE1 = false |
596 | local VALUE2 = false | |
597 | - | --[[ Killing Default Animations Initiated ]] |
597 | + | local ROBLOXIDLEANIMATION = IT("Animation") |
598 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
599 | - | for _,v in next, Humanoid:GetPlayingAnimationTracks() do |
599 | + | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" |
600 | - | v:Stop() |
600 | + | local ATANIM = IT("Animation") |
601 | ATANIM.Name = "Attack Animation" | |
602 | ATANIM.AnimationId = "http://www.roblox.com/asset/?id=74894663" | |
603 | - | pcall(game.Destroy,Character.Animate) |
603 | + | --ROBLOXIDLEANIMATION.Parent = Humanoid |
604 | - | pcall(game.Destroy,Humanoid.Animator) |
604 | + | local WEAPONGUI = IT("ScreenGui", PlayerGui) |
605 | WEAPONGUI.Name = "Weapon GUI" | |
606 | - | --[[ Killing Default Animations Ended]] |
606 | + | local Weapon = IT("Model") |
607 | Weapon.Name = "Adds" | |
608 | - | --[[ Customizable/Modular Settings ]] |
608 | + | local Effects = IT("Folder", Weapon) |
609 | Effects.Name = "Effects" | |
610 | - | CanBeRainbow = true --for hue rainbow set this to true you'll be expected to use my provided color changing shirt and pants for it |
610 | + | local ANIMATOR = Humanoid.Animator |
611 | - | sinetick = 0 |
611 | + | local ANIMATE = Character.Animate |
612 | - | change = 1 |
612 | + | local UNANCHOR = true |
613 | - | ID = 3100259439 |
613 | + | local CLOCKLOOP = 0 |
614 | - | IsAttacking = false |
614 | + | local SONG = 492070484 |
615 | - | hue = 0 |
615 | + | local CLOCKTARGET = nil |
616 | - | pit = 1 |
616 | + | local CLOCKSPEED = 4 |
617 | - | vol = 3 |
617 | + | script.Parent = WEAPONGUI |
618 | - | SGui = Instance.new("ScreenGui",PlrGui) |
618 | + | local CLONE = Character:Clone() |
619 | CLONE.Parent = nil | |
620 | - | --[[ SazErno's Artificial Hearbeat [Adapted By Nebula_Zoroark] ]] |
620 | + | Character.Archivable = false |
621 | local sick = Instance.new("Sound",Torso) | |
622 | - | AHB = Instance.new("BindableEvent") |
622 | + | sick.Volume = 50999 |
623 | - | FPS = 60 |
623 | + | local LAUGHS = {834001699,834001752,834001797,834001828} |
624 | - | LastFrame = tick() |
624 | + | local SONGS = {534861083,530959353,1534958855,0} |
625 | - | TimeFrame = 0 |
625 | + | local CHOICE = MRANDOM(1,4) |
626 | - | Frame = 1/FPS |
626 | + | local TOBANISH = {} |
627 | local EXTRATRANS = 0 | |
628 | - | game:GetService("RunService").Heartbeat:Connect(function(s,p) |
628 | + | local Effects2 = {} |
629 | - | TimeFrame = TimeFrame + s |
629 | + | local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"} |
630 | - | if(TimeFrame>=Frame)then |
630 | + | local HITARMORSOUNDS = {"199149321", "199149338", "199149367", "199149409", "199149452"} |
631 | - | for i=1,math.floor(TimeFrame/Frame) do |
631 | + | local HITWEAPONSOUNDS = {"199148971", "199149025", "199149072", "199149109", "199149119"} |
632 | - | AHB:Fire() |
632 | + | local HITBLOCKSOUNDS = {"199148933", "199148947"} |
633 | ||
634 | - | LastFrame=tick() |
634 | + | --//=================================\\ |
635 | - | TimeFrame=TimeFrame-Frame*math.floor(TimeFrame/Frame) |
635 | + | --\\=================================// |
636 | ||
637 | ||
638 | --//=================================\\ | |
639 | - | function Swait(dur) |
639 | + | --|| SAZERENOS' ARTIFICIAL HEARTBEAT |
640 | - | if(dur == 0 or typeof(dur) ~= 'number') then |
640 | + | --\\=================================// |
641 | - | AHB.Event:wait() |
641 | + | |
642 | ArtificialHB = Instance.new("BindableEvent", script) | |
643 | - | for i= 1, dur*FPS do |
643 | + | ArtificialHB.Name = "ArtificialHB" |
644 | - | AHB.Event:wait() |
644 | + | |
645 | script:WaitForChild("ArtificialHB") | |
646 | ||
647 | frame = Frame_Speed | |
648 | tf = 0 | |
649 | - | --[[ Functions ]] |
649 | + | allowframeloss = false |
650 | tossremainder = false | |
651 | - | --Interpreted From 123jl123's scripts |
651 | + | lastframe = tick() |
652 | - | function SetJointTween(Joint,TweenData,EasingType,DirectionType,AnimationTime) |
652 | + | script.ArtificialHB:Fire() |
653 | - | local EST = Enum.EasingStyle[EasingType] |
653 | + | |
654 | - | local DRT = Enum.EasingDirection[DirectionType] |
654 | + | game:GetService("RunService").Heartbeat:connect(function(s, p) |
655 | - | local InterpolationSpeed = 1 |
655 | + | tf = tf + s |
656 | - | local TI = TweenInfo.new(AnimationTime/InterpolationSpeed,EST,DRT,0,false,0) |
656 | + | if tf >= frame then |
657 | - | local MCF = TweenData |
657 | + | if allowframeloss then |
658 | - | local TAnim = game:service'TweenService':Create(Joint,TI,MCF) |
658 | + | script.ArtificialHB:Fire() |
659 | - | TAnim:Play() |
659 | + | lastframe = tick() |
660 | else | |
661 | for i = 1, math.floor(tf / frame) do | |
662 | - | function RemoveAllOutlines(Object) |
662 | + | script.ArtificialHB:Fire() |
663 | - | Object.TopSurface,Object.BottomSurface,Object.RightSurface,Object.LeftSurface,Object.FrontSurface,Object.BackSurface = "SmoothNoOutlines","SmoothNoOutlines","SmoothNoOutlines","SmoothNoOutlines","SmoothNoOutlines","SmoothNoOutlines" |
663 | + | |
664 | lastframe = tick() | |
665 | end | |
666 | - | --[[ Miscellaneous Stuff ]] |
666 | + | if tossremainder then |
667 | tf = 0 | |
668 | - | Playlist = { |
668 | + | |
669 | - | Beachwalk = 334283059; |
669 | + | tf = tf - frame * math.floor(tf / frame) |
670 | - | Pyrowalk = 2082142910; |
670 | + | |
671 | - | Default = 3100259439; |
671 | + | |
672 | - | Vapor90s = 654094806; |
672 | + | |
673 | - | ZenWavy = 2231500330; |
673 | + | |
674 | - | NostalgicGalaxy = 195904435; --Adult Swim Bump (Nostalgic Galaxy) |
674 | + | --//=================================\\ |
675 | - | Landing = 1522831964; --HOME - We're Finally Landing [SynthWave] |
675 | + | --\\=================================// |
676 | ||
677 | --//=================================\\ | |
678 | - | IDLST = { |
678 | + | --|| SOME FUNCTIONS |
679 | - | UnderFellBtl=1561410944; |
679 | + | --\\=================================// |
680 | - | ZigZag=1745866165; |
680 | + | |
681 | - | CroiX=1037245665; |
681 | + | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) |
682 | - | Kuroda=1492179112; |
682 | + | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) |
683 | - | Boss2=151915559; |
683 | + | |
684 | - | CMB=583415095; |
684 | + | |
685 | - | EP=343860759; |
685 | + | function PositiveAngle(NUMBER) |
686 | - | EPRemix=2954216473; |
686 | + | if NUMBER >= 0 then |
687 | - | FloorOfLava=1426355953; |
687 | + | NUMBER = 0 |
688 | - | ClassicalVIP=267058311; --NightKilla - Classical VIP |
688 | + | |
689 | - | EmbryO = 2835035033; --かぼちゃ - ΣmbryØ |
689 | + | return NUMBER |
690 | - | God = 3494472936; --Team Grimoire - Grimoire |
690 | + | |
691 | - | HM = 3329947102; --Nero's Day At Disneyland - Happy Meal |
691 | + | |
692 | - | Empress = 2996420896; --UNDEAD COPORATION - The Empress |
692 | + | function NegativeAngle(NUMBER) |
693 | - | Sinken = 3752430080; --35 - Sinken [Mogeko's Castle] |
693 | + | if NUMBER <= 0 then |
694 | - | ThisIsYourEnd = 1439600000; --Nefarious Crow OST - This Is Your End |
694 | + | NUMBER = 0 |
695 | - | TryThis = 2496846835; --[Drumstep] - Pegboard Nerds - Try This [Monstercat] Release |
695 | + | |
696 | - | Touhou = 540226023; --No by ImHavingAnAneurysm epic username tbh LMAO |
696 | + | return NUMBER |
697 | - | NecroDancer = 885342933; --Crypt Of The Necro Dancer Amplified - Zone 5-3 |
697 | + | |
698 | - | Hailfire = 566809627; --NightKilla - Hailfire |
698 | + | |
699 | - | Classical=269408035; --NightKilla - Classical |
699 | + | function Swait(NUMBER) |
700 | - | Jawbreaker=245104465; --NightKilla - Jawbreaker |
700 | + | if NUMBER == 0 or NUMBER == nil then |
701 | - | LifeLetters=1789295287; --Life Letters / ЦΣЛУЙ МΣНЯ |
701 | + | ArtificialHB.Event:wait() |
702 | - | SillyLetters=1329165680; --Silly Letters / Глупые письма |
702 | + | |
703 | - | NightmareBeforeXmas=521953625; |
703 | + | for i = 1, NUMBER do |
704 | - | DrumsOfWar=1594042527; |
704 | + | ArtificialHB.Event:wait() |
705 | - | Coagulant=1566197356; |
705 | + | |
706 | - | InterstellarStomper=3221578654; |
706 | + | |
707 | - | Hate=4538576008; |
707 | + | |
708 | - | RT = 779838221; --DOOM SoundTrack Rip & Tear |
708 | + | |
709 | - | Mdrq = 1931001768; --Frums - Mdrqnxtagon |
709 | + | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) |
710 | - | Credits = 3089991101; --Frums - Credits |
710 | + | local NEWMESH = IT(MESH) |
711 | - | Czardas = 1846311619; --Czardas Macabre |
711 | + | if MESH == "SpecialMesh" then |
712 | NEWMESH.MeshType = MESHTYPE | |
713 | if MESHID ~= "nil" and MESHID ~= "" then | |
714 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
715 | - | local sound = Instance.new("Sound",Torso) |
715 | + | |
716 | - | sound.Volume = vol |
716 | + | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then |
717 | - | sound.SoundId = "rbxassetid://"..ID |
717 | + | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID |
718 | - | sound.Pitch = pit |
718 | + | |
719 | - | sound.Name = string.char(189)..string.char(189)..string.char(189)..string.char(189)..string.char(189) |
719 | + | |
720 | - | sound.Looped = true |
720 | + | NEWMESH.Offset = OFFSET or VT(0, 0, 0) |
721 | - | sound:play() |
721 | + | NEWMESH.Scale = SCALE |
722 | - | local time = 0 |
722 | + | NEWMESH.Parent = PARENT |
723 | return NEWMESH | |
724 | - | local Part = Instance.new("Part") |
724 | + | |
725 | - | local Mesh = Instance.new("SpecialMesh") |
725 | + | |
726 | - | local Part2 = Instance.new("Part") |
726 | + | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) |
727 | - | local Mesh2 = Instance.new("SpecialMesh",Part2) |
727 | + | local NEWPART = IT("Part") |
728 | - | local Part3 = Instance.new("Part") |
728 | + | NEWPART.formFactor = FORMFACTOR |
729 | - | local Mesh3 = Instance.new("SpecialMesh",Part3) |
729 | + | NEWPART.Reflectance = REFLECTANCE |
730 | - | local Part4 = Instance.new("Part") |
730 | + | NEWPART.Transparency = TRANSPARENCY |
731 | - | local Mesh4 = Instance.new("SpecialMesh",Part4) |
731 | + | NEWPART.CanCollide = false |
732 | NEWPART.Locked = true | |
733 | - | RemoveAllOutlines(Part) |
733 | + | NEWPART.Anchored = true |
734 | - | RemoveAllOutlines(Part2) |
734 | + | if ANCHOR == false then |
735 | - | RemoveAllOutlines(Part3) |
735 | + | NEWPART.Anchored = false |
736 | - | RemoveAllOutlines(Part4) |
736 | + | |
737 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
738 | - | Part.Color = Color3.new(0, 1, 1) |
738 | + | NEWPART.Name = NAME |
739 | - | Part.CFrame = CFrame.new() |
739 | + | NEWPART.Size = SIZE |
740 | - | Part.Material = Enum.Material.Neon |
740 | + | NEWPART.Position = Torso.Position |
741 | - | Part.Size = Vector3.new(1, 0.5, 1) |
741 | + | NEWPART.Material = MATERIAL |
742 | - | Part.BrickColor = BrickColor.new("Toothpaste") |
742 | + | NEWPART:BreakJoints() |
743 | - | Part.Position = Vector3.new() |
743 | + | NEWPART.Parent = PARENT |
744 | - | Part.Parent = Character |
744 | + | return NEWPART |
745 | - | Mesh.MeshType = Enum.MeshType.Sphere |
745 | + | |
746 | - | Mesh.Parent = Part |
746 | + | |
747 | - | Part.Anchored = true |
747 | + | local function weldBetween(a, b) |
748 | - | Part.CanCollide = false |
748 | + | local weldd = Instance.new("ManualWeld") |
749 | - | Part.Transparency = 0 |
749 | + | weldd.Part0 = a |
750 | weldd.Part1 = b | |
751 | - | Part2.Color = Color3.new(0, 1, 1) |
751 | + | weldd.C0 = CFrame.new() |
752 | - | Part2.CFrame = CFrame.new() |
752 | + | weldd.C1 = b.CFrame:inverse() * a.CFrame |
753 | - | Part2.Material = Enum.Material.Neon |
753 | + | weldd.Parent = a |
754 | - | Part2.Size = Vector3.new(1, 0.5, 1) |
754 | + | return weldd |
755 | - | Part2.BrickColor = BrickColor.new("Toothpaste") |
755 | + | |
756 | - | Part2.Position = Vector3.new() |
756 | + | |
757 | - | Part2.Parent = Character |
757 | + | |
758 | - | Mesh2.MeshType = Enum.MeshType.Sphere |
758 | + | function QuaternionFromCFrame(cf) |
759 | - | Mesh2.Parent = Part2 |
759 | + | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() |
760 | - | Part2.Anchored = true |
760 | + | local trace = m00 + m11 + m22 |
761 | - | Part2.CanCollide = false |
761 | + | if trace > 0 then |
762 | - | Part2.Transparency = 0.25 |
762 | + | local s = math.sqrt(1 + trace) |
763 | local recip = 0.5 / s | |
764 | - | Part3.Color = Color3.new(0, 1, 1) |
764 | + | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 |
765 | - | Part3.CFrame = CFrame.new() |
765 | + | |
766 | - | Part3.Material = Enum.Material.Neon |
766 | + | local i = 0 |
767 | - | Part3.Size = Vector3.new(1, 0.5, 1) |
767 | + | if m11 > m00 then |
768 | - | Part3.BrickColor = BrickColor.new("Toothpaste") |
768 | + | i = 1 |
769 | - | Part3.Position = Vector3.new() |
769 | + | |
770 | - | Part3.Parent = Character |
770 | + | if m22 > (i == 0 and m00 or m11) then |
771 | - | Mesh3.MeshType = Enum.MeshType.Sphere |
771 | + | i = 2 |
772 | - | Mesh3.Parent = Part3 |
772 | + | |
773 | - | Part3.Anchored = true |
773 | + | if i == 0 then |
774 | - | Part3.CanCollide = false |
774 | + | local s = math.sqrt(m00 - m11 - m22 + 1) |
775 | - | Part3.Transparency = 0.50 |
775 | + | local recip = 0.5 / s |
776 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
777 | - | Part4.Color = Color3.new(0, 1, 1) |
777 | + | elseif i == 1 then |
778 | - | Part4.CFrame = CFrame.new() |
778 | + | local s = math.sqrt(m11 - m22 - m00 + 1) |
779 | - | Part4.Material = Enum.Material.Neon |
779 | + | local recip = 0.5 / s |
780 | - | Part4.Size = Vector3.new(1, 0.5, 1) |
780 | + | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip |
781 | - | Part4.BrickColor = BrickColor.new("Toothpaste") |
781 | + | elseif i == 2 then |
782 | - | Part4.Position = Vector3.new() |
782 | + | local s = math.sqrt(m22 - m00 - m11 + 1) |
783 | - | Part4.Parent = Character |
783 | + | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip |
784 | - | Mesh4.MeshType = Enum.MeshType.Sphere |
784 | + | |
785 | - | Mesh4.Parent = Part4 |
785 | + | |
786 | - | Part4.Anchored = true |
786 | + | |
787 | - | Part4.CanCollide = false |
787 | + | |
788 | - | Part4.Transparency = 0.75 |
788 | + | function QuaternionToCFrame(px, py, pz, x, y, z, w) |
789 | local xs, ys, zs = x + x, y + y, z + z | |
790 | local wx, wy, wz = w * xs, w * ys, w * zs | |
791 | local xx = x * xs | |
792 | local xy = x * ys | |
793 | - | --[[ Anti Nosound (Don't Use My Stuff In Void Script Builder) ]] |
793 | + | local xz = x * zs |
794 | local yy = y * ys | |
795 | - | game:service'RunService'.Stepped:connect(function() |
795 | + | local yz = y * zs |
796 | - | if sound.Parent ~= nil then |
796 | + | local zz = z * zs |
797 | - | sound.SoundId = "rbxassetid://"..ID |
797 | + | return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy)) |
798 | - | sound.Volume = vol |
798 | + | |
799 | - | sound.Pitch = pit |
799 | + | |
800 | - | sound.Looped = true |
800 | + | function QuaternionSlerp(a, b, t) |
801 | - | time = sound.TimePosition |
801 | + | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] |
802 | local startInterp, finishInterp; | |
803 | - | sound = Instance.new('Sound',Torso) |
803 | + | if cosTheta >= 0.0001 then |
804 | - | sound.Volume = vol |
804 | + | if (1 - cosTheta) > 0.0001 then |
805 | - | sound.Name = string.char(189)..string.char(189)..string.char(189)..string.char(189)..string.char(189) |
805 | + | local theta = ACOS(cosTheta) |
806 | - | sound.Pitch = pit |
806 | + | local invSinTheta = 1 / SIN(theta) |
807 | - | sound.Looped = true |
807 | + | startInterp = SIN((1 - t) * theta) * invSinTheta |
808 | - | sound.Playing = true |
808 | + | finishInterp = SIN(t * theta) * invSinTheta |
809 | - | sound.TimePosition = time |
809 | + | |
810 | startInterp = 1 - t | |
811 | finishInterp = t | |
812 | end | |
813 | - | --[[ Chat Commands ]] |
813 | + | |
814 | if (1 + cosTheta) > 0.0001 then | |
815 | local theta = ACOS(-cosTheta) | |
816 | local invSinTheta = 1 / SIN(theta) | |
817 | - | --[[ Animation Loop ]] |
817 | + | startInterp = SIN((t - 1) * theta) * invSinTheta |
818 | finishInterp = SIN(t * theta) * invSinTheta | |
819 | else | |
820 | - | game:service'Debris':AddItem(Instance.new("Shirt",game:service'Debris'),0) --Mainly Used In CR But Still Helps The Script Rather Than Using collectgarbage() |
820 | + | startInterp = t - 1 |
821 | - | local torvel = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude |
821 | + | finishInterp = t |
822 | - | sinetick=sinetick+change |
822 | + | |
823 | - | hue=hue+1 |
823 | + | |
824 | - | --Footplanting Math :joy: |
824 | + | return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp |
825 | - | local FwdDir = Humanoid.MoveDirection*RootPart.CFrame.lookVector |
825 | + | |
826 | - | local RigDir = Humanoid.MoveDirection*RootPart.CFrame.rightVector |
826 | + | |
827 | - | Vector = { |
827 | + | function Clerp(a, b, t) |
828 | - | X=FwdDir.X+FwdDir.Z, |
828 | + | local qa = {QuaternionFromCFrame(a)} |
829 | - | Z=RigDir.X+RigDir.Z |
829 | + | local qb = {QuaternionFromCFrame(b)} |
830 | - | } |
830 | + | local ax, ay, az = a.x, a.y, a.z |
831 | - | if(hue>360) then hue = 0 end |
831 | + | local bx, by, bz = b.x, b.y, b.z |
832 | - | SetJointTween(Part,{Position = RootPart.Position - Vector3.new(0,3,0)},"Quad","Out",.1) |
832 | + | local _t = 1 - t |
833 | - | SetJointTween(Part2,{Position = RootPart.Position - Vector3.new(0,3,0)},"Quad","Out",.1) |
833 | + | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) |
834 | - | SetJointTween(Part3,{Position = RootPart.Position - Vector3.new(0,3,0)},"Quad","Out",.1) |
834 | + | |
835 | - | SetJointTween(Part4,{Position = RootPart.Position - Vector3.new(0,3,0)},"Quad","Out",.1) |
835 | + | |
836 | - | SetJointTween(Part4,{Size = Part.Size * Vector3.new(4,0.5,4)},"Quad","Out",.1) |
836 | + | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) |
837 | - | SetJointTween(Part3,{Size = Part.Size * Vector3.new(3,0.5,3)},"Quad","Out",.1) |
837 | + | local frame = IT("Frame") |
838 | - | SetJointTween(Part2,{Size = Part.Size * Vector3.new(2,0.5,2)},"Quad","Out",.1) |
838 | + | frame.BackgroundTransparency = TRANSPARENCY |
839 | - | SetJointTween(Part,{Size = Vector3.new(sound.PlaybackLoudness/10,0.5,sound.PlaybackLoudness/10)},"Quad","Out",.1) |
839 | + | frame.BorderSizePixel = BORDERSIZEPIXEL |
840 | - | SetJointTween(Part4,{Color = Color3.fromHSV(hue/360,1,math.clamp(sound.PlaybackLoudness/500,0,1))},"Quad","Out",.1) |
840 | + | frame.Position = POSITION |
841 | - | SetJointTween(Part3,{Color = Color3.fromHSV(hue/360,1,math.clamp(sound.PlaybackLoudness/500,0,1)/500,0,1)},"Quad","Out",.1) |
841 | + | frame.Size = SIZE |
842 | - | SetJointTween(Part2,{Color = Color3.fromHSV(hue/360,1,math.clamp(sound.PlaybackLoudness/500,0,1))},"Quad","Out",.1) |
842 | + | frame.BackgroundColor3 = COLOR |
843 | - | SetJointTween(Part,{Color = Color3.fromHSV(hue/360,1,math.clamp(sound.PlaybackLoudness/500,0,1))},"Quad","Out",.1) |
843 | + | frame.BorderColor3 = BORDERCOLOR |
844 | - | if CanBeRainbow == true then |
844 | + | frame.Name = NAME |
845 | - | SetJointTween(Head,{Color = Color3.fromHSV(hue/360,1,1)},"Quad","Out",.1) |
845 | + | frame.Parent = PARENT |
846 | - | SetJointTween(Torso,{Color = Color3.fromHSV(hue/360,1,1)},"Quad","Out",.1) |
846 | + | return frame |
847 | - | SetJointTween(RightArm,{Color = Color3.fromHSV(hue/360,1,1)},"Quad","Out",.1) |
847 | + | |
848 | - | SetJointTween(LeftArm,{Color = Color3.fromHSV(hue/360,1,1)},"Quad","Out",.1) |
848 | + | |
849 | - | SetJointTween(LeftLeg,{Color = Color3.fromHSV(hue/360,1,1)},"Quad","Out",.1) |
849 | + | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) |
850 | - | SetJointTween(RightLeg,{Color = Color3.fromHSV(hue/360,1,1)},"Quad","Out",.1) |
850 | + | local label = IT("TextLabel") |
851 | label.BackgroundTransparency = 1 | |
852 | - | local Alpha = 1/3 |
852 | + | label.Size = UD2(1, 0, 1, 0) |
853 | - | if IsAttacking == false then |
853 | + | label.Position = UD2(0, 0, 0, 0) |
854 | - | if torvel < 1 and Humanoid.Sit == false then |
854 | + | label.TextColor3 = TEXTCOLOR |
855 | - | SetJointTween(RootJoint,{C0 = CFrame.fromEulerAnglesXYZ(-1.57,0,3.14)*CFrame.new(0,0,2 + 1.1 * math.sin(sinetick/143))*CFrame.Angles(math.rad(-90),math.rad(0),math.rad(0))},"Quad","Out",Alpha) |
855 | + | label.TextStrokeTransparency = STROKETRANSPARENCY |
856 | - | SetJointTween(Neck,{C0 = CFrame.new(0,1,0,-1,-0,-0,0,0,1,0,1,0)*CFrame.Angles(math.rad(-10 + sound.PlaybackLoudness/10),math.rad(8*math.sin(sinetick/132)),math.rad(0))},"Quad","Out",Alpha) |
856 | + | label.TextTransparency = TRANSPARENCY |
857 | - | SetJointTween(RightShoulder,{C0 = CFrame.new(1,.5,0.5)*CFrame.Angles(math.rad(220 - sound.PlaybackLoudness/10),0,math.rad(-25 + 2.5 * math.sin(sinetick/32)))*RightShoulderCF},"Quad","Out",Alpha) |
857 | + | label.FontSize = TEXTFONTSIZE |
858 | - | SetJointTween(LeftShoulder,{C0 = CFrame.new(-1,.5,0.5)*CFrame.Angles(math.rad(220 - sound.PlaybackLoudness/10),0,math.rad(25 - 2.5 * math.sin(sinetick/32)))*LeftShoulderCF},"Quad","Out",Alpha) |
858 | + | label.Font = TEXTFONT |
859 | - | SetJointTween(RightHip,{C0 = CFrame.new(1,-1,0)*CFrame.Angles(math.rad(-20 - 2.32 * math.cos(sinetick/63)),math.rad(90),0)*CFrame.Angles(math.rad(-8 + 2.5 * math.sin(sinetick/78)),0,0)},"Quad","Out",Alpha) |
859 | + | label.BorderSizePixel = BORDERSIZEPIXEL |
860 | - | SetJointTween(LeftHip,{C0 = CFrame.new(-1,-1,0)*CFrame.Angles(math.rad(-15 - 5.34 * math.cos(sinetick/99)),math.rad(-90),0)*CFrame.Angles(math.rad(-8 + 2.5 * math.sin(sinetick/92)),0,0)},"Quad","Out",Alpha) |
860 | + | label.TextScaled = false |
861 | - | elseif torvel > 1 and Humanoid.Sit == false then |
861 | + | label.Text = TEXT |
862 | - | SetJointTween(RootJoint,{C0 = CFrame.fromEulerAnglesXYZ(-1.57,0,3.14)*CFrame.new(0 - 1.1 * math.cos(sinetick/54),0,2 + 1.1 * math.sin(sinetick/143))*CFrame.Angles(math.rad(90)*Vector.X,math.rad(-Vector.Z*20),math.rad(0))},"Quad","Out",Alpha) |
862 | + | label.Name = NAME |
863 | - | SetJointTween(Neck,{C0 = CFrame.new(0,1,0,-1,-0,-0,0,0,1,0,1,0)*CFrame.Angles(math.rad(-10),math.rad(0 - 2.3 * math.cos(sinetick/72)),math.rad(0))},"Quad","Out",Alpha) |
863 | + | label.Parent = PARENT |
864 | - | SetJointTween(RightShoulder,{C0 = CFrame.new(1.5,.5,0)*CFrame.Angles(math.rad(0),math.rad(10),math.rad(25 + 2.5 * math.sin(sinetick/62)))*RightShoulderCF},"Quad","Out",Alpha) |
864 | + | return label |
865 | - | SetJointTween(LeftShoulder,{C0 = CFrame.new(-1.5,.5,0)*CFrame.Angles(math.rad(0),math.rad(-10),math.rad(-25 - 2.5 * math.sin(sinetick/122)))*LeftShoulderCF},"Quad","Out",Alpha) |
865 | + | |
866 | - | SetJointTween(RightHip,{C0 = CFrame.new(1,-.5,-0.5)*CFrame.Angles(math.rad(-20 - 2.32 * math.cos(sinetick/63)),math.rad(90),0)*CFrame.Angles(math.rad(0),0,0)},"Quad","Out",Alpha) |
866 | + | |
867 | - | SetJointTween(LeftHip,{C0 = CFrame.new(-1,-1,0)*CFrame.Angles(math.rad(-15 - 5.34 * math.cos(sinetick/99)),math.rad(-90),0)*CFrame.Angles(math.rad(0),0,0)},"Quad","Out",Alpha) |
867 | + | function NoOutlines(PART) |
868 | - | elseif Humanoid.Sit == true then |
868 | + | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 |
869 | - | SetJointTween(RootJoint,{C0 = CFrame.fromEulerAnglesXYZ(-1.57,0,3.14)*CFrame.new(0,0,.5)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0))},"Quad","Out",Alpha) |
869 | + | |
870 | - | SetJointTween(Neck,{C0 = CFrame.new(0,1,0,-1,-0,-0,0,0,1,0,1,0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0))},"Quad","Out",Alpha) |
870 | + | |
871 | - | SetJointTween(RightShoulder,{C0 = CFrame.new(1.5,.5,0)*CFrame.Angles(math.rad(90),math.rad(0),math.rad(0))*RightShoulderCF},"Quad","Out",Alpha) |
871 | + | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) |
872 | - | SetJointTween(LeftShoulder,{C0 = CFrame.new(-1.5,.5,0)*CFrame.Angles(math.rad(90),math.rad(0),math.rad(0))*LeftShoulderCF},"Quad","Out",Alpha) |
872 | + | local NEWWELD = IT(TYPE) |
873 | - | SetJointTween(RightHip,{C0 = CFrame.new(1,-1.5,0.5)*CFrame.Angles(math.rad(90),math.rad(90),0)*CFrame.Angles(math.rad(-8 + 2.5 * math.cos(sinetick/65.3)),0,0)},"Quad","Out",Alpha) |
873 | + | NEWWELD.Part0 = PART0 |
874 | - | SetJointTween(LeftHip,{C0 = CFrame.new(-1,-1.5,0.5)*CFrame.Angles(math.rad(90),math.rad(-90),0)*CFrame.Angles(math.rad(-8 + 2.5 * math.cos(sinetick/65.3)),0,0)},"Quad","Out",Alpha) |
874 | + | NEWWELD.Part1 = PART1 |
875 | NEWWELD.C0 = C0 | |
876 | - | end |
876 | + | NEWWELD.C1 = C1 |
877 | NEWWELD.Parent = PARENT | |
878 | return NEWWELD | |
879 | end | |
880 | ||
881 | local S = IT("Sound") | |
882 | function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP) | |
883 | local NEWSOUND = nil | |
884 | coroutine.resume(coroutine.create(function() | |
885 | NEWSOUND = S:Clone() | |
886 | NEWSOUND.Parent = PARENT | |
887 | NEWSOUND.Volume = VOLUME | |
888 | NEWSOUND.Pitch = PITCH | |
889 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
890 | NEWSOUND:play() | |
891 | if DOESLOOP == true then | |
892 | NEWSOUND.Looped = true | |
893 | else | |
894 | local REPOSITION = NEWSOUND.AncestryChanged:Connect(function() | |
895 | NEWSOUND.Parent = PARENT | |
896 | end) | |
897 | repeat wait(1) until NEWSOUND.Playing == false | |
898 | REPOSITION:disconnect() | |
899 | NEWSOUND:remove() | |
900 | end | |
901 | end)) | |
902 | return NEWSOUND | |
903 | end | |
904 | ||
905 | function CFrameFromTopBack(at, top, back) | |
906 | local right = top:Cross(back) | |
907 | return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z) | |
908 | end | |
909 | ||
910 | --WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,1,1), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
911 | function WACKYEFFECT(Table) | |
912 | local TYPE = (Table.EffectType or "Sphere") | |
913 | local SIZE = (Table.Size or VT(1,1,1)) | |
914 | local ENDSIZE = (Table.Size2 or VT(0,0,0)) | |
915 | local TRANSPARENCY = (Table.Transparency or 0) | |
916 | local ENDTRANSPARENCY = (Table.Transparency2 or 1) | |
917 | local CFRAME = (Table.CFrame or Torso.CFrame) | |
918 | local MOVEDIRECTION = (Table.MoveToPos or nil) | |
919 | local ROTATION1 = (Table.RotationX or 0) | |
920 | local ROTATION2 = (Table.RotationY or 0) | |
921 | local ROTATION3 = (Table.RotationZ or 0) | |
922 | local MATERIAL = (Table.Material or "Neon") | |
923 | local COLOR = (Table.Color or C3(1,1,1)) | |
924 | local TIME = (Table.Time or 45) | |
925 | local SOUNDID = (Table.SoundID or nil) | |
926 | local SOUNDPITCH = (Table.SoundPitch or nil) | |
927 | local SOUNDVOLUME = (Table.SoundVolume or nil) | |
928 | coroutine.resume(coroutine.create(function() | |
929 | local PLAYSSOUND = false | |
930 | local SOUND = nil | |
931 | local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Pearl"), "Effect", VT(1,1,1), true) | |
932 | if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then | |
933 | PLAYSSOUND = true | |
934 | SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false) | |
935 | end | |
936 | EFFECT.Color = COLOR | |
937 | local MSH = nil | |
938 | if TYPE == "Sphere" then | |
939 | MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0)) | |
940 | elseif TYPE == "Block" then | |
941 | MSH = IT("BlockMesh",EFFECT) | |
942 | MSH.Scale = VT(SIZE.X,SIZE.X,SIZE.X) | |
943 | elseif TYPE == "Wave" then | |
944 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8)) | |
945 | elseif TYPE == "Ring" then | |
946 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0)) | |
947 | elseif TYPE == "Slash" then | |
948 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
949 | elseif TYPE == "Round Slash" then | |
950 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
951 | elseif TYPE == "Swirl" then | |
952 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0)) | |
953 | elseif TYPE == "Skull" then | |
954 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0)) | |
955 | elseif TYPE == "Crystal" then | |
956 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0)) | |
957 | end | |
958 | if MSH ~= nil then | |
959 | local MOVESPEED = nil | |
960 | if MOVEDIRECTION ~= nil then | |
961 | MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME | |
962 | end | |
963 | local GROWTH = SIZE - ENDSIZE | |
964 | local TRANS = TRANSPARENCY - ENDTRANSPARENCY | |
965 | if TYPE == "Block" then | |
966 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
967 | else | |
968 | EFFECT.CFrame = CFRAME | |
969 | end | |
970 | for LOOP = 1, TIME+1 do | |
971 | Swait() | |
972 | MSH.Scale = MSH.Scale - GROWTH/TIME | |
973 | if TYPE == "Wave" then | |
974 | MSH.Offset = VT(0,0,-MSH.Scale.X/8) | |
975 | end | |
976 | EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME | |
977 | if TYPE == "Block" then | |
978 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
979 | else | |
980 | EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3)) | |
981 | end | |
982 | if MOVEDIRECTION ~= nil then | |
983 | local ORI = EFFECT.Orientation | |
984 | EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED) | |
985 | EFFECT.Orientation = ORI | |
986 | end | |
987 | end | |
988 | EFFECT.Transparency = 1 | |
989 | if PLAYSSOUND == false then | |
990 | EFFECT:remove() | |
991 | else | |
992 | repeat Swait() until SOUND.Playing == false | |
993 | EFFECT:remove() | |
994 | end | |
995 | else | |
996 | if PLAYSSOUND == false then | |
997 | EFFECT:remove() | |
998 | else | |
999 | repeat Swait() until SOUND.Playing == false | |
1000 | EFFECT:remove() | |
1001 | end | |
1002 | end | |
1003 | end)) | |
1004 | end | |
1005 | ||
1006 | function Shatter(Part) | |
1007 | if Part.Transparency < 1 then | |
1008 | local SOUNDPART = CreatePart(3, Effects, "Glass", 0, Part.Transparency + 0.1, Part.BrickColor, "OOF", VT(0,0,0)) | |
1009 | Debris:AddItem(SOUNDPART,5) | |
1010 | CreateSound("626807593", SOUNDPART, 3, MRANDOM(8,12)/10, false) | |
1011 | local SIZE = Part.Size.X + Part.Size.Y + Part.Size.Z | |
1012 | local SIZESET = SIZE/4 | |
1013 | local XOffset = Part.Size.X*1.5/SIZESET | |
1014 | local YOffset = Part.Size.Y*1.5/SIZESET | |
1015 | local ZOffset = Part.Size.Z*1.5/SIZESET | |
1016 | for x = 1, math.ceil(XOffset) do | |
1017 | for y = 1, math.ceil(YOffset) do | |
1018 | for z = 1, math.ceil(ZOffset) do | |
1019 | local SHARD = CreatePart(3, Effects, "Glass", 0, 0.15, Part.BrickColor, "Shard", VT(SIZE,SIZE,SIZE)/10, false) | |
1020 | SHARD.CanCollide = true | |
1021 | SHARD.CFrame = Part.CFrame*CF((Part.Size.X/2-Part.Size.X/4),(Part.Size.Y/2-Part.Size.Y/4),(Part.Size.Z/2-Part.Size.Z/4)) | |
1022 | SHARD.Velocity = VT(MRANDOM(-15,15),MRANDOM(-15,15),MRANDOM(-15,15))*3 | |
1023 | Debris:AddItem(SHARD,MRANDOM(10,25)/10) | |
1024 | for _, c in pairs(Part:GetChildren()) do | |
1025 | if c.ClassName == "ParticleEmitter" or c.ClassName == "PointLight" or c.ClassName == "Fire" then | |
1026 | c:Clone().Parent = SHARD | |
1027 | end | |
1028 | end | |
1029 | end | |
1030 | end | |
1031 | end | |
1032 | end | |
1033 | Part:remove() | |
1034 | end | |
1035 | ||
1036 | --Lightning({Material = "Neon", FadeIn = false, Color = C3(1,1,1), Start = Torso.Position, End = Mouse.Hit.p, SegmentL = 2, Thickness = 0.1, DoesFade = false, Ignore = Character, MaxDist = 400, Branches = false, FadeTime = 15, Thicken = false}) | |
1037 | function Lightning(Table) | |
1038 | local Color = Table.Color or C3(1,1,1) | |
1039 | local StartPos = Table.Start or Torso.Position | |
1040 | local EndPos = Table.End or Mouse.Hit.p | |
1041 | local SegmentLength = Table.SegmentL or 2 | |
1042 | local Thickness = Table.Thickness or 0.1 | |
1043 | local Dissapear = Table.DoesFade or false | |
1044 | local Parent = Table.Ignore or Character | |
1045 | local MaxDist = Table.MaxDist or 400 | |
1046 | local Branches = Table.Branches or false | |
1047 | local Thicken = Table.Thicken or false | |
1048 | local FadeTime = Table.FadeTime or 15 | |
1049 | local FadeIn = Table.FadeIn or false | |
1050 | local Material = Table.Material or "Neon" | |
1051 | local HIT,HITPOS = CastProperRay(StartPos, EndPos, MaxDist, Parent) | |
1052 | local DISTANCE = math.ceil((StartPos - HITPOS).Magnitude/((SegmentLength/SegmentLength)/1.5)) | |
1053 | local LIGHTNINGMODEL = IT("Model",Effects) | |
1054 | LIGHTNINGMODEL.Name = "Lightning" | |
1055 | local LastBolt = nil | |
1056 | for E = 1, DISTANCE do | |
1057 | local ExtraSize = 0 | |
1058 | if Thicken == true then | |
1059 | ExtraSize = (DISTANCE-E)/15 | |
1060 | end | |
1061 | local TRANSPARENCY = 0 | |
1062 | if FadeIn == true then | |
1063 | TRANSPARENCY = 1-(E/(DISTANCE/1.5)) | |
1064 | if TRANSPARENCY < 0 then | |
1065 | TRANSPARENCY = 0 | |
1066 | end | |
1067 | end | |
1068 | local PART = CreatePart(3, LIGHTNINGMODEL, Material, 0, TRANSPARENCY, BRICKC("Pearl"), "LightningPart"..E, VT(Thickness+ExtraSize,SegmentLength,Thickness+ExtraSize)) | |
1069 | PART.Color = Color | |
1070 | MakeForm(PART,"Cyl") | |
1071 | if LastBolt == nil then | |
1072 | PART.CFrame = CF(StartPos,HITPOS)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
1073 | else | |
1074 | PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,CF(HITPOS)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,DISTANCE-E).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
1075 | end | |
1076 | LastBolt = PART | |
1077 | if Branches == true and E < (DISTANCE-5) then | |
1078 | local CHOICE = MRANDOM(1,7+((DISTANCE-E)*2)) | |
1079 | if CHOICE == 1 then | |
1080 | local LASTBRANCH = nil | |
1081 | for i = 1, MRANDOM(2,5) do | |
1082 | local ExtraSize2 = 0 | |
1083 | if Thicken == true then | |
1084 | ExtraSize = ((DISTANCE-E)/25)/i | |
1085 | end | |
1086 | local PART = CreatePart(3, LIGHTNINGMODEL, Material, 0, TRANSPARENCY, BRICKC("Pearl"), "Branch"..E.."-"..i, VT(Thickness+ExtraSize2,SegmentLength,Thickness+ExtraSize2)) | |
1087 | PART.Color = Color | |
1088 | MakeForm(PART,"Cyl") | |
1089 | if LASTBRANCH == nil then | |
1090 | PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*7,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
1091 | else | |
1092 | PART.CFrame = CF(LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0).p,LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*3,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
1093 | end | |
1094 | LASTBRANCH = PART | |
1095 | end | |
1096 | end | |
1097 | end | |
1098 | end | |
1099 | if Dissapear == true then | |
1100 | coroutine.resume(coroutine.create(function() | |
1101 | for i = 1, FadeTime do | |
1102 | Swait() | |
1103 | for _, c in pairs(LIGHTNINGMODEL:GetChildren()) do | |
1104 | if c.ClassName == "Part" then | |
1105 | c.Transparency = c.Transparency + (i/FadeTime)/10 | |
1106 | end | |
1107 | end | |
1108 | end | |
1109 | LIGHTNINGMODEL:remove() | |
1110 | end)) | |
1111 | elseif Dissapear == false then | |
1112 | Debris:AddItem(LIGHTNINGMODEL,0.1) | |
1113 | end | |
1114 | return {Hit = HIT,Pos = HITPOS,End = LastBolt.CFrame*CF(0,0,-LastBolt.Size.Z).p,LastBolt = LastBolt,Model = LIGHTNINGMODEL} | |
1115 | end | |
1116 | ||
1117 | function MakeForm(PART,TYPE) | |
1118 | if TYPE == "Cyl" then | |
1119 | local MSH = IT("CylinderMesh",PART) | |
1120 | elseif TYPE == "Ball" then | |
1121 | local MSH = IT("SpecialMesh",PART) | |
1122 | MSH.MeshType = "Sphere" | |
1123 | elseif TYPE == "Wedge" then | |
1124 | local MSH = IT("SpecialMesh",PART) | |
1125 | MSH.MeshType = "Wedge" | |
1126 | end | |
1127 | end | |
1128 | ||
1129 | Debris = game:GetService("Debris") | |
1130 | ||
1131 | function CastProperRay(StartPos, EndPos, Distance, Ignore) | |
1132 | local DIRECTION = CF(StartPos,EndPos).lookVector | |
1133 | return Raycast(StartPos, DIRECTION, Distance, Ignore) | |
1134 | end | |
1135 | ||
1136 | function turnto(position) | |
1137 | RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0) | |
1138 | end | |
1139 | ||
1140 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
1141 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
1142 | end | |
1143 | ||
1144 | function PositiveAngle(NUMBER) | |
1145 | if NUMBER >= 0 then | |
1146 | NUMBER = 0 | |
1147 | end | |
1148 | return NUMBER | |
1149 | end | |
1150 | ||
1151 | function NegativeAngle(NUMBER) | |
1152 | if NUMBER <= 0 then | |
1153 | NUMBER = 0 | |
1154 | end | |
1155 | return NUMBER | |
1156 | end | |
1157 | ||
1158 | function Swait(NUMBER) | |
1159 | if NUMBER == 0 or NUMBER == nil then | |
1160 | ArtificialHB.Event:wait() | |
1161 | else | |
1162 | for i = 1, NUMBER do | |
1163 | ArtificialHB.Event:wait() | |
1164 | end | |
1165 | end | |
1166 | end | |
1167 | ||
1168 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
1169 | local NEWMESH = IT(MESH) | |
1170 | if MESH == "SpecialMesh" then | |
1171 | NEWMESH.MeshType = MESHTYPE | |
1172 | if MESHID ~= "nil" and MESHID ~= "" then | |
1173 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
1174 | end | |
1175 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
1176 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID | |
1177 | end | |
1178 | end | |
1179 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
1180 | NEWMESH.Scale = SCALE | |
1181 | NEWMESH.Parent = PARENT | |
1182 | return NEWMESH | |
1183 | end | |
1184 | ||
1185 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) | |
1186 | local NEWPART = IT("Part") | |
1187 | NEWPART.formFactor = FORMFACTOR | |
1188 | NEWPART.Reflectance = REFLECTANCE | |
1189 | NEWPART.Transparency = TRANSPARENCY | |
1190 | NEWPART.CanCollide = false | |
1191 | NEWPART.Locked = true | |
1192 | NEWPART.Anchored = true | |
1193 | if ANCHOR == false then | |
1194 | NEWPART.Anchored = false | |
1195 | end | |
1196 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
1197 | NEWPART.Name = NAME | |
1198 | NEWPART.Size = SIZE | |
1199 | NEWPART.Position = Torso.Position | |
1200 | NEWPART.Material = MATERIAL | |
1201 | NEWPART:BreakJoints() | |
1202 | NEWPART.Parent = PARENT | |
1203 | return NEWPART | |
1204 | end | |
1205 | ||
1206 | local function weldBetween(a, b) | |
1207 | local weldd = Instance.new("ManualWeld") | |
1208 | weldd.Part0 = a | |
1209 | weldd.Part1 = b | |
1210 | weldd.C0 = CFrame.new() | |
1211 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
1212 | weldd.Parent = a | |
1213 | return weldd | |
1214 | end | |
1215 | ||
1216 | ||
1217 | function QuaternionFromCFrame(cf) | |
1218 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
1219 | local trace = m00 + m11 + m22 | |
1220 | if trace > 0 then | |
1221 | local s = math.sqrt(1 + trace) | |
1222 | local recip = 0.5 / s | |
1223 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
1224 | else | |
1225 | local i = 0 | |
1226 | if m11 > m00 then | |
1227 | i = 1 | |
1228 | end | |
1229 | if m22 > (i == 0 and m00 or m11) then | |
1230 | i = 2 | |
1231 | end | |
1232 | if i == 0 then | |
1233 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
1234 | local recip = 0.5 / s | |
1235 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
1236 | elseif i == 1 then | |
1237 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
1238 | local recip = 0.5 / s | |
1239 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
1240 | elseif i == 2 then | |
1241 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
1242 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
1243 | end | |
1244 | end | |
1245 | end | |
1246 | ||
1247 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
1248 | local xs, ys, zs = x + x, y + y, z + z | |
1249 | local wx, wy, wz = w * xs, w * ys, w * zs | |
1250 | local xx = x * xs | |
1251 | local xy = x * ys | |
1252 | local xz = x * zs | |
1253 | local yy = y * ys | |
1254 | local yz = y * zs | |
1255 | local zz = z * zs | |
1256 | return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy)) | |
1257 | end | |
1258 | ||
1259 | function QuaternionSlerp(a, b, t) | |
1260 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
1261 | local startInterp, finishInterp; | |
1262 | if cosTheta >= 0.0001 then | |
1263 | if (1 - cosTheta) > 0.0001 then | |
1264 | local theta = ACOS(cosTheta) | |
1265 | local invSinTheta = 1 / SIN(theta) | |
1266 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
1267 | finishInterp = SIN(t * theta) * invSinTheta | |
1268 | else | |
1269 | startInterp = 1 - t | |
1270 | finishInterp = t | |
1271 | end | |
1272 | else | |
1273 | if (1 + cosTheta) > 0.0001 then | |
1274 | local theta = ACOS(-cosTheta) | |
1275 | local invSinTheta = 1 / SIN(theta) | |
1276 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
1277 | finishInterp = SIN(t * theta) * invSinTheta | |
1278 | else | |
1279 | startInterp = t - 1 | |
1280 | finishInterp = t | |
1281 | end | |
1282 | end | |
1283 | return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp | |
1284 | end | |
1285 | ||
1286 | function Clerp(a, b, t) | |
1287 | local qa = {QuaternionFromCFrame(a)} | |
1288 | local qb = {QuaternionFromCFrame(b)} | |
1289 | local ax, ay, az = a.x, a.y, a.z | |
1290 | local bx, by, bz = b.x, b.y, b.z | |
1291 | local _t = 1 - t | |
1292 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
1293 | end | |
1294 | ||
1295 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
1296 | local frame = IT("Frame") | |
1297 | frame.BackgroundTransparency = TRANSPARENCY | |
1298 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
1299 | frame.Position = POSITION | |
1300 | frame.Size = SIZE | |
1301 | frame.BackgroundColor3 = COLOR | |
1302 | frame.BorderColor3 = BORDERCOLOR | |
1303 | frame.Name = NAME | |
1304 | frame.Parent = PARENT | |
1305 | return frame | |
1306 | end | |
1307 | ||
1308 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
1309 | local label = IT("TextLabel") | |
1310 | label.BackgroundTransparency = 1 | |
1311 | label.Size = UD2(1, 0, 1, 0) | |
1312 | label.Position = UD2(0, 0, 0, 0) | |
1313 | label.TextColor3 = TEXTCOLOR | |
1314 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
1315 | label.TextTransparency = TRANSPARENCY | |
1316 | label.FontSize = TEXTFONTSIZE | |
1317 | label.Font = TEXTFONT | |
1318 | label.BorderSizePixel = BORDERSIZEPIXEL | |
1319 | label.TextScaled = false | |
1320 | label.Text = TEXT | |
1321 | label.Name = NAME | |
1322 | label.Parent = PARENT | |
1323 | return label | |
1324 | end | |
1325 | ||
1326 | function NoOutlines(PART) | |
1327 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
1328 | end | |
1329 | ||
1330 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
1331 | local NEWWELD = IT(TYPE) | |
1332 | NEWWELD.Part0 = PART0 | |
1333 | NEWWELD.Part1 = PART1 | |
1334 | NEWWELD.C0 = C0 | |
1335 | NEWWELD.C1 = C1 | |
1336 | NEWWELD.Parent = PARENT | |
1337 | return NEWWELD | |
1338 | end | |
1339 | ||
1340 | local S = IT("Sound") | |
1341 | function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP) | |
1342 | local NEWSOUND = nil | |
1343 | coroutine.resume(coroutine.create(function() | |
1344 | NEWSOUND = S:Clone() | |
1345 | NEWSOUND.Parent = PARENT | |
1346 | NEWSOUND.Volume = VOLUME | |
1347 | NEWSOUND.Pitch = PITCH | |
1348 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
1349 | NEWSOUND:play() | |
1350 | if DOESLOOP == true then | |
1351 | NEWSOUND.Looped = true | |
1352 | else | |
1353 | repeat wait(1) until NEWSOUND.Playing == false or NEWSOUND.Parent ~= PARENT | |
1354 | NEWSOUND:remove() | |
1355 | end | |
1356 | end)) | |
1357 | return NEWSOUND | |
1358 | end | |
1359 | ||
1360 | function CFrameFromTopBack(at, top, back) | |
1361 | local right = top:Cross(back) | |
1362 | return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z) | |
1363 | end | |
1364 | ||
1365 | --WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
1366 | function WACKYEFFECT(Table) | |
1367 | local TYPE = (Table.EffectType or "Sphere") | |
1368 | local SIZE = (Table.Size or VT(1,1,1)) | |
1369 | local ENDSIZE = (Table.Size2 or VT(0,0,0)) | |
1370 | local TRANSPARENCY = (Table.Transparency or 0) | |
1371 | local ENDTRANSPARENCY = (Table.Transparency2 or 1) | |
1372 | local CFRAME = (Table.CFrame or Torso.CFrame) | |
1373 | local MOVEDIRECTION = (Table.MoveToPos or nil) | |
1374 | local ROTATION1 = (Table.RotationX or 0) | |
1375 | local ROTATION2 = (Table.RotationY or 0) | |
1376 | local ROTATION3 = (Table.RotationZ or 0) | |
1377 | local MATERIAL = (Table.Material or "Neon") | |
1378 | local COLOR = (Table.Color or C3(0,0,0)) | |
1379 | local TIME = (Table.Time or 45) | |
1380 | local SOUNDID = (Table.SoundID or nil) | |
1381 | local SOUNDPITCH = (Table.SoundPitch or nil) | |
1382 | local SOUNDVOLUME = (Table.SoundVolume or nil) | |
1383 | coroutine.resume(coroutine.create(function() | |
1384 | local PLAYSSOUND = false | |
1385 | local SOUND = nil | |
1386 | local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Pearl"), "Effect", VT(1,1,1), true) | |
1387 | if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then | |
1388 | PLAYSSOUND = true | |
1389 | SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false) | |
1390 | end | |
1391 | EFFECT.Color = COLOR | |
1392 | local MSH = nil | |
1393 | if TYPE == "Sphere" then | |
1394 | MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0)) | |
1395 | elseif TYPE == "Block" then | |
1396 | MSH = IT("BlockMesh",EFFECT) | |
1397 | MSH.Scale = VT(SIZE.X,SIZE.X,SIZE.X) | |
1398 | elseif TYPE == "Wave" then | |
1399 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8)) | |
1400 | elseif TYPE == "Ring" then | |
1401 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0)) | |
1402 | elseif TYPE == "Slash" then | |
1403 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
1404 | elseif TYPE == "Round Slash" then | |
1405 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
1406 | elseif TYPE == "Swirl" then | |
1407 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0)) | |
1408 | elseif TYPE == "Skull" then | |
1409 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0)) | |
1410 | elseif TYPE == "Crystal" then | |
1411 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0)) | |
1412 | end | |
1413 | if MSH ~= nil then | |
1414 | local MOVESPEED = nil | |
1415 | if MOVEDIRECTION ~= nil then | |
1416 | MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME | |
1417 | end | |
1418 | local GROWTH = SIZE - ENDSIZE | |
1419 | local TRANS = TRANSPARENCY - ENDTRANSPARENCY | |
1420 | if TYPE == "Block" then | |
1421 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
1422 | else | |
1423 | EFFECT.CFrame = CFRAME | |
1424 | end | |
1425 | for LOOP = 1, TIME+1 do | |
1426 | Swait() | |
1427 | MSH.Scale = MSH.Scale - GROWTH/TIME | |
1428 | if TYPE == "Wave" then | |
1429 | MSH.Offset = VT(0,0,-MSH.Scale.X/8) | |
1430 | end | |
1431 | EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME | |
1432 | if TYPE == "Block" then | |
1433 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
1434 | else | |
1435 | EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3)) | |
1436 | end | |
1437 | if MOVEDIRECTION ~= nil then | |
1438 | local ORI = EFFECT.Orientation | |
1439 | EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED) | |
1440 | EFFECT.Orientation = ORI | |
1441 | end | |
1442 | end | |
1443 | if PLAYSSOUND == false then | |
1444 | EFFECT:remove() | |
1445 | else | |
1446 | SOUND.Stopped:Connect(function() | |
1447 | EFFECT:remove() | |
1448 | end) | |
1449 | end | |
1450 | else | |
1451 | if PLAYSSOUND == false then | |
1452 | EFFECT:remove() | |
1453 | else | |
1454 | repeat Swait() until SOUND.Playing == false | |
1455 | EFFECT:remove() | |
1456 | end | |
1457 | end | |
1458 | end)) | |
1459 | end | |
1460 | --Lightning({Material = "Neon", FadeIn = false, Color = C3(1,1,1), Start = Torso.Position, End = Mouse.Hit.p, SegmentL = 2, Thickness = 0.1, DoesFade = false, Ignore = Character, MaxDist = 400, Branches = false, FadeTime = 15, Thicken = false}) | |
1461 | function Lightning(Table) | |
1462 | local Color = Table.Color or C3(1,1,1) | |
1463 | local StartPos = Table.Start or Torso.Position | |
1464 | local EndPos = Table.End or Mouse.Hit.p | |
1465 | local SegmentLength = Table.SegmentL or 2 | |
1466 | local Thickness = Table.Thickness or 0.1 | |
1467 | local Dissapear = Table.DoesFade or false | |
1468 | local Parent = Table.Ignore or Character | |
1469 | local MaxDist = Table.MaxDist or 400 | |
1470 | local Branches = Table.Branches or false | |
1471 | local Thicken = Table.Thicken or false | |
1472 | local FadeTime = Table.FadeTime or 15 | |
1473 | local FadeIn = Table.FadeIn or false | |
1474 | local Material = Table.Material or "Neon" | |
1475 | local HIT,HITPOS = CastProperRay(StartPos, EndPos, MaxDist, Parent) | |
1476 | local DISTANCE = math.ceil((StartPos - HITPOS).Magnitude/((SegmentLength/SegmentLength)/1.5)) | |
1477 | local LIGHTNINGMODEL = IT("Model",Effects) | |
1478 | LIGHTNINGMODEL.Name = "Lightning" | |
1479 | local LastBolt = nil | |
1480 | for E = 1, DISTANCE do | |
1481 | local ExtraSize = 0 | |
1482 | if Thicken == true then | |
1483 | ExtraSize = (DISTANCE-E)/15 | |
1484 | end | |
1485 | local TRANSPARENCY = 0 | |
1486 | if FadeIn == true then | |
1487 | TRANSPARENCY = 1-(E/(DISTANCE/1.5)) | |
1488 | if TRANSPARENCY < 0 then | |
1489 | TRANSPARENCY = 0 | |
1490 | end | |
1491 | end | |
1492 | local PART = CreatePart(3, LIGHTNINGMODEL, Material, 0, TRANSPARENCY, BRICKC("Pearl"), "LightningPart"..E, VT(Thickness+ExtraSize,SegmentLength,Thickness+ExtraSize)) | |
1493 | PART.Color = Color | |
1494 | MakeForm(PART,"Cyl") | |
1495 | if LastBolt == nil then | |
1496 | PART.CFrame = CF(StartPos,HITPOS)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
1497 | else | |
1498 | PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,CF(HITPOS)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,DISTANCE-E).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
1499 | end | |
1500 | LastBolt = PART | |
1501 | if Branches == true and E < (DISTANCE-5) then | |
1502 | local CHOICE = MRANDOM(1,7+((DISTANCE-E)*2)) | |
1503 | if CHOICE == 1 then | |
1504 | local LASTBRANCH = nil | |
1505 | for i = 1, MRANDOM(2,5) do | |
1506 | local ExtraSize2 = 0 | |
1507 | if Thicken == true then | |
1508 | ExtraSize = ((DISTANCE-E)/25)/i | |
1509 | end | |
1510 | local PART = CreatePart(3, LIGHTNINGMODEL, Material, 0, TRANSPARENCY, BRICKC("Pearl"), "Branch"..E.."-"..i, VT(Thickness+ExtraSize2,SegmentLength,Thickness+ExtraSize2)) | |
1511 | PART.Color = Color | |
1512 | MakeForm(PART,"Cyl") | |
1513 | if LASTBRANCH == nil then | |
1514 | PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*7,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
1515 | else | |
1516 | PART.CFrame = CF(LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0).p,LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*3,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0) | |
1517 | end | |
1518 | LASTBRANCH = PART | |
1519 | end | |
1520 | end | |
1521 | end | |
1522 | end | |
1523 | if Dissapear == true then | |
1524 | coroutine.resume(coroutine.create(function() | |
1525 | for i = 1, FadeTime do | |
1526 | Swait() | |
1527 | for _, c in pairs(LIGHTNINGMODEL:GetChildren()) do | |
1528 | if c.ClassName == "Part" then | |
1529 | c.Transparency = c.Transparency + (i/FadeTime)/10 | |
1530 | end | |
1531 | end | |
1532 | end | |
1533 | LIGHTNINGMODEL:remove() | |
1534 | end)) | |
1535 | elseif Dissapear == false then | |
1536 | Debris:AddItem(LIGHTNINGMODEL,0.1) | |
1537 | end | |
1538 | return {Hit = HIT,Pos = HITPOS,End = LastBolt.CFrame*CF(0,0,-LastBolt.Size.Z).p,LastBolt = LastBolt,Model = LIGHTNINGMODEL} | |
1539 | end | |
1540 | function CreateSwirl(SIZE,WAIT,CFRAME,DOESROT,ROT,COLOR,GROW) | |
1541 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0,0,0)) | |
1542 | wave.Color = COLOR | |
1543 | local mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "1051557", "", SIZE, VT(0,0,0)) | |
1544 | wave.CFrame = CFRAME | |
1545 | coroutine.resume(coroutine.create(function(PART) | |
1546 | for i = 1, WAIT do | |
1547 | Swait() | |
1548 | mesh.Scale = mesh.Scale + GROW | |
1549 | mesh.Offset = VT(0,0,-(mesh.Scale.X/8)) | |
1550 | if DOESROT == true then | |
1551 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0,ROT,0) | |
1552 | end | |
1553 | wave.Transparency = wave.Transparency + (0.5/WAIT) | |
1554 | if wave.Transparency > 0.99 then | |
1555 | wave:remove() | |
1556 | end | |
1557 | end | |
1558 | end)) | |
1559 | end | |
1560 | ||
1561 | function MagicSphere(SIZE,WAIT,CFRAME,COLOR,GROW) | |
1562 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(COLOR), "Effect", VT(1,1,1), true) | |
1563 | wave.Color = COLOR | |
1564 | local mesh = CreateMesh("SpecialMesh", wave, "Sphere", "", "", SIZE, VT(0,0,0)) | |
1565 | wave.CFrame = CFRAME | |
1566 | coroutine.resume(coroutine.create(function(PART) | |
1567 | for i = 1, WAIT do | |
1568 | Swait() | |
1569 | mesh.Scale = mesh.Scale + GROW | |
1570 | wave.Transparency = wave.Transparency + (1/WAIT) | |
1571 | if wave.Transparency > 0.99 then | |
1572 | wave:remove() | |
1573 | end | |
1574 | end | |
1575 | end)) | |
1576 | end | |
1577 | function MakeForm(PART,TYPE) | |
1578 | if TYPE == "Cyl" then | |
1579 | local MSH = IT("BlockMesh",PART) | |
1580 | elseif TYPE == "Ball" then | |
1581 | local MSH = IT("SpecialMesh",PART) | |
1582 | MSH.MeshType = "Sphere" | |
1583 | elseif TYPE == "Cyl2" then | |
1584 | local MSH = IT("CylinderMesh",PART) | |
1585 | elseif TYPE == "Wedge" then | |
1586 | local MSH = IT("SpecialMesh",PART) | |
1587 | MSH.MeshType = "Wedge" | |
1588 | end | |
1589 | end | |
1590 | ||
1591 | function SpawnTrail(FROM,TO,BIG) | |
1592 | local TRAIL = CreatePart(3, Effects, "Neon", 0, 0.5, "Light gray", "Trail", VT(0,0,0)) | |
1593 | MakeForm(TRAIL,"Cyl") | |
1594 | local DIST = (FROM - TO).Magnitude | |
1595 | if BIG == true then | |
1596 | TRAIL.Size = VT(0.5,DIST,0.5) | |
1597 | else | |
1598 | TRAIL.Size = VT(0.25,DIST,0.25) | |
1599 | end | |
1600 | TRAIL.CFrame = CF(FROM, TO) * CF(0, 0, -DIST/2) * ANGLES(RAD(90),RAD(0),RAD(0)) | |
1601 | coroutine.resume(coroutine.create(function() | |
1602 | for i = 1, 5 do | |
1603 | Swait() | |
1604 | TRAIL.Transparency = TRAIL.Transparency + 0.1 | |
1605 | end | |
1606 | TRAIL:remove() | |
1607 | end)) | |
1608 | end | |
1609 | ||
1610 | Debris = game:GetService("Debris") | |
1611 | ||
1612 | function CastProperRay(StartPos, EndPos, Distance, Ignore) | |
1613 | local DIRECTION = CF(StartPos,EndPos).lookVector | |
1614 | return Raycast(StartPos, DIRECTION, Distance, Ignore) | |
1615 | end | |
1616 | ||
1617 | function turnto(position) | |
1618 | RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0) | |
1619 | end | |
1620 | ||
1621 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
1622 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
1623 | end | |
1624 | ||
1625 | function PositiveAngle(NUMBER) | |
1626 | if NUMBER >= 0 then | |
1627 | NUMBER = 0 | |
1628 | end | |
1629 | return NUMBER | |
1630 | end | |
1631 | ||
1632 | function NegativeAngle(NUMBER) | |
1633 | if NUMBER <= 0 then | |
1634 | NUMBER = 0 | |
1635 | end | |
1636 | return NUMBER | |
1637 | end | |
1638 | ||
1639 | function Swait(NUMBER) | |
1640 | if NUMBER == 0 or NUMBER == nil then | |
1641 | ArtificialHB.Event:wait() | |
1642 | else | |
1643 | for i = 1, NUMBER do | |
1644 | ArtificialHB.Event:wait() | |
1645 | end | |
1646 | end | |
1647 | end | |
1648 | ||
1649 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
1650 | local NEWMESH = IT(MESH) | |
1651 | if MESH == "SpecialMesh" then | |
1652 | NEWMESH.MeshType = MESHTYPE | |
1653 | if MESHID ~= "nil" and MESHID ~= "" then | |
1654 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
1655 | end | |
1656 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
1657 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID | |
1658 | end | |
1659 | end | |
1660 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
1661 | NEWMESH.Scale = SCALE | |
1662 | NEWMESH.Parent = PARENT | |
1663 | return NEWMESH | |
1664 | end | |
1665 | ||
1666 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) | |
1667 | local NEWPART = IT("Part") | |
1668 | NEWPART.formFactor = FORMFACTOR | |
1669 | NEWPART.Reflectance = REFLECTANCE | |
1670 | NEWPART.Transparency = TRANSPARENCY | |
1671 | NEWPART.CanCollide = false | |
1672 | NEWPART.Locked = true | |
1673 | NEWPART.Anchored = true | |
1674 | if ANCHOR == false then | |
1675 | NEWPART.Anchored = false | |
1676 | end | |
1677 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
1678 | NEWPART.Name = NAME | |
1679 | NEWPART.Size = SIZE | |
1680 | NEWPART.Position = Torso.Position | |
1681 | NEWPART.Material = MATERIAL | |
1682 | NEWPART:BreakJoints() | |
1683 | NEWPART.Parent = PARENT | |
1684 | return NEWPART | |
1685 | end | |
1686 | ||
1687 | local function weldBetween(a, b) | |
1688 | local weldd = IT("Weld") | |
1689 | weldd.Part0 = a | |
1690 | weldd.Part1 = b | |
1691 | weldd.C0 = CF() | |
1692 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
1693 | weldd.Parent = a | |
1694 | return weldd | |
1695 | end | |
1696 | ||
1697 | ||
1698 | function QuaternionFromCFrame(cf) | |
1699 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
1700 | local trace = m00 + m11 + m22 | |
1701 | if trace > 0 then | |
1702 | local s = math.sqrt(1 + trace) | |
1703 | local recip = 0.5 / s | |
1704 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
1705 | else | |
1706 | local i = 0 | |
1707 | if m11 > m00 then | |
1708 | i = 1 | |
1709 | end | |
1710 | if m22 > (i == 0 and m00 or m11) then | |
1711 | i = 2 | |
1712 | end | |
1713 | if i == 0 then | |
1714 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
1715 | local recip = 0.5 / s | |
1716 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
1717 | elseif i == 1 then | |
1718 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
1719 | local recip = 0.5 / s | |
1720 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
1721 | elseif i == 2 then | |
1722 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
1723 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
1724 | end | |
1725 | end | |
1726 | end | |
1727 | ||
1728 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
1729 | local xs, ys, zs = x + x, y + y, z + z | |
1730 | local wx, wy, wz = w * xs, w * ys, w * zs | |
1731 | local xx = x * xs | |
1732 | local xy = x * ys | |
1733 | local xz = x * zs | |
1734 | local yy = y * ys | |
1735 | local yz = y * zs | |
1736 | local zz = z * zs | |
1737 | return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy)) | |
1738 | end | |
1739 | ||
1740 | function QuaternionSlerp(a, b, t) | |
1741 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
1742 | local startInterp, finishInterp; | |
1743 | if cosTheta >= 0.0001 then | |
1744 | if (1 - cosTheta) > 0.0001 then | |
1745 | local theta = ACOS(cosTheta) | |
1746 | local invSinTheta = 1 / SIN(theta) | |
1747 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
1748 | finishInterp = SIN(t * theta) * invSinTheta | |
1749 | else | |
1750 | startInterp = 1 - t | |
1751 | finishInterp = t | |
1752 | end | |
1753 | else | |
1754 | if (1 + cosTheta) > 0.0001 then | |
1755 | local theta = ACOS(-cosTheta) | |
1756 | local invSinTheta = 1 / SIN(theta) | |
1757 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
1758 | finishInterp = SIN(t * theta) * invSinTheta | |
1759 | else | |
1760 | startInterp = t - 1 | |
1761 | finishInterp = t | |
1762 | end | |
1763 | end | |
1764 | return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp | |
1765 | end | |
1766 | ||
1767 | function Clerp(a, b, t) | |
1768 | local qa = {QuaternionFromCFrame(a)} | |
1769 | local qb = {QuaternionFromCFrame(b)} | |
1770 | local ax, ay, az = a.x, a.y, a.z | |
1771 | local bx, by, bz = b.x, b.y, b.z | |
1772 | local _t = 1 - t | |
1773 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
1774 | end | |
1775 | ||
1776 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
1777 | local frame = IT("Frame") | |
1778 | frame.BackgroundTransparency = TRANSPARENCY | |
1779 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
1780 | frame.Position = POSITION | |
1781 | frame.Size = SIZE | |
1782 | frame.BackgroundColor3 = COLOR | |
1783 | frame.BorderColor3 = BORDERCOLOR | |
1784 | frame.Name = NAME | |
1785 | frame.Parent = PARENT | |
1786 | return frame | |
1787 | end | |
1788 | ||
1789 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
1790 | local label = IT("TextLabel") | |
1791 | label.BackgroundTransparency = 1 | |
1792 | label.Size = UD2(1, 0, 1, 0) | |
1793 | label.Position = UD2(0, 0, 0, 0) | |
1794 | label.TextColor3 = TEXTCOLOR | |
1795 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
1796 | label.TextTransparency = TRANSPARENCY | |
1797 | label.FontSize = TEXTFONTSIZE | |
1798 | label.Font = TEXTFONT | |
1799 | label.BorderSizePixel = BORDERSIZEPIXEL | |
1800 | label.TextScaled = false | |
1801 | label.Text = TEXT | |
1802 | label.Name = NAME | |
1803 | label.Parent = PARENT | |
1804 | return label | |
1805 | end | |
1806 | ||
1807 | function NoOutlines(PART) | |
1808 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
1809 | end | |
1810 | ||
1811 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
1812 | local NEWWELD = IT(TYPE) | |
1813 | NEWWELD.Part0 = PART0 | |
1814 | NEWWELD.Part1 = PART1 | |
1815 | NEWWELD.C0 = C0 | |
1816 | NEWWELD.C1 = C1 | |
1817 | NEWWELD.Parent = PARENT | |
1818 | return NEWWELD | |
1819 | end | |
1820 | ||
1821 | local S = IT("Sound") | |
1822 | function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP) | |
1823 | local NEWSOUND = nil | |
1824 | coroutine.resume(coroutine.create(function() | |
1825 | NEWSOUND = S:Clone() | |
1826 | NEWSOUND.Parent = PARENT | |
1827 | NEWSOUND.Volume = VOLUME | |
1828 | NEWSOUND.Pitch = PITCH | |
1829 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
1830 | NEWSOUND:play() | |
1831 | if DOESLOOP == true then | |
1832 | NEWSOUND.Looped = true | |
1833 | else | |
1834 | repeat wait(1) until NEWSOUND.Playing == false | |
1835 | NEWSOUND:remove() | |
1836 | end | |
1837 | end)) | |
1838 | return NEWSOUND | |
1839 | end | |
1840 | ||
1841 | function CFrameFromTopBack(at, top, back) | |
1842 | local right = top:Cross(back) | |
1843 | return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z) | |
1844 | end | |
1845 | ||
1846 | --WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,1,1), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
1847 | function WACKYEFFECT(Table) | |
1848 | local TYPE = (Table.EffectType or "Sphere") | |
1849 | local SIZE = (Table.Size or VT(1,1,1)) | |
1850 | local ENDSIZE = (Table.Size2 or VT(0,0,0)) | |
1851 | local TRANSPARENCY = (Table.Transparency or 0) | |
1852 | local ENDTRANSPARENCY = (Table.Transparency2 or 1) | |
1853 | local CFRAME = (Table.CFrame or Torso.CFrame) | |
1854 | local MOVEDIRECTION = (Table.MoveToPos or nil) | |
1855 | local ROTATION1 = (Table.RotationX or 0) | |
1856 | local ROTATION2 = (Table.RotationY or 0) | |
1857 | local ROTATION3 = (Table.RotationZ or 0) | |
1858 | local MATERIAL = (Table.Material or "Neon") | |
1859 | local COLOR = (Table.Color or C3(1,1,1)) | |
1860 | local TIME = (Table.Time or 45) | |
1861 | local SOUNDID = (Table.SoundID or nil) | |
1862 | local SOUNDPITCH = (Table.SoundPitch or nil) | |
1863 | local SOUNDVOLUME = (Table.SoundVolume or nil) | |
1864 | coroutine.resume(coroutine.create(function() | |
1865 | local PLAYSSOUND = false | |
1866 | local SOUND = nil | |
1867 | local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Pearl"), "Effect", VT(1,1,1), true) | |
1868 | if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then | |
1869 | PLAYSSOUND = true | |
1870 | SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false) | |
1871 | end | |
1872 | EFFECT.Color = COLOR | |
1873 | local MSH = nil | |
1874 | if TYPE == "Sphere" then | |
1875 | MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0)) | |
1876 | elseif TYPE == "Block" then | |
1877 | MSH = IT("BlockMesh",EFFECT) | |
1878 | MSH.Scale = VT(SIZE.X,SIZE.X,SIZE.X) | |
1879 | elseif TYPE == "Wave" then | |
1880 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8)) | |
1881 | elseif TYPE == "Ring" then | |
1882 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0)) | |
1883 | elseif TYPE == "Slash" then | |
1884 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
1885 | elseif TYPE == "Round Slash" then | |
1886 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
1887 | elseif TYPE == "Swirl" then | |
1888 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0)) | |
1889 | elseif TYPE == "Skull" then | |
1890 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0)) | |
1891 | elseif TYPE == "Crystal" then | |
1892 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0)) | |
1893 | end | |
1894 | if MSH ~= nil then | |
1895 | local MOVESPEED = nil | |
1896 | if MOVEDIRECTION ~= nil then | |
1897 | MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME | |
1898 | end | |
1899 | local GROWTH = SIZE - ENDSIZE | |
1900 | local TRANS = TRANSPARENCY - ENDTRANSPARENCY | |
1901 | if TYPE == "Block" then | |
1902 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
1903 | else | |
1904 | EFFECT.CFrame = CFRAME | |
1905 | end | |
1906 | for LOOP = 1, TIME+1 do | |
1907 | Swait() | |
1908 | MSH.Scale = MSH.Scale - GROWTH/TIME | |
1909 | if TYPE == "Wave" then | |
1910 | MSH.Offset = VT(0,0,-MSH.Scale.X/8) | |
1911 | end | |
1912 | EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME | |
1913 | if TYPE == "Block" then | |
1914 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
1915 | else | |
1916 | EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3)) | |
1917 | end | |
1918 | if MOVEDIRECTION ~= nil then | |
1919 | local ORI = EFFECT.Orientation | |
1920 | EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED) | |
1921 | EFFECT.Orientation = ORI | |
1922 | end | |
1923 | end | |
1924 | if PLAYSSOUND == false then | |
1925 | EFFECT:remove() | |
1926 | else | |
1927 | SOUND.Stopped:Connect(function() | |
1928 | EFFECT:remove() | |
1929 | end) | |
1930 | end | |
1931 | else | |
1932 | if PLAYSSOUND == false then | |
1933 | EFFECT:remove() | |
1934 | else | |
1935 | repeat Swait() until SOUND.Playing == false | |
1936 | EFFECT:remove() | |
1937 | end | |
1938 | end | |
1939 | end)) | |
1940 | end | |
1941 | ||
1942 | function MakeForm(PART,TYPE) | |
1943 | if TYPE == "Cyl" then | |
1944 | local MSH = IT("CylinderMesh",PART) | |
1945 | elseif TYPE == "Ball" then | |
1946 | local MSH = IT("SpecialMesh",PART) | |
1947 | MSH.MeshType = "Sphere" | |
1948 | elseif TYPE == "Wedge" then | |
1949 | local MSH = IT("SpecialMesh",PART) | |
1950 | MSH.MeshType = "Wedge" | |
1951 | end | |
1952 | end | |
1953 | ||
1954 | Debris = game:GetService("Debris") | |
1955 | ||
1956 | function CastProperRay(StartPos, EndPos, Distance, Ignore) | |
1957 | local DIRECTION = CF(StartPos,EndPos).lookVector | |
1958 | return Raycast(StartPos, DIRECTION, Distance, Ignore) | |
1959 | end | |
1960 | ||
1961 | function turnto(position) | |
1962 | RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0) | |
1963 | end | |
1964 | ||
1965 | function SpawnTrail(FROM,TO,BIG) | |
1966 | local TRAIL = CreatePart(3, Effects, "Neon", 0, 0.5, "Really red", "Trail", VT(0,0,0)) | |
1967 | MakeForm(TRAIL,"Cyl") | |
1968 | local DIST = (FROM - TO).Magnitude | |
1969 | if BIG == true then | |
1970 | TRAIL.Size = VT(0.5,DIST,0.5) | |
1971 | else | |
1972 | TRAIL.Size = VT(0.25,DIST,0.25) | |
1973 | end | |
1974 | TRAIL.CFrame = CF(FROM, TO) * CF(0, 0, -DIST/2) * ANGLES(RAD(90),RAD(0),RAD(0)) | |
1975 | coroutine.resume(coroutine.create(function() | |
1976 | for i = 1, 5 do | |
1977 | Swait() | |
1978 | TRAIL.Transparency = TRAIL.Transparency + 0.1 | |
1979 | end | |
1980 | TRAIL:remove() | |
1981 | end)) | |
1982 | end | |
1983 | ||
1984 | local asd = Instance.new("ParticleEmitter") | |
1985 | asd.Color = ColorSequence.new(Color3.new(0.5, 0, 0), Color3.new(.3, 0, 0)) | |
1986 | asd.LightEmission = .1 | |
1987 | asd.Texture = "http://www.roblox.com/asset/?ID=291880914" | |
1988 | aaa = NumberSequence.new({NumberSequenceKeypoint.new(0, 0.6),NumberSequenceKeypoint.new(1, 2)}) | |
1989 | bbb = NumberSequence.new({NumberSequenceKeypoint.new(0, 1),NumberSequenceKeypoint.new(0.0636, 0), NumberSequenceKeypoint.new(1, 1)}) | |
1990 | asd.Transparency = bbb | |
1991 | asd.Size = aaa | |
1992 | asd.ZOffset = .9 | |
1993 | asd.Acceleration = Vector3.new(0, -15, 0) | |
1994 | asd.LockedToPart = false | |
1995 | asd.EmissionDirection = "Back" | |
1996 | asd.Lifetime = NumberRange.new(1, 2) | |
1997 | asd.Rotation = NumberRange.new(-100, 100) | |
1998 | asd.RotSpeed = NumberRange.new(-100, 100) | |
1999 | asd.Speed = NumberRange.new(10) | |
2000 | asd.Enabled = false | |
2001 | asd.VelocitySpread = 999 | |
2002 | ||
2003 | function getbloody(victim,amount) | |
2004 | local PART = CreatePart(3, Effects, "Metal", 0, 1, "Mid gray", "Blood", victim.Size) | |
2005 | PART.CFrame = victim.CFrame | |
2006 | local HITPLAYERSOUNDS = {"356551938","264486467"} | |
2007 | Debris:AddItem(PART,5) | |
2008 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
2009 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
2010 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
2011 | local prtcl = asd:Clone() | |
2012 | prtcl.Parent = PART | |
2013 | prtcl:Emit(amount*10) | |
2014 | end | |
2015 | ||
2016 | local Particle = IT("ParticleEmitter",nil) | |
2017 | Particle.Enabled = false | |
2018 | Particle.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,1),NumberSequenceKeypoint.new(0.3,0.95),NumberSequenceKeypoint.new(1,1)}) | |
2019 | Particle.LightEmission = 0.5 | |
2020 | Particle.Rate = 150 | |
2021 | Particle.ZOffset = 1 | |
2022 | Particle.Rotation = NumberRange.new(-180, 180) | |
2023 | Particle.RotSpeed = NumberRange.new(-180, 180) | |
2024 | Particle.Texture = "http://www.roblox.com/asset/?id=304437537" | |
2025 | Particle.Color = ColorSequence.new(C3(1,0,0),C3(0.4,0,0)) | |
2026 | ||
2027 | --ParticleEmitter({Speed = 5, Drag = 0, Size1 = 1, Size2 = 5, Lifetime1 = 1, Lifetime2 = 1.5, Parent = Torso, Emit = 100, Offset = 360, Enabled = false}) | |
2028 | function ParticleEmitter(Table) | |
2029 | local PRTCL = Particle:Clone() | |
2030 | local Speed = Table.Speed or 5 | |
2031 | local Drag = Table.Drag or 0 | |
2032 | local Size1 = Table.Size1 or 1 | |
2033 | local Size2 = Table.Size2 or 5 | |
2034 | local Lifetime1 = Table.Lifetime1 or 1 | |
2035 | local Lifetime2 = Table.Lifetime2 or 1.5 | |
2036 | local Parent = Table.Parent or Torso | |
2037 | local Emit = Table.Emit or 100 | |
2038 | local Offset = Table.Offset or 360 | |
2039 | local Acel = Table.Acel or VT(0,0,0) | |
2040 | local Enabled = Table.Enabled or false | |
2041 | PRTCL.Parent = Parent | |
2042 | PRTCL.Size = NumberSequence.new(Size1,Size2) | |
2043 | PRTCL.Lifetime = NumberRange.new(Lifetime1,Lifetime2) | |
2044 | PRTCL.Speed = NumberRange.new(Speed) | |
2045 | PRTCL.VelocitySpread = Offset | |
2046 | PRTCL.Drag = Drag | |
2047 | PRTCL.Acceleration = Acel | |
2048 | if Enabled == false then | |
2049 | PRTCL:Emit(Emit) | |
2050 | Debris:AddItem(PRTCL,Lifetime2) | |
2051 | else | |
2052 | PRTCL.Enabled = true | |
2053 | end | |
2054 | return PRTCL | |
2055 | end | |
2056 | ||
2057 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
2058 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
2059 | end | |
2060 | ||
2061 | function PositiveAngle(NUMBER) | |
2062 | if NUMBER >= 0 then | |
2063 | NUMBER = 0 | |
2064 | end | |
2065 | return NUMBER | |
2066 | end | |
2067 | ||
2068 | function NegativeAngle(NUMBER) | |
2069 | if NUMBER <= 0 then | |
2070 | NUMBER = 0 | |
2071 | end | |
2072 | return NUMBER | |
2073 | end | |
2074 | ||
2075 | function Swait(NUMBER) | |
2076 | if NUMBER == 0 or NUMBER == nil then | |
2077 | ArtificialHB.Event:wait() | |
2078 | else | |
2079 | for i = 1, NUMBER do | |
2080 | ArtificialHB.Event:wait() | |
2081 | end | |
2082 | end | |
2083 | end | |
2084 | ||
2085 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
2086 | local NEWMESH = IT(MESH) | |
2087 | if MESH == "SpecialMesh" then | |
2088 | NEWMESH.MeshType = MESHTYPE | |
2089 | if MESHID ~= "nil" and MESHID ~= "" then | |
2090 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
2091 | end | |
2092 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
2093 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID | |
2094 | end | |
2095 | end | |
2096 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
2097 | NEWMESH.Scale = SCALE | |
2098 | NEWMESH.Parent = PARENT | |
2099 | return NEWMESH | |
2100 | end | |
2101 | ||
2102 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) | |
2103 | local NEWPART = IT("Part") | |
2104 | NEWPART.formFactor = FORMFACTOR | |
2105 | NEWPART.Reflectance = REFLECTANCE | |
2106 | NEWPART.Transparency = TRANSPARENCY | |
2107 | NEWPART.CanCollide = false | |
2108 | NEWPART.Locked = true | |
2109 | NEWPART.Anchored = true | |
2110 | if ANCHOR == false then | |
2111 | NEWPART.Anchored = false | |
2112 | end | |
2113 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
2114 | NEWPART.Name = NAME | |
2115 | NEWPART.Size = SIZE | |
2116 | NEWPART.Position = Torso.Position | |
2117 | NEWPART.Material = MATERIAL | |
2118 | NEWPART:BreakJoints() | |
2119 | NEWPART.Parent = PARENT | |
2120 | return NEWPART | |
2121 | end | |
2122 | ||
2123 | local function weldBetween(a, b) | |
2124 | local weldd = Instance.new("ManualWeld") | |
2125 | weldd.Part0 = a | |
2126 | weldd.Part1 = b | |
2127 | weldd.C0 = CFrame.new() | |
2128 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
2129 | weldd.Parent = a | |
2130 | return weldd | |
2131 | end | |
2132 | ||
2133 | ||
2134 | function QuaternionFromCFrame(cf) | |
2135 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
2136 | local trace = m00 + m11 + m22 | |
2137 | if trace > 0 then | |
2138 | local s = math.sqrt(1 + trace) | |
2139 | local recip = 0.5 / s | |
2140 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
2141 | else | |
2142 | local i = 0 | |
2143 | if m11 > m00 then | |
2144 | i = 1 | |
2145 | end | |
2146 | if m22 > (i == 0 and m00 or m11) then | |
2147 | i = 2 | |
2148 | end | |
2149 | if i == 0 then | |
2150 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
2151 | local recip = 0.5 / s | |
2152 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
2153 | elseif i == 1 then | |
2154 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
2155 | local recip = 0.5 / s | |
2156 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
2157 | elseif i == 2 then | |
2158 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
2159 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
2160 | end | |
2161 | end | |
2162 | end | |
2163 | ||
2164 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
2165 | local xs, ys, zs = x + x, y + y, z + z | |
2166 | local wx, wy, wz = w * xs, w * ys, w * zs | |
2167 | local xx = x * xs | |
2168 | local xy = x * ys | |
2169 | local xz = x * zs | |
2170 | local yy = y * ys | |
2171 | local yz = y * zs | |
2172 | local zz = z * zs | |
2173 | return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy)) | |
2174 | end | |
2175 | ||
2176 | function QuaternionSlerp(a, b, t) | |
2177 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
2178 | local startInterp, finishInterp; | |
2179 | if cosTheta >= 0.0001 then | |
2180 | if (1 - cosTheta) > 0.0001 then | |
2181 | local theta = ACOS(cosTheta) | |
2182 | local invSinTheta = 1 / SIN(theta) | |
2183 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
2184 | finishInterp = SIN(t * theta) * invSinTheta | |
2185 | else | |
2186 | startInterp = 1 - t | |
2187 | finishInterp = t | |
2188 | end | |
2189 | else | |
2190 | if (1 + cosTheta) > 0.0001 then | |
2191 | local theta = ACOS(-cosTheta) | |
2192 | local invSinTheta = 1 / SIN(theta) | |
2193 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
2194 | finishInterp = SIN(t * theta) * invSinTheta | |
2195 | else | |
2196 | startInterp = t - 1 | |
2197 | finishInterp = t | |
2198 | end | |
2199 | end | |
2200 | return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp | |
2201 | end | |
2202 | ||
2203 | function Clerp(a, b, t) | |
2204 | local qa = {QuaternionFromCFrame(a)} | |
2205 | local qb = {QuaternionFromCFrame(b)} | |
2206 | local ax, ay, az = a.x, a.y, a.z | |
2207 | local bx, by, bz = b.x, b.y, b.z | |
2208 | local _t = 1 - t | |
2209 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
2210 | end | |
2211 | ||
2212 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
2213 | local frame = IT("Frame") | |
2214 | frame.BackgroundTransparency = TRANSPARENCY | |
2215 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
2216 | frame.Position = POSITION | |
2217 | frame.Size = SIZE | |
2218 | frame.BackgroundColor3 = COLOR | |
2219 | frame.BorderColor3 = BORDERCOLOR | |
2220 | frame.Name = NAME | |
2221 | frame.Parent = PARENT | |
2222 | return frame | |
2223 | end | |
2224 | ||
2225 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
2226 | local label = IT("TextLabel") | |
2227 | label.BackgroundTransparency = 1 | |
2228 | label.Size = UD2(1, 0, 1, 0) | |
2229 | label.Position = UD2(0, 0, 0, 0) | |
2230 | label.TextColor3 = TEXTCOLOR | |
2231 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
2232 | label.TextTransparency = TRANSPARENCY | |
2233 | label.FontSize = TEXTFONTSIZE | |
2234 | label.Font = TEXTFONT | |
2235 | label.BorderSizePixel = BORDERSIZEPIXEL | |
2236 | label.TextStrokeColor3 = C3(1,1,1) | |
2237 | label.TextScaled = false | |
2238 | label.Text = TEXT | |
2239 | label.Name = NAME | |
2240 | label.Parent = PARENT | |
2241 | return label | |
2242 | end | |
2243 | ||
2244 | function NoOutlines(PART) | |
2245 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
2246 | end | |
2247 | ||
2248 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
2249 | local NEWWELD = IT(TYPE) | |
2250 | NEWWELD.Part0 = PART0 | |
2251 | NEWWELD.Part1 = PART1 | |
2252 | NEWWELD.C0 = C0 | |
2253 | NEWWELD.C1 = C1 | |
2254 | NEWWELD.Parent = PARENT | |
2255 | return NEWWELD | |
2256 | end | |
2257 | ||
2258 | local S = IT("Sound") | |
2259 | function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP) | |
2260 | local NEWSOUND = nil | |
2261 | coroutine.resume(coroutine.create(function() | |
2262 | NEWSOUND = S:Clone() | |
2263 | NEWSOUND.Parent = PARENT | |
2264 | NEWSOUND.Volume = VOLUME | |
2265 | NEWSOUND.Pitch = PITCH | |
2266 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
2267 | NEWSOUND:play() | |
2268 | if DOESLOOP == true then | |
2269 | NEWSOUND.Looped = true | |
2270 | else | |
2271 | repeat wait(1) until NEWSOUND.Playing == false | |
2272 | NEWSOUND:remove() | |
2273 | end | |
2274 | end)) | |
2275 | return NEWSOUND | |
2276 | end | |
2277 | ||
2278 | function CFrameFromTopBack(at, top, back) | |
2279 | local right = top:Cross(back) | |
2280 | return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z) | |
2281 | end | |
2282 | ||
2283 | --WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,1,1), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
2284 | function WACKYEFFECT(Table) | |
2285 | local TYPE = (Table.EffectType or "Sphere") | |
2286 | local SIZE = (Table.Size or VT(1,1,1)) | |
2287 | local ENDSIZE = (Table.Size2 or VT(0,0,0)) | |
2288 | local TRANSPARENCY = (Table.Transparency or 0) | |
2289 | local ENDTRANSPARENCY = (Table.Transparency2 or 1) | |
2290 | local CFRAME = (Table.CFrame or Torso.CFrame) | |
2291 | local MOVEDIRECTION = (Table.MoveToPos or nil) | |
2292 | local ROTATION1 = (Table.RotationX or 0) | |
2293 | local ROTATION2 = (Table.RotationY or 0) | |
2294 | local ROTATION3 = (Table.RotationZ or 0) | |
2295 | local MATERIAL = (Table.Material or "Neon") | |
2296 | local COLOR = (Table.Color or C3(66/255, 0/255, 127/2551)) | |
2297 | local TIME = (Table.Time or 45) | |
2298 | local SOUNDID = (Table.SoundID or nil) | |
2299 | local SOUNDPITCH = (Table.SoundPitch or nil) | |
2300 | local SOUNDVOLUME = (Table.SoundVolume or nil) | |
2301 | coroutine.resume(coroutine.create(function() | |
2302 | local PLAYSSOUND = false | |
2303 | local SOUND = nil | |
2304 | local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Dark indigo"), "Effect", VT(1,1,1), true) | |
2305 | if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then | |
2306 | PLAYSSOUND = true | |
2307 | SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false) | |
2308 | end | |
2309 | EFFECT.Color = COLOR | |
2310 | local MSH = nil | |
2311 | if TYPE == "Sphere" then | |
2312 | MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0)) | |
2313 | elseif TYPE == "Block" then | |
2314 | MSH = IT("BlockMesh",EFFECT) | |
2315 | MSH.Scale = VT(SIZE.X,SIZE.X,SIZE.X) | |
2316 | elseif TYPE == "Wave" then | |
2317 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8)) | |
2318 | elseif TYPE == "Ring" then | |
2319 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0)) | |
2320 | elseif TYPE == "Slash" then | |
2321 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
2322 | elseif TYPE == "Round Slash" then | |
2323 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0)) | |
2324 | elseif TYPE == "Swirl" then | |
2325 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0)) | |
2326 | elseif TYPE == "Skull" then | |
2327 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0)) | |
2328 | elseif TYPE == "Crystal" then | |
2329 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0)) | |
2330 | end | |
2331 | if MSH ~= nil then | |
2332 | local MOVESPEED = nil | |
2333 | if MOVEDIRECTION ~= nil then | |
2334 | MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME | |
2335 | end | |
2336 | local GROWTH = SIZE - ENDSIZE | |
2337 | local TRANS = TRANSPARENCY - ENDTRANSPARENCY | |
2338 | if TYPE == "Block" then | |
2339 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
2340 | else | |
2341 | EFFECT.CFrame = CFRAME | |
2342 | end | |
2343 | for LOOP = 1, TIME+1 do | |
2344 | Swait() | |
2345 | MSH.Scale = MSH.Scale - GROWTH/TIME | |
2346 | if TYPE == "Wave" then | |
2347 | MSH.Offset = VT(0,0,-MSH.Scale.X/8) | |
2348 | end | |
2349 | EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME | |
2350 | if TYPE == "Block" then | |
2351 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
2352 | else | |
2353 | EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3)) | |
2354 | end | |
2355 | if MOVEDIRECTION ~= nil then | |
2356 | local ORI = EFFECT.Orientation | |
2357 | EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED) | |
2358 | EFFECT.Orientation = ORI | |
2359 | end | |
2360 | end | |
2361 | if PLAYSSOUND == false then | |
2362 | EFFECT:remove() | |
2363 | else | |
2364 | repeat Swait() until SOUND.Playing == false | |
2365 | EFFECT:remove() | |
2366 | end | |
2367 | else | |
2368 | if PLAYSSOUND == false then | |
2369 | EFFECT:remove() | |
2370 | else | |
2371 | repeat Swait() until SOUND.Playing == false | |
2372 | EFFECT:remove() | |
2373 | end | |
2374 | end | |
2375 | end)) | |
2376 | end | |
2377 | ||
2378 | function MakeForm(PART,TYPE) | |
2379 | if TYPE == "Cyl" then | |
2380 | local MSH = IT("CylinderMesh",PART) | |
2381 | elseif TYPE == "Ball" then | |
2382 | local MSH = IT("SpecialMesh",PART) | |
2383 | MSH.MeshType = "Sphere" | |
2384 | elseif TYPE == "Wedge" then | |
2385 | local MSH = IT("SpecialMesh",PART) | |
2386 | MSH.MeshType = "Wedge" | |
2387 | end | |
2388 | end | |
2389 | ||
2390 | Debris = game:GetService("Debris") | |
2391 | ||
2392 | function CastProperRay(StartPos, EndPos, Distance, Ignore) | |
2393 | local DIRECTION = CF(StartPos,EndPos).lookVector | |
2394 | return Raycast(StartPos, DIRECTION, Distance, Ignore) | |
2395 | end | |
2396 | ||
2397 | function turnto(position) | |
2398 | RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0) | |
2399 | end | |
2400 | ||
2401 | --//=================================\\ | |
2402 | --|| WEAPON CREATION | |
2403 | --\\=================================// | |
2404 | ||
2405 | Humanoid.Parent = nil | |
2406 | RootPart.Size = RootPart.Size*SIZE | |
2407 | Torso.Size = Torso.Size*SIZE | |
2408 | RightArm.Size = RightArm.Size*SIZE | |
2409 | RightLeg.Size = RightLeg.Size*SIZE | |
2410 | LeftArm.Size = LeftArm.Size*SIZE | |
2411 | LeftLeg.Size = LeftLeg.Size*SIZE | |
2412 | RootJoint.C0 = ROOTC0 * CF(0 * SIZE, 0 * SIZE, 0 * SIZE) * ANGLES(RAD(0), RAD(0), RAD(0)) | |
2413 | RootJoint.C1 = ROOTC0 * CF(0 * SIZE, 0 * SIZE, 0 * SIZE) * ANGLES(RAD(0), RAD(0), RAD(0)) | |
2414 | Neck.C0 = NECKC0 * CF(0 * SIZE, 0 * SIZE, 0 + ((1 * SIZE) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)) | |
2415 | Neck.C1 = CF(0 * SIZE, -0.5 * SIZE, 0 * SIZE) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
2416 | RightShoulder.C1 = CF(0 * SIZE, 0.5 * SIZE, -0.35 * SIZE) | |
2417 | LeftShoulder.C1 = CF(0 * SIZE, 0.5 * SIZE, -0.35 * SIZE) | |
2418 | RightHip.C0 = CF(1 * SIZE, -1 * SIZE, 0 * SIZE) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) | |
2419 | LeftHip.C0 = CF(-1 * SIZE, -1 * SIZE, 0 * SIZE) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) | |
2420 | RightHip.C1 = CF(0.5 * SIZE, 1 * SIZE, 0 * SIZE) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) | |
2421 | LeftHip.C1 = CF(-0.5 * SIZE, 1 * SIZE, 0 * SIZE) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) | |
2422 | Head.Size = Head.Size*SIZE | |
2423 | RootJoint.Parent = RootPart | |
2424 | Neck.Parent = Torso | |
2425 | RightShoulder.Parent = Torso | |
2426 | LeftShoulder.Parent = Torso | |
2427 | RightHip.Parent = Torso | |
2428 | LeftHip.Parent = Torso | |
2429 | ||
2430 | Humanoid.DisplayDistanceType = "None" | |
2431 | local naeeym2 = IT("BillboardGui",Character) | |
2432 | naeeym2.AlwaysOnTop = true | |
2433 | naeeym2.Size = UDim2.new(5,35,2,15) | |
2434 | naeeym2.StudsOffset = Vector3.new(0,2,0) | |
2435 | naeeym2.MaxDistance = 75 | |
2436 | naeeym2.Adornee = Character.Head | |
2437 | naeeym2.Name = "Name" | |
2438 | local tecks2 = IT("TextLabel",naeeym2) | |
2439 | tecks2.BackgroundTransparency = 1 | |
2440 | tecks2.TextScaled = true | |
2441 | tecks2.BorderSizePixel = 0 | |
2442 | tecks2.Text = "The Ruler Of Space And Time" | |
2443 | tecks2.Font = "Fantasy" | |
2444 | tecks2.TextSize = 30 | |
2445 | tecks2.TextStrokeTransparency = 0 | |
2446 | tecks2.TextColor3 = C3(0,0,0) | |
2447 | tecks2.TextStrokeColor3 = C3(255/255, 255/255, 0/255) | |
2448 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
2449 | tecks2.Parent = naeeym2 | |
2450 | local top = Instance.new("Shirt") | |
2451 | top.ShirtTemplate = "rbxassetid://36929738" | |
2452 | top.Parent = Character | |
2453 | top.Name = "Cloth" | |
2454 | local bottom = Instance.new("Pants") | |
2455 | bottom.PantsTemplate = "rbxassetid://36929780" | |
2456 | bottom.Parent = Character | |
2457 | bottom.Name = "Cloth" | |
2458 | ||
2459 | local PRT = CreatePart(3, Weapon, "Fabric", 0, 0, "Really black", "Hat", VT(1,1,1),false) | |
2460 | PRT.Color = C3(0,0,0) | |
2461 | CreateWeldOrSnapOrMotor("Weld", Head, Head, PRT, CF(0,0.72*SIZE,0.1) * ANGLES(RAD(15), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2462 | CreateMesh("SpecialMesh", PRT, "FileMesh", "", "", VT(1,1,1)*SIZE, VT(0,0,0)) | |
2463 | PRT.Transparency = 1 | |
2464 | local PRT = CreatePart(3, Character, "Fabric", 0, 0, "Really black", "Detail", VT(1,1,1),false) | |
2465 | PRT.Color = C3(0,0,0) | |
2466 | CreateWeldOrSnapOrMotor("Weld", Head, Head, PRT, CF(0,0,-.5*SIZE), CF(0, 0, 0)) | |
2467 | CreateMesh("SpecialMesh", PRT, "FileMesh", "636922328", "636922344", VT(0.06,0.06,0.06)*SIZE, VT(0,0.08,1)) | |
2468 | local PRT = CreatePart(3, Character, "Neon", 0, 0, "Really black", "Detail", VT(1,1.2,0.2),false) | |
2469 | PRT.Color = C3(255/255, 0/255, 0/255) | |
2470 | MakeForm(PRT,"Ball") | |
2471 | PRT.Transparency = 1 | |
2472 | CreateWeldOrSnapOrMotor("Weld", Head, Head, PRT, CF(0,0,-.5*SIZE), CF(0, 0, 0)) | |
2473 | local PRT = CreatePart(3, Character, "Neon", 0, 0, "Really black", "Detail", VT(0.5,0.4,0.5),false) | |
2474 | PRT.Transparency = 1 | |
2475 | PRT.Color = C3(255/255, 255/255, 0/255) | |
2476 | MakeForm(PRT,"Ball") | |
2477 | CreateWeldOrSnapOrMotor("Weld", Head, Head, PRT, CF(0,-0.3,-.5*SIZE), CF(0, 0, 0)) | |
2478 | local PRT = CreatePart(3, Character, "Neon", 0, 0, "Really black", "Detail", VT(0.5,0.3,0.3),false) | |
2479 | PRT.Transparency = 1 | |
2480 | PRT.Color = C3(255/255, 255/255, 0/255) | |
2481 | MakeForm(PRT,"Ball") | |
2482 | CreateWeldOrSnapOrMotor("Weld", Head, Head, PRT, CF(0.25,0.25,-.5*SIZE), CF(0, 0, 0)) | |
2483 | local PRT = CreatePart(3, Character, "Neon", 0, 0, "Really black", "Detail", VT(0.5,0.3,0.3),false) | |
2484 | PRT.Color = C3(255/255, 255/255, 0/255) | |
2485 | MakeForm(PRT,"Ball") | |
2486 | PRT.Transparency = 1 | |
2487 | ||
2488 | local Aura = Instance.new('ParticleEmitter') | |
2489 | Aura.Name = "Aura" | |
2490 | Aura.Texture = "rbxassetid://" | |
2491 | Aura.Parent = PRT | |
2492 | Aura.LightEmission = 0.3 | |
2493 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2494 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(255/255, 0/255, 0/255)) | |
2495 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2496 | Aura.LockedToPart = false | |
2497 | Aura.Lifetime = NumberRange.new(2) | |
2498 | Aura.Rate = 30 | |
2499 | Aura.Speed = NumberRange.new(1) | |
2500 | Aura.EmissionDirection = "Top" | |
2501 | CreateWeldOrSnapOrMotor("Weld", Head, Head, PRT, CF(-0.25,0.25,-.5*SIZE), CF(0, 0, 0)) | |
2502 | ||
2503 | local Particle = IT("ParticleEmitter",nil) | |
2504 | Particle.Enabled = false | |
2505 | Particle.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,0.3),NumberSequenceKeypoint.new(0.3,0),NumberSequenceKeypoint.new(1,1)}) | |
2506 | Particle.LightEmission = 0.5 | |
2507 | Particle.Rate = 150 | |
2508 | Particle.ZOffset = 0.2 | |
2509 | Particle.Rotation = NumberRange.new(-180, 180) | |
2510 | Particle.RotSpeed = NumberRange.new(-180, 180) | |
2511 | Particle.Texture = "http://www.roblox.com/asset/?id=304437537" | |
2512 | Particle.Color = ColorSequence.new(C3(0,0,0),C3(0,0,0)) | |
2513 | ||
2514 | --ParticleEmitter({Speed = 5, Drag = 0, Size1 = 1, Size2 = 5, Lifetime1 = 1, Lifetime2 = 1.5, Parent = Torso, Emit = 100, Offset = 360, Enabled = false}) | |
2515 | function ParticleEmitter(Table) | |
2516 | local PRTCL = Particle:Clone() | |
2517 | local Speed = Table.Speed or 5 | |
2518 | local Drag = Table.Drag or 0 | |
2519 | local Size1 = Table.Size1 or 1 | |
2520 | local Size2 = Table.Size2 or 5 | |
2521 | local Lifetime1 = Table.Lifetime1 or 1 | |
2522 | local Lifetime2 = Table.Lifetime2 or 1.5 | |
2523 | local Parent = Table.Parent or Torso | |
2524 | local Emit = Table.Emit or 100 | |
2525 | local Offset = Table.Offset or 360 | |
2526 | local Acel = Table.Acel or VT(0,0,0) | |
2527 | local Enabled = Table.Enabled or false | |
2528 | PRTCL.Parent = Parent | |
2529 | PRTCL.Size = NumberSequence.new(Size1,Size2) | |
2530 | PRTCL.Lifetime = NumberRange.new(Lifetime1,Lifetime2) | |
2531 | PRTCL.Speed = NumberRange.new(Speed) | |
2532 | PRTCL.VelocitySpread = Offset | |
2533 | PRTCL.Drag = Drag | |
2534 | PRTCL.Acceleration = Acel | |
2535 | if Enabled == false then | |
2536 | PRTCL:Emit(Emit) | |
2537 | Debris:AddItem(PRTCL,Lifetime2) | |
2538 | else | |
2539 | PRTCL.Enabled = true | |
2540 | end | |
2541 | return PRTCL | |
2542 | end | |
2543 | ||
2544 | ||
2545 | local Handle = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.2,0.6,0.2),false) | |
2546 | local RightArmGrasp = CreateWeldOrSnapOrMotor("Weld", Handle, RightArm, Handle, CF(0,-1, 0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0.21, 0)) | |
2547 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.2,0.5,0.2),false) | |
2548 | MakeForm(Part,"Wedge") | |
2549 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.3, 0.2) * ANGLES(RAD(0), RAD(180), RAD(0)), CF(0, 0, 0)) | |
2550 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.2,0.3,0.2),false) | |
2551 | MakeForm(Part,"Wedge") | |
2552 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.4, 0) * ANGLES(RAD(0), RAD(0), RAD(180)), CF(0, 0, 0)) | |
2553 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.3,0.3,0.3),false) | |
2554 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.5, 0.2) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2555 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.3,0.5,0.5),false) | |
2556 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.5) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2557 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.4,0.4,0.4),false) | |
2558 | MakeForm(Part,"Cyl") | |
2559 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.5) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2560 | for i = 1, 8 do | |
2561 | local Piece = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Eye", VT(0,0.35,0.41),false) | |
2562 | CreateWeldOrSnapOrMotor("Weld", Handle, Part, Piece, CF(0, 0, 0) * ANGLES(RAD(0), RAD((360/8)*i), RAD(0)), CF(0, 0, 0)) | |
2563 | end | |
2564 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Eye", VT(0.38,0.41,0.38),false) | |
2565 | MakeForm(Part,"Cyl") | |
2566 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.5) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2567 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.37,0.5,0.37),false) | |
2568 | MakeForm(Part,"Ball") | |
2569 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.3) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2570 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.2,0.7,0.4),false) | |
2571 | MakeForm(Part,"Wedge") | |
2572 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.7, 0.5) * ANGLES(RAD(90), RAD(180), RAD(180)), CF(0, 0, 0)) | |
2573 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.3,0.4,0.2),false) | |
2574 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.7) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2575 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.35,0.35,0.35),false) | |
2576 | MakeForm(Part,"Cyl") | |
2577 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.7) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2578 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.5,0.1,0.5),false) | |
2579 | MakeForm(Part,"Cyl") | |
2580 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 1) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2581 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.5,0.1,0.45),false) | |
2582 | MakeForm(Part,"Cyl") | |
2583 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 1.1) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2584 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.2,0.5,0.2),false) | |
2585 | MakeForm(Part,"Wedge") | |
2586 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.55, 0.2) * ANGLES(RAD(-135), RAD(0), RAD(0)), CF(0, -0.3, 0)) | |
2587 | local LASTPART = Handle | |
2588 | for i = 1, 10 do | |
2589 | if LASTPART == Handle then | |
2590 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.1,0.2,0),false) | |
2591 | LASTPART = Part | |
2592 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.1, 0.2) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2593 | else | |
2594 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.1,0.05,0),false) | |
2595 | CreateWeldOrSnapOrMotor("Weld", Handle, LASTPART, Part, CF(0, 0.025, 0) * ANGLES(RAD(8), RAD(0), RAD(0)), CF(0, -0.025, 0)) | |
2596 | LASTPART = Part | |
2597 | end | |
2598 | end | |
2599 | ||
2600 | local Barrel = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.15,2,0.15),false) | |
2601 | MakeForm(Barrel,"Cyl") | |
2602 | CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Barrel, CF(0, -0.6, 1.8) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2603 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0.25,1,0.25),false) | |
2604 | MakeForm(Part,"Cyl") | |
2605 | CreateWeldOrSnapOrMotor("Weld", Handle, Barrel, Part, CF(0, -0.6, 0), CF(0, 0, 0)) | |
2606 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0,0.1,0.2),false) | |
2607 | MakeForm(Part,"Wedge") | |
2608 | CreateWeldOrSnapOrMotor("Weld", Handle, Barrel, Part, CF(0, 0.945, 0.1) * ANGLES(RAD(180), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2609 | local Hole = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Eye", VT(0.125,0,0.125),false) | |
2610 | MakeForm(Hole,"Cyl") | |
2611 | CreateWeldOrSnapOrMotor("Weld", Handle, Barrel, Hole, CF(0, 0.98, 0), CF(0, 0, 0)) | |
2612 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Light gray", "Part", VT(0,0,0),false) | |
2613 | local GEARWELD = CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.7), CF(0, 0, 0)) | |
2614 | CreateMesh("SpecialMesh", Part, "FileMesh", 156292343, "", VT(0.8,0.8,1.5), VT(0,0,0.2)) | |
2615 | local Part = CreatePart(3, Weapon, "SmoothPlastic", 0, 0.5, "Light gray", "Eye", VT(0,0,0),false) | |
2616 | local GEARWELD2 = CreateWeldOrSnapOrMotor("Weld", Handle, Handle, Part, CF(0, -0.6, 0.7), CF(0, 0, 0)) | |
2617 | CreateMesh("SpecialMesh", Part, "FileMesh", 156292343, "", VT(0.9,0.9,0.3), VT(0,0,0.2)) | |
2618 | coroutine.resume(coroutine.create(function() | |
2619 | while wait() do | |
2620 | GEARWELD.C0 = GEARWELD.C0 * ANGLES(RAD(0), RAD(0), RAD(5)) | |
2621 | GEARWELD2.C0 = GEARWELD2.C0 * ANGLES(RAD(0), RAD(0), RAD(-5)) | |
2622 | end | |
2623 | end)) | |
2624 | ||
2625 | ParticleEmitter({Speed = 0.2, Drag = 0, Size1 = 0.1, Size2 = 0, Lifetime1 = 0.3, Lifetime2 = 0.5, Parent = Hole, Emit = 100, Offset = 360, Enabled = true, Acel = VT(0,5,0)}) | |
2626 | --ParticleEmitter({Speed = 0.5, Drag = 0, Size1 = 0.2, Size2 = 0, Lifetime1 = 0.3, Lifetime2 = 0.7, Parent = Dangle, Emit = 100, Offset = 360, Enabled = true, Acel = VT(0,5,0)}) | |
2627 | ||
2628 | for _, c in pairs(Weapon:GetDescendants()) do | |
2629 | if c.ClassName == "Part" and c.Name ~= "Eye" and c.Parent ~= Effects and c.Parent.Parent ~= Effects then | |
2630 | c.Material = "Glass" | |
2631 | c.Color = C3(0,0,0) | |
2632 | elseif c.ClassName == "Part" and c.Name == "Eye" then | |
2633 | c.Color = C3(0,0,0) | |
2634 | c.Material = "Neon" | |
2635 | end | |
2636 | end | |
2637 | ||
2638 | Weapon.Parent = Character | |
2639 | for _, c in pairs(Weapon:GetChildren()) do | |
2640 | if c.ClassName == "Part" then | |
2641 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
2642 | end | |
2643 | end | |
2644 | ||
2645 | local BODY = {} | |
2646 | for _, c in pairs(Character:GetDescendants()) do | |
2647 | if c:IsA("BasePart") and c.Name ~= "Handle" then | |
2648 | if c ~= RootPart and c ~= Torso and c ~= Head and c ~= RightArm and c ~= LeftArm and c ~= RightLeg and c ~= LeftLeg then | |
2649 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
2650 | end | |
2651 | table.insert(BODY,{c,c.Parent,c.Material,c.Color,c.Transparency}) | |
2652 | elseif c:IsA("JointInstance") then | |
2653 | table.insert(BODY,{c,c.Parent,nil,nil,nil}) | |
2654 | end | |
2655 | end | |
2656 | for e = 1, #BODY do | |
2657 | if BODY[e] ~= nil then | |
2658 | local STUFF = BODY[e] | |
2659 | local PART = STUFF[1] | |
2660 | local PARENT = STUFF[2] | |
2661 | local MATERIAL = STUFF[3] | |
2662 | local COLOR = STUFF[4] | |
2663 | local TRANSPARENCY = STUFF[5] | |
2664 | if PART.ClassName == "Part" and PART ~= RootPart then | |
2665 | PART.Material = MATERIAL | |
2666 | PART.Color = COLOR | |
2667 | PART.Transparency = TRANSPARENCY | |
2668 | end | |
2669 | PART.AncestryChanged:Connect(function() | |
2670 | PART.Parent = PARENT | |
2671 | end) | |
2672 | end | |
2673 | end | |
2674 | ||
2675 | Humanoid.Died:connect(function() | |
2676 | Humanoid.Parent = nil | |
2677 | Humanoid.MaxHealth = "inf" | |
2678 | Humanoid.Health = "inf" | |
2679 | refit() | |
2680 | Humanoid.Parent = Character | |
2681 | CreateSound("907330011", Head, 10, 1.2) | |
2682 | end) | |
2683 | ||
2684 | local LASTPART = Head | |
2685 | for i = 1, 24 do | |
2686 | local MATH = (1-(i/30)) | |
2687 | if LASTPART == Head then | |
2688 | ||
2689 | local Aura = Instance.new('ParticleEmitter') | |
2690 | Aura.Name = "Aura" | |
2691 | Aura.Texture = "rbxassetid://" | |
2692 | Aura.Parent = Horn | |
2693 | Aura.LightEmission = 0.8 | |
2694 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2695 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(0/255, 0/255, 0/255)) | |
2696 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2697 | Aura.LockedToPart = true | |
2698 | Aura.Lifetime = NumberRange.new(2) | |
2699 | Aura.Rate = 25 | |
2700 | Aura.Speed = NumberRange.new(0.1) | |
2701 | Aura.EmissionDirection = "Top" | |
2702 | else | |
2703 | ||
2704 | local Aura = Instance.new('ParticleEmitter') | |
2705 | Aura.Name = "Aura" | |
2706 | Aura.Texture = "rbxassetid://" | |
2707 | Aura.Parent = Horn | |
2708 | Aura.LightEmission = 0.8 | |
2709 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2710 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(0/255, 0/255, 0/255)) | |
2711 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2712 | Aura.LockedToPart = true | |
2713 | Aura.Lifetime = NumberRange.new(2) | |
2714 | Aura.Rate = 25 | |
2715 | Aura.Speed = NumberRange.new(0.1) | |
2716 | Aura.EmissionDirection = "Top" | |
2717 | end | |
2718 | end | |
2719 | local LASTPART = Head | |
2720 | for i = 1, 24 do | |
2721 | local MATH = (1-(i/30)) | |
2722 | if LASTPART == Head then | |
2723 | ||
2724 | local Aura = Instance.new('ParticleEmitter') | |
2725 | Aura.Name = "Aura" | |
2726 | Aura.Texture = "rbxassetid://" | |
2727 | Aura.LightEmission = 0.8 | |
2728 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2729 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(0/255, 0/255, 0/255)) | |
2730 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2731 | Aura.LockedToPart = true | |
2732 | Aura.Lifetime = NumberRange.new(2) | |
2733 | Aura.Rate = 25 | |
2734 | Aura.Speed = NumberRange.new(0.1) | |
2735 | Aura.EmissionDirection = "Top" | |
2736 | else | |
2737 | Aura.Name = "Aura" | |
2738 | Aura.Texture = "rbxassetid://" | |
2739 | Aura.LightEmission = 0.8 | |
2740 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2741 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(0/255, 0/255, 0/255)) | |
2742 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2743 | Aura.LockedToPart = true | |
2744 | Aura.Lifetime = NumberRange.new(2) | |
2745 | Aura.Rate = 25 | |
2746 | Aura.Speed = NumberRange.new(0.1) | |
2747 | Aura.EmissionDirection = "Top" | |
2748 | end | |
2749 | end | |
2750 | local LASTPART = Head | |
2751 | for i = 1, 8 do | |
2752 | local MATH = (1-(i/14)) | |
2753 | if LASTPART == Head then | |
2754 | ||
2755 | local Aura = Instance.new('ParticleEmitter') | |
2756 | Aura.Name = "Aura" | |
2757 | Aura.Texture = "rbxassetid://" | |
2758 | Aura.LightEmission = 0.8 | |
2759 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2760 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(0/255, 0/255, 0/255)) | |
2761 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2762 | Aura.LockedToPart = true | |
2763 | Aura.Lifetime = NumberRange.new(2) | |
2764 | Aura.Rate = 25 | |
2765 | Aura.Speed = NumberRange.new(0.1) | |
2766 | Aura.EmissionDirection = "Top" | |
2767 | else | |
2768 | ||
2769 | local Aura = Instance.new('ParticleEmitter') | |
2770 | Aura.Name = "Aura" | |
2771 | Aura.Texture = "rbxassetid://" | |
2772 | Aura.Parent = Horn | |
2773 | Aura.LightEmission = 0.8 | |
2774 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2775 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(0/255, 0/255, 0/255)) | |
2776 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2777 | Aura.LockedToPart = true | |
2778 | Aura.Lifetime = NumberRange.new(2) | |
2779 | Aura.Rate = 25 | |
2780 | Aura.Speed = NumberRange.new(0.1) | |
2781 | Aura.EmissionDirection = "Top" | |
2782 | end | |
2783 | end | |
2784 | local LASTPART = Head | |
2785 | for i = 1, 8 do | |
2786 | local MATH = (1-(i/14)) | |
2787 | if LASTPART == Head then | |
2788 | local Aura = Instance.new('ParticleEmitter') | |
2789 | Aura.Name = "Aura" | |
2790 | Aura.Texture = "rbxassetid://" | |
2791 | Aura.Parent = Horn | |
2792 | Aura.LightEmission = 0.8 | |
2793 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2794 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(0/255, 0/255, 0/255)) | |
2795 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2796 | Aura.LockedToPart = true | |
2797 | Aura.Lifetime = NumberRange.new(2) | |
2798 | Aura.Rate = 25 | |
2799 | Aura.Speed = NumberRange.new(0.1) | |
2800 | Aura.EmissionDirection = "Top" | |
2801 | else | |
2802 | local Horn = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Dirt brown", "Detail", VT(0.25*MATH,0.15,0.25*MATH),false) | |
2803 | CreateWeldOrSnapOrMotor("Weld", LASTPART, LASTPART, Horn, CF(0, Horn.Size.Y/2, 0) * ANGLES(RAD(10), RAD(-3), RAD(0)), CF(0, -Horn.Size.Y/2, 0)) | |
2804 | LASTPART = Horn | |
2805 | Horn.Color = C3(1-((i*4-4)/255),1-((i*6-6)/255),0/255) | |
2806 | local Aura = Instance.new('ParticleEmitter') | |
2807 | Aura.Name = "Aura" | |
2808 | Aura.Texture = "rbxassetid://" | |
2809 | Aura.Parent = Horn | |
2810 | Aura.LightEmission = 0.8 | |
2811 | Aura.Transparency = NumberSequence.new(0,0.6,1) | |
2812 | Aura.Color = ColorSequence.new(Color3.new(255/255, 255/255, 255/255),Color3.new(0/255, 0/255, 0/255)) | |
2813 | Aura.Size = NumberSequence.new(0.3,0.2,0.1) | |
2814 | Aura.LockedToPart = true | |
2815 | Aura.Lifetime = NumberRange.new(2) | |
2816 | Aura.Rate = 25 | |
2817 | Aura.Speed = NumberRange.new(0.1) | |
2818 | Aura.EmissionDirection = "Top" | |
2819 | end | |
2820 | end | |
2821 | local PRT = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Watch", VT(1.05,0.06,1.05)*SIZE,false) | |
2822 | CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, PRT, CF(0,-0.5*SIZE,0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0)) | |
2823 | local PRT = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Watch", VT(0.5,0.1,0.5)*SIZE,false) | |
2824 | CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, PRT, CF(0,-0.5*SIZE,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, -0.5*SIZE, 0)) | |
2825 | MakeForm(PRT,"Cyl") | |
2826 | local PRT = CreatePart(3, Weapon, "Neon", 0, 0, "Mid gray", "Watch", VT(0.45,0.11,0.45)*SIZE,false) | |
2827 | CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, PRT, CF(0,-0.5*SIZE,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, -0.5*SIZE, 0)) | |
2828 | MakeForm(PRT,"Cyl") | |
2829 | PRT.Color = C3(255/255, 255/255, 0/255) | |
2830 | local RING = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Watch", VT(0.055,0.15,0.055)*SIZE,false) | |
2831 | CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, RING, CF(0,-0.5*SIZE,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, -0.5*SIZE, 0)) | |
2832 | MakeForm(RING,"Cyl") | |
2833 | RING.Color = C3(0,0,0) | |
2834 | for i = 1, 12 do | |
2835 | local PRT = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Watch", VT(0,0.15,0)*SIZE,false) | |
2836 | PRT.Color = C3(0,0,0) | |
2837 | local MSH = IT("BlockMesh",PRT) | |
2838 | MSH.Scale = VT(0.6,1,1) | |
2839 | CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, PRT, CF(0,-0.5*SIZE,0) * ANGLES(RAD(90), RAD((360/12)*i), RAD(0)), CF(0, -0.49*SIZE, 0) * CF(0, 0, -0.2*SIZE)) | |
2840 | end | |
2841 | local PRT = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Watch", VT(0,0.15,0.15)*SIZE,false) | |
2842 | PRT.Color = C3(0,0,0) | |
2843 | local MSH = IT("BlockMesh",PRT) | |
2844 | MSH.Scale = VT(0.4,1,1) | |
2845 | local WATCH1 = CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, PRT, CF(0,-0.5*SIZE,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, -0.49*SIZE, 0) * CF(0, 0, -0.075*SIZE)) | |
2846 | local PRT = CreatePart(3, Weapon, "Metal", 0, 0, "Mid gray", "Watch", VT(0,0.15,0.15/1.5)*SIZE,false) | |
2847 | PRT.Color = C3(0,0,0) | |
2848 | local MSH = IT("BlockMesh",PRT) | |
2849 | MSH.Scale = VT(0.4,1,1) | |
2850 | local WATCH2 = CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, PRT, CF(0,-0.5*SIZE,0) * ANGLES(RAD(90), RAD(0), RAD(0)), CF(0, -0.49*SIZE, 0) * CF(0, 0, -(0.075/1.5)*SIZE)) | |
2851 | coroutine.resume(coroutine.create(function() | |
2852 | while true do | |
2853 | Swait() | |
2854 | CLOCKLOOP = CLOCKLOOP - 1*CLOCKSPEED | |
2855 | WATCH1.C0 = Clerp(WATCH1.C0, CF(0,-0.5*SIZE,0) * ANGLES(RAD(90), RAD(CLOCKLOOP*5), RAD(0)), 1 / Animation_Speed) | |
2856 | WATCH2.C0 = Clerp(WATCH2.C0, CF(0,-0.5*SIZE,0) * ANGLES(RAD(90), RAD(CLOCKLOOP*5/2), RAD(0)), 1 / Animation_Speed) | |
2857 | if CLOCKLOOP <= -150 then | |
2858 | if VALUE1 == false then | |
2859 | CLOCKLOOP = 0 | |
2860 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.45,0.11,0.45)*SIZE, Size2 = VT(3,3,3), Transparency = 0, Transparency2 = 1, CFrame = RING.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(255, 255, 0), SoundID = 743521450, SoundPitch = 1.2, SoundVolume = 2}) | |
2861 | local HITFLOOR,HITPOS = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 25*SIZE, Character) | |
2862 | ApplyAoE(HITPOS,10,15,45,75,true) | |
2863 | WACKYEFFECT({Time = 15, EffectType = "Wave", Size = VT(0.45,0.11,0.45)*SIZE, Size2 = VT(15,2,15), Transparency = 0, Transparency2 = 1, CFrame = CF(HITPOS), MoveToPos = nil, RotationX = 0, RotationY = -15, RotationZ = 0, Material = "Neon", Color = C3(255, 255, 0), SoundID = nil, SoundPitch = 0.5, SoundVolume = 4}) | |
2864 | WACKYEFFECT({Time = 15, EffectType = "Wave", Size = VT(0.45,0.11,0.45)*SIZE, Size2 = VT(12,3,12), Transparency = 0, Transparency2 = 1, CFrame = CF(HITPOS), MoveToPos = nil, RotationX = 0, RotationY = 15, RotationZ = 0, Material = "Neon", Color = C3(255, 255, 0), SoundID = nil, SoundPitch = 0.5, SoundVolume = 4}) | |
2865 | if CLOCKTARGET ~= nil then | |
2866 | CLOCKTARGET.Health = CLOCKTARGET.Health - 20 | |
2867 | if CLOCKTARGET.Torso ~= nil then | |
2868 | CLOCKTARGET.Torso.CFrame = CLOCKTARGET.Torso.CFrame * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))) | |
2869 | end | |
2870 | if CLOCKTARGET.Health == 0 then | |
2871 | CLOCKTARGET = nil | |
2872 | end | |
2873 | end | |
2874 | end | |
2875 | end | |
2876 | end | |
2877 | end)) | |
2878 | ||
2879 | for _, c in pairs(Weapon:GetChildren()) do | |
2880 | if c.ClassName == "Part" then | |
2881 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
2882 | end | |
2883 | end | |
2884 | ||
2885 | Neck.Name = "Weld" | |
2886 | RootJoint.Name = "Weld" | |
2887 | RightShoulder.Name = "Weld" | |
2888 | LeftShoulder.Name = "Weld" | |
2889 | RightHip.Name = "Weld" | |
2890 | LeftHip.Name = "Weld" | |
2891 | ||
2892 | local BODY = {} | |
2893 | for _, c in pairs(Character:GetDescendants()) do | |
2894 | if c:IsA("BasePart") and c.Name ~= "Handle" then | |
2895 | if c ~= RootPart and c ~= Torso and c ~= Head and c ~= RightArm and c ~= LeftArm and c ~= RightLeg and c ~= LeftLeg then | |
2896 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
2897 | end | |
2898 | table.insert(BODY,{c,c.Parent,c.Material,c.Color,c.Transparency}) | |
2899 | elseif c:IsA("JointInstance") then | |
2900 | table.insert(BODY,{c,c.Parent,nil,nil,nil}) | |
2901 | end | |
2902 | end | |
2903 | for e = 1, #BODY do | |
2904 | if BODY[e] ~= nil then | |
2905 | local STUFF = BODY[e] | |
2906 | local PART = STUFF[1] | |
2907 | local PARENT = STUFF[2] | |
2908 | local MATERIAL = STUFF[3] | |
2909 | local COLOR = STUFF[4] | |
2910 | local TRANSPARENCY = STUFF[5] | |
2911 | if PART.ClassName == "Part" and PART ~= RootPart then | |
2912 | PART.Material = MATERIAL | |
2913 | PART.Color = COLOR | |
2914 | PART.Transparency = TRANSPARENCY | |
2915 | end | |
2916 | PART.AncestryChanged:Connect(function() | |
2917 | PART.Parent = PARENT | |
2918 | end) | |
2919 | end | |
2920 | end | |
2921 | ||
2922 | function refit() | |
2923 | Character.Parent = workspace | |
2924 | for e = 1, #BODY do | |
2925 | if BODY[e] ~= nil then | |
2926 | local STUFF = BODY[e] | |
2927 | local PART = STUFF[1] | |
2928 | local PARENT = STUFF[2] | |
2929 | local MATERIAL = STUFF[3] | |
2930 | local COLOR = STUFF[4] | |
2931 | local TRANSPARENCY = STUFF[5] | |
2932 | if PART.ClassName == "Part" and PART ~= RootPart then | |
2933 | PART.Material = MATERIAL | |
2934 | PART.Color = COLOR | |
2935 | PART.Transparency = TRANSPARENCY | |
2936 | end | |
2937 | if PART.Parent ~= PARENT then | |
2938 | Humanoid:remove() | |
2939 | PART.Parent = PARENT | |
2940 | Humanoid = IT("Humanoid",Character) | |
2941 | end | |
2942 | end | |
2943 | end | |
2944 | end | |
2945 | local SKILLTEXTCOLOR = C3(255/255, 255/255, 0/255) | |
2946 | local SKILLFONT = "Fantasy" | |
2947 | local SKILLTEXTSIZE = 7 | |
2948 | ||
2949 | Weapon.Parent = Character | |
2950 | Humanoid.Parent = Character | |
2951 | ||
2952 | Humanoid.Died:connect(function() | |
2953 | Humanoid.Parent = nil | |
2954 | Humanoid.MaxHealth = "inf" | |
2955 | Humanoid.Health = "inf" | |
2956 | refit() | |
2957 | Humanoid.Parent = Character | |
2958 | CreateSound("907330011", Head, 10, 1.2) | |
2959 | end) | |
2960 | ||
2961 | local SKILL1FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.1, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 1 Frame") | |
2962 | local SKILL2FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.63, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 2 Frame") | |
2963 | local SKILL3FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.215, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 3 Frame") | |
2964 | local SKILL4FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.525, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 4 Frame") | |
2965 | local SKILL5FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.365, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 5 Frame") | |
2966 | local SKILL7FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.23, 0, 0.85, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 7 Frame") | |
2967 | local SKILL6FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.365, 0, 0.100, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 6 Frame") | |
2968 | local SKILL9FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.475, 0, 0.100, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 9 Frame") | |
2969 | local SKILL10FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.225, 0, 0.100, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 10 Frame") | |
2970 | ||
2971 | local SKILL1TEXT = CreateLabel(SKILL1FRAME, "[Z] Time Spikes", SKILLTEXTCOLOR, SKILLTEXTSIZE-1, SKILLFONT, 0, 2, 0, "Text 1") | |
2972 | local SKILL2TEXT = CreateLabel(SKILL2FRAME, "[B] Time Stop", SKILLTEXTCOLOR, SKILLTEXTSIZE-1, SKILLFONT, 0, 2, 0, "Text 2") | |
2973 | local SKILL3TEXT = CreateLabel(SKILL3FRAME, "[C] Space's Bullet", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 3") | |
2974 | local SKILL4TEXT = CreateLabel(SKILL4FRAME, "[V] Time Shot", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 4") | |
2975 | local SKILL5TEXT = CreateLabel(SKILL5FRAME, "[X] Red Star", SKILLTEXTCOLOR, SKILLTEXTSIZE+1, SKILLFONT, 0, 2, 0, "Text 5") | |
2976 | local SKILL7TEXT = CreateLabel(SKILL7FRAME, "[R] Time Blast", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 7") | |
2977 | local SKILL6TEXT = CreateLabel(SKILL6FRAME, "[F] Ultimate Blast", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.7, "Text 6") | |
2978 | local SKILL9TEXT = CreateLabel(SKILL9FRAME, "[Q] Warp", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.7, "Text 9") | |
2979 | local SKILL10TEXT = CreateLabel(SKILL10FRAME, "[E] God Mode", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.7, "Text 10") | |
2980 | ||
2981 | function printbye(Name) | |
2982 | local MESSAGES = {"You cannot struggle, ","Your existance is an insult, ","Fade, ","Your existance is not desired, ","You are not permitted here, ","You are not to decide your fate, ","Be gone, ","You are already dead, ","Your live is an anomaly, ","Don't dare to return, ","Why are you resisting, ","You cannot exist here, ","Why are you struggling, ","Your fate was already decided, ","Goodbye, ","You cannot ignore my command, ","You cannot resist my command, ","You already died, "} | |
2983 | warn(MESSAGES[MRANDOM(1,#MESSAGES)]..Name..".") | |
2984 | end | |
2985 | ||
2986 | workspace.ChildAdded:connect(function(instance) | |
2987 | for BANISH = 1, #TOBANISH do | |
2988 | if TOBANISH[BANISH] ~= nil then | |
2989 | if instance.Name == TOBANISH[BANISH] then | |
2990 | coroutine.resume(coroutine.create(function() | |
2991 | printbye(instance.Name) | |
2992 | instance:ClearAllChildren() | |
2993 | Debris:AddItem(instance,0.0005) | |
2994 | end)) | |
2995 | end | |
2996 | end | |
2997 | end | |
2998 | end) | |
2999 | ||
3000 | ||
3001 | --//=================================\\ | |
3002 | --|| DAMAGING | |
3003 | --\\=================================// | |
3004 | ||
3005 | function Kill(Foe) | |
3006 | if Foe then | |
3007 | coroutine.resume(coroutine.create(function() | |
3008 | --if game.Players:FindFirstChild(Foe.Name) then | |
3009 | table.insert(TOBANISH,Foe.Name) | |
3010 | printbye(Foe.Name) | |
3011 | --end | |
3012 | Foe.Archivable = true | |
3013 | local CLONE = Foe:Clone() | |
3014 | Foe:Destroy() | |
3015 | CLONE.Parent = Effects | |
3016 | CLONE:BreakJoints() | |
3017 | local MATERIALS = {"Glass","Neon"} | |
3018 | for _, c in pairs(CLONE:GetDescendants()) do | |
3019 | if c:IsA("BasePart") then | |
3020 | if c.Name == "Torso" or c.Name == "UpperTorso" or c == CLONE.PrimaryPart then | |
3021 | CreateSound(340722848, c, 10, 1, false) | |
3022 | end | |
3023 | c.Anchored = true | |
3024 | c.Transparency = c.Transparency + 0.2 | |
3025 | c.Material = MATERIALS[MRANDOM(1,2)] | |
3026 | c.Color = C3(0,0,0) | |
3027 | if c.ClassName == "MeshPart" then | |
3028 | c.TextureID = "" | |
3029 | end | |
3030 | if c:FindFirstChildOfClass("SpecialMesh") then | |
3031 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
3032 | end | |
3033 | if c:FindFirstChildOfClass("Decal") then | |
3034 | c:FindFirstChildOfClass("Decal"):remove() | |
3035 | end | |
3036 | c.Name = "Banished" | |
3037 | c.CanCollide = false | |
3038 | else | |
3039 | c:remove() | |
3040 | end | |
3041 | end | |
3042 | local A = false | |
3043 | for i = 1, 35 do | |
3044 | if A == false then | |
3045 | A = true | |
3046 | elseif A == true then | |
3047 | A = false | |
3048 | end | |
3049 | for _, c in pairs(CLONE:GetDescendants()) do | |
3050 | if c:IsA("BasePart") then | |
3051 | c.Anchored = true | |
3052 | c.Material = MATERIALS[MRANDOM(1,2)] | |
3053 | c.Transparency = c.Transparency + 0.8/35 | |
3054 | if A == false then | |
3055 | c.CFrame = c.CFrame*CF(MRANDOM(-45,45)/45,MRANDOM(-45,45)/45,MRANDOM(-45,45)/45) | |
3056 | elseif A == true then | |
3057 | c.CFrame = c.CFrame*CF(MRANDOM(-45,45)/45,MRANDOM(-45,45)/45,MRANDOM(-45,45)/45) | |
3058 | end | |
3059 | end | |
3060 | end | |
3061 | Swait() | |
3062 | end | |
3063 | CLONE:remove() | |
3064 | end)) | |
3065 | end | |
3066 | end | |
3067 | ||
3068 | local asd = Instance.new("ParticleEmitter") | |
3069 | asd.Color = ColorSequence.new(Color3.new(0.5, 0, 0), Color3.new(.3, 0, 0)) | |
3070 | asd.LightEmission = .1 | |
3071 | asd.Texture = "http://www.roblox.com/asset/?ID=291880914" | |
3072 | aaa = NumberSequence.new({NumberSequenceKeypoint.new(0, 0.6),NumberSequenceKeypoint.new(1, 2)}) | |
3073 | bbb = NumberSequence.new({NumberSequenceKeypoint.new(0, 1),NumberSequenceKeypoint.new(0.0636, 0), NumberSequenceKeypoint.new(1, 1)}) | |
3074 | asd.Transparency = bbb | |
3075 | asd.Size = aaa | |
3076 | asd.ZOffset = .9 | |
3077 | asd.Acceleration = Vector3.new(0, -15, 0) | |
3078 | asd.LockedToPart = false | |
3079 | asd.EmissionDirection = "Back" | |
3080 | asd.Lifetime = NumberRange.new(1, 2) | |
3081 | asd.Rotation = NumberRange.new(-100, 100) | |
3082 | asd.RotSpeed = NumberRange.new(-100, 100) | |
3083 | asd.Speed = NumberRange.new(10) | |
3084 | asd.Enabled = false | |
3085 | asd.VelocitySpread = 999 | |
3086 | function getbloody(victim,amount) | |
3087 | local PART = CreatePart(3, Effects, "Metal", 0, 1, "Mid gray", "Blood", victim.Size) | |
3088 | PART.CFrame = victim.CFrame | |
3089 | local HITPLAYERSOUNDS = {"356551938","264486467"} | |
3090 | Debris:AddItem(PART,5) | |
3091 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
3092 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
3093 | CreateSound(HITPLAYERSOUNDS[MRANDOM(1, #HITPLAYERSOUNDS)], PART, 1, (math.random(8,12)/10)) | |
3094 | local prtcl = asd:Clone() | |
3095 | prtcl.Parent = PART | |
3096 | prtcl:Emit(amount*10) | |
3097 | end | |
3098 | function Banish(Char) | |
3099 | local NewCharacter = Instance.new("Model",Effects) | |
3100 | NewCharacter.Name = "Ow im ded ;-;" | |
3101 | for _, c in pairs(Char:GetDescendants()) do | |
3102 | if c:IsA("BasePart") and c.Transparency == 0 then | |
3103 | if c.Parent == Char then | |
3104 | getbloody(c,5) | |
3105 | end | |
3106 | c:BreakJoints() | |
3107 | c.Material = "Glass" | |
3108 | c.Color = C3(0.5,0,0) | |
3109 | c.CanCollide = true | |
3110 | c.Transparency = 0.3 | |
3111 | if c:FindFirstChildOfClass("SpecialMesh") then | |
3112 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
3113 | end | |
3114 | if c.Name == "Head" then | |
3115 | c:ClearAllChildren() | |
3116 | c.Size = VT(c.Size.Y,c.Size.Y,c.Size.Y) | |
3117 | end | |
3118 | if c.ClassName == "MeshPart" then | |
3119 | c.TextureID = "" | |
3120 | end | |
3121 | if c:FindFirstChildOfClass("BodyPosition") then | |
3122 | c:FindFirstChildOfClass("BodyPosition"):remove() | |
3123 | end | |
3124 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
3125 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
3126 | end | |
3127 | c.Parent = NewCharacter | |
3128 | c.Name = "DeadPart" | |
3129 | c.Velocity = VT(MRANDOM(-45,45),MRANDOM(-45,45),MRANDOM(-45,45))/15 | |
3130 | c.RotVelocity = VT(MRANDOM(-45,45),MRANDOM(-15,85),MRANDOM(-45,45)) | |
3131 | end | |
3132 | end | |
3133 | Char:remove() | |
3134 | Debris:AddItem(NewCharacter,5) | |
3135 | end | |
3136 | ||
3137 | function ApplyAoE(POSITION,RANGE,ISBANISH) | |
3138 | local CHILDREN = workspace:GetDescendants() | |
3139 | for index, CHILD in pairs(CHILDREN) do | |
3140 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
3141 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
3142 | if HUM then | |
3143 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
3144 | if TORSO then | |
3145 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
3146 | if ISBANISH == true then | |
3147 | Banish(CHILD) | |
3148 | else | |
3149 | if ISBANISH == "Gravity" then | |
3150 | HUM.PlatformStand = true | |
3151 | if TORSO:FindFirstChild("V3BanishForce"..Player.Name) then | |
3152 | local grav = Instance.new("BodyPosition",TORSO) | |
3153 | grav.D = 15 | |
3154 | grav.P = 20000 | |
3155 | grav.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
3156 | grav.position = TORSO.Position | |
3157 | grav.Name = "V3BanishForce"..Player.Name | |
3158 | else | |
3159 | TORSO:FindFirstChild("V3BanishForce"..Player.Name).position = TORSO.Position+VT(0,0.3,0) | |
3160 | TORSO.RotVelocity = VT(MRANDOM(-25,25),MRANDOM(-25,25),MRANDOM(-25,25)) | |
3161 | end | |
3162 | else | |
3163 | HUM.PlatformStand = false | |
3164 | end | |
3165 | end | |
3166 | elseif ISBANISH == "Gravity" then | |
3167 | if TORSO:FindFirstChild("V3BanishForce"..Player.Name) then | |
3168 | TORSO:FindFirstChild("V3BanishForce"..Player.Name):remove() | |
3169 | HUM.PlatformStand = false | |
3170 | end | |
3171 | end | |
3172 | end | |
3173 | end | |
3174 | end | |
3175 | end | |
3176 | end | |
3177 | function ApplyKill(POSITION,RANGE,BRUTAL) | |
3178 | local CHILDREN = workspace:GetDescendants() | |
3179 | for index, CHILD in pairs(CHILDREN) do | |
3180 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
3181 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
3182 | if HUM then | |
3183 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
3184 | if TORSO then | |
3185 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
3186 | if BRUTAL == true then | |
3187 | Banish(CHILD) | |
3188 | else | |
3189 | CHILD:BreakJoints() | |
3190 | end | |
3191 | end | |
3192 | end | |
3193 | end | |
3194 | end | |
3195 | end | |
3196 | end | |
3197 | ||
3198 | function ApplyDamage(Humanoid,Damage) | |
3199 | Damage = Damage * DAMAGEMULTIPLIER | |
3200 | if Humanoid.Health ~= 0 then | |
3201 | Humanoid.Health = Humanoid.Health - Damage | |
3202 | end | |
3203 | end | |
3204 | ||
3205 | function ApplyAoE(POSITION,RANGE,MINDMG,MAXDMG,FLING,INSTAKILL,OPTION) | |
3206 | local CHILDREN = workspace:GetDescendants() | |
3207 | for index, CHILD in pairs(CHILDREN) do | |
3208 | if CHILD.ClassName == "Model" and CHILD ~= Character then | |
3209 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
3210 | if HUM then | |
3211 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
3212 | if TORSO then | |
3213 | if (TORSO.Position - POSITION).Magnitude <= RANGE then | |
3214 | if INSTAKILL == true then | |
3215 | CHILD:BreakJoints() | |
3216 | if OPTION ~= nil then | |
3217 | Kill(CHILD,OPTION) | |
3218 | end | |
3219 | else | |
3220 | local DMG = MRANDOM(MINDMG,MAXDMG) | |
3221 | ApplyDamage(HUM,DMG) | |
3222 | end | |
3223 | if FLING ~= 0 then | |
3224 | for _, c in pairs(CHILD:GetChildren()) do | |
3225 | if c:IsA("BasePart") then | |
3226 | local bv = Instance.new("BodyVelocity") | |
3227 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
3228 | bv.velocity = CF(POSITION,TORSO.Position).lookVector*FLING | |
3229 | bv.Parent = c | |
3230 | Debris:AddItem(bv,0.05) | |
3231 | end | |
3232 | end | |
3233 | end | |
3234 | end | |
3235 | end | |
3236 | end | |
3237 | end | |
3238 | end | |
3239 | end | |
3240 | ||
3241 | function Kill(Victim,Fire) | |
3242 | coroutine.resume(coroutine.create(function() | |
3243 | local NIL = script.TotalNil:Clone() | |
3244 | NIL.Parent = Victim | |
3245 | NIL.Disabled = false | |
3246 | if Fire ~= true then | |
3247 | Victim:BreakJoints() | |
3248 | for _, c in pairs(Victim:GetChildren()) do | |
3249 | if c:IsA("BasePart") then | |
3250 | c.Anchored = true | |
3251 | end | |
3252 | end | |
3253 | for _, c in pairs(Victim:GetChildren()) do | |
3254 | if c:IsA("BasePart") then | |
3255 | Shatter(c) | |
3256 | end | |
3257 | end | |
3258 | else | |
3259 | Victim:BreakJoints() | |
3260 | local FIRES = {} | |
3261 | for _, e in pairs(Victim:GetDescendants()) do | |
3262 | if e:IsA("BasePart") and e.Name ~= "HumanoidRootPart" and e.Parent.ClassName ~= "Folder" then | |
3263 | e.Transparency = 1 | |
3264 | e:ClearAllChildren() | |
3265 | local FIRE = script.HellFire:Clone() | |
3266 | FIRE.Parent = e | |
3267 | FIRE.Enabled = true | |
3268 | table.insert(FIRES,FIRE) | |
3269 | elseif e.ClassName == "Decal" then | |
3270 | e:remove() | |
3271 | end | |
3272 | end | |
3273 | for i = 1, 50 do | |
3274 | Victim:BreakJoints() | |
3275 | wait() | |
3276 | end | |
3277 | for i = 1, #FIRES do | |
3278 | FIRES[i].Enabled = false | |
3279 | end | |
3280 | wait(1.1) | |
3281 | Victim:remove() | |
3282 | end | |
3283 | end)) | |
3284 | end | |
3285 | ||
3286 | --//=================================\\ | |
3287 | --|| ATTACK FUNCTIONS AND STUFF | |
3288 | --\\=================================// | |
3289 | ||
3290 | function Kill(Foe) | |
3291 | if Foe then | |
3292 | coroutine.resume(coroutine.create(function() | |
3293 | --if game.Players:FindFirstChild(Foe.Name) then | |
3294 | table.insert(TOBANISH,Foe.Name) | |
3295 | printbye(Foe.Name) | |
3296 | --end | |
3297 | Foe.Archivable = true | |
3298 | local CLONE = Foe:Clone() | |
3299 | Foe:Destroy() | |
3300 | CLONE.Parent = Effects | |
3301 | CLONE:BreakJoints() | |
3302 | local MATERIALS = {"Glass","Neon"} | |
3303 | for _, c in pairs(CLONE:GetDescendants()) do | |
3304 | if c:IsA("BasePart") then | |
3305 | if c.Name == "Torso" or c.Name == "UpperTorso" or c == CLONE.PrimaryPart then | |
3306 | CreateSound(340722848, c, 10, 1, false) | |
3307 | end | |
3308 | c.Anchored = true | |
3309 | c.Transparency = c.Transparency + 0.2 | |
3310 | c.Material = MATERIALS[MRANDOM(1,2)] | |
3311 | c.Color = C3(0,0,0) | |
3312 | if c.ClassName == "MeshPart" then | |
3313 | c.TextureID = "" | |
3314 | end | |
3315 | if c:FindFirstChildOfClass("SpecialMesh") then | |
3316 | c:FindFirstChildOfClass("SpecialMesh").TextureId = "" | |
3317 | end | |
3318 | if c:FindFirstChildOfClass("Decal") then | |
3319 | c:FindFirstChildOfClass("Decal"):remove() | |
3320 | end | |
3321 | c.Name = "Banished" | |
3322 | c.CanCollide = false | |
3323 | else | |
3324 | c:remove() | |
3325 | end | |
3326 | end | |
3327 | local A = false | |
3328 | for i = 1, 35 do | |
3329 | if A == false then | |
3330 | A = true | |
3331 | elseif A == true then | |
3332 | A = false | |
3333 | end | |
3334 | for _, c in pairs(CLONE:GetDescendants()) do | |
3335 | if c:IsA("BasePart") then | |
3336 | c.Anchored = true | |
3337 | c.Material = MATERIALS[MRANDOM(1,2)] | |
3338 | c.Transparency = c.Transparency + 0.8/35 | |
3339 | if A == false then | |
3340 | c.CFrame = c.CFrame*CF(MRANDOM(-45,45)/45,MRANDOM(-45,45)/45,MRANDOM(-45,45)/45) | |
3341 | elseif A == true then | |
3342 | c.CFrame = c.CFrame*CF(MRANDOM(-45,45)/45,MRANDOM(-45,45)/45,MRANDOM(-45,45)/45) | |
3343 | end | |
3344 | end | |
3345 | end | |
3346 | Swait() | |
3347 | end | |
3348 | CLONE:remove() | |
3349 | end)) | |
3350 | end | |
3351 | end | |
3352 | ||
3353 | function Madness() | |
3354 | ATTACK = true | |
3355 | Rooted = false | |
3356 | local GYRO = IT("BodyGyro",RootPart) | |
3357 | GYRO.D = 750 | |
3358 | GYRO.P = 20000 | |
3359 | GYRO.MaxTorque = VT(0,40000000,0) | |
3360 | local LOCKED = true | |
3361 | local SHOT = false | |
3362 | coroutine.resume(coroutine.create(function() | |
3363 | for i=0, 1, 0.1 / Animation_Speed do | |
3364 | GYRO.CFrame = CF(RootPart.Position,Mouse.Hit.p) | |
3365 | Swait() | |
3366 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3367 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3368 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.15 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(100), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(35)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3369 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3370 | end | |
3371 | LOCKED = false | |
3372 | SHOT = true | |
3373 | repeat | |
3374 | GYRO.CFrame = CF(RootPart.Position,Mouse.Hit.p) | |
3375 | Swait() | |
3376 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3377 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3378 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.15 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(100), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(35)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3379 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3380 | until HOLD == false and SHOT == false | |
3381 | for i=0, 0.3, 0.1 / Animation_Speed do | |
3382 | Swait() | |
3383 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3384 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3385 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.15 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(100), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(35)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3386 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3387 | end | |
3388 | GYRO:remove() | |
3389 | ATTACK = false | |
3390 | Rooted = false | |
3391 | end)) | |
3392 | repeat wait() until LOCKED == false | |
3393 | repeat | |
3394 | SHOT = true | |
3395 | wait(0.2) | |
3396 | SHOT = false | |
3397 | local BULLET = Lightning({Material = "Glass", FadeIn = true, Color = C3(0,0,0), Start = Hole.CFrame*CF(0, 1, 0.045).p, End = Mouse.Hit.p, SegmentL = 1, Thickness = 0.1, DoesFade = true, Ignore = Character, MaxDist = 400, Branches = false, FadeTime = 22, Thicken = false}) | |
3398 | local HIT = BULLET.Hit | |
3399 | local HITPOS = BULLET.End | |
3400 | if HIT then | |
3401 | if HIT.Parent:FindFirstChildOfClass("Humanoid") then | |
3402 | Kill(HIT.Parent) | |
3403 | end | |
3404 | end | |
3405 | WACKYEFFECT({Time = 25, EffectType = "Block", Size = VT(0,0,0), Size2 = VT(3,3,3), Transparency = 0, Transparency2 = 1, CFrame = CF(HITPOS), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = C3(1,0,0), SoundID = 304999618, SoundPitch = 2, SoundVolume = 1}) | |
3406 | WACKYEFFECT({Time = 15, EffectType = "Skull", Size = VT(0,0,0), Size2 = VT(3,3,3), Transparency = 0, Transparency2 = 1, CFrame = Hole.CFrame*CF(0, 1, 0.045) * ANGLES(RAD(90), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = 1, SoundVolume = 2}) | |
3407 | WACKYEFFECT({Time = 15, EffectType = "Wave", Size = VT(0,0,0), Size2 = VT(1,1.2,1), Transparency = 0, Transparency2 = 1, CFrame = Hole.CFrame*CF(0, 1, 0.045) * ANGLES(RAD(0), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = 145080998, SoundPitch = 1, SoundVolume = 2}) | |
3408 | WACKYEFFECT({Time = 15, EffectType = "Wave", Size = VT(0,0,0), Size2 = VT(2,1,2), Transparency = 0, Transparency2 = 1, CFrame = Hole.CFrame*CF(0, 1, 0.045) * ANGLES(RAD(0), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 145080998, SoundPitch = 1, SoundVolume = 2}) | |
3409 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.3,0.3,0.3), Size2 = VT(0,25,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hole.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3410 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.3,0.3,0.3), Size2 = VT(0,25,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hole.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3411 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.3,0.3,0.3), Size2 = VT(0,25,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hole.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3412 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.3,0.3,0.3), Size2 = VT(0,25,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hole.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3413 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.3,0.3,0.3), Size2 = VT(0,25,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hole.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3414 | until HOLD == false | |
3415 | end | |
3416 | ||
3417 | function Banisher_Bullet() | |
3418 | ATTACK = true | |
3419 | Rooted = false | |
3420 | for i=0, 0.4, 0.1 / Animation_Speed do | |
3421 | Swait() | |
3422 | turnto(Mouse.Hit.p) | |
3423 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
3424 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.5 / Animation_Speed) | |
3425 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
3426 | end | |
3427 | repeat | |
3428 | for i=0, 0.2, 0.1 / Animation_Speed do | |
3429 | Swait() | |
3430 | turnto(Mouse.Hit.p) | |
3431 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
3432 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.5 / Animation_Speed) | |
3433 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
3434 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
3435 | end | |
3436 | local HIT,POS = CastProperRay(Hole.Position, Mouse.Hit.p, 1000, Character) | |
3437 | SpawnTrail(Hole.Position,POS) | |
3438 | if HIT ~= nil then | |
3439 | if HIT.Parent ~= workspace and HIT.Parent.ClassName ~= "Folder" then | |
3440 | Banish(HIT.Parent) | |
3441 | end | |
3442 | end | |
3443 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0.3,0,0.3), Size2 = VT(1,1.5,1), Transparency = 0, Transparency2 = 1, CFrame = Hole.CFrame, MoveToPos = Hole.CFrame*CF(0,0.5,0).p, RotationX = 0, RotationY = -15, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
3444 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0.3,0,0.3), Size2 = VT(2,0.5,2), Transparency = 0, Transparency2 = 1, CFrame = Hole.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 5, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 904440937, SoundPitch = MRANDOM(8,11)/10, SoundVolume = 8}) | |
3445 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0.3,0,0.3), Size2 = VT(2,0.5,2), Transparency = 0, Transparency2 = 1, CFrame = CF(POS,Hole.Position) * ANGLES(RAD(-90), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = -5, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(8,11)/10, SoundVolume = 8}) | |
3446 | WACKYEFFECT({Time = 25, EffectType = "Wave", Size = VT(0.3,0,0.3), Size2 = VT(2,0.5,2), Transparency = 0, Transparency2 = 1, CFrame = CF(POS,Hole.Position) * ANGLES(RAD(-90), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = 5, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(8,11)/10, SoundVolume = 8}) | |
3447 | for i=0, 0.3, 0.1 / Animation_Speed do | |
3448 | Swait() | |
3449 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
3450 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.25 / Animation_Speed) | |
3451 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(15), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
3452 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
3453 | end | |
3454 | until KEYHOLD == false | |
3455 | ATTACK = false | |
3456 | Rooted = false | |
3457 | end | |
3458 | ||
3459 | function AttackTemplate() | |
3460 | ATTACK = true | |
3461 | Rooted = false | |
3462 | for i=0, 1, 0.1 / Animation_Speed do | |
3463 | Swait() | |
3464 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
3465 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
3466 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
3467 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
3468 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
3469 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
3470 | end | |
3471 | ATTACK = false | |
3472 | Rooted = false | |
3473 | end | |
3474 | ||
3475 | function HI() | |
3476 | ATTACK = true | |
3477 | Rooted = false | |
3478 | local LOOP = 0 | |
3479 | for i=0, 0.1, 0.1 / Animation_Speed do | |
3480 | Swait() | |
3481 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(15 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3482 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-15 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3483 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.15 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(140), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(5 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3484 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(5-3 * COS(SINE / 6)), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3485 | end | |
3486 | for i=0, 3, 0.1 / Animation_Speed do | |
3487 | Swait() | |
3488 | LOOP = LOOP + 1 | |
3489 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(5 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3490 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-5 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3491 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.15 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(140), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(5 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3492 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.8, 0.4) * ANGLES(RAD(170), RAD(0), RAD(-25 - 25 * SIN(LOOP / 5))) * ANGLES(RAD(0), RAD(-45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3493 | end | |
3494 | for i=0, 0.1, 0.1 / Animation_Speed do | |
3495 | Swait() | |
3496 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(25 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3497 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-25 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3498 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.15 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(140), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(5 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3499 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(5-3 * COS(SINE / 6)), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3500 | end | |
3501 | ATTACK = false | |
3502 | Rooted = false | |
3503 | end | |
3504 | ||
3505 | function Mercy() | |
3506 | ATTACK = true | |
3507 | Rooted = true | |
3508 | local SPOTS = {} | |
3509 | for i = 1, 15 do | |
3510 | Swait() | |
3511 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(25 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3512 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-25 - 2.5 * SIN(SINE / 12))), 0.1 / Animation_Speed) | |
3513 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.75, 0) * ANGLES(RAD(170), RAD(0), RAD(5)) * RIGHTSHOULDERC0, 0.1 / Animation_Speed) | |
3514 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3515 | end | |
3516 | WACKYEFFECT({Time = 15, EffectType = "Block", Size = VT(15,15,15), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0.6, CFrame = Hole.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Maroon".Color, SoundID = nil, SoundPitch = 1, SoundVolume = 7}) | |
3517 | for i=0, 0.5, 0.1 / Animation_Speed do | |
3518 | Swait() | |
3519 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(65 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3520 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-65 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3521 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.75, 0) * ANGLES(RAD(170), RAD(0), RAD(5)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3522 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3523 | end | |
3524 | local HITFLOOR,HITPOS = Raycast(Mouse.Hit.p+VT(0,1,0), (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 150, Character) | |
3525 | table.insert(SPOTS,HITPOS) | |
3526 | CreateSound(145080998, Hole, 2, 1, false) | |
3527 | Lightning({Material = "Neon", FadeIn = false, Color = C3(1,0,0), Start = Hole.CFrame*CF(0, 1, 0.045).p, End = Hole.CFrame*CF(0, 1000, 0.045).p, SegmentL = 1, Thickness = 0.1, DoesFade = true, Ignore = Character, MaxDist = 400, Branches = false, FadeTime = 22, Thicken = false}) | |
3528 | coroutine.resume(coroutine.create(function() | |
3529 | local POS = Mouse.Hit.p | |
3530 | local RAY = CreatePart(3, Effects, "Neon", 0, 0, "Really black", "Strike", VT(0,0,0)) | |
3531 | MakeForm(RAY,"Cyl") | |
3532 | local SPHERE = CreatePart(3, Effects, "Neon", 0, 0, "Really black", "Strike", VT(0,0,0)) | |
3533 | MakeForm(SPHERE,"Ball") | |
3534 | local SHIELD = CreatePart(3, Effects, "Neon", 0, 0.5, "Really black", "Strike", VT(0,0,0)) | |
3535 | MakeForm(SHIELD,"Ball") | |
3536 | SHIELD.CFrame = CF(POS) | |
3537 | RAY.CFrame = CF(POS) | |
3538 | SPHERE.CFrame = CF(POS) | |
3539 | CreateSound(440145570, SPHERE, 10, 0.8, false) | |
3540 | CreateSound(415700134, SPHERE, 10, 0.8, false) | |
3541 | for i = 1, 200 do | |
3542 | Swait() | |
3543 | WACKYEFFECT({Time = 15, EffectType = "Wave", Size = VT(0,0,0), Size2 = VT(SPHERE.Size.X*1.2,5+(i),SPHERE.Size.X*1.2), Transparency = 0, Transparency2 = 1, CFrame = SPHERE.CFrame*ANGLES(RAD(0), RAD(i), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = i, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
3544 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.3,0.3,0.3), Size2 = VT(0,25,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hole.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(1,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3545 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(SPHERE.Size.X*2,5+(i),SPHERE.Size.X*2), Transparency = 0, Transparency2 = 1, CFrame = SPHERE.CFrame*ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(1,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3546 | RAY.Size = RAY.Size + VT(0.05,0,0.05) | |
3547 | SPHERE.Size = SPHERE.Size + VT(0.4,0.4,0.4) | |
3548 | SHIELD.Size = SPHERE.Size + VT(0.5,0.5,0.5) | |
3549 | ApplyKill(SPHERE.Position,SPHERE.Size.X/2,true) | |
3550 | end | |
3551 | for i = 1, 45 do | |
3552 | Swait() | |
3553 | RAY.Transparency = RAY.Transparency + 1/45 | |
3554 | SPHERE.Transparency = RAY.Transparency | |
3555 | SHIELD.Transparency = SPHERE.Transparency + 1/45 | |
3556 | end | |
3557 | RAY:remove() | |
3558 | SHIELD:remove() | |
3559 | SPHERE:remove() | |
3560 | end)) | |
3561 | ATTACK = false | |
3562 | Rooted = false | |
3563 | end | |
3564 | function Warp() | |
3565 | for e = 1, #BODY do | |
3566 | if BODY[e] ~= nil then | |
3567 | local STUFF = BODY[e] | |
3568 | local PART = STUFF[1] | |
3569 | if PART:IsA("BasePart") and PART ~= RootPart and PART.Name ~= "FaceGradient" and PART.Name ~= "Hair" and PART.Transparency ~= 1 then | |
3570 | local PRT = PART:Clone() | |
3571 | PRT.Anchored = true | |
3572 | PRT.CanCollide = false | |
3573 | PRT.Material = "Neon" | |
3574 | PRT.Color = C3(0,0,0) | |
3575 | PRT.Name = "WarpEffect" | |
3576 | PRT.Parent = Effects | |
3577 | PRT.CFrame = PART.CFrame | |
3578 | PRT:BreakJoints() | |
3579 | if PRT:FindFirstChildOfClass("Sound") then | |
3580 | PRT:FindFirstChildOfClass("Sound"):remove() | |
3581 | end | |
3582 | if PRT:FindFirstChildOfClass("Decal") then | |
3583 | PRT:FindFirstChildOfClass("Decal"):remove() | |
3584 | end | |
3585 | coroutine.resume(coroutine.create(function() | |
3586 | for i = 1, 100 do | |
3587 | Swait() | |
3588 | PRT.Transparency = PRT.Transparency + 1/100 | |
3589 | end | |
3590 | PRT:remove() | |
3591 | end)) | |
3592 | end | |
3593 | end | |
3594 | end | |
3595 | CreateSound(217767125, Torso, 10, 1) | |
3596 | local POS = RootPart.Orientation | |
3597 | RootPart.CFrame = CF(Mouse.Hit.p+VT(0,6,0)) | |
3598 | RootPart.Orientation = POS | |
3599 | RootJoint.Parent = RootPart | |
3600 | WACKYEFFECT({EffectType = "Sphere", Size = VT(SIZE*20,0,SIZE*20), Size2 = VT(0,SIZE*750,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Eyes.Position), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 130972023, SoundPitch = 1, SoundVolume = 5}) | |
3601 | ATTACK = false | |
3602 | Rooted = false | |
3603 | end | |
3604 | function killnearest(position,range,maxstrength,BRUTAL,RANGE) | |
3605 | for i,v in ipairs(workspace:GetChildren()) do | |
3606 | local body = v:GetChildren() | |
3607 | for part = 1, #body do | |
3608 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
3609 | if(body[part].Position - position).Magnitude < range then | |
3610 | if v.ClassName == "Model" then | |
3611 | v:BreakJoints() | |
3612 | end | |
3613 | --table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2}) | |
3614 | local bv = Instance.new("BodyVelocity") | |
3615 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
3616 | bv.velocity = CF(position,body[part].Position).lookVector*maxstrength | |
3617 | bv.Parent = body[part] | |
3618 | Debris:AddItem(bv,0.2) | |
3619 | end | |
3620 | end | |
3621 | end | |
3622 | if v.ClassName == "Part" then | |
3623 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
3624 | --table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2}) | |
3625 | v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength | |
3626 | end | |
3627 | end | |
3628 | end | |
3629 | end | |
3630 | function Darkness() | |
3631 | ATTACK = true | |
3632 | Rooted = true | |
3633 | local GYRO = IT("BodyGyro",RootPart) | |
3634 | GYRO.D = 100 | |
3635 | GYRO.P = 2000 | |
3636 | GYRO.MaxTorque = VT(0,4000000,0) | |
3637 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
3638 | CreateSound("429459101", RightArm, 10, 0.8) | |
3639 | for i=0, 3.5, 0.1 / Animation_Speed do | |
3640 | Swait() | |
3641 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
3642 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.3,0.3,0.3), Size2 = VT(0,10,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hole.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3643 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(-25 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3644 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(25 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3645 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.75 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(0), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(5 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3646 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3647 | end | |
3648 | GYRO:remove() | |
3649 | for i=0, 0.15, 0.1 / Animation_Speed do | |
3650 | Swait() | |
3651 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
3652 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.3,0.3,0.3), Size2 = VT(0,10,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hole.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(0,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3653 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(-25 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3654 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(25 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3655 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.75 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(0), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(5 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3656 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3657 | end | |
3658 | local BOMBSPOTS = {} | |
3659 | for i = 1, 25 do | |
3660 | local SPOT = CreatePart(3, Effects, "Neon", 0, 0, "Relly black", "Blade", VT(8,1,8)) | |
3661 | SPOT.Color = SKILLTEXTCOLOR | |
3662 | SPOT.CFrame = RootPart.CFrame*CF((MRANDOM(-15,15)/40)*i,-5,-i*5) | |
3663 | table.insert(BOMBSPOTS,SPOT) | |
3664 | MakeForm(SPOT,"Cyl2") | |
3665 | end | |
3666 | for i=0, 0.2, 0.1 / Animation_Speed do | |
3667 | Swait() | |
3668 | WACKYEFFECT({Time = 15, EffectType = "Block", Size = VT(15,15,15), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0.6, CFrame = Hole.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really black".Color, SoundID = nil, SoundPitch = 1, SoundVolume = 7}) | |
3669 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(-25 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3670 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(25 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3671 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.75 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(0), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(5 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3672 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3673 | end | |
3674 | ATTACK = false | |
3675 | Rooted = false | |
3676 | coroutine.resume(coroutine.create(function() | |
3677 | Swait(3) | |
3678 | for i = 1, #BOMBSPOTS do | |
3679 | if BOMBSPOTS[i] ~= nil then | |
3680 | local E = BOMBSPOTS[i] | |
3681 | coroutine.resume(coroutine.create(function() | |
3682 | local BLADE = CreatePart(3, Effects, "SmoothPlastic", 0, 1, "Relly black", "Blade", VT(0,0,0)) | |
3683 | BLADE.Color = SKILLTEXTCOLOR | |
3684 | CreateMesh("SpecialMesh", BLADE, "FileMesh", "93108071", "", VT(0.6,1,0.4)*3, VT(0,0,0)) | |
3685 | CreateSound(HITWEAPONSOUNDS[MRANDOM(1,#HITWEAPONSOUNDS)], BLADE, 4, 0.6) | |
3686 | BLADE.CFrame = E.CFrame*CF(0,-3,0)*ANGLES(RAD(MRANDOM(-15,15)),RAD(90),RAD(MRANDOM(-15,15))) | |
3687 | for i = 1, 10 do | |
3688 | Swait() | |
3689 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0.5,0.5,0.5), Size2 = VT(0,50,0), Transparency = 0, Transparency2 = 1, CFrame = CF(BLADE.Position) * ANGLES(RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360)), RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-35,35), RotationZ = 0, Material = "Glass", Color = C3(1,0,0), SoundID = nil, SoundPitch = MRANDOM(7,15)/10, SoundVolume = 10}) | |
3690 | killnearest(BLADE.Position,6,80) | |
3691 | BLADE.CFrame = BLADE.CFrame*CF(0,0.3,0) | |
3692 | BLADE.Transparency = BLADE.Transparency - 0.1 | |
3693 | end | |
3694 | Swait(45) | |
3695 | for i = 1, 100 do | |
3696 | Swait() | |
3697 | BLADE.Transparency = BLADE.Transparency + 0.01 | |
3698 | E.Transparency = E.Transparency + 0.01 | |
3699 | end | |
3700 | BLADE:remove() | |
3701 | E:remove() | |
3702 | end)) | |
3703 | end | |
3704 | end | |
3705 | end)) | |
3706 | end | |
3707 | function Death() | |
3708 | if Mouse.Target.Parent ~= Character and Mouse.Target.Parent.Parent ~= Character and Mouse.Target.Parent:FindFirstChildOfClass("Humanoid") ~= nil then | |
3709 | local HUM = Mouse.Target.Parent:FindFirstChildOfClass("Humanoid") | |
3710 | local TORSO = HUM.Parent:FindFirstChild("Torso") or HUM.Parent:FindFirstChild("UpperTorso") | |
3711 | if TORSO and HUM.Health > 0 then | |
3712 | ATTACK = true | |
3713 | Rooted = true | |
3714 | local GYRO = IT("BodyGyro",RootPart) | |
3715 | GYRO.D = 175 | |
3716 | GYRO.P = 20000 | |
3717 | GYRO.MaxTorque = VT(0,40000,0) | |
3718 | for i=0, 1, 0.1 / Animation_Speed do | |
3719 | Swait() | |
3720 | GYRO.cframe = CF(RootPart.Position,TORSO.Position) | |
3721 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(50)), 1 / Animation_Speed) | |
3722 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(-50)), 1 / Animation_Speed) | |
3723 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(50)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3724 | end | |
3725 | WACKYEFFECT({Time = 15, EffectType = "Block", Size = VT(15,15,15), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0.6, CFrame = Hole.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really black".Color, SoundID = nil, SoundPitch = 1, SoundVolume = 7}) | |
3726 | WACKYEFFECT({Time = 15, EffectType = "Block", Size = VT(15,15,15), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0.6, CFrame = Hole.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really black".Color, SoundID = nil, SoundPitch = 1, SoundVolume = 7}) | |
3727 | local MAGIC = ParticleEmitter({Speed = 5, Drag = 3, Size1 = 1.7, Size2 = 0, Lifetime1 = 1, Lifetime2 = 3, Parent = TORSO, Emit = 100, Offset = 360, Enabled = true}) | |
3728 | MAGIC.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,1),NumberSequenceKeypoint.new(1,0)}) | |
3729 | local grav = Instance.new("BodyPosition",TORSO) | |
3730 | grav.D = 1500 | |
3731 | grav.P = 20000 | |
3732 | grav.maxForce = Vector3.new(math.huge,math.huge,math.huge) | |
3733 | grav.position = TORSO.Position+VT(0,15,0) | |
3734 | Debris:AddItem(grav,10) | |
3735 | Debris:AddItem(MAGIC,10) | |
3736 | CreateSound(429459101, Torso, 7, 1, false) | |
3737 | CreateSound(429459101, TORSO, 7, 1, false) | |
3738 | GYRO:remove() | |
3739 | ATTACK = false | |
3740 | Rooted = false | |
3741 | end | |
3742 | end | |
3743 | end | |
3744 | ||
3745 | function TakeOnMe() | |
3746 | Speed = 5 | |
3747 | local MEME = CreateSound(288703954, Effects, 2, 1, false) | |
3748 | ATTACK = true | |
3749 | Rooted = false | |
3750 | local DANCE = true | |
3751 | local KEY = Mouse.KeyDown:connect(function(NEWKEY) | |
3752 | if NEWKEY == "p" then | |
3753 | DANCE = false | |
3754 | end | |
3755 | end) | |
3756 | while true do | |
3757 | for i = 1, 15 do | |
3758 | Swait() | |
3759 | MEME.Parent = Effects | |
3760 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, -0.4+((15-i)/45)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
3761 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
3762 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.55, 0.75, 0) * ANGLES(RAD(0), RAD(0), RAD(-10)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3763 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.55, 0.75, 0) * ANGLES(RAD(0), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3764 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.6, -0.3) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
3765 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, 0, -1) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
3766 | end | |
3767 | if DANCE == false then | |
3768 | break | |
3769 | end | |
3770 | for i = 1, 15 do | |
3771 | Swait() | |
3772 | MEME.Parent = Effects | |
3773 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, -0.4+((15-i)/45)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
3774 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
3775 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.55, 0.75, 0) * ANGLES(RAD(0), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3776 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.55, 0.75, 0) * ANGLES(RAD(0), RAD(0), RAD(10)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3777 | RightHip.C0 = Clerp(RightHip.C0, CF(1, 0, -1) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
3778 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.6, -0.3) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
3779 | end | |
3780 | end | |
3781 | KEY:Disconnect() | |
3782 | MEME:remove() | |
3783 | Speed = 25 | |
3784 | ATTACK = false | |
3785 | Rooted = false | |
3786 | end | |
3787 | ||
3788 | function TimeStop () | |
3789 | local HITFLOOR,HITPOS = Raycast(RootPart.CFrame*CF(0,0,-6.5).p, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4*SIZE, Character) | |
3790 | CHOICE = 6 | |
3791 | CreateSound(1193182658, Character, 5, 1, false) | |
3792 | back = CreateSound(1841228386, Character, 9999, 1, false) | |
3793 | local killsky = Instance.new('Sky', game:GetService'Lighting') | |
3794 | killsky.SkyboxBk = "rbxassetid://1013852" | |
3795 | killsky.SkyboxDn = "rbxassetid://1013853" | |
3796 | killsky.SkyboxFt = "rbxassetid://1013850" | |
3797 | killsky.SkyboxLf = "rbxassetid://1013851" | |
3798 | killsky.SkyboxRt = "rbxassetid://1013849" | |
3799 | killsky.SkyboxUp = "rbxassetid://1013854" | |
3800 | killsky.StarCount = 0 | |
3801 | killsky.SunAngularSize = 0 | |
3802 | killsky.MoonAngularSize = 0 | |
3803 | killsky.MoonTextureId = "" | |
3804 | killsky.CelestialBodiesShown = false | |
3805 | game.Lighting.FogColor = Color3.new(1,1,0) | |
3806 | game.Lighting.FogEnd = 1400 | |
3807 | if HITFLOOR ~= nil then | |
3808 | ATTACK = false | |
3809 | Rooted = false | |
3810 | local RINGSPIN = true | |
3811 | local CONSTRUCTING = true | |
3812 | local RING = CreatePart(3, Effects, "Neon", 0, 1, "New Yeller", "Ring", VT(0,0,0)) | |
3813 | RING.Color = C3(0,0,0) | |
3814 | MakeForm(RING,"Cyl") | |
3815 | RING.CFrame = CF(HITPOS) | |
3816 | coroutine.resume(coroutine.create(function() | |
3817 | repeat | |
3818 | Swait() | |
3819 | RING.CFrame = RING.CFrame * ANGLES(RAD(0), RAD(5), RAD(0)) | |
3820 | until CONSTRUCTING == false | |
3821 | repeat | |
3822 | Swait() | |
3823 | RING.CFrame = RING.CFrame * ANGLES(RAD(0), RAD(5), RAD(0)) | |
3824 | until RINGSPIN == false | |
3825 | for i = 1, 25 do | |
3826 | Swait() | |
3827 | RING.CFrame = RING.CFrame * ANGLES(RAD(0), RAD(5), RAD(0)) | |
3828 | RING.Size = RING.Size - VT(0.15,0,0.15) | |
3829 | --DECAL.Transparency = DECAL.Transparency + 1/25 | |
3830 | RING.Transparency = RING.Transparency + 1/25 | |
3831 | end | |
3832 | RING:remove() | |
3833 | end)) | |
3834 | for i = 1, 15 do | |
3835 | Swait() | |
3836 | RING.Size = RING.Size + VT(0,0,0) | |
3837 | RING.Transparency = RING.Transparency - 1/15 | |
3838 | end | |
3839 | end | |
3840 | local RANDOMEFFECT = MRANDOM(1) | |
3841 | local BASE = CreatePart(3, Character, "Neon", 0, 0, "New Yeller", "Black", VT(2,1.8,2)) | |
3842 | BASE.Color = C3(0,0,0) | |
3843 | BASE.Transparency = 1 | |
3844 | BASE.CFrame = CF(HITPOS+VT(0,-8,0),VT(RootPart.Position.X,HITPOS.Y-8,RootPart.Position.Z)) | |
3845 | if RANDOMEFFECT == 1 then | |
3846 | local FIELD = CreatePart(3, Effects, "Neon", 0, 0, "New Yeller", "Field", VT(0.3,0.3,0.3)) | |
3847 | FIELD.CFrame = BASE.CFrame | |
3848 | MakeForm(FIELD,"Ball") | |
3849 | for i = 1, 50 do | |
3850 | Swait() | |
3851 | FIELD.Size = VT(0,0,0) | |
3852 | FIELD.CFrame = FIELD.CFrame * CF(0,0.75-(i/45),0) | |
3853 | end | |
3854 | end | |
3855 | wait(0.2) | |
3856 | local FIELD = CreatePart(3, Effects, "Neon", 0, 0, "New Yeller", "Field", VT(0.3,0.3,0.3)) | |
3857 | FIELD.CFrame = BASE.CFrame | |
3858 | local LOOP = CreateSound(1393698948, Character, 0, 1, true) | |
3859 | coroutine.resume(coroutine.create(function() | |
3860 | for i = 1, 75 do | |
3861 | Swait() | |
3862 | LOOP.Volume = LOOP.Volume + 10/75 | |
3863 | LOOP.Parent = FIELD | |
3864 | local CHILDREN = workspace:GetDescendants() | |
3865 | for index, CHILD in pairs(CHILDREN) do | |
3866 | if CHILD.ClassName == "Model" and CHILD ~= Character and CHILD.Parent ~= Effects then | |
3867 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
3868 | if HUM then | |
3869 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
3870 | if TORSO then | |
3871 | if (TORSO.Position - FIELD.Position).Magnitude <= FIELD.Size.X/2 then | |
3872 | HUM.Health = HUM.Health - 0 | |
3873 | TORSO.Velocity = VT(0,5,0) | |
3874 | HUM.PlatformStand = true | |
3875 | if TORSO.RotVelocity.Magnitude < 15 then | |
3876 | TORSO.Anchored = true | |
3877 | end | |
3878 | end | |
3879 | end | |
3880 | end | |
3881 | end | |
3882 | end | |
3883 | FIELD.Size = FIELD.Size + VT(90,90,90) | |
3884 | FIELD.Transparency = FIELD.Transparency + 0.8/75 | |
3885 | end | |
3886 | for i = 1, 500 do | |
3887 | Swait() | |
3888 | LOOP.Parent = FIELD | |
3889 | local CHILDREN = workspace:GetDescendants() | |
3890 | for index, CHILD in pairs(CHILDREN) do | |
3891 | if CHILD.ClassName == "Model" and CHILD ~= Character and CHILD.Parent ~= Effects then | |
3892 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
3893 | if HUM then | |
3894 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
3895 | if TORSO then | |
3896 | if (TORSO.Position - FIELD.Position).Magnitude <= FIELD.Size.X/2 then | |
3897 | TORSO.Velocity = VT(0,5,0) | |
3898 | HUM.Health = HUM.Health - 0 | |
3899 | HUM.PlatformStand = true | |
3900 | if TORSO.RotVelocity.Magnitude < 15 then | |
3901 | TORSO.Anchored = true | |
3902 | end | |
3903 | end | |
3904 | end | |
3905 | end | |
3906 | end | |
3907 | end | |
3908 | end | |
3909 | wait (20) | |
3910 | back:Remove() | |
3911 | CreateSound(1538466750, Character, 99999, 1, false) | |
3912 | killsky:Remove() | |
3913 | game.Lighting.FogEnd = 90000000 | |
3914 | wait (5) | |
3915 | CHOICE = MRANDOM (1,5) | |
3916 | for i = 1, 25 do | |
3917 | Swait() | |
3918 | LOOP.Volume = LOOP.Volume + 10/25 | |
3919 | LOOP.Parent = FIELD | |
3920 | local CHILDREN = workspace:GetDescendants() | |
3921 | for index, CHILD in pairs(CHILDREN) do | |
3922 | if CHILD.ClassName == "Model" and CHILD ~= Character and CHILD.Parent ~= Effects then | |
3923 | local HUM = CHILD:FindFirstChildOfClass("Humanoid") | |
3924 | if HUM then | |
3925 | local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso") | |
3926 | if TORSO then | |
3927 | if (TORSO.Position - FIELD.Position).Magnitude <= FIELD.Size.X/1.8 then | |
3928 | TORSO.Velocity = VT(0,5,0) | |
3929 | HUM.Health = HUM.Health - 0 | |
3930 | HUM.PlatformStand = false | |
3931 | if TORSO.RotVelocity.Magnitude < 15 then | |
3932 | TORSO.Anchored = false | |
3933 | end | |
3934 | end | |
3935 | end | |
3936 | end | |
3937 | end | |
3938 | FIELD.Size = FIELD.Size - VT(3,3,3) | |
3939 | FIELD.Transparency = FIELD.Transparency + 0.2/25 | |
3940 | end | |
3941 | end | |
3942 | end)) | |
3943 | FIELD:Remove() | |
3944 | ATTACK = false | |
3945 | Rooted = false | |
3946 | end | |
3947 | ||
3948 | function FingerMagic() | |
3949 | ATTACK = true | |
3950 | Rooted = false | |
3951 | for i=0, 0.1, 0.1 / Animation_Speed do | |
3952 | Swait() | |
3953 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(25 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3954 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-25 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3955 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.15 + 0.25 * COS(SINE / 12), -0.3) * ANGLES(RAD(140), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(5 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3956 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -0.4) * ANGLES(RAD(5-3 * COS(SINE / 6)), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3957 | end | |
3958 | for i=0, 1, 0.1 / Animation_Speed do | |
3959 | Swait() | |
3960 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3961 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(0 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
3962 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(15 + 7.5 * SIN(SINE / 12))) * ANGLES(RAD(0), RAD(-45), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
3963 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.15 + 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(160), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
3964 | end | |
3965 | WACKYEFFECT({Time = 25, EffectType = "Block", Size = VT(0,0,0), Size2 = VT(3,3,3), Transparency = 0, Transparency2 = 1, CFrame = LeftArm.CFrame*CF(0,-1,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = 304999618, SoundPitch = 1, SoundVolume = 1}) | |
3966 | for i = 1, 5 do | |
3967 | WACKYEFFECT({Time = 25, EffectType = "Block", Size = VT(1,1,1), Size2 = VT(0,7,0), Transparency = 0, Transparency2 = 1, CFrame = LeftArm.CFrame*CF(0,-1,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = nil, SoundPitch = 2, SoundVolume = 1}) | |
3968 | end | |
3969 | CreateSound(217767125, LeftArm, 10, 1, false) | |
3970 | coroutine.resume(coroutine.create(function() | |
3971 | local EXPLODED = false | |
3972 | for i = 1, 3 do | |
3973 | coroutine.resume(coroutine.create(function() | |
3974 | local HITFLOOR,HITPOS = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 15, Character) | |
3975 | if HITFLOOR then | |
3976 | local CFRAME = CF(HITPOS) * ANGLES(RAD(0), RAD((360/3)*i), RAD(0)) | |
3977 | for i = 1, 35 do | |
3978 | wait() | |
3979 | for _, c in pairs(workspace:GetChildren()) do | |
3980 | if EXPLODED == false and c.ClassName == "Model" and c:FindFirstChildOfClass("Humanoid") and c ~= Character then | |
3981 | local HUM = c:FindFirstChildOfClass("Humanoid") | |
3982 | local TORSO = c:FindFirstChild("Torso") or c:FindFirstChild("UpperTorso") | |
3983 | if TORSO and HUM.Health > 0 then | |
3984 | if (TORSO.Position - CFRAME.p).Magnitude < 10 then | |
3985 | EXPLODED = true | |
3986 | coroutine.resume(coroutine.create(function() | |
3987 | for i = 1, 15 do | |
3988 | Kill(CFRAME*CF(0,10,0).p,30+(i*4),0,0,-35,false) | |
3989 | wait(0.2) | |
3990 | WACKYEFFECT({Time = 35, EffectType = "Wave", Size = VT(0,0,0), Size2 = VT(15+(i*2),5,15+(i*2)), Transparency = 0, Transparency2 = 1, CFrame = CFRAME, MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-2,2)*15, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = 1, SoundVolume = 7}) | |
3991 | WACKYEFFECT({Time = 25, EffectType = "Block", Size = VT(15,15,15)+VT(i*2,i*2,i*2), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0, CFrame = CFRAME*CF(0,10,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = 304999618, SoundPitch = 1, SoundVolume = 1}) | |
3992 | WACKYEFFECT({Time = 25, EffectType = "Block", Size = VT(12,12,12)+VT(i*2,i*2,i*2), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0, CFrame = CFRAME*CF(0,10,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0.7,0,0), SoundID = nil, SoundPitch = 1, SoundVolume = 1}) | |
3993 | end | |
3994 | WACKYEFFECT({Time = 50, EffectType = "Block", Size = VT(15,15,15)+VT(i*2,i*2,i*2), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0, CFrame = CFRAME*CF(0,10,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = 304999618, SoundPitch = 1, SoundVolume = 1}) | |
3995 | wait(1) | |
3996 | WACKYEFFECT({Time = 60, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(100,100,100)*5, Transparency = 0.4, Transparency2 = 1, CFrame = CFRAME*CF(0,10,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0.3,0,0), SoundID = 461105534, SoundPitch = 1, SoundVolume = 10}) | |
3997 | local PART = CreatePart(3, Effects, "Neon", 0, 1, BRICKC("Pearl"), "Effect", VT(1,1,1), true) | |
3998 | PART.CFrame = CFRAME*CF(0,10,0) | |
3999 | Debris:AddItem(PART,10) | |
4000 | local PARTICLES = script.Explode:Clone() | |
4001 | PARTICLES.Parent = PART | |
4002 | PARTICLES:Emit(500) | |
4003 | Kill(CFRAME*CF(0,10,0).p,45*2,0,0,350,true) | |
4004 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(90,90,90)*2, Transparency = 0.8, Transparency2 = 1, CFrame = CFRAME*CF(0,10,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = nil, SoundPitch = 1, SoundVolume = 3}) | |
4005 | WACKYEFFECT({EffectType = "Ring", Size = VT(00,0.01)/20, Size2 = VT(35,35,0.01), Transparency = 0.7, Transparency2 = 1, CFrame = CFRAME*CF(0,10,0)*ANGLES(RAD(0), RAD(90), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
4006 | WACKYEFFECT({EffectType = "Ring", Size = VT(00,0.01)/20, Size2 = VT(35,35,0.01), Transparency = 0.7, Transparency2 = 1, CFrame = CFRAME*CF(0,10,0)*ANGLES(RAD(90), RAD(0), RAD(0)), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
4007 | end)) | |
4008 | end | |
4009 | end | |
4010 | end | |
4011 | end | |
4012 | if EXPLODED == true then | |
4013 | break | |
4014 | end | |
4015 | CFRAME = CFRAME * ANGLES(RAD(0), RAD(10), RAD(0)) * CF(0,0,-3) | |
4016 | WACKYEFFECT({Time = 35, EffectType = "Wave", Size = VT(10,15,10), Size2 = VT(0,35,0), Transparency = 1, Transparency2 = 0.9, CFrame = CFRAME, MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-2,2)*15, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = 1, SoundVolume = 7}) | |
4017 | WACKYEFFECT({Time = 35, EffectType = "Wave", Size = VT(15,15,15), Size2 = VT(0,25,0), Transparency = 1, Transparency2 = 0.6, CFrame = CFRAME, MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-2,2)*15, RotationZ = 0, Material = "Neon", Color = BRICKC"Maroon".Color, SoundID = nil, SoundPitch = 1, SoundVolume = 7}) | |
4018 | end | |
4019 | end | |
4020 | end)) | |
4021 | end | |
4022 | end)) | |
4023 | for i=0, 1, 0.1 / Animation_Speed do | |
4024 | Swait() | |
4025 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
4026 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(0 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
4027 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(15 + 7.5 * SIN(SINE / 12))) * ANGLES(RAD(0), RAD(-45), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4028 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.15 + 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(170), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(5 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4029 | end | |
4030 | ATTACK = false | |
4031 | Rooted = false | |
4032 | end | |
4033 | ||
4034 | function PainlessRain() | |
4035 | ATTACK = true | |
4036 | Rooted = true | |
4037 | local SPOTS = {} | |
4038 | local BULLETS = 0 | |
4039 | repeat | |
4040 | BULLETS = BULLETS + 1 | |
4041 | for i = 1, 15 do | |
4042 | Swait() | |
4043 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(25 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
4044 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-25 - 2.5 * SIN(SINE / 12))), 0.1 / Animation_Speed) | |
4045 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.75, 0) * ANGLES(RAD(170), RAD(0), RAD(5)) * RIGHTSHOULDERC0, 0.1 / Animation_Speed) | |
4046 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4047 | end | |
4048 | until KEYHOLD == false | |
4049 | for i = 1, BULLETS do | |
4050 | for i=0, 0.5, 0.1 / Animation_Speed do | |
4051 | Swait() | |
4052 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(65 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
4053 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-65 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
4054 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.75, 0) * ANGLES(RAD(170), RAD(0), RAD(5)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4055 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4056 | end | |
4057 | local HITFLOOR,HITPOS = Raycast(Mouse.Hit.p+VT(0,1,0), (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 150, Character) | |
4058 | table.insert(SPOTS,HITPOS) | |
4059 | ||
4060 | for i=0, 0.35, 0.1 / Animation_Speed do | |
4061 | Swait() | |
4062 | ||
4063 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(65 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
4064 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(-65 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
4065 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.75, 0) * ANGLES(RAD(170), RAD(0), RAD(-5)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4066 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0.4) * ANGLES(RAD(-5), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4067 | end | |
4068 | end | |
4069 | coroutine.resume(coroutine.create(function() | |
4070 | for i = 1, #SPOTS do | |
4071 | wait(0.1) | |
4072 | coroutine.resume(coroutine.create(function() | |
4073 | local SPOT = SPOTS[i] | |
4074 | local BOLT = Lightning({Material = "Neon", FadeIn = true, Color = C3(1,0,0), Start = SPOT+VT(0,150,0), End = SPOT, SegmentL = 1, Thickness = 0.1, DoesFade = true, Ignore = Character, MaxDist = 400, Branches = false, FadeTime = 125, Thicken = true}) | |
4075 | local POSITION = BOLT.Pos | |
4076 | ApplyAoE(POSITION,75/2,0,0,350,true) | |
4077 | WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(50,150,50), Transparency = 0.3, Transparency2 = 1, CFrame = CF(POSITION), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,0,0), SoundID = nil, SoundPitch = 1, SoundVolume = 3}) | |
4078 | WACKYEFFECT({Time = 75, EffectType = "Wave", Size = VT(15,0,15), Size2 = VT(75,5,75), Transparency = 0, Transparency2 = 1, CFrame = CF(POSITION), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-2,2)*15, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = 165970126, SoundPitch = 1, SoundVolume = 4}) | |
4079 | WACKYEFFECT({Time = 75, EffectType = "Wave", Size = VT(15,0,15), Size2 = VT(35,15,35), Transparency = 0, Transparency2 = 1, CFrame = CF(POSITION), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-2,2)*15, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = 1, SoundVolume = 7}) | |
4080 | end)) | |
4081 | end | |
4082 | end)) | |
4083 | ATTACK = false | |
4084 | Rooted = false | |
4085 | end | |
4086 | ||
4087 | function Noclip() | |
4088 | ATTACK = true | |
4089 | Rooted = true | |
4090 | UNANCHOR = false | |
4091 | RootPart.Anchored = true | |
4092 | local CLIPPING = true | |
4093 | local MOVEMENT = nil | |
4094 | CreateSound(96098241, Torso, 3, MRANDOM(9,12)/10, false) | |
4095 | for i = 1, 50 do | |
4096 | Swait() | |
4097 | EXTRATRANS = EXTRATRANS + 0.5/50 | |
4098 | RootPart.CFrame = RootPart.CFrame * CF(0,(1-(i/50))/4.3,0) | |
4099 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4100 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4101 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.1, 0.5, -0.45) * ANGLES(RAD(110), RAD(0), RAD(-80)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4102 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.1, 0.15, -0.45) * ANGLES(RAD(80), RAD(0), RAD(80)) * ANGLES(RAD(0), RAD(45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4103 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(-2), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4104 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-70), RAD(0)) * ANGLES(RAD(-2), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4105 | end | |
4106 | local AURA = CreateSound(1393698948, Torso, 3, 1, true) | |
4107 | local KEY = Mouse.KeyDown:connect(function(NEWKEY) | |
4108 | if NEWKEY == "w" then | |
4109 | MOVEMENT = "Forward" | |
4110 | repeat | |
4111 | Swait() | |
4112 | RootPart.CFrame = RootPart.CFrame * CF(0,0,-0.2) | |
4113 | until KEYHOLD == false | |
4114 | elseif NEWKEY == "s" then | |
4115 | MOVEMENT = "Backwards" | |
4116 | repeat | |
4117 | Swait() | |
4118 | RootPart.CFrame = RootPart.CFrame * CF(0,0,0.2) | |
4119 | until KEYHOLD == false | |
4120 | elseif NEWKEY == "a" then | |
4121 | MOVEMENT = "Strafe" | |
4122 | repeat | |
4123 | Swait() | |
4124 | RootPart.CFrame = RootPart.CFrame * CF(0.2,0,0) | |
4125 | until KEYHOLD == false | |
4126 | elseif NEWKEY == "d" then | |
4127 | MOVEMENT = "Strafe" | |
4128 | repeat | |
4129 | Swait() | |
4130 | RootPart.CFrame = RootPart.CFrame * CF(-0.2,0,0) | |
4131 | until KEYHOLD == false | |
4132 | elseif NEWKEY == "e" then | |
4133 | CLIPPING = false | |
4134 | end | |
4135 | MOVEMENT = nil | |
4136 | end) | |
4137 | local LOOP = 0 | |
4138 | repeat | |
4139 | Swait() | |
4140 | AURA.Parent = Torso | |
4141 | LOOP = LOOP + 1 | |
4142 | if LOOP >= 15 then | |
4143 | LOOP = 0 | |
4144 | WACKYEFFECT({Time = 15, EffectType = "Wave", Size = VT(5,0,5), Size2 = VT(15,1,15), Transparency = 0.7, Transparency2 = 1, CFrame = CF(RootPart.CFrame*CF(0,-3.5,0).p), MoveToPos = nil, RotationX = 0, RotationY = MRANDOM(-2,2)*15, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = nil, SoundPitch = nil, SoundVolume = nil}) | |
4145 | end | |
4146 | if MOVEMENT == nil then | |
4147 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4148 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4149 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.1, 0.5, -0.45) * ANGLES(RAD(110), RAD(0), RAD(-80)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4150 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.1, 0.15, -0.45) * ANGLES(RAD(80), RAD(0), RAD(80)) * ANGLES(RAD(0), RAD(45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4151 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.3 - 0.1 * SIN(SINE / 12), -0.6) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4152 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.1 * SIN(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4153 | elseif MOVEMENT == "Forward" then | |
4154 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(15), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4155 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4156 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.1, 0.5, -0.45) * ANGLES(RAD(110), RAD(0), RAD(-80)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4157 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.1, 0.15, -0.45) * ANGLES(RAD(80), RAD(0), RAD(80)) * ANGLES(RAD(0), RAD(45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4158 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.3 - 0.1 * SIN(SINE / 12), -0.6) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4159 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.1 * SIN(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4160 | elseif MOVEMENT == "Backwards" then | |
4161 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(-15), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4162 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4163 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.1, 0.5, -0.45) * ANGLES(RAD(110), RAD(0), RAD(-80)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4164 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.1, 0.15, -0.45) * ANGLES(RAD(80), RAD(0), RAD(80)) * ANGLES(RAD(0), RAD(45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4165 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.3 - 0.1 * SIN(SINE / 12), -0.6) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4166 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.1 * SIN(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4167 | elseif MOVEMENT == "Strafe" then | |
4168 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(2), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4169 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(10 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4170 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.1, 0.5, -0.45) * ANGLES(RAD(110), RAD(0), RAD(-80)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4171 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.1, 0.15, -0.45) * ANGLES(RAD(80), RAD(0), RAD(80)) * ANGLES(RAD(0), RAD(45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4172 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.3 - 0.1 * SIN(SINE / 12), -0.6) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4173 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.1 * SIN(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4174 | end | |
4175 | until CLIPPING == false | |
4176 | KEY:Disconnect() | |
4177 | coroutine.resume(coroutine.create(function() | |
4178 | for i = 1, 20 do | |
4179 | Swait() | |
4180 | AURA.Volume = AURA.Volume - 3/20 | |
4181 | end | |
4182 | AURA:remove() | |
4183 | end)) | |
4184 | CreateSound(814168787, Torso, 1, MRANDOM(9,12)/10, false) | |
4185 | for i = 1, 50 do | |
4186 | Swait() | |
4187 | EXTRATRANS = EXTRATRANS - 0.5/50 | |
4188 | RootPart.CFrame = RootPart.CFrame * CF(0,-(1-(i/50))/4.3,0) | |
4189 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4190 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4191 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.1, 0.5, -0.45) * ANGLES(RAD(110), RAD(0), RAD(-80)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4192 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.1, 0.15, -0.45) * ANGLES(RAD(80), RAD(0), RAD(80)) * ANGLES(RAD(0), RAD(45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4193 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(-2), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4194 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-70), RAD(0)) * ANGLES(RAD(-2), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4195 | end | |
4196 | EXTRATRANS = 0 | |
4197 | UNANCHOR = true | |
4198 | ATTACK = false | |
4199 | Rooted = false | |
4200 | end | |
4201 | ||
4202 | --//=================================\\ | |
4203 | --|| ASSIGN THINGS TO KEYS | |
4204 | --\\=================================// | |
4205 | ||
4206 | function MouseDown(Mouse) | |
4207 | HOLD = true | |
4208 | if ATTACK == false then | |
4209 | end | |
4210 | end | |
4211 | ||
4212 | function MouseUp(Mouse) | |
4213 | HOLD = false | |
4214 | end | |
4215 | ||
4216 | function KeyDown(Key) | |
4217 | KEYHOLD = true | |
4218 | if Key == "q" and ATTACK == false then | |
4219 | Warp() | |
4220 | end | |
4221 | ||
4222 | if Key == "b" and ATTACK == false then | |
4223 | TimeStop() | |
4224 | end | |
4225 | ||
4226 | if Key == "v" and ATTACK == false then | |
4227 | Madness() | |
4228 | end | |
4229 | ||
4230 | if Key == "x" and ATTACK == false then | |
4231 | Mercy() | |
4232 | end | |
4233 | ||
4234 | if Key == "t" and ATTACK == false then | |
4235 | HI() | |
4236 | end | |
4237 | ||
4238 | if Key == "f" and ATTACK == false then | |
4239 | FingerMagic() | |
4240 | end | |
4241 | ||
4242 | if Key == "r" and ATTACK == false then | |
4243 | PainlessRain() | |
4244 | end | |
4245 | ||
4246 | if Key == "z" and ATTACK == false then | |
4247 | Darkness() | |
4248 | end | |
4249 | ||
4250 | if Key == "c" and ATTACK == false then | |
4251 | Banisher_Bullet() | |
4252 | end | |
4253 | ||
4254 | if Key == "e" and ATTACK == false then | |
4255 | Noclip() | |
4256 | end | |
4257 | ||
4258 | if Key == "p" and ATTACK == false then | |
4259 | TakeOnMe() | |
4260 | end | |
4261 | end | |
4262 | ||
4263 | function KeyUp(Key) | |
4264 | KEYHOLD = false | |
4265 | end | |
4266 | ||
4267 | Mouse.Button1Down:connect(function(NEWKEY) | |
4268 | MouseDown(NEWKEY) | |
4269 | end) | |
4270 | Mouse.Button1Up:connect(function(NEWKEY) | |
4271 | MouseUp(NEWKEY) | |
4272 | end) | |
4273 | Mouse.KeyDown:connect(function(NEWKEY) | |
4274 | KeyDown(NEWKEY) | |
4275 | end) | |
4276 | Mouse.KeyUp:connect(function(NEWKEY) | |
4277 | KeyUp(NEWKEY) | |
4278 | end) | |
4279 | ||
4280 | --//=================================\\ | |
4281 | --\\=================================// | |
4282 | ||
4283 | ||
4284 | function unanchor() | |
4285 | if UNANCHOR == true then | |
4286 | RootPart.Anchored = false | |
4287 | end | |
4288 | g = Character:GetChildren() | |
4289 | for i = 1, #g do | |
4290 | if g[i].ClassName == "Part" and g[i] ~= RootPart then | |
4291 | g[i].Anchored = false | |
4292 | end | |
4293 | end | |
4294 | g = Weapon:GetChildren() | |
4295 | for i = 1, #g do | |
4296 | if g[i].ClassName == "Part" then | |
4297 | g[i].Anchored = false | |
4298 | end | |
4299 | end | |
4300 | end | |
4301 | ||
4302 | ||
4303 | --//=================================\\ | |
4304 | --|| WRAP THE WHOLE SCRIPT UP | |
4305 | --\\=================================// | |
4306 | ||
4307 | Humanoid.Changed:connect(function(Jump) | |
4308 | if Jump == "Jump" and (Disable_Jump == true) then | |
4309 | Humanoid.Jump = false | |
4310 | end | |
4311 | end) | |
4312 | ||
4313 | while true do | |
4314 | Swait() | |
4315 | refit() | |
4316 | script.Parent = WEAPONGUI | |
4317 | for _,v in next, Humanoid:GetPlayingAnimationTracks() do | |
4318 | v:Stop(); | |
4319 | end | |
4320 | ANIMATE.Parent = nil | |
4321 | SINE = SINE + CHANGE*1.5 | |
4322 | local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude | |
4323 | local TORSOVERTICALVELOCITY = RootPart.Velocity.y | |
4324 | local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4*SIZE, Character) | |
4325 | local WALKSPEEDVALUE = 10 / (Humanoid.WalkSpeed / 16) | |
4326 | if ANIM == "Walk" and TORSOVELOCITY > 1 then | |
4327 | RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0 * COS(SINE / (WALKSPEEDVALUE / 2)) * SIZE) * ANGLES(RAD(0), RAD(0) - RootPart.RotVelocity.Y / 75, RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
4328 | Neck.C1 = Clerp(Neck.C1, CF(0 * SIZE, -0.5 * SIZE, 0 * SIZE) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(2.5 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0) - Head.RotVelocity.Y / 30), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
4329 | elseif (ANIM ~= "Walk") or (TORSOVELOCITY < 1) then | |
4330 | RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
4331 | Neck.C1 = Clerp(Neck.C1, CF(0 * SIZE, -0.5 * SIZE, 0 * SIZE) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
4332 | end | |
4333 | if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then | |
4334 | ANIM = "Jump" | |
4335 | if ATTACK == false then | |
4336 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0*SIZE, 0*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4337 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0*SIZE, 0*SIZE, 0 + ((1.1*SIZE) - 1)) * ANGLES(RAD(-20), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4338 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5*SIZE, 0.5*SIZE, 0*SIZE) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4339 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5*SIZE, 0.5*SIZE, 0*SIZE) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4340 | RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -1*SIZE, -0.3*SIZE) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-20)), 1 / Animation_Speed) | |
4341 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE, -0.3*SIZE) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(20)), 1 / Animation_Speed) | |
4342 | end | |
4343 | elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then | |
4344 | ANIM = "Fall" | |
4345 | if ATTACK == false then | |
4346 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0*SIZE, 0*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4347 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0*SIZE, 0*SIZE, 0 + ((1.1*SIZE) - 1)) * ANGLES(RAD(20), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4348 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5*SIZE, 0.5*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(0), RAD(60)) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4349 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5*SIZE, 0.5*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(0), RAD(-60)) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4350 | RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -1*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(20)), 1 / Animation_Speed) | |
4351 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 1 / Animation_Speed) | |
4352 | end | |
4353 | elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then | |
4354 | ANIM = "Idle" | |
4355 | if ATTACK == false then | |
4356 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 1 + 0.5 * COS(SINE / 12)) * ANGLES(RAD(0 - 3 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4357 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1.1*SIZE) - 1)) * ANGLES(RAD(0 - 5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4358 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(0.75*SIZE, 0.5*SIZE, -1*SIZE) * ANGLES(RAD(70), RAD(0), RAD(-70)) * ANGLES(RAD(20), RAD(25), RAD(-15)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed) | |
4359 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1*SIZE, 0.2*SIZE, -0.5*SIZE) * ANGLES(RAD(25), RAD(0), RAD(85)) * LEFTSHOULDERC0, 0.4 / Animation_Speed) | |
4360 | RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -0.5*SIZE - 0.05*SIZE * COS(SINE / 12), -0.5*SIZE) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4361 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -0.8*SIZE - 0.05*SIZE * COS(SINE / 12), -0.01*SIZE) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4362 | end | |
4363 | elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then | |
4364 | ANIM = "Walk" | |
4365 | if ATTACK == false then | |
4366 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 1 + 0.5 * COS(SINE / 12)) * ANGLES(RAD(15), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4367 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1.1*SIZE) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed) | |
4368 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25*SIZE, 0.5*SIZE, 0.5*SIZE) * ANGLES(RAD(-35), RAD(-25 + 2.5 * SIN(SINE / WALKSPEEDVALUE)), RAD(-55 + 2.5 * SIN(SINE / WALKSPEEDVALUE))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
4369 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25*SIZE, 0.5*SIZE, 0.5*SIZE) * ANGLES(RAD(-35), RAD(25 - 2.5 * SIN(SINE / WALKSPEEDVALUE)), RAD(55 - 2.5 * SIN(SINE / WALKSPEEDVALUE))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
4370 | RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -0.5*SIZE - 0.05*SIZE * COS(SINE / 12), -0.5*SIZE) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4371 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -0.8*SIZE - 0.05*SIZE * COS(SINE / 12), -0.01*SIZE) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
4372 | end | |
4373 | end | |
4374 | unanchor() | |
4375 | Humanoid.MaxHealth = "inf" | |
4376 | Humanoid.Health = "inf" | |
4377 | if Rooted == false then | |
4378 | Disable_Jump = false | |
4379 | Humanoid.WalkSpeed = Speed | |
4380 | elseif Rooted == true then | |
4381 | Disable_Jump = true | |
4382 | Humanoid.WalkSpeed = 0 | |
4383 | end | |
4384 | for _, c in pairs(Character:GetChildren()) do | |
4385 | if c.ClassName == "Part" and c.Name ~= "Detail" then | |
4386 | c.Material = "Fabric" | |
4387 | if c:FindFirstChildOfClass("ParticleEmitter") then | |
4388 | c:FindFirstChildOfClass("ParticleEmitter"):remove() | |
4389 | end | |
4390 | if c ~= Head then | |
4391 | c.Color = C3(0,0,0) | |
4392 | else | |
4393 | c.Color = C3(0,0,0) | |
4394 | end | |
4395 | if c == Head then | |
4396 | if c:FindFirstChild("face") then | |
4397 | c.face:remove() | |
4398 | end | |
4399 | end | |
4400 | elseif c.ClassName == "CharacterMesh" or c.ClassName == "Accessory" or c.Name == "Body Colors" then | |
4401 | c:remove() | |
4402 | elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") and c.Name ~= "Cloth" then | |
4403 | c:remove() | |
4404 | end | |
4405 | end | |
4406 | sick.SoundId = "rbxassetid://"..bored[CHOICE] | |
4407 | sick.Looped = true | |
4408 | sick.Pitch = 1 | |
4409 | sick.Volume = 999999 | |
4410 | sick.Parent = Character | |
4411 | sick:Resume() | |
4412 | --sick.Playing = false | |
4413 | Humanoid.Name = "Master of Time = "..Player.Name | |
4414 | end | |
4415 | ||
4416 | --//=================================\\ | |
4417 | --\\=================================// | |
4418 | ||
4419 | ||
4420 | ||
4421 | ||
4422 | ||
4423 | --//====================================================\\-- | |
4424 | --|| END OF SCRIPT | |
4425 | --\\====================================================//-- | |
4426 | ||
4427 | lol = getcustomasset or getsynasset | |
4428 | getgenv().LoadLibrary = function(lib) return loadstring(game:HttpGet("https://raw.githubusercontent.com/Roblox/Core-Scripts/master/CoreScriptsRoot/Libraries/" .. lib .. ".lua"))() end |