SHOW:
|
|
- or go back to the newest paste.
1 | --https://github.com/Mokiros/roblox-FE-compatibility | |
2 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end | |
3 | local Player,game,owner = owner,game | |
4 | local RealPlayer = Player | |
5 | do print("FE Compatibility code V2 by Mokiros")local RealPlayer=RealPlayer;script.Parent=RealPlayer.Character;local a=function(b)b[1].f[b[2]]=nil end;local c={__index={disconnect=a,Disconnect=a}}local d={__index={Connect=function(b,e)local f=tostring(math.random(0,10000))while b.f[f]do f=tostring(math.random(0,10000))end;b.f[f]=e;return setmetatable({b,f},c)end}}d.__index.connect=d.__index.Connect;local function g()return setmetatable({f={}},d)end;local h={Hit=CFrame.new(),KeyUp=g(),KeyDown=g(),Button1Up=g(),Button1Down=g(),Button2Up=g(),Button2Down=g()}h.keyUp=h.KeyUp;h.keyDown=h.KeyDown;local i={InputBegan=g(),InputEnded=g()}local CAS={Actions={},BindAction=function(self,j,k,l,...)CAS.Actions[j]=k and{Name=j,Function=k,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function m(self,n,...)for o,e in pairs(self[n].f)do e(...)end end;h.T=m;i.T=m;local p=Instance.new("RemoteEvent")p.Name="UserInput_Event"p.OnServerEvent:Connect(function(q,r)if q~=RealPlayer then return end;h.Target=r.e;h.Hit=r.d;if not r.f then local s=r.c==Enum.UserInputState.Begin;if r.b==Enum.UserInputType.MouseButton1 then return h:T(s and"Button1Down"or"Button1Up")end;if r.b==Enum.UserInputType.MouseButton2 then return h:T(s and"Button2Down"or"Button2Up")end;for o,t in pairs(CAS.Actions)do for o,u in pairs(t.Keys)do if u==r.a then t.Function(t.Name,r.c,r)end end end;h:T(s and"KeyDown"or"KeyUp",r.a.Name:lower())i:T(s and"InputBegan"or"InputEnded",r,false)end end)p.Parent=NLS([==[local a=script:WaitForChild("UserInput_Event")local b=owner:GetMouse()local c=game:GetService("UserInputService")local d=function(e,f)if f then return end;a:FireServer({a=e.KeyCode,b=e.UserInputType,c=e.UserInputState,d=b.Hit,e=b.Target})end;c.InputBegan:Connect(d)c.InputEnded:Connect(d)local g,h;local i=game:GetService("RunService").Heartbeat;while true do if g~=b.Hit or h~=b.Target then g,h=b.Hit,b.Target;a:FireServer({f=1,Target=h,d=g})end;for j=1,2 do i:Wait()end end]==],script)local v=game;local w={__index=function(self,u)local x=rawget(self,"_RealService")if x then return typeof(x[u])=="function"and function(o,...)return x[u](x,...)end or x[u]end end,__newindex=function(self,u,y)local x=rawget(self,"_RealService")if x then x[u]=y end end}local function z(t,A)t._RealService=typeof(A)=="string"and v:GetService(A)or A;return setmetatable(t,w)end;local B={GetService=function(self,x)return rawget(self,x)or v:GetService(x)end,Players=z({LocalPlayer=z({GetMouse=function(self)return h end},Player)},"Players"),UserInputService=z(i,"UserInputService"),ContextActionService=z(CAS,"ContextActionService"),RunService=z({_btrs={},RenderStepped=v:GetService("RunService").Heartbeat,BindToRenderStep=function(self,j,o,k)self._btrs[j]=self.Heartbeat:Connect(k)end,UnbindFromRenderStep=function(self,j)self._btrs[j]:Disconnect()end},"RunService")}rawset(B.Players,"localPlayer",B.Players.LocalPlayer)B.service=B.GetService;z(B,game)game,owner=B,B.Players.LocalPlayer end local Player = game:GetService("Players").LocalPlayer | |
6 | local Character = Player.Character | |
7 | local Torso = Character.Torso | |
8 | ||
9 | ca=CFrame.Angles | |
10 | cn=CFrame.new | |
11 | it=Instance.new | |
12 | rd=math.rad | |
13 | v3=Vector3.new | |
14 | ||
15 | Interpolate = function(CFrame1, CFrame2) | |
16 | local Table1 = {CFrame1:components()} | |
17 | local Table2 = {CFrame2:components()} | |
18 | local NewCFrame = {} | |
19 | for i,v in ipairs(Table1) do | |
20 | local Difference = Table2[i] - v | |
21 | if i < 4 then | |
22 | local NewValue | |
23 | if math.abs(Difference) < 0.1 then | |
24 | NewValue = Table2[i] | |
25 | else | |
26 | NewValue = v + ((Difference/math.abs(Difference)) * 0.1) | |
27 | end | |
28 | NewCFrame[i] = NewValue | |
29 | else | |
30 | local NewValue | |
31 | if math.abs(Difference) < 0.1 then | |
32 | - | sick.SoundId = "rbxassetid://1237585433" |
32 | + | NewValue = Table2[i] |
33 | else | |
34 | - | sick.Pitch = .9 |
34 | + | NewValue = v + ((Difference/math.abs(Difference)) * 0.1) |
35 | end | |
36 | NewCFrame[i] = NewValue | |
37 | end | |
38 | end | |
39 | return CFrame.new(unpack(NewCFrame)) | |
40 | end | |
41 | ||
42 | Prop = function(Parent, Name, x, y, z, Anchored, CanCollide, Color) | |
43 | local Part = Instance.new("Part",Parent) | |
44 | Part.Name = Name | |
45 | Part.FormFactor = 3 | |
46 | Part.Size = Vector3.new(x, y, z) | |
47 | Part.Anchored = Anchored | |
48 | Part.CanCollide = CanCollide | |
49 | Part.BrickColor = BrickColor.new(Color) | |
50 | Part.TopSurface = 0 | |
51 | Part.BottomSurface = 0 | |
52 | Part:BreakJoints() | |
53 | return Part | |
54 | end | |
55 | ||
56 | Mesh = function(Parent, MeshType,x, y, z,MeshId,TextureId) | |
57 | local Mesh = nil | |
58 | if MeshType=="CylinderMesh" then | |
59 | Mesh=Instance.new("CylinderMesh",Parent) | |
60 | Mesh.Scale=Vector3.new(x,y,z) | |
61 | elseif MeshType~="BlockMesh" and MeshType~="CylinderMesh" then | |
62 | Mesh=Instance.new("SpecialMesh",Parent) | |
63 | Mesh.MeshType = MeshType | |
64 | Mesh.MeshId = MeshId or "" | |
65 | Mesh.Scale = Vector3.new(x, y, z) | |
66 | return Mesh | |
67 | end | |
68 | end | |
69 | ||
70 | Weld = function(Part0, Part1, C0, C1) | |
71 | local Weld = Instance.new("Weld",Part0) | |
72 | Weld.Part0 = Part0 | |
73 | Weld.Part1 = Part1 | |
74 | Weld.C0 = C0 or CFrame.new() | |
75 | Weld.C1 = C1 or CFrame.new() | |
76 | return Weld | |
77 | end | |
78 | ||
79 | local Handle = Prop(Character, "Handle", 0.2, 1.5, 0.2, false, false, "Really black") | |
80 | Weld(Torso, Handle, CFrame.new(0, 5, 0)) | |
81 | local Guard = Prop(Character, "Guard", 1.5,0.1,0.2,false, false, "Really black") | |
82 | Weld(Handle, Guard, CFrame.new(0, 1.5/2, 0)) | |
83 | local Pivot = Prop(Character,"",0,0,0,false,false,"") -- this is basicly an invisible part | |
84 | local Pivot2 = Prop(Character,"",0,0,0,false,false,"") | |
85 | Pivot.Transparency = 1 | |
86 | Pivot2.Transparency = 1 | |
87 | Weld(Guard,Pivot,CFrame.new(0,-0.75,0)*CFrame.Angles(0,0,math.rad(-40-90))) | |
88 | Weld(Guard,Pivot2,CFrame.new(0,0.75,0)*CFrame.Angles(0,0,math.rad(40+90))) | |
89 | local Guard2 = Prop(Character, "Guard2", 0.1, 0.5, 0.2, false, false, "Really black") | |
90 | Weld(Pivot, Guard2, CFrame.new(0, -0.25, 0)) | |
91 | local Guard3 = Prop(Character, "Guard3", 0.1, 0.5, 0.2, false, false, "Really black") | |
92 | Weld(Pivot2, Guard3, CFrame.new(0, 0.25, 0)) | |
93 | local Design = Prop(Character, "Design", 0.5, 1, 0.5, false, false, "Gold") | |
94 | Mesh(Design, "FileMesh", 0.5, 1, 0.5,"http://www.roblox.com/Asset/?id=9756362") | |
95 | Weld(Handle, Design, CFrame.new(0, -0.75, 0)) | |
96 | local Ball = Prop(Character, "Ball1", 0.3, 0.3, 0.3, false, false, "Gold") | |
97 | Mesh(Ball, "Sphere", 1, 1, 1) | |
98 | Weld(Pivot, Ball) | |
99 | local Ball2 = Prop(Character, "Ball2", 0.3, 0.3, 0.3, false, false, "Gold") | |
100 | Mesh(Ball2, "Sphere", 1, 1, 1) | |
101 | Weld(Pivot2, Ball2) | |
102 | local Spike = Prop(Character, "Spike1", 0.1, 1, 0.1, false, false, "Gold") | |
103 | Mesh(Spike, "FileMesh", 0.1, 1, 0.1,"http://www.roblox.com/asset/?id=1033714") | |
104 | Weld(Pivot, Spike, CFrame.new(-0.3, 0, 0) * CFrame.Angles(math.rad(0), 0, math.rad(90))) | |
105 | local Spike2 = Prop(Character, "Spike2", 0.1, 1, 0.1, false, false, "Gold") | |
106 | Mesh(Spike2, "FileMesh", 0.1, 1, 0.1, "http://www.roblox.com/asset/?id=1033714") | |
107 | Weld(Pivot2, Spike2, CFrame.new(-0.3, 0, 0) * CFrame.Angles(math.rad(0), 0, math.rad(90))) | |
108 | Mesh(Handle, "CylinderMesh", 1, 1, 1) --//====================================================\\-- | |
109 | --|| CREATED BY SHACKLUSTER | |
110 | --\\====================================================//-- | |
111 | ||
112 | ||
113 | ||
114 | wait(0.2) | |
115 | ||
116 | ||
117 | ||
118 | Player = game:GetService("Players").LocalPlayer | |
119 | PlayerGui = Player.PlayerGui | |
120 | Cam = workspace.CurrentCamera | |
121 | Backpack = Player.Backpack | |
122 | Character = Player.Character | |
123 | Humanoid = Character.Humanoid | |
124 | Mouse = Player:GetMouse() | |
125 | RootPart = Character["HumanoidRootPart"] | |
126 | Torso = Character["Torso"] | |
127 | Head = Character["Head"] | |
128 | RightArm = Character["Right Arm"] | |
129 | LeftArm = Character["Left Arm"] | |
130 | RightLeg = Character["Right Leg"] | |
131 | LeftLeg = Character["Left Leg"] | |
132 | RootJoint = RootPart["RootJoint"] | |
133 | Neck = Torso["Neck"] | |
134 | RightShoulder = Torso["Right Shoulder"] | |
135 | LeftShoulder = Torso["Left Shoulder"] | |
136 | RightHip = Torso["Right Hip"] | |
137 | LeftHip = Torso["Left Hip"] | |
138 | local sick = Instance.new("Sound",Character) | |
139 | sick.SoundId = "rbxassetid://2483634238" | |
140 | sick.Looped = true | |
141 | sick.Pitch = 1 | |
142 | sick.Volume = 1 | |
143 | sick:Play() | |
144 | ||
145 | IT = Instance.new | |
146 | CF = CFrame.new | |
147 | VT = Vector3.new | |
148 | RAD = math.rad | |
149 | C3 = Color3.new | |
150 | UD2 = UDim2.new | |
151 | BRICKC = BrickColor.new | |
152 | ANGLES = CFrame.Angles | |
153 | EULER = CFrame.fromEulerAnglesXYZ | |
154 | COS = math.cos | |
155 | ACOS = math.acos | |
156 | SIN = math.sin | |
157 | ASIN = math.asin | |
158 | ABS = math.abs | |
159 | MRANDOM = math.random | |
160 | FLOOR = math.floor | |
161 | ||
162 | --//=================================\\ | |
163 | --|| CUSTOMIZATION | |
164 | --\\=================================// | |
165 | ||
166 | Class_Name = "Greed" | |
167 | Weapon_Name = "Add-ons" | |
168 | ||
169 | Custom_Colors = { | |
170 | Custom_Color_1 = BRICKC("Institutional white"); --1st color for the weapon. | |
171 | Custom_Color_2 = BRICKC("Institutional white"); --2nd color for the weapon. | |
172 | ||
173 | Custom_Color_3 = BRICKC("Institutional white"); --Color for the abilities. | |
174 | Custom_Color_4 = BRICKC("Institutional white"); --Color for the secondary bar. | |
175 | Custom_Color_5 = BRICKC("Institutional white"); --Color for the mana bar. | |
176 | Custom_Color_6 = BRICKC("Institutional white"); --Color for the health bar. | |
177 | Custom_Color_7 = BRICKC("Institutional white"); --Color for the stun bar. | |
178 | ||
179 | Custom_Color_8 = BRICKC("Institutional white"); --Background for the mana bar. | |
180 | Custom_Color_9 = BRICKC("Institutional white"); --Background for the secondary mana bar. | |
181 | Custom_Color_10 = BRICKC("Institutional white"); --Background for the stun bar. | |
182 | Custom_Color_11 = BRICKC("Institutional white"); --Background for the health bar. | |
183 | Custom_Color_12 = BRICKC("Institutional white"); --Background for the abilities. | |
184 | } | |
185 | ||
186 | ||
187 | Player_Size = 1 --Size of the player. | |
188 | Animation_Speed = 3 | |
189 | Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60) | |
190 | ||
191 | local Speed = 9 | |
192 | local Effects2 = {} | |
193 | ||
194 | --//=================================\\ | |
195 | --|| END OF CUSTOMIZATION | |
196 | --\\=================================// | |
197 | ||
198 | local function weldBetween(a, b) | |
199 | local weldd = Instance.new("ManualWeld") | |
200 | weldd.Part0 = a | |
201 | weldd.Part1 = b | |
202 | weldd.C0 = CFrame.new() | |
203 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
204 | weldd.Parent = a | |
205 | return weldd | |
206 | end | |
207 | ||
208 | --//=================================\\ | |
209 | --|| USEFUL VALUES | |
210 | --\\=================================// | |
211 | ||
212 | local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
213 | local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
214 | local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) | |
215 | local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) | |
216 | local CO1 = 0 | |
217 | local CO2 = 0 | |
218 | local CO3 = 0 | |
219 | local CO4 = 0 | |
220 | local CHANGEDEFENSE = 0 | |
221 | local CHANGEDAMAGE = 0 | |
222 | local CHANGEMOVEMENT = 0 | |
223 | local ANIM = "Idle" | |
224 | local ATTACK = false | |
225 | local EQUIPPED = false | |
226 | local HOLD = false | |
227 | local COMBO = 1 | |
228 | local LASTPOINT = nil | |
229 | local BLCF = nil | |
230 | local SCFR = nil | |
231 | local STAGGERHITANIM = false | |
232 | local STAGGERANIM = false | |
233 | local STUNANIM = false | |
234 | local CRITCHANCENUMBER = 0 | |
235 | local IDLENUMBER = 0 | |
236 | local DONUMBER = 0 | |
237 | local HANDIDLE = false | |
238 | local Rooted = false | |
239 | local SINE = 0 | |
240 | local CHANGE = 2 / Animation_Speed | |
241 | local WALKINGANIM = false | |
242 | local WALK = 0 | |
243 | local DISABLEJUMPING = false | |
244 | local ROBLOXIDLEANIMATION = IT("Animation") | |
245 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
246 | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" | |
247 | --ROBLOXIDLEANIMATION.Parent = Humanoid | |
248 | local ANIMATOR = Humanoid.Animator | |
249 | local ANIMATE = Character.Animate | |
250 | local UNANCHOR = true | |
251 | ||
252 | local SKILLTEXTCOLOR = C3(0,0,0) | |
253 | ||
254 | --//=================================\\ | |
255 | --\\=================================// | |
256 | ||
257 | ||
258 | --//=================================\\ | |
259 | --|| SAZERENOS' ARTIFICIAL HEARTBEAT | |
260 | --\\=================================// | |
261 | ||
262 | ArtificialHB = Instance.new("BindableEvent", script) | |
263 | ArtificialHB.Name = "ArtificialHB" | |
264 | ||
265 | script:WaitForChild("ArtificialHB") | |
266 | ||
267 | frame = Frame_Speed | |
268 | tf = 0 | |
269 | allowframeloss = false | |
270 | tossremainder = false | |
271 | lastframe = tick() | |
272 | script.ArtificialHB:Fire() | |
273 | ||
274 | game:GetService("RunService").Heartbeat:connect(function(s, p) | |
275 | tf = tf + s | |
276 | if tf >= frame then | |
277 | if allowframeloss then | |
278 | script.ArtificialHB:Fire() | |
279 | lastframe = tick() | |
280 | else | |
281 | for i = 1, math.floor(tf / frame) do | |
282 | script.ArtificialHB:Fire() | |
283 | end | |
284 | lastframe = tick() | |
285 | end | |
286 | if tossremainder then | |
287 | tf = 0 | |
288 | else | |
289 | tf = tf - frame * math.floor(tf / frame) | |
290 | end | |
291 | end | |
292 | end) | |
293 | ||
294 | --//=================================\\ | |
295 | --\\=================================// | |
296 | ||
297 | ||
298 | ||
299 | ||
300 | ||
301 | --//=================================\\ | |
302 | --|| SOME FUNCTIONS | |
303 | --\\=================================// | |
304 | ||
305 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
306 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
307 | end | |
308 | ||
309 | function PositiveAngle(NUMBER) | |
310 | if NUMBER >= 0 then | |
311 | NUMBER = 0 | |
312 | end | |
313 | return NUMBER | |
314 | end | |
315 | ||
316 | function NegativeAngle(NUMBER) | |
317 | if NUMBER <= 0 then | |
318 | NUMBER = 0 | |
319 | end | |
320 | return NUMBER | |
321 | end | |
322 | ||
323 | function Swait(NUMBER) | |
324 | if NUMBER == 0 or NUMBER == nil then | |
325 | ArtificialHB.Event:wait() | |
326 | else | |
327 | for i = 1, NUMBER do | |
328 | ArtificialHB.Event:wait() | |
329 | end | |
330 | end | |
331 | end | |
332 | ||
333 | function QuaternionFromCFrame(cf) | |
334 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
335 | local trace = m00 + m11 + m22 | |
336 | if trace > 0 then | |
337 | local s = math.sqrt(1 + trace) | |
338 | local recip = 0.5 / s | |
339 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
340 | else | |
341 | local i = 0 | |
342 | if m11 > m00 then | |
343 | i = 1 | |
344 | end | |
345 | if m22 > (i == 0 and m00 or m11) then | |
346 | i = 2 | |
347 | end | |
348 | if i == 0 then | |
349 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
350 | local recip = 0.5 / s | |
351 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
352 | elseif i == 1 then | |
353 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
354 | local recip = 0.5 / s | |
355 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
356 | elseif i == 2 then | |
357 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
358 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
359 | end | |
360 | end | |
361 | end | |
362 | ||
363 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
364 | local xs, ys, zs = x + x, y + y, z + z | |
365 | local wx, wy, wz = w * xs, w * ys, w * zs | |
366 | local xx = x * xs | |
367 | local xy = x * ys | |
368 | local xz = x * zs | |
369 | local yy = y * ys | |
370 | local yz = y * zs | |
371 | local zz = z * zs | |
372 | 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)) | |
373 | end | |
374 | - | speak.SoundId = "rbxassetid://418252437" |
374 | + | |
375 | function QuaternionSlerp(a, b, t) | |
376 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
377 | local startInterp, finishInterp; | |
378 | if cosTheta >= 0.0001 then | |
379 | if (1 - cosTheta) > 0.0001 then | |
380 | local theta = ACOS(cosTheta) | |
381 | local invSinTheta = 1 / SIN(theta) | |
382 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
383 | finishInterp = SIN(t * theta) * invSinTheta | |
384 | else | |
385 | startInterp = 1 - t | |
386 | finishInterp = t | |
387 | end | |
388 | else | |
389 | if (1 + cosTheta) > 0.0001 then | |
390 | local theta = ACOS(-cosTheta) | |
391 | local invSinTheta = 1 / SIN(theta) | |
392 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
393 | finishInterp = SIN(t * theta) * invSinTheta | |
394 | else | |
395 | startInterp = t - 1 | |
396 | finishInterp = t | |
397 | end | |
398 | end | |
399 | 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 | |
400 | end | |
401 | ||
402 | function Clerp(a, b, t) | |
403 | local qa = {QuaternionFromCFrame(a)} | |
404 | local qb = {QuaternionFromCFrame(b)} | |
405 | local ax, ay, az = a.x, a.y, a.z | |
406 | local bx, by, bz = b.x, b.y, b.z | |
407 | local _t = 1 - t | |
408 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
409 | end | |
410 | ||
411 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
412 | local frame = IT("Frame") | |
413 | frame.BackgroundTransparency = TRANSPARENCY | |
414 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
415 | frame.Position = POSITION | |
416 | frame.Size = SIZE | |
417 | frame.BackgroundColor3 = COLOR | |
418 | frame.BorderColor3 = BORDERCOLOR | |
419 | frame.Name = NAME | |
420 | frame.Parent = PARENT | |
421 | return frame | |
422 | end | |
423 | ||
424 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
425 | local label = IT("TextLabel") | |
426 | label.BackgroundTransparency = 1 | |
427 | label.Size = UD2(1, 0, 1, 0) | |
428 | label.Position = UD2(0, 0, 0, 0) | |
429 | - | hit.BrickColor = BRICKC("Dark orange") |
429 | + | |
430 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
431 | label.TextTransparency = TRANSPARENCY | |
432 | label.FontSize = TEXTFONTSIZE | |
433 | label.Font = TEXTFONT | |
434 | label.BorderSizePixel = BORDERSIZEPIXEL | |
435 | label.TextScaled = false | |
436 | label.Text = TEXT | |
437 | label.Name = NAME | |
438 | label.Parent = PARENT | |
439 | return label | |
440 | end | |
441 | ||
442 | function NoOutlines(PART) | |
443 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
444 | end | |
445 | ||
446 | ||
447 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
448 | local NEWWELD = IT(TYPE) | |
449 | NEWWELD.Part0 = PART0 | |
450 | NEWWELD.Part1 = PART1 | |
451 | NEWWELD.C0 = C0 | |
452 | NEWWELD.C1 = C1 | |
453 | NEWWELD.Parent = PARENT | |
454 | return NEWWELD | |
455 | - | CreateSound("1037197054", child, 2, 1) |
455 | + | |
456 | ||
457 | function CreateSound(ID, PARENT, VOLUME, PITCH) | |
458 | local NEWSOUND = nil | |
459 | coroutine.resume(coroutine.create(function() | |
460 | NEWSOUND = IT("Sound", PARENT) | |
461 | NEWSOUND.Volume = VOLUME | |
462 | NEWSOUND.Pitch = PITCH | |
463 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
464 | Swait() | |
465 | NEWSOUND:play() | |
466 | game:GetService("Debris"):AddItem(NEWSOUND, 10) | |
467 | end)) | |
468 | return NEWSOUND | |
469 | end | |
470 | ||
471 | function CFrameFromTopBack(at, top, back) | |
472 | local right = top:Cross(back) | |
473 | 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) | |
474 | end | |
475 | ||
476 | --//=================================\\ | |
477 | --|| SPEECH | |
478 | --\\=================================// | |
479 | ||
480 | local speak = Instance.new("Sound",Head) | |
481 | speak.SoundId = "rbxassetid://" | |
482 | speak.Volume = 4 | |
483 | ||
484 | function chatfunc(text,waitt) | |
485 | local chat = coroutine.wrap(function() | |
486 | if Character:FindFirstChild("TalkingBillBoard")~= nil then | |
487 | Character:FindFirstChild("TalkingBillBoard").Parent = nil | |
488 | end | |
489 | local naeeym2 = Instance.new("BillboardGui",Character) | |
490 | naeeym2.Size = UDim2.new(0,100,0,40) | |
491 | naeeym2.StudsOffset = Vector3.new(0,2,0) | |
492 | naeeym2.Adornee = Character.Head | |
493 | naeeym2.Name = "TalkingBillBoard" | |
494 | naeeym2.AlwaysOnTop = true | |
495 | local tecks2 = Instance.new("TextLabel",naeeym2) | |
496 | tecks2.BackgroundTransparency = 1 | |
497 | tecks2.BorderSizePixel = 0 | |
498 | tecks2.Text = "" | |
499 | tecks2.Font = "Fantasy" | |
500 | tecks2.TextSize = 30 | |
501 | tecks2.TextStrokeTransparency = 1 | |
502 | tecks2.TextColor3 = SKILLTEXTCOLOR | |
503 | tecks2.TextStrokeColor3 = Color3.new(0,0,0) | |
504 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
505 | for i = 1,string.len(text),1 do | |
506 | if naeeym2.Parent ~= nil then | |
507 | tecks2.Text = string.sub(text,1,i) | |
508 | speak.PlaybackSpeed = (math.random(8,9)/10) | |
509 | speak:Play() | |
510 | Swait(3) | |
511 | - | chatfunc("Oh why hello there!",100) |
511 | + | |
512 | end | |
513 | - | chatfunc("Wanna Join the White Crusaders?",5) |
513 | + | |
514 | coroutine.resume(coroutine.create(function() | |
515 | - | chatfunc("No?",1) |
515 | + | |
516 | tecks2.TextTransparency = tecks2.TextTransparency + 0.1 | |
517 | - | chatfunc("Well then, join the niggers burning in hell.",1) |
517 | + | |
518 | end | |
519 | naeeym2:Destroy() | |
520 | end)) | |
521 | end) | |
522 | chat() | |
523 | end | |
524 | ||
525 | --//=================================\\ | |
526 | --|| DAMAGING | |
527 | --\\=================================// | |
528 | ||
529 | function goldify(hit) | |
530 | local GOLDNAMES = {"Gold","Shiny rock","Munz","$$"} | |
531 | hit.Anchored = false | |
532 | hit.CanCollide = true | |
533 | hit.Parent = workspace | |
534 | hit.Name = GOLDNAMES[MRANDOM(1,#GOLDNAMES)] | |
535 | hit.Material = "Plastic" | |
536 | hit.BrickColor = BRICKC("Gold") | |
537 | if hit:FindFirstChildOfClass("SpecialMesh") then | |
538 | local mesh = hit:FindFirstChildOfClass("SpecialMesh") | |
539 | mesh.TextureId = "" | |
540 | end | |
541 | if hit:FindFirstChildOfClass("Decal") then | |
542 | local mesh = hit:FindFirstChildOfClass("Decal") | |
543 | mesh:remove() | |
544 | end | |
545 | if hit.ClassName == "MeshPart" then | |
546 | hit.TextureID = "" | |
547 | end | |
548 | if hit.ClassName == "UnionOperation" then | |
549 | hit.UsePartColor = true | |
550 | end | |
551 | end | |
552 | ||
553 | function turntogold(hit) | |
554 | if hit.Parent ~= Character then | |
555 | if hit.Parent ~= workspace then | |
556 | print("My gold...") | |
557 | local body = hit.Parent:GetChildren() | |
558 | for part = 1, #body do | |
559 | local child = body[part] | |
560 | if child.ClassName == "Part" or child.ClassName == "MeshPart" or child.ClassName == "UnionOperation" then | |
561 | if child.Name == "Head" then | |
562 | CreateSound("747238556", child, 2, 1) | |
563 | end | |
564 | goldify(child) | |
565 | elseif child.ClassName == "Accessory" or child.ClassName == "Hat" then | |
566 | if child:FindFirstChild("Handle") then | |
567 | goldify(child.Handle) | |
568 | end | |
569 | end | |
570 | end | |
571 | else | |
572 | goldify(hit) | |
573 | end | |
574 | end | |
575 | end | |
576 | ||
577 | --//=================================\\ | |
578 | --|| ATTACK FUNCTIONS AND STUFF | |
579 | --\\=================================// | |
580 | ||
581 | local hit = Torso.Touched:Connect(function(hit) | |
582 | if hit.Parent:FindFirstChild("Humanoid") then | |
583 | turntogold(hit) | |
584 | end | |
585 | end) | |
586 | local hit = RightArm.Touched:Connect(function(hit) | |
587 | if hit.Parent:FindFirstChild("Humanoid") then | |
588 | turntogold(hit) | |
589 | end | |
590 | end) | |
591 | local hit = LeftArm.Touched:Connect(function(hit) | |
592 | if hit.Parent:FindFirstChild("Humanoid") then | |
593 | turntogold(hit) | |
594 | end | |
595 | end) | |
596 | local hit = RightLeg.Touched:Connect(function(hit) | |
597 | if hit.Parent:FindFirstChild("Humanoid") then | |
598 | turntogold(hit) | |
599 | end | |
600 | end) | |
601 | local hit = LeftLeg.Touched:Connect(function(hit) | |
602 | if hit.Parent:FindFirstChild("Humanoid") then | |
603 | turntogold(hit) | |
604 | end | |
605 | end) | |
606 | local hit = Head.Touched:Connect(function(hit) | |
607 | if hit.Parent:FindFirstChild("Humanoid") then | |
608 | turntogold(hit) | |
609 | end | |
610 | end) | |
611 | ||
612 | --//=================================\\ | |
613 | --|| ASSIGN THINGS TO KEYS | |
614 | --\\=================================// | |
615 | ||
616 | function KeyDown(Key) | |
617 | if Key == "t" and ATTACK == false then | |
618 | chatfunc("I wish I was normal",100) | |
619 | Swait(150) | |
620 | chatfunc("Seriously Everything I touch becomes gold.",5) | |
621 | Swait(150) | |
622 | chatfunc("It sucks",1) | |
623 | Swait(45) | |
624 | chatfunc("Well I wished this so it really doesn't damn matter.",1) | |
625 | end | |
626 | end | |
627 | ||
628 | function KeyUp(Key) | |
629 | end | |
630 | ||
631 | Mouse.KeyDown:connect(function(NEWKEY) | |
632 | KeyDown(NEWKEY) | |
633 | end) | |
634 | Mouse.KeyUp:connect(function(NEWKEY) | |
635 | KeyUp(NEWKEY) | |
636 | end) | |
637 | ||
638 | ||
639 | --//=================================\\ | |
640 | --\\=================================// | |
641 | ||
642 | ||
643 | function unanchor() | |
644 | if UNANCHOR == true then | |
645 | g = Character:GetChildren() | |
646 | for i = 1, #g do | |
647 | if g[i].ClassName == "Part" then | |
648 | g[i].Anchored = false | |
649 | end | |
650 | end | |
651 | end | |
652 | end | |
653 | ||
654 | ||
655 | --//=================================\\ | |
656 | --|| WRAP THE WHOLE SCRIPT UP | |
657 | --\\=================================// | |
658 | ||
659 | ||
660 | ANIMATE.Parent = nil | |
661 | local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION) | |
662 | IDLEANIMATION:Play() | |
663 | ||
664 | while true do | |
665 | Swait() | |
666 | SINE = SINE + CHANGE | |
667 | local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude | |
668 | local TORSOVERTICALVELOCITY = RootPart.Velocity.y | |
669 | local LV = Torso.CFrame:pointToObjectSpace(Torso.Velocity - Torso.Position) | |
670 | local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4 * Player_Size, Character) | |
671 | local WALKSPEEDVALUE = 6 / (Humanoid.WalkSpeed / 16) | |
672 | if ANIM == "Walk" and TORSOVELOCITY > 1 then | |
673 | RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, -0.1 * COS(SINE / (WALKSPEEDVALUE / 2)) * Player_Size) * ANGLES(RAD(0), RAD(0) - RootPart.RotVelocity.Y / 75, RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
674 | Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_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) | |
675 | RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(30 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
676 | LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(30 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
677 | elseif (ANIM ~= "Walk") or (TORSOVELOCITY < 1) then | |
678 | RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
679 | Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
680 | RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
681 | LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
682 | end | |
683 | if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then | |
684 | ANIM = "Jump" | |
685 | if ATTACK == false then | |
686 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
687 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(-20), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
688 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed) | |
689 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 0.2 / Animation_Speed) | |
690 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, -0.3 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
691 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, -0.3 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(20)), 0.2 / Animation_Speed) | |
692 | end | |
693 | elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then | |
694 | ANIM = "Fall" | |
695 | if ATTACK == false then | |
696 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
697 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(20), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
698 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(60)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed) | |
699 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(-60)) * LEFTSHOULDERC0, 0.2 / Animation_Speed) | |
700 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.2 / Animation_Speed) | |
701 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
702 | end | |
703 | elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then | |
704 | ANIM = "Idle" | |
705 | if ATTACK == false then | |
706 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, -0.2 * Player_Size + 0.05 * COS(SINE / 12) * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
707 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(25 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
708 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
709 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
710 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.8 * Player_Size - 0.05 * COS(SINE / 12) * Player_Size, -0.01 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
711 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.8 * Player_Size - 0.05 * COS(SINE / 12) * Player_Size, -0.01 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
712 | end | |
713 | elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then | |
714 | ANIM = "Walk" | |
715 | WALK = WALK + 1 / Animation_Speed | |
716 | if WALK >= 15 - (5 * (Humanoid.WalkSpeed / 16 / Player_Size)) then | |
717 | WALK = 0 | |
718 | if WALKINGANIM == true then | |
719 | WALKINGANIM = false | |
720 | elseif WALKINGANIM == false then | |
721 | WALKINGANIM = true | |
722 | end | |
723 | end | |
724 | --RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
725 | --LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
726 | if ATTACK == false then | |
727 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, -0.2 * Player_Size + 0.05 * COS(SINE / 12) * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
728 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(25 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
729 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(30 * COS(SINE / WALKSPEEDVALUE)), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
730 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-30 * COS(SINE / WALKSPEEDVALUE)), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
731 | RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, -0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
732 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, -0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
733 | end | |
734 | end | |
735 | if #Effects2>0 then | |
736 | for e=1,#Effects2 do | |
737 | if Effects2[e]~=nil then | |
738 | local Thing=Effects2[e] | |
739 | if Thing~=nil then | |
740 | local Part=Thing[1] | |
741 | local Mode=Thing[2] | |
742 | local Delay=Thing[3] | |
743 | local IncX=Thing[4] | |
744 | local IncY=Thing[5] | |
745 | local IncZ=Thing[6] | |
746 | local Part2=Thing[8] | |
747 | if Thing[1].Transparency<=1 then | |
748 | if Thing[2]=="Block1" then | |
749 | Thing[1].CFrame=Thing[1].CFrame | |
750 | Mesh=Thing[1].Mesh | |
751 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
752 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
753 | elseif Thing[2]=="Cylinder" then | |
754 | Mesh=Thing[1].Mesh | |
755 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
756 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
757 | elseif Thing[2]=="Blood" then | |
758 | Mesh=Thing[7] | |
759 | Thing[1].CFrame=Thing[1].CFrame*CF(0,.5,0) | |
760 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
761 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
762 | elseif Thing[2]=="Elec" then | |
763 | Mesh=Thing[1].Mesh | |
764 | Mesh.Scale=Mesh.Scale+VT(Thing[7],Thing[8],Thing[9]) | |
765 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
766 | elseif Thing[2]=="Disappear" then | |
767 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
768 | end | |
769 | else | |
770 | Part.Parent=nil | |
771 | table.remove(Effects2,e) | |
772 | end | |
773 | end | |
774 | end | |
775 | end | |
776 | end | |
777 | unanchor() | |
778 | if Rooted == false then | |
779 | Disable_Jump = false | |
780 | Humanoid.WalkSpeed = Speed | |
781 | elseif Rooted == true then | |
782 | Disable_Jump = true | |
783 | Humanoid.WalkSpeed = 0 | |
784 | end | |
785 | end local Player = game:GetService("Players").LocalPlayer | |
786 | local Character = Player.Character | |
787 | local Torso = Character.Torso | |
788 | ||
789 | ca=CFrame.Angles | |
790 | cn=CFrame.new | |
791 | it=Instance.new | |
792 | rd=math.rad | |
793 | v3=Vector3.new | |
794 | ||
795 | Interpolate = function(CFrame1, CFrame2) | |
796 | local Table1 = {CFrame1:components()} | |
797 | local Table2 = {CFrame2:components()} | |
798 | local NewCFrame = {} | |
799 | for i,v in ipairs(Table1) do | |
800 | local Difference = Table2[i] - v | |
801 | if i < 4 then | |
802 | local NewValue | |
803 | if math.abs(Difference) < 0.1 then | |
804 | NewValue = Table2[i] | |
805 | else | |
806 | NewValue = v + ((Difference/math.abs(Difference)) * 0.1) | |
807 | end | |
808 | NewCFrame[i] = NewValue | |
809 | else | |
810 | local NewValue | |
811 | if math.abs(Difference) < 0.1 then | |
812 | NewValue = Table2[i] | |
813 | else | |
814 | NewValue = v + ((Difference/math.abs(Difference)) * 0.1) | |
815 | end | |
816 | NewCFrame[i] = NewValue | |
817 | end | |
818 | end | |
819 | return CFrame.new(unpack(NewCFrame)) | |
820 | end | |
821 | ||
822 | Prop = function(Parent, Name, x, y, z, Anchored, CanCollide, Color) | |
823 | local Part = Instance.new("Part",Parent) | |
824 | Part.Name = Name | |
825 | Part.FormFactor = 3 | |
826 | Part.Size = Vector3.new(x, y, z) | |
827 | Part.Anchored = Anchored | |
828 | Part.CanCollide = CanCollide | |
829 | Part.BrickColor = BrickColor.new(Color) | |
830 | Part.TopSurface = 0 | |
831 | Part.BottomSurface = 0 | |
832 | Part:BreakJoints() | |
833 | return Part | |
834 | end | |
835 | ||
836 | Mesh = function(Parent, MeshType,x, y, z,MeshId,TextureId) | |
837 | local Mesh = nil | |
838 | if MeshType=="CylinderMesh" then | |
839 | Mesh=Instance.new("CylinderMesh",Parent) | |
840 | Mesh.Scale=Vector3.new(x,y,z) | |
841 | elseif MeshType~="BlockMesh" and MeshType~="CylinderMesh" then | |
842 | Mesh=Instance.new("SpecialMesh",Parent) | |
843 | Mesh.MeshType = MeshType | |
844 | Mesh.MeshId = MeshId or "" | |
845 | Mesh.Scale = Vector3.new(x, y, z) | |
846 | return Mesh | |
847 | end | |
848 | end | |
849 | ||
850 | Weld = function(Part0, Part1, C0, C1) | |
851 | local Weld = Instance.new("Weld",Part0) | |
852 | Weld.Part0 = Part0 | |
853 | Weld.Part1 = Part1 | |
854 | Weld.C0 = C0 or CFrame.new() | |
855 | Weld.C1 = C1 or CFrame.new() | |
856 | return Weld | |
857 | end | |
858 | ||
859 | local Handle = Prop(Character, "Handle", 0.2, 1.5, 0.2, false, false, "Really black") | |
860 | Weld(Torso, Handle, CFrame.new(0, 5, 0)) | |
861 | local Guard = Prop(Character, "Guard", 1.5,0.1,0.2,false, false, "Really black") | |
862 | Weld(Handle, Guard, CFrame.new(0, 1.5/2, 0)) | |
863 | local Pivot = Prop(Character,"",0,0,0,false,false,"") -- this is basicly an invisible part | |
864 | local Pivot2 = Prop(Character,"",0,0,0,false,false,"") | |
865 | Pivot.Transparency = 1 | |
866 | Pivot2.Transparency = 1 | |
867 | Weld(Guard,Pivot,CFrame.new(0,-0.75,0)*CFrame.Angles(0,0,math.rad(-40-90))) | |
868 | Weld(Guard,Pivot2,CFrame.new(0,0.75,0)*CFrame.Angles(0,0,math.rad(40+90))) | |
869 | local Guard2 = Prop(Character, "Guard2", 0.1, 0.5, 0.2, false, false, "Really black") | |
870 | Weld(Pivot, Guard2, CFrame.new(0, -0.25, 0)) | |
871 | local Guard3 = Prop(Character, "Guard3", 0.1, 0.5, 0.2, false, false, "Really black") | |
872 | Weld(Pivot2, Guard3, CFrame.new(0, 0.25, 0)) | |
873 | local Design = Prop(Character, "Design", 0.5, 1, 0.5, false, false, "Gold") | |
874 | Mesh(Design, "FileMesh", 0.5, 1, 0.5,"http://www.roblox.com/Asset/?id=9756362") | |
875 | Weld(Handle, Design, CFrame.new(0, -0.75, 0)) | |
876 | local Ball = Prop(Character, "Ball1", 0.3, 0.3, 0.3, false, false, "Gold") | |
877 | Mesh(Ball, "Sphere", 1, 1, 1) | |
878 | Weld(Pivot, Ball) | |
879 | local Ball2 = Prop(Character, "Ball2", 0.3, 0.3, 0.3, false, false, "Gold") | |
880 | Mesh(Ball2, "Sphere", 1, 1, 1) | |
881 | Weld(Pivot2, Ball2) | |
882 | local Spike = Prop(Character, "Spike1", 0.1, 1, 0.1, false, false, "Gold") | |
883 | Mesh(Spike, "FileMesh", 0.1, 1, 0.1,"http://www.roblox.com/asset/?id=1033714") | |
884 | Weld(Pivot, Spike, CFrame.new(-0.3, 0, 0) * CFrame.Angles(math.rad(0), 0, math.rad(90))) | |
885 | local Spike2 = Prop(Character, "Spike2", 0.1, 1, 0.1, false, false, "Gold") | |
886 | Mesh(Spike2, "FileMesh", 0.1, 1, 0.1, "http://www.roblox.com/asset/?id=1033714") | |
887 | Weld(Pivot2, Spike2, CFrame.new(-0.3, 0, 0) * CFrame.Angles(math.rad(0), 0, math.rad(90))) | |
888 | Mesh(Handle, "CylinderMesh", 1, 1, 1) | |
889 | ||
890 | --//=================================\\ | |
891 | --\\=================================// | |
892 | ||
893 | ||
894 | ||
895 | ||
896 | ||
897 | --//====================================================\\-- | |
898 | --|| END OF SCRIPT | |
899 | --\\====================================================//-- |