SHOW:
|
|
- or go back to the newest paste.
| 1 | --------------------------This is an Official script from Duelist-------------------------- | |
| 2 | ---{-------------------- -------------------}---
| |
| 3 | ---{-------------------- / \ -------------------}---
| |
| 4 | ---{-------------------- II -------------------}---
| |
| 5 | ---{-------------------- II -------------------}---
| |
| 6 | ---{-------------------- II -------------------}---
| |
| 7 | ---{-------------------- A========A -------------------}---
| |
| 8 | ---{-------------------- II -------------------}---
| |
| 9 | ---{-------------------- II -------------------}---
| |
| 10 | ---{-------------------- W -------------------}---
| |
| 11 | ------------------------------------------------------------------------------------------------------------- | |
| 12 | ||
| 13 | --https://github.com/Mokiros/roblox-FE-compatibility | |
| 14 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
| |
| 15 | local Player,game,owner = owner,game | |
| 16 | local RealPlayer = Player | |
| 17 | do | |
| 18 | print("FE Compatibility code V2 by Mokiros")
| |
| 19 | local RealPlayer = RealPlayer | |
| 20 | script.Parent = RealPlayer.Character | |
| 21 | ||
| 22 | --Fake event to make stuff like Mouse.KeyDown work | |
| 23 | local Disconnect_Function = function(this) | |
| 24 | this[1].Functions[this[2]] = nil | |
| 25 | end | |
| 26 | local Disconnect_Metatable = {__index={disconnect=Disconnect_Function,Disconnect=Disconnect_Function}}
| |
| 27 | local FakeEvent_Metatable = {__index={
| |
| 28 | Connect = function(this,f) | |
| 29 | local i = tostring(math.random(0,10000)) | |
| 30 | while this.Functions[i] do | |
| 31 | i = tostring(math.random(0,10000)) | |
| 32 | end | |
| 33 | this.Functions[i] = f | |
| 34 | return setmetatable({this,i},Disconnect_Metatable)
| |
| 35 | end | |
| 36 | }} | |
| 37 | FakeEvent_Metatable.__index.connect = FakeEvent_Metatable.__index.Connect | |
| 38 | local function fakeEvent() | |
| 39 | return setmetatable({Functions={}},FakeEvent_Metatable)
| |
| 40 | end | |
| 41 | ||
| 42 | --Creating fake input objects with fake variables | |
| 43 | local FakeMouse = {Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
| |
| 44 | FakeMouse.keyUp = FakeMouse.KeyUp | |
| 45 | FakeMouse.keyDown = FakeMouse.KeyDown | |
| 46 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
| |
| 47 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
| |
| 48 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
| |
| 49 | end} | |
| 50 | --Merged 2 functions into one by checking amount of arguments | |
| 51 | CAS.UnbindAction = CAS.BindAction | |
| 52 | ||
| 53 | --This function will trigger the events that have been :Connect()'ed | |
| 54 | local function TriggerEvent(self,ev,...) | |
| 55 | for _,f in pairs(self[ev].Functions) do | |
| 56 | f(...) | |
| 57 | end | |
| 58 | end | |
| 59 | FakeMouse.TriggerEvent = TriggerEvent | |
| 60 | UIS.TriggerEvent = TriggerEvent | |
| 61 | ||
| 62 | --Client communication | |
| 63 | local Event = Instance.new("RemoteEvent")
| |
| 64 | Event.Name = "UserInput_Event" | |
| 65 | Event.OnServerEvent:Connect(function(plr,io) | |
| 66 | if plr~=RealPlayer then return end | |
| 67 | FakeMouse.Target = io.Target | |
| 68 | FakeMouse.Hit = io.Hit | |
| 69 | if not io.isMouse then | |
| 70 | local b = io.UserInputState == Enum.UserInputState.Begin | |
| 71 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
| 72 | return FakeMouse:TriggerEvent(b and "Button1Down" or "Button1Up") | |
| 73 | end | |
| 74 | if io.UserInputType == Enum.UserInputType.MouseButton2 then | |
| 75 | return FakeMouse:TriggerEvent(b and "Button2Down" or "Button2Up") | |
| 76 | end | |
| 77 | for _,t in pairs(CAS.Actions) do | |
| 78 | for _,k in pairs(t.Keys) do | |
| 79 | if k==io.KeyCode then | |
| 80 | t.Function(t.Name,io.UserInputState,io) | |
| 81 | end | |
| 82 | end | |
| 83 | end | |
| 84 | FakeMouse:TriggerEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
| 85 | UIS:TriggerEvent(b and "InputBegan" or "InputEnded",io,false) | |
| 86 | end | |
| 87 | end) | |
| 88 | Event.Parent = NLS([==[local Event = script:WaitForChild("UserInput_Event")
| |
| 89 | local Mouse = owner:GetMouse() | |
| 90 | local UIS = game:GetService("UserInputService")
| |
| 91 | local input = function(io,RobloxHandled) | |
| 92 | if RobloxHandled then return end | |
| 93 | --Since InputObject is a client-side instance, we create and pass table instead | |
| 94 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
| |
| 95 | end | |
| 96 | UIS.InputBegan:Connect(input) | |
| 97 | UIS.InputEnded:Connect(input) | |
| 98 | local h,t | |
| 99 | --Give the server mouse data every second frame, but only if the values changed | |
| 100 | --If player is not moving their mouse, client won't fire events | |
| 101 | local HB = game:GetService("RunService").Heartbeat
| |
| 102 | while true do | |
| 103 | if h~=Mouse.Hit or t~=Mouse.Target then | |
| 104 | h,t=Mouse.Hit,Mouse.Target | |
| 105 | Event:FireServer({isMouse=true,Target=t,Hit=h})
| |
| 106 | end | |
| 107 | --Wait 2 frames | |
| 108 | for i=1,2 do | |
| 109 | HB:Wait() | |
| 110 | end | |
| 111 | end]==],script) | |
| 112 | ||
| 113 | ----Sandboxed game object that allows the usage of client-side methods and services | |
| 114 | --Real game object | |
| 115 | local RealGame = game | |
| 116 | ||
| 117 | --Metatable for fake service | |
| 118 | local FakeService_Metatable = {
| |
| 119 | __index = function(self,k) | |
| 120 | local s = rawget(self,"_RealService") | |
| 121 | if s then | |
| 122 | return typeof(s[k])=="function" | |
| 123 | and function(_,...)return s[k](s,...)end or s[k] | |
| 124 | end | |
| 125 | end, | |
| 126 | __newindex = function(self,k,v) | |
| 127 | local s = rawget(self,"_RealService") | |
| 128 | if s then s[k]=v end | |
| 129 | end | |
| 130 | } | |
| 131 | local function FakeService(t,RealService) | |
| 132 | t._RealService = typeof(RealService)=="string" and RealGame:GetService(RealService) or RealService | |
| 133 | return setmetatable(t,FakeService_Metatable) | |
| 134 | end | |
| 135 | ||
| 136 | --Fake game object | |
| 137 | local FakeGame = {
| |
| 138 | GetService = function(self,s) | |
| 139 | return rawget(self,s) or RealGame:GetService(s) | |
| 140 | end, | |
| 141 | Players = FakeService({
| |
| 142 | LocalPlayer = FakeService({GetMouse=function(self)return FakeMouse end},Player)
| |
| 143 | },"Players"), | |
| 144 | UserInputService = FakeService(UIS,"UserInputService"), | |
| 145 | ContextActionService = FakeService(CAS,"ContextActionService"), | |
| 146 | RunService = FakeService({
| |
| 147 | _btrs = {},
| |
| 148 | RenderStepped = RealGame:GetService("RunService").Heartbeat,
| |
| 149 | BindToRenderStep = function(self,name,_,fun) | |
| 150 | self._btrs[name] = self.Heartbeat:Connect(fun) | |
| 151 | end, | |
| 152 | UnbindFromRenderStep = function(self,name) | |
| 153 | self._btrs[name]:Disconnect() | |
| 154 | end, | |
| 155 | },"RunService") | |
| 156 | } | |
| 157 | rawset(FakeGame.Players,"localPlayer",FakeGame.Players.LocalPlayer) | |
| 158 | FakeGame.service = FakeGame.GetService | |
| 159 | FakeService(FakeGame,game) | |
| 160 | --Changing owner to fake player object to support owner:GetMouse() | |
| 161 | game,owner = FakeGame,FakeGame.Players.LocalPlayer | |
| 162 | end | |
| 163 | ||
| 164 | local p = game.Players.LocalPlayer | |
| 165 | --300899323 | |
| 166 | local char = p.Character | |
| 167 | local mouse = p:GetMouse() | |
| 168 | local larm = char["Left Arm"] | |
| 169 | local rarm = char["Right Arm"] | |
| 170 | local lleg = char["Left Leg"] | |
| 171 | local rleg = char["Right Leg"] | |
| 172 | local hed = char.Head | |
| 173 | local torso = char.Torso | |
| 174 | local hum = char.Humanoid | |
| 175 | local cam = game.Workspace.CurrentCamera | |
| 176 | local root = char.HumanoidRootPart | |
| 177 | local RootPart = char.HumanoidRootPart | |
| 178 | local rj = root.RootJoint | |
| 179 | local deb = false | |
| 180 | local shot = 0 | |
| 181 | local stanceToggle = "Idle1" | |
| 182 | local l = game:GetService("Lighting")
| |
| 183 | local rs = game:GetService("RunService").RenderStepped
| |
| 184 | local hb = game:GetService("RunService").Heartbeat
| |
| 185 | local Stepped = game:GetService("RunService").Stepped
| |
| 186 | math.randomseed(os.time()) | |
| 187 | hum.JumpPower = 70 | |
| 188 | hed.face:Remove() | |
| 189 | local euler = CFrame.fromEulerAnglesXYZ | |
| 190 | ---------------------------------------------------- | |
| 191 | local Character = char | |
| 192 | --------------------------------------------------- | |
| 193 | local Effects = {}
| |
| 194 | wait(0.016666666666667) | |
| 195 | equipc0 = CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1) | |
| 196 | unequipc0 = CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1) | |
| 197 | local player = game.Players.localPlayer | |
| 198 | local humanoid = char.Humanoid | |
| 199 | local mouse = player:GetMouse() | |
| 200 | local weldBetween = function(a, b) | |
| 201 | local weldd = Instance.new("ManualWeld")
| |
| 202 | weldd.Part0 = a | |
| 203 | weldd.Part1 = b | |
| 204 | weldd.C0 = CFrame.new() | |
| 205 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
| 206 | weldd.Parent = a | |
| 207 | return weldd | |
| 208 | end | |
| 209 | ||
| 210 | vt = Vector3.new | |
| 211 | local m = Instance.new("Model", char)
| |
| 212 | local larm = char["Left Arm"] | |
| 213 | local rarm = char["Right Arm"] | |
| 214 | local lleg = char["Left Leg"] | |
| 215 | local rleg = char["Right Leg"] | |
| 216 | local hed = char.Head | |
| 217 | local torso = char.Torso | |
| 218 | local cam = game.Workspace.CurrentCamera | |
| 219 | local RootPart = char.HumanoidRootPart | |
| 220 | local equipped = false | |
| 221 | local attack = false | |
| 222 | local Anim = "Idle" | |
| 223 | local idle = 0 | |
| 224 | local sprint = false | |
| 225 | local battlestance = false | |
| 226 | local attacktype = 1 | |
| 227 | local state = "none" | |
| 228 | local torsovelocity = RootPart.Velocity * Vector3.new(1, 0, 1).magnitude | |
| 229 | local velocity = RootPart.Velocity.y | |
| 230 | local sine = 0 | |
| 231 | local change = 1 | |
| 232 | ||
| 233 | it = Instance.new | |
| 234 | local on = false | |
| 235 | local grabbed = false | |
| 236 | local skill1 = false | |
| 237 | local skill2 = false | |
| 238 | local skill3 = false | |
| 239 | local skill4 = false | |
| 240 | local cooldown1 = 0 | |
| 241 | local cooldown2 = 0 | |
| 242 | local cooldown3 = 0 | |
| 243 | local cooldown4 = 0 | |
| 244 | local co1 = 10 | |
| 245 | local co2 = 15 | |
| 246 | local co3 = 20 | |
| 247 | local co4 = 35 | |
| 248 | local inputserv = game:GetService("UserInputService")
| |
| 249 | local typing = false | |
| 250 | local crit = false | |
| 251 | local critchance = 2 | |
| 252 | local critdamageaddmin = 3 | |
| 253 | local critdamageaddmax = 7 | |
| 254 | local maxstamina = 100 | |
| 255 | local stamina = 0 | |
| 256 | local skill1stam = 10 | |
| 257 | local skill2stam = 20 | |
| 258 | local skill3stam = 35 | |
| 259 | local skill4stam = 50 | |
| 260 | local recovermana = 5 | |
| 261 | local defensevalue = 1 | |
| 262 | local speedvalue = 1 | |
| 263 | local mindamage = 5 | |
| 264 | local maxdamage = 7 | |
| 265 | local damagevalue = 1 | |
| 266 | local maramistcutterchance = 25 | |
| 267 | local cn = CFrame.new | |
| 268 | local mr = math.rad | |
| 269 | local angles = CFrame.Angles | |
| 270 | local ud = UDim2.new | |
| 271 | local c3 = Color3.new | |
| 272 | F1 = Instance.new("Folder", char)
| |
| 273 | F1.Name = "Effects Folder" | |
| 274 | F2 = Instance.new("Folder", F1)
| |
| 275 | F2.Name = "Effects" | |
| 276 | ---------------------------------------------------- | |
| 277 | fat = Instance.new("BindableEvent",script)
| |
| 278 | fat.Name = "Heartbeat" | |
| 279 | ||
| 280 | script:WaitForChild("Heartbeat")
| |
| 281 | ||
| 282 | frame = 1/30 | |
| 283 | tf = 0 | |
| 284 | allowframeloss = false --if set to true will fire every frame it possibly can. This will result in multiple events happening at the same time whenever delta returns frame*2 or greater. | |
| 285 | tossremainder = false --if set to true t will be set to 0 after Fire()-ing. | |
| 286 | lastframe = tick() | |
| 287 | script.Heartbeat:Fire() --ayy lmao | |
| 288 | ||
| 289 | game:GetService("RunService").Heartbeat:connect(function(s,p) --herp derp
| |
| 290 | tf = tf + s | |
| 291 | if tf >= frame then | |
| 292 | if allowframeloss then | |
| 293 | script.Heartbeat:Fire() | |
| 294 | lastframe=tick() | |
| 295 | else | |
| 296 | --print("FIRED "..math.floor(t/frame).." FRAME(S)","REMAINDER "..(t - frame*(math.floor(t/frame))))
| |
| 297 | for i=1, math.floor(tf/frame) do | |
| 298 | script.Heartbeat:Fire() | |
| 299 | end | |
| 300 | lastframe=tick() | |
| 301 | end | |
| 302 | if tossremainder then | |
| 303 | tf = 0 | |
| 304 | else | |
| 305 | tf = tf - frame * math.floor(tf/frame) | |
| 306 | end | |
| 307 | end | |
| 308 | end) | |
| 309 | swait = function(num) | |
| 310 | if num == 0 or num == nil then | |
| 311 | game:service("RunService").Heartbeat:wait(0)
| |
| 312 | else | |
| 313 | for i = 0, num do | |
| 314 | game:service("RunService").Heartbeat:wait(0)
| |
| 315 | end | |
| 316 | end | |
| 317 | end | |
| 318 | ---------------------------------------------------- | |
| 319 | function lerp(a, b, t) -- Linear interpolation | |
| 320 | return a + (b - a)*t | |
| 321 | end | |
| 322 | ||
| 323 | function slerp(a, b, t) --Spherical interpolation | |
| 324 | dot = a:Dot(b) | |
| 325 | if dot > 0.99999 or dot < -0.99999 then | |
| 326 | return t <= 0.5 and a or b | |
| 327 | else | |
| 328 | r = math.acos(dot) | |
| 329 | return (a*math.sin((1 - t)*r) + b*math.sin(t*r)) / math.sin(r) | |
| 330 | end | |
| 331 | end | |
| 332 | ||
| 333 | function matrixInterpolate(a, b, t) | |
| 334 | local ax, ay, az, a00, a01, a02, a10, a11, a12, a20, a21, a22 = a:components() | |
| 335 | local bx, by, bz, b00, b01, b02, b10, b11, b12, b20, b21, b22 = b:components() | |
| 336 | local v0 = lerp(Vector3.new(ax, ay, az), Vector3.new(bx , by , bz), t) -- Position | |
| 337 | local v1 = slerp(Vector3.new(a00, a01, a02), Vector3.new(b00, b01, b02), t) -- Vector right | |
| 338 | local v2 = slerp(Vector3.new(a10, a11, a12), Vector3.new(b10, b11, b12), t) -- Vector up | |
| 339 | local v3 = slerp(Vector3.new(a20, a21, a22), Vector3.new(b20, b21, b22), t) -- Vector back | |
| 340 | local t = v1:Dot(v2) | |
| 341 | if not (t < 0 or t == 0 or t > 0) then -- Failsafe | |
| 342 | return CFrame.new() | |
| 343 | end | |
| 344 | return CFrame.new( | |
| 345 | v0.x, v0.y, v0.z, | |
| 346 | v1.x, v1.y, v1.z, | |
| 347 | v2.x, v2.y, v2.z, | |
| 348 | v3.x, v3.y, v3.z) | |
| 349 | end | |
| 350 | ---------------------------------------------------- | |
| 351 | function genWeld(a,b) | |
| 352 | local w = Instance.new("Weld",a)
| |
| 353 | w.Part0 = a | |
| 354 | w.Part1 = b | |
| 355 | return w | |
| 356 | end | |
| 357 | function weld(a, b) | |
| 358 | local weld = Instance.new("Weld")
| |
| 359 | weld.Name = "W" | |
| 360 | weld.Part0 = a | |
| 361 | weld.Part1 = b | |
| 362 | weld.C0 = a.CFrame:inverse() * b.CFrame | |
| 363 | weld.Parent = a | |
| 364 | return weld; | |
| 365 | end | |
| 366 | ---------------------------------------------------- | |
| 367 | function Lerp(c1,c2,al) | |
| 368 | local com1 = {c1.X,c1.Y,c1.Z,c1:toEulerAnglesXYZ()}
| |
| 369 | local com2 = {c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
| |
| 370 | for i,v in pairs(com1) do | |
| 371 | com1[i] = v+(com2[i]-v)*al | |
| 372 | end | |
| 373 | return CFrame.new(com1[1],com1[2],com1[3]) * CFrame.Angles(select(4,unpack(com1))) | |
| 374 | end | |
| 375 | ---------------------------------------------------- | |
| 376 | newWeld = function(wp0, wp1, wc0x, wc0y, wc0z) | |
| 377 | local wld = Instance.new("Weld", wp1)
| |
| 378 | wld.Part0 = wp0 | |
| 379 | wld.Part1 = wp1 | |
| 380 | wld.C0 = CFrame.new(wc0x, wc0y, wc0z) | |
| 381 | end | |
| 382 | function weld5(part0, part1, c0, c1) | |
| 383 | weeld=Instance.new("Weld", part0)
| |
| 384 | weeld.Part0=part0 | |
| 385 | weeld.Part1=part1 | |
| 386 | weeld.C0=c0 | |
| 387 | weeld.C1=c1 | |
| 388 | return weeld | |
| 389 | end | |
| 390 | ---------------------------------------------------- | |
| 391 | newWeld(torso, larm, -1.5, 0.5, 0) | |
| 392 | larm.Weld.C1 = CFrame.new(0, 0.5, 0) | |
| 393 | newWeld(torso, rarm, 1.5, 0.5, 0) | |
| 394 | rarm.Weld.C1 = CFrame.new(0, 0.5, 0) | |
| 395 | newWeld(torso, hed, 0, 1.5, 0) | |
| 396 | newWeld(torso, lleg, -0.5, -1, 0) | |
| 397 | lleg.Weld.C1 = CFrame.new(0, 1, 0) | |
| 398 | newWeld(torso, rleg, 0.5, -1, 0) | |
| 399 | rleg.Weld.C1 = CFrame.new(0, 1, 0) | |
| 400 | newWeld(root, torso, 0, -1, 0) | |
| 401 | torso.Weld.C1 = CFrame.new(0, -1, 0) | |
| 402 | ||
| 403 | ---------------------------------------------------- | |
| 404 | Debounces = {
| |
| 405 | Doe = false; | |
| 406 | CanAttack = true; | |
| 407 | CanJoke = true; | |
| 408 | NoIdl = false; | |
| 409 | Slashing = false; | |
| 410 | Slashed = false; | |
| 411 | ks = false; | |
| 412 | } | |
| 413 | local myVars = {
| |
| 414 | false, -- Unsheathed 1 | |
| 415 | nil, -- Grabbed Entity 2 | |
| 416 | 0, -- Attack number 3 | |
| 417 | false, -- Running 4 | |
| 418 | false, --Powers Mode 5 | |
| 419 | false, -- 6 | |
| 420 | } | |
| 421 | ---------------------------------------------------- | |
| 422 | ||
| 423 | function GetParts(obj) | |
| 424 | for i, v in pairs(obj:GetChildren())do | |
| 425 | if ( v:IsA'BasePart' ) then | |
| 426 | if v.Name ~= "Trail" then | |
| 427 | Instance.new("ForceField", v);
| |
| 428 | end | |
| 429 | end | |
| 430 | GetParts(v); | |
| 431 | end | |
| 432 | end | |
| 433 | --GetParts(char) | |
| 434 | ||
| 435 | function NoOutline(Part) | |
| 436 | Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10 | |
| 437 | end | |
| 438 | function part(formfactor,parent,reflectance,transparency,brickcolor,name,size) | |
| 439 | local fp=it("Part")
| |
| 440 | fp.formFactor=formfactor | |
| 441 | fp.Parent=parent | |
| 442 | fp.Reflectance=reflectance | |
| 443 | fp.Transparency=transparency | |
| 444 | fp.CanCollide=false | |
| 445 | fp.Locked=true | |
| 446 | fp.BrickColor=brickcolor | |
| 447 | fp.Name=name | |
| 448 | fp.Size=size | |
| 449 | fp.Position=torso.Position | |
| 450 | NoOutline(fp) | |
| 451 | fp.Material="Neon" | |
| 452 | fp:BreakJoints() | |
| 453 | return fp | |
| 454 | end | |
| 455 | -------------------------------------- | |
| 456 | Character.Archivable = true | |
| 457 | local yellow = Character:Clone() | |
| 458 | yellow.Name = "" | |
| 459 | for _,c in pairs(yellow:children()) do | |
| 460 | if c.className == "Model" or c.className == "Script" or c.className == "BodyColors" or c.className == "Hat" or c.Name == "Stats" then | |
| 461 | c.Parent = nil | |
| 462 | end | |
| 463 | if c.className == "Part" then | |
| 464 | NoOutline(c) | |
| 465 | c.CanCollide = false | |
| 466 | c.Transparency = 1 | |
| 467 | if c.Name == "HumanoidRootPart" then | |
| 468 | c.Transparency = 1 | |
| 469 | end | |
| 470 | c.BrickColor = BrickColor.new("New Yeller")
| |
| 471 | for _,d in pairs(c:children()) do | |
| 472 | if d.className == "Weld" or d.className == "Motor" or d.className == "Motor6D" or d.className == "Decal" then | |
| 473 | d.Parent = nil | |
| 474 | end | |
| 475 | end | |
| 476 | end | |
| 477 | do | |
| 478 | do | |
| 479 | if c.className == "Humanoid" then | |
| 480 | c.Parent = nil | |
| 481 | end | |
| 482 | end | |
| 483 | end | |
| 484 | end | |
| 485 | yellow.Parent = Character | |
| 486 | if yellow:findFirstChild("HumanoidRootPart") ~= nil then
| |
| 487 | yellow.HumanoidRootPart.Anchored = true | |
| 488 | end | |
| 489 | shed = yellow.Head | |
| 490 | storso = yellow.Torso | |
| 491 | sroot = yellow.HumanoidRootPart | |
| 492 | slarm = yellow["Left Arm"] | |
| 493 | srarm = yellow["Right Arm"] | |
| 494 | slleg = yellow["Left Leg"] | |
| 495 | srleg = yellow["Right Leg"] | |
| 496 | storso.Size = storso.Size + Vector3.new(.2,.1,.2) | |
| 497 | slarm.Size = slarm.Size + Vector3.new(.2,.1,.2) | |
| 498 | srarm.Size = srarm.Size + Vector3.new(.2,.1,.2) | |
| 499 | slleg.Size = slleg.Size + Vector3.new(.2,.1,.2) | |
| 500 | srleg.Size = srleg.Size + Vector3.new(.2,.1,.2) | |
| 501 | shed.Size = shed.Size + Vector3.new(.2,.1,.2) | |
| 502 | newWeld(storso, slarm, -1.5, 0.5, 0) | |
| 503 | slarm.Weld.C1 = CFrame.new(0, 0.5, 0) | |
| 504 | newWeld(storso, srarm, 1.5, 0.5, 0) | |
| 505 | srarm.Weld.C1 = CFrame.new(0, 0.5, 0) | |
| 506 | newWeld(storso, shed, 0, 1.5, 0) | |
| 507 | newWeld(storso, slleg, -0.5, -1, 0) | |
| 508 | slleg.Weld.C1 = CFrame.new(0, 1, 0) | |
| 509 | newWeld(storso, srleg, 0.5, -1, 0) | |
| 510 | srleg.Weld.C1 = CFrame.new(0, 1, 0) | |
| 511 | newWeld(sroot, storso, 0, -1, 0) | |
| 512 | storso.Weld.C1 = CFrame.new(0, -1, 0) | |
| 513 | Character.Archivable = false | |
| 514 | local forms = {
| |
| 515 | yellow | |
| 516 | } | |
| 517 | --------------------------------------------- | |
| 518 | function parto(formfactor,parent,material,reflectance,transparency,brickcolor,name,size) | |
| 519 | local fp=it("Part")
| |
| 520 | fp.formFactor=formfactor | |
| 521 | fp.Parent=parent | |
| 522 | fp.Reflectance=reflectance | |
| 523 | fp.Transparency=transparency | |
| 524 | fp.CanCollide=false | |
| 525 | fp.Locked=true | |
| 526 | fp.BrickColor=BrickColor.new(tostring(brickcolor)) | |
| 527 | fp.Name=name | |
| 528 | fp.Size=size | |
| 529 | fp.Position=char.Torso.Position | |
| 530 | NoOutline(fp) | |
| 531 | fp.Material="Neon" | |
| 532 | fp:BreakJoints() | |
| 533 | return fp | |
| 534 | end | |
| 535 | ||
| 536 | local PowerBrickColor = BrickColor.new("Really red")
| |
| 537 | function Showdamage(Pos, Text, Time, Color) | |
| 538 | local Rate = (1 / 30) | |
| 539 | local Pos = (Pos or Vector3.new(0, 0, 0)) | |
| 540 | local Text = (Text or "") | |
| 541 | local Time = (Time or 2) | |
| 542 | local Color = (Color or Color3.new(1, 0, 0)) | |
| 543 | local EffectPart = parto("Custom", workspace, "Neon", 0, 1, BrickColor.new(Color), "Effect", vt(0, 0, 0))
| |
| 544 | EffectPart.Anchored = true | |
| 545 | local BillboardGui = Instance.new("BillboardGui")
| |
| 546 | BillboardGui.Size = UDim2.new(3, 0, 3, 0) | |
| 547 | BillboardGui.Adornee = EffectPart | |
| 548 | BillboardGui.Parent = EffectPart | |
| 549 | ||
| 550 | local TextLabel = Instance.new("TextLabel")
| |
| 551 | TextLabel.BackgroundTransparency = 1 | |
| 552 | TextLabel.Size = UDim2.new(1, 0, 1, 0) | |
| 553 | TextLabel.Text = Text | |
| 554 | TextLabel.TextColor3 = Color | |
| 555 | TextLabel.TextScaled = true | |
| 556 | TextLabel.Font = Enum.Font.SourceSansBold | |
| 557 | TextLabel.Parent = BillboardGui | |
| 558 | TextLabel.TextStrokeTransparency = 0 | |
| 559 | TextLabel.TextTransparency = 0.2 | |
| 560 | ||
| 561 | ||
| 562 | game.Debris:AddItem(EffectPart, (Time + 0.1)) | |
| 563 | EffectPart.Parent = game:GetService("Workspace")
| |
| 564 | delay(0, function() | |
| 565 | local Frames = (Time / Rate) | |
| 566 | for Frame = 1, Frames do | |
| 567 | wait(Rate) | |
| 568 | local Percent = (Frame / Frames) | |
| 569 | EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0) | |
| 570 | TextLabel.TextTransparency = Percent | |
| 571 | end | |
| 572 | if EffectPart and EffectPart.Parent then | |
| 573 | EffectPart:Destroy() | |
| 574 | end | |
| 575 | end) | |
| 576 | end | |
| 577 | ||
| 578 | Damagefunc = function(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch) | |
| 579 | if hit.Parent == nil then | |
| 580 | return | |
| 581 | end | |
| 582 | local h = hit.Parent:FindFirstChild("Humanoid")
| |
| 583 | for _, v in pairs(hit.Parent:children()) do | |
| 584 | if v:IsA("Humanoid") then
| |
| 585 | h = v | |
| 586 | end | |
| 587 | end | |
| 588 | if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("Torso") ~= nil then
| |
| 589 | if hit.Parent:findFirstChild("DebounceHit") ~= nil then
| |
| 590 | if hit.Parent.DebounceHit.Value == true then | |
| 591 | return | |
| 592 | end | |
| 593 | end | |
| 594 | if h.MaxHealth >= math.huge then | |
| 595 | hit:BreakJoints() | |
| 596 | end | |
| 597 | local c = Instance.new("ObjectValue")
| |
| 598 | c.Name = "creator" | |
| 599 | c.Value = game:service("Players").LocalPlayer
| |
| 600 | c.Parent = h | |
| 601 | ||
| 602 | game:GetService("Debris"):AddItem(c, .5)
| |
| 603 | if HitSound ~= nil and HitPitch ~= nil then | |
| 604 | --so(HitSound, hit, 1, HitPitch) | |
| 605 | end | |
| 606 | local Damage = math.random(minim, maxim) | |
| 607 | -- h:TakeDamage(Damage) | |
| 608 | local blocked = false | |
| 609 | local block = hit.Parent:findFirstChild("Block")
| |
| 610 | if block ~= nil then | |
| 611 | if block.className == "IntValue" then | |
| 612 | if block.Value > 0 then | |
| 613 | blocked = true | |
| 614 | block.Value = block.Value - 1 | |
| 615 | print(block.Value) | |
| 616 | end | |
| 617 | end | |
| 618 | end | |
| 619 | if blocked == false then | |
| 620 | -- h:TakeDamage(Damage) | |
| 621 | h.Health = h.Health - Damage | |
| 622 | if Damage ~= 0 then | |
| 623 | Showdamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1, PowerBrickColor.Color) | |
| 624 | end | |
| 625 | else | |
| 626 | h.Health = h.Health - (Damage / 2) | |
| 627 | if Damage ~=0 then | |
| 628 | Showdamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1, PowerBrickColor.Color) | |
| 629 | end | |
| 630 | end | |
| 631 | if Type == "Knockdown" then | |
| 632 | local hum = hit.Parent.Humanoid | |
| 633 | hum.PlatformStand = true | |
| 634 | coroutine.resume(coroutine.create(function(HHumanoid) | |
| 635 | swait(1) | |
| 636 | HHumanoid.PlatformStand = false | |
| 637 | end), hum) | |
| 638 | local angle = (hit.Position - (Property.Position + Vector3.new(0, 0, 0))).unit | |
| 639 | local bodvol = Instance.new("BodyVelocity")
| |
| 640 | bodvol.velocity = angle * knockback | |
| 641 | bodvol.P = 5000 | |
| 642 | bodvol.maxForce = Vector3.new(8e+003, 8e+003, 8e+003) | |
| 643 | bodvol.Parent = hit | |
| 644 | ||
| 645 | local rl = Instance.new("BodyAngularVelocity")
| |
| 646 | rl.P = 3000 | |
| 647 | rl.maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000 | |
| 648 | rl.angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)) | |
| 649 | rl.Parent = hit | |
| 650 | ||
| 651 | game:GetService("Debris"):AddItem(bodvol, .5)
| |
| 652 | game:GetService("Debris"):AddItem(rl, .5)
| |
| 653 | elseif Type == "Plat" then | |
| 654 | local hum = hit.Parent.Humanoid | |
| 655 | hum.PlatformStand = true | |
| 656 | coroutine.resume(coroutine.create(function(HHumanoid) | |
| 657 | wait(0.8) | |
| 658 | HHumanoid.PlatformStand = false | |
| 659 | end), hum) | |
| 660 | ||
| 661 | local rl = Instance.new("BodyAngularVelocity")
| |
| 662 | rl.P = 3000 | |
| 663 | rl.maxTorque = Vector3.new(100, 100, 100) * 500 | |
| 664 | rl.angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)) | |
| 665 | rl.Parent = hit | |
| 666 | ||
| 667 | game:GetService("Debris"):AddItem(rl, .5)
| |
| 668 | ||
| 669 | local vp = Instance.new("BodyVelocity")
| |
| 670 | vp.P = 500 | |
| 671 | vp.maxForce = Vector3.new(math.huge, 0, math.huge) | |
| 672 | vp.velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05 | |
| 673 | ||
| 674 | if knockback > 0 then | |
| 675 | vp.Parent = hit.Parent.Torso | |
| 676 | end | |
| 677 | game:GetService("Debris"):AddItem(vp, .5)
| |
| 678 | ||
| 679 | elseif Type == "Normal" then | |
| 680 | local vp = Instance.new("BodyVelocity")
| |
| 681 | vp.P = 500 | |
| 682 | vp.maxForce = Vector3.new(math.huge, 0, math.huge) | |
| 683 | vp.velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05 | |
| 684 | ||
| 685 | if knockback > 0 then | |
| 686 | vp.Parent = hit.Parent.Torso | |
| 687 | end | |
| 688 | game:GetService("Debris"):AddItem(vp, .5)
| |
| 689 | elseif Type == "Gravitate" then | |
| 690 | local tor = hit.Parent.Torso | |
| 691 | local bp = Instance.new("BodyPosition",tor)
| |
| 692 | bp.P = 500 | |
| 693 | bp.maxForce = Vector3.new(4000, 1000, 4000) | |
| 694 | bp.Position = char.Torso.Position | |
| 695 | game:GetService("Debris"):AddItem(bp, Delay)
| |
| 696 | elseif Type == "Up" then | |
| 697 | local bodyVelocity = Instance.new("BodyVelocity")
| |
| 698 | bodyVelocity.velocity = vt(0, 20, 0) | |
| 699 | bodyVelocity.P = 5000 | |
| 700 | bodyVelocity.maxForce = Vector3.new(8e+003, 8e+003, 8e+003) | |
| 701 | bodyVelocity.Parent = hit | |
| 702 | ||
| 703 | game:GetService("Debris"):AddItem(bodyVelocity, .5)
| |
| 704 | elseif Type == "Snare" then | |
| 705 | local bp = Instance.new("BodyPosition")
| |
| 706 | bp.P = 2000 | |
| 707 | bp.D = 100 | |
| 708 | bp.maxForce = Vector3.new(math.huge, math.huge, math.huge) | |
| 709 | bp.position = hit.Parent.Torso.Position | |
| 710 | bp.Parent = hit.Parent.Torso | |
| 711 | game:GetService("Debris"):AddItem(bp, 1)
| |
| 712 | ||
| 713 | elseif Type == "Freeze" then | |
| 714 | local BodPos = Instance.new("BodyPosition")
| |
| 715 | BodPos.P = 50000 | |
| 716 | BodPos.D = 1000 | |
| 717 | BodPos.maxForce = Vector3.new(math.huge, math.huge, math.huge) | |
| 718 | BodPos.position = hit.Parent.Torso.Position | |
| 719 | BodPos.Parent = hit.Parent.Torso | |
| 720 | ||
| 721 | local BodGy = Instance.new("BodyGyro")
| |
| 722 | BodGy.maxTorque = Vector3.new(4e+005, 4e+005, 4e+005) * math.huge | |
| 723 | BodGy.P = 20e+003 | |
| 724 | BodGy.Parent = hit.Parent.Torso | |
| 725 | BodGy.cframe = hit.Parent.Torso.CFrame | |
| 726 | ||
| 727 | hit.Parent.Torso.Anchored = true | |
| 728 | coroutine.resume(coroutine.create(function(Part) | |
| 729 | swait(1.5) | |
| 730 | Part.Anchored = false | |
| 731 | end), hit.Parent.Torso) | |
| 732 | game:GetService("Debris"):AddItem(BodPos, 3)
| |
| 733 | game:GetService("Debris"):AddItem(BodGy, 3)
| |
| 734 | ||
| 735 | ||
| 736 | elseif Type=="Target" then | |
| 737 | if Targetting==false then | |
| 738 | ZTarget=hit.Parent.Torso | |
| 739 | coroutine.resume(coroutine.create(function(Part) | |
| 740 | --so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
| |
| 741 | swait(5) | |
| 742 | --so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
| |
| 743 | end),ZTarget) | |
| 744 | TargHum=ZTarget.Parent:findFirstChild("Humanoid")
| |
| 745 | targetgui=Instance.new("BillboardGui")
| |
| 746 | targetgui.Parent=ZTarget | |
| 747 | targetgui.Size=UDim2.new(10,100,10,100) | |
| 748 | targ=Instance.new("ImageLabel")
| |
| 749 | targ.Parent=targetgui | |
| 750 | targ.BackgroundTransparency=1 | |
| 751 | targ.Image="rbxassetid://4834067" | |
| 752 | targ.Size=UDim2.new(1,0,1,0) | |
| 753 | cam.CameraType="Scriptable" | |
| 754 | cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position) | |
| 755 | dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z) | |
| 756 | workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position) | |
| 757 | Targetting=true | |
| 758 | RocketTarget=ZTarget | |
| 759 | for i=1,Property do | |
| 760 | if Humanoid.Health>0 and char.Parent~=nil and TargHum.Health>0 and TargHum.Parent~=nil and Targetting==true then | |
| 761 | swait() | |
| 762 | end | |
| 763 | cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position) | |
| 764 | dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z) | |
| 765 | cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)*cf(0,5,10)*euler(-0.3,0,0) | |
| 766 | end | |
| 767 | Targetting=false | |
| 768 | RocketTarget=nil | |
| 769 | targetgui.Parent=nil | |
| 770 | cam.CameraType="Custom" | |
| 771 | end | |
| 772 | end | |
| 773 | ||
| 774 | local debounce = Instance.new("BoolValue")
| |
| 775 | debounce.Name = "DebounceHit" | |
| 776 | debounce.Parent = hit.Parent | |
| 777 | debounce.Value = true | |
| 778 | game:GetService("Debris"):AddItem(debounce, Delay)
| |
| 779 | c = Instance.new("ObjectValue")
| |
| 780 | c.Name = "creator" | |
| 781 | c.Value = Player | |
| 782 | c.Parent = h | |
| 783 | game:GetService("Debris"):AddItem(c, .5)
| |
| 784 | end | |
| 785 | end | |
| 786 | MousePlane = function() | |
| 787 | local mouse = game.Players.LocalPlayer:GetMouse() | |
| 788 | local buttspoop = (game.Players.LocalPlayer.Character.HumanoidRootPart.Position - mouse.Hit.p).unit | |
| 789 | return -Vector3.new(buttspoop.x,0,buttspoop.z).unit | |
| 790 | end | |
| 791 | ||
| 792 | NewPart = function(size, cframe, color, meshtype, meshscale) | |
| 793 | local par = Instance.new("Part")
| |
| 794 | par.formFactor = "Custom" | |
| 795 | par.TopSurface = 0 | |
| 796 | par.BottomSurface = 0 | |
| 797 | par.Size = size | |
| 798 | par.CFrame = cframe | |
| 799 | par.Material = "Neon" | |
| 800 | par.BrickColor = BrickColor.new(color) | |
| 801 | do | |
| 802 | if meshtype then | |
| 803 | local m = Instance.new(meshtype, par) | |
| 804 | m.Scale = meshscale | |
| 805 | end | |
| 806 | return par | |
| 807 | end | |
| 808 | end | |
| 809 | MousePlane = function() | |
| 810 | local mouse = game.Players.LocalPlayer:GetMouse() | |
| 811 | local buttspoop = (game.Players.LocalPlayer.Character.HumanoidRootPart.Position - mouse.Hit.p).unit | |
| 812 | return -Vector3.new(buttspoop.x,0,buttspoop.z).unit | |
| 813 | end | |
| 814 | ||
| 815 | function giant(p, size) | |
| 816 | local pchar = p.Character | |
| 817 | if pchar then | |
| 818 | local function scale(chr,scl) | |
| 819 | ||
| 820 | for _,v in pairs(pchar:GetChildren()) do | |
| 821 | if v:IsA("Accessory") then
| |
| 822 | v:Clone() | |
| 823 | v.Parent = game.Lighting | |
| 824 | end | |
| 825 | end | |
| 826 | ||
| 827 | local Head = chr['Head'] | |
| 828 | local Torso = chr['Torso'] | |
| 829 | local LA = chr['Left Arm'] | |
| 830 | local RA = chr['Right Arm'] | |
| 831 | local LL = chr['Left Leg'] | |
| 832 | local RL = chr['Right Leg'] | |
| 833 | local HRP = chr['HumanoidRootPart'] | |
| 834 | ||
| 835 | wait(0.1) | |
| 836 | ||
| 837 | Head.formFactor = 3 | |
| 838 | Torso.formFactor = 3 | |
| 839 | LA.formFactor = 3 | |
| 840 | RA.formFactor = 3 | |
| 841 | LL.formFactor = 3 | |
| 842 | RL.formFactor = 3 | |
| 843 | HRP.formFactor = 3 | |
| 844 | Head.Mesh.Scale = Vector3.new(scl + .25, scl + .25, scl + .25) | |
| 845 | Torso.Size = Vector3.new(scl * 2, scl * 2, scl) | |
| 846 | LA.Size = Vector3.new(scl, scl * 2, scl) | |
| 847 | RA.Size = Vector3.new(scl, scl * 2, scl) | |
| 848 | LL.Size = Vector3.new(scl, scl * 2, scl) | |
| 849 | RL.Size = Vector3.new(scl, scl * 2, scl) | |
| 850 | HRP.Size = Vector3.new(scl * 2, scl * 2, scl) | |
| 851 | for i,v in pairs(pchar:GetChildren()) do | |
| 852 | if v:IsA("Hat") then
| |
| 853 | print("FOUND ACCESSORY")
| |
| 854 | for ii,vi in pairs(v:GetChildren()) do | |
| 855 | if vi:IsA("Mesh") then
| |
| 856 | vi.Scale = Vector3.new(scl, scl, scl) | |
| 857 | elseif vi:IsA("Part") then
| |
| 858 | print("FOUND PART")
| |
| 859 | for iii,vii in pairs(vi:GetChildren()) do | |
| 860 | if vii:IsA("Mesh") then
| |
| 861 | vii.Scale = Vector3.new(scl, scl, scl) | |
| 862 | end | |
| 863 | end | |
| 864 | end | |
| 865 | end | |
| 866 | end | |
| 867 | end | |
| 868 | local Motor1 = Instance.new('Motor6D', Torso)
| |
| 869 | Motor1.Part0 = Torso | |
| 870 | Motor1.Part1 = Head | |
| 871 | Motor1.C0 = CFrame.new(0, 1 * scl, 0) * CFrame.Angles(-1.6, 0, 3.1) | |
| 872 | Motor1.C1 = CFrame.new(0, -0.5 * scl, 0) * CFrame.Angles(-1.6, 0, 3.1) | |
| 873 | Motor1.Name = "Neck" | |
| 874 | ||
| 875 | local Motor2 = Instance.new('Motor6D', Torso)
| |
| 876 | Motor2.Part0 = Torso | |
| 877 | Motor2.Part1 = LA | |
| 878 | Motor2.C0 = CFrame.new(-1 * scl, 0.5 * scl, 0) * CFrame.Angles(0, -1.6, 0) | |
| 879 | Motor2.C1 = CFrame.new(0.5 * scl, 0.5 * scl, 0) * CFrame.Angles(0, -1.6, 0) | |
| 880 | Motor2.Name = "Left Shoulder" | |
| 881 | ||
| 882 | local Motor3 = Instance.new('Motor6D', Torso)
| |
| 883 | Motor3.Part0 = Torso | |
| 884 | Motor3.Part1 = RA | |
| 885 | Motor3.C0 = CFrame.new(1 * scl, 0.5 * scl, 0) * CFrame.Angles(0, 1.6, 0) | |
| 886 | Motor3.C1 = CFrame.new(-0.5 * scl, 0.5 * scl, 0) * CFrame.Angles(0, 1.6, 0) | |
| 887 | Motor3.Name = "Right Shoulder" | |
| 888 | ||
| 889 | local Motor4 = Instance.new('Motor6D', Torso)
| |
| 890 | Motor4.Part0 = Torso | |
| 891 | Motor4.Part1 = LL | |
| 892 | Motor4.C0 = CFrame.new(-1 * scl, -1 * scl, 0) * CFrame.Angles(0, -1.6, 0) | |
| 893 | Motor4.C1 = CFrame.new(-0.5 * scl, 1 * scl, 0) * CFrame.Angles(0, -1.6, 0) | |
| 894 | Motor4.Name = "Left Hip" | |
| 895 | ||
| 896 | local Motor5 = Instance.new('Motor6D', Torso)
| |
| 897 | Motor5.Part0 = Torso | |
| 898 | Motor5.Part1 = RL | |
| 899 | Motor5.C0 = CFrame.new(1 * scl, -1 * scl, 0) * CFrame.Angles(0, 1.6, 0) | |
| 900 | Motor5.C1 = CFrame.new(0.5 * scl, 1 * scl, 0) * CFrame.Angles(0, 1.6, 0) | |
| 901 | Motor5.Name = "Right Hip" | |
| 902 | ||
| 903 | local Motor6 = Instance.new('Motor6D', HRP)
| |
| 904 | Motor6.Part0 = HRP | |
| 905 | Motor6.Part1 = Torso | |
| 906 | Motor6.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(-1.6, 0, -3.1) | |
| 907 | Motor6.C1 = CFrame.new(0, 0, 0) * CFrame.Angles(-1.6, 0, -3.1) | |
| 908 | ||
| 909 | end | |
| 910 | ||
| 911 | scale(pchar, size) | |
| 912 | pchar.Humanoid.WalkSpeed = 15 * size | |
| 913 | ||
| 914 | for _,v in pairs(game.Lighting:GetChildren()) do | |
| 915 | if v:IsA("Accessory") then
| |
| 916 | for ii,vi in pairs(v:GetChildren()) do | |
| 917 | if vi:IsA("Part") then
| |
| 918 | print("FOUND PART")
| |
| 919 | for iii,vii in pairs(vi:GetChildren()) do | |
| 920 | if vii:IsA("SpecialMesh") then
| |
| 921 | print(vii) | |
| 922 | vii.Scale = Vector3.new(size, size, size) | |
| 923 | end | |
| 924 | end | |
| 925 | end | |
| 926 | end | |
| 927 | v.Parent = pchar | |
| 928 | end | |
| 929 | end | |
| 930 | end | |
| 931 | end | |
| 932 | ||
| 933 | rayCast = function(pos, dir, maxl, ignore) | |
| 934 | return game:service("Workspace"):FindPartOnRay(Ray.new(pos, dir.unit * (maxl or 999.999)), ignore)
| |
| 935 | end | |
| 936 | ||
| 937 | MagicWave = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 938 | local mesh = function(Mesh, part, meshtype, meshid, offset, scale) | |
| 939 | local mesh = it(Mesh) | |
| 940 | mesh.Parent = part | |
| 941 | if Mesh == "SpecialMesh" then | |
| 942 | mesh.MeshType = meshtype | |
| 943 | if meshid ~= "nil" then | |
| 944 | mesh.MeshId = "http://www.roblox.com/asset/?id=" .. meshid | |
| 945 | end | |
| 946 | end | |
| 947 | mesh.Offset = offset | |
| 948 | mesh.Scale = scale | |
| 949 | return mesh | |
| 950 | end | |
| 951 | local prt = part(3, F2, 0, 0, brickcolor, "Effect", vt()) | |
| 952 | prt.Anchored = true | |
| 953 | prt.CFrame = cframe | |
| 954 | local msh = mesh("SpecialMesh", prt, "FileMesh", "20329976", vt(0, 0, 0), vt(x1, y1, z1))
| |
| 955 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 956 | table.insert(Effects, {prt, "Cylinder1", delay, x3, y3, z3, msh})
| |
| 957 | end | |
| 958 | function FindNearestTorso(Position,Distance,SinglePlayer) | |
| 959 | if SinglePlayer then return(SinglePlayer.Torso.CFrame.p -Position).magnitude < Distance end | |
| 960 | local List = {}
| |
| 961 | for i,v in pairs(workspace:GetChildren())do | |
| 962 | if v:IsA("Model")then
| |
| 963 | if v:findFirstChild("Torso")then
| |
| 964 | if v ~= char then | |
| 965 | if(v.Torso.Position -Position).magnitude <= Distance then | |
| 966 | table.insert(List,v) | |
| 967 | end | |
| 968 | end | |
| 969 | end | |
| 970 | end | |
| 971 | end | |
| 972 | return List | |
| 973 | end | |
| 974 | ||
| 975 | function MagicBlock(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay) | |
| 976 | ||
| 977 | local mesh = function(Mesh,part,meshtype,meshid,offset,scale) | |
| 978 | local mesh=it(Mesh) | |
| 979 | mesh.Parent=part | |
| 980 | if Mesh=="SpecialMesh" then | |
| 981 | mesh.MeshType=meshtype | |
| 982 | mesh.MeshId=meshid | |
| 983 | end | |
| 984 | mesh.Offset=offset | |
| 985 | mesh.Scale=scale | |
| 986 | return mesh | |
| 987 | end | |
| 988 | local prt=part(3,F2,0,0,brickcolor,"Effect",vt()) | |
| 989 | prt.Anchored=true | |
| 990 | prt.CFrame=cframe | |
| 991 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 992 | game:GetService("Debris"):AddItem(prt,5)
| |
| 993 | table.insert(Effects,{prt,"Block1",delay,x3,y3,z3}) --part, type, delay
| |
| 994 | --[[coroutine.resume(coroutine.create(function(Part,Mesh,dur) | |
| 995 | for i=0,1,delay do | |
| 996 | wait() | |
| 997 | Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 998 | Part.Transparency=i | |
| 999 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1000 | end | |
| 1001 | Part.Parent=nil | |
| 1002 | end),prt,msh)]] | |
| 1003 | end | |
| 1004 | function Lightning(Part0,Part1,Times,Offset,Color,Thickness,Trans) -- Lightning module | |
| 1005 | --[[Part0 = Vector3 (Start pos) | |
| 1006 | Part1 = Vector3 (End pos) | |
| 1007 | Times = number (Amount of lightning parts) | |
| 1008 | Offset = number (Offset) | |
| 1009 | Color = color (brickcolor value) | |
| 1010 | Thickness = number (thickness) | |
| 1011 | Trans = number (transparency) | |
| 1012 | ]]-- | |
| 1013 | local magz = (Part0 - Part1).magnitude | |
| 1014 | local curpos = Part0 | |
| 1015 | local trz = {-Offset,Offset}
| |
| 1016 | for i=1,Times do | |
| 1017 | local li = Instance.new("Part", torso)
| |
| 1018 | li.Name = "Lightning" | |
| 1019 | li.TopSurface =0 | |
| 1020 | li.Material = "Neon" | |
| 1021 | li.BottomSurface = 0 | |
| 1022 | li.Anchored = true | |
| 1023 | li.Locked = true | |
| 1024 | li.Transparency = Trans or 0.4 | |
| 1025 | li.BrickColor = BrickColor.new(Color) | |
| 1026 | li.formFactor = "Custom" | |
| 1027 | li.CanCollide = false | |
| 1028 | li.Size = Vector3.new(Thickness,Thickness,magz/Times) | |
| 1029 | local Offzet = Vector3.new(trz[math.random(1,2)],trz[math.random(1,2)],trz[math.random(1,2)]) | |
| 1030 | local trolpos = CFrame.new(curpos,Part1)*CFrame.new(0,0,magz/Times).p+Offzet | |
| 1031 | if Times == i then | |
| 1032 | local magz2 = (curpos - Part1).magnitude | |
| 1033 | li.Size = Vector3.new(Thickness,Thickness,magz2) | |
| 1034 | li.CFrame = CFrame.new(curpos,Part1)*CFrame.new(0,0,-magz2/2) | |
| 1035 | else | |
| 1036 | li.CFrame = CFrame.new(curpos,trolpos)*CFrame.new(0,0,magz/Times/2) | |
| 1037 | end | |
| 1038 | curpos = li.CFrame*CFrame.new(0,0,magz/Times/2).p | |
| 1039 | game.Debris:AddItem(li,.1) | |
| 1040 | end | |
| 1041 | end | |
| 1042 | local Neons = {BrickColor.new("Bright red"), BrickColor.new("Bright orange"), BrickColor.new("Bright yellow"), BrickColor.new("Bright green"), BrickColor.new("Bright blue"), BrickColor.new("Royal purple"), BrickColor.new("Bright violet")}
| |
| 1043 | local neonazi = "Bright red", "Bright orange", "Bright yellow", "Bright green", "Bright blue", "Bright violet", "Royal purple" | |
| 1044 | local effects = Instance.new("Model", char)
| |
| 1045 | effects.Name = "Effects" | |
| 1046 | do2 = function(brickcolor) | |
| 1047 | ||
| 1048 | ||
| 1049 | local mesh = function(Mesh,part,meshtype,meshid,offset,scale) | |
| 1050 | local mesh=it(Mesh) | |
| 1051 | mesh.Parent=part | |
| 1052 | if Mesh=="SpecialMesh" then | |
| 1053 | mesh.MeshType=meshtype | |
| 1054 | mesh.MeshId=meshid | |
| 1055 | end | |
| 1056 | mesh.Offset=offset | |
| 1057 | mesh.Scale=scale | |
| 1058 | return mesh | |
| 1059 | end | |
| 1060 | local rara1 = Instance.new("NumberValue", Decrease)
| |
| 1061 | rara1.Name = "DecreaseMvmt" | |
| 1062 | rara1.Value = -0.05 | |
| 1063 | local rara2 = Instance.new("NumberValue", Decrease)
| |
| 1064 | rara2.Name = "DecreaseDef" | |
| 1065 | rara2.Value = 0.1 | |
| 1066 | --so("341336144", larm, 1, 1)
| |
| 1067 | --so("341336144", rarm, 1, 1)
| |
| 1068 | sbreaker = true | |
| 1069 | local sbref1 = part(3, effects, 0, 1, BrickColor.new("Black"), "Reference", vt())
| |
| 1070 | local sbrwld1 = weld(sbref1, sbref1, larm, cf(0, 1, 0)) | |
| 1071 | local sbref2 = part(3, effects, 0, 1, BrickColor.new("Black"), "Reference", vt())
| |
| 1072 | local sbrwld2 = weld(sbref2, sbref2, rarm, cf(0, 1, 0)) | |
| 1073 | local sref = part(3, nil, 0, 1, BrickColor.new("Black"), "Reference", vt())
| |
| 1074 | sref.Anchored = true | |
| 1075 | TehM = nil | |
| 1076 | TehM = torso.Position | |
| 1077 | MouseLook = cf(RootPart.Position) | |
| 1078 | local hit, pos = rayCast(RootPart.Position, MouseLook.lookVector, 200, char) | |
| 1079 | rand = cf(math.random(0, 0) / 100, 10, math.random(0, 0) / 100) | |
| 1080 | sref.CFrame = cf(RootPart.Position)*rand | |
| 1081 | local hit2, pos2 = rayCast(sref.Position, CFrame.new(sref.Position, sref.Position - Vector3.new(0, 1, 0)).lookVector, 999, char) | |
| 1082 | local d1 = part(3, effects, 0, 0.5, BrickColor.new("White"), "Effect", vt())
| |
| 1083 | d1.Anchored = true | |
| 1084 | d1.CFrame = cf(RootPart.Position) | |
| 1085 | d1.Material = "Neon" | |
| 1086 | msh = mesh("CylinderMesh", d1, "nil", "nil", vt(0, 0, 0), vt(50, 5, 50))
| |
| 1087 | d2 = d1:Clone() | |
| 1088 | d2.Transparency = 1 | |
| 1089 | d2.Parent = d1 | |
| 1090 | d2.CFrame = cf(d1.Position) | |
| 1091 | d2.BrickColor = brickcolor | |
| 1092 | refda = part(3, effects, 0, 1, BrickColor.new("Black"), "Reference", vt())
| |
| 1093 | refda.Anchored = true | |
| 1094 | refda.CFrame = cf(d1.Position) * cf(0, 500, 0) | |
| 1095 | game:GetService("Debris"):AddItem(refda, 1)
| |
| 1096 | local mag = (refda.Position - d1.Position).magnitude | |
| 1097 | --MagicCylinder(BrickColor.new("White"), CFrame.new((refda.Position + d1.Position) / 2, d1.Position) * angles(1.57, 0, 0), 40, mag * 5, 40, 0, 0, 0, 0.3)
| |
| 1098 | Lightning(refda.Position, d1.Position, 15, 5, brickcolor.Color, 3.5, 0.2, 0.05) | |
| 1099 | MagicBlock(brickcolor, cf(d1.Position), 40, 40, 40, -1, -1, -1, 0.08, 1) | |
| 1100 | refda.CFrame = cf(d1.Position) | |
| 1101 | --MagniDamage(refda, 5, 10, 12, 0, "Knockdown2", refda, 0.1, 1, (math.random(10, 12)), nil, nil, true) | |
| 1102 | refda.CFrame = cf(d1.Position) * cf(0, 3, 0) | |
| 1103 | --MagniDamage(refda, 5, 10, 12, 0, "Knockdown2", refda, 0.1, 1, (math.random(10, 12)), nil, nil, true) | |
| 1104 | refda.CFrame = cf(d1.Position) | |
| 1105 | --so("341336446", refda, 1, math.random(100, 120) / 100)
| |
| 1106 | --so("341336459", refda, 1, math.random(100, 120) / 100)
| |
| 1107 | rara1.Parent = nil | |
| 1108 | rara2.Parent = nil | |
| 1109 | sbrwld1.Parent = nil | |
| 1110 | sbrwld2.Parent = nil | |
| 1111 | sbref1.Anchored = true | |
| 1112 | sbref2.Anchored = true | |
| 1113 | game:GetService("Debris"):AddItem(d1, 0)
| |
| 1114 | game:GetService("Debris"):AddItem(d2, 0)
| |
| 1115 | game:GetService("Debris"):AddItem(sbref1, 0)
| |
| 1116 | game:GetService("Debris"):AddItem(sbref2, 0)
| |
| 1117 | end | |
| 1118 | function fly(hite, knockback) | |
| 1119 | if hite:FindFirstChild('Humanoid') ~= nil then
| |
| 1120 | local hum = hite.Humanoid | |
| 1121 | hum.PlatformStand = true | |
| 1122 | coroutine.resume(coroutine.create(function(HHumanoid) | |
| 1123 | wait(0.8) | |
| 1124 | HHumanoid.PlatformStand = false | |
| 1125 | end), hum) | |
| 1126 | local rl = Instance.new("BodyAngularVelocity")
| |
| 1127 | rl.P = 3000 | |
| 1128 | rl.maxTorque = Vector3.new(100, 100, 100) * 500 | |
| 1129 | rl.angularvelocity = Vector3.new(math.random(-10, 10), math.random(-20, 20), math.random(-10, 10)) | |
| 1130 | rl.Parent = hite.Torso | |
| 1131 | game:GetService("Debris"):AddItem(rl, .5)
| |
| 1132 | ||
| 1133 | local vp = Instance.new("BodyVelocity")
| |
| 1134 | vp.P = 500 | |
| 1135 | vp.maxForce = Vector3.new(math.huge, 100, math.huge) | |
| 1136 | vp.velocity = RootPart.CFrame.lookVector * knockback + RootPart.Velocity / 1.05 | |
| 1137 | if knockback > 0 then | |
| 1138 | vp.Parent = hite.Torso | |
| 1139 | end | |
| 1140 | game:GetService("Debris"):AddItem(vp, .5)
| |
| 1141 | elseif hite.className == 'Part' then | |
| 1142 | local rl = Instance.new("BodyAngularVelocity")
| |
| 1143 | rl.P = 3000 | |
| 1144 | rl.maxTorque = Vector3.new(100, 100, 100) * 500 | |
| 1145 | rl.angularvelocity = Vector3.new(math.random(-10, 10), math.random(-20, 20), math.random(-10, 10)) | |
| 1146 | rl.Parent = hite | |
| 1147 | game:GetService("Debris"):AddItem(rl, .5)
| |
| 1148 | ||
| 1149 | local vp = Instance.new("BodyVelocity")
| |
| 1150 | vp.P = 500 | |
| 1151 | vp.maxForce = Vector3.new(math.huge, 100, math.huge) | |
| 1152 | vp.velocity = RootPart.CFrame.lookVector * knockback + RootPart.Velocity / 1.05 | |
| 1153 | if knockback > 0 then | |
| 1154 | vp.Parent = hite | |
| 1155 | end | |
| 1156 | game:GetService("Debris"):AddItem(vp, .5)
| |
| 1157 | end | |
| 1158 | end | |
| 1159 | function ap(arg1) | |
| 1160 | if arg1 == 1 then | |
| 1161 | for i,v in pairs(yellow:children()) do | |
| 1162 | if v:IsA'Part' then | |
| 1163 | storso.CFrame = torso.CFrame | |
| 1164 | Debounces.Doe = true | |
| 1165 | v.Transparency = 0.7 | |
| 1166 | yellow.HumanoidRootPart.Transparency = 1 | |
| 1167 | end | |
| 1168 | end | |
| 1169 | end | |
| 1170 | end | |
| 1171 | function dap(arg1) | |
| 1172 | if arg1 == 1 then | |
| 1173 | for i,v in pairs(yellow:children()) do | |
| 1174 | if v:IsA'Part' then | |
| 1175 | Debounces.Doe = false | |
| 1176 | v.Transparency = 1 | |
| 1177 | end | |
| 1178 | end | |
| 1179 | end | |
| 1180 | end | |
| 1181 | --------------------------------------------------- | |
| 1182 | local modes = {
| |
| 1183 | ['cannon'] = true, | |
| 1184 | ['lightning'] = false, | |
| 1185 | ['beam'] = false | |
| 1186 | } | |
| 1187 | --Attacks | |
| 1188 | function attack1(brickcolor) | |
| 1189 | Debounces.CanAttack = false | |
| 1190 | Debounces.NoIdl = true | |
| 1191 | Debounces.on = true | |
| 1192 | sroot.Anchored = false | |
| 1193 | coroutine.resume(coroutine.create(function() | |
| 1194 | for i=1,10 do | |
| 1195 | --wait(0.01) | |
| 1196 | srarm.Weld.C0 = Lerp(srarm.Weld.C0, CFrame.new(1.5,0.65,0)*CFrame.Angles(math.rad(-90),math.rad(0),math.rad(120)), 0.2) | |
| 1197 | slarm.Weld.C0 = Lerp(slarm.Weld.C0, CFrame.new(-1.5,0.65,0)*CFrame.Angles(math.rad(20),math.rad(0),math.rad(-20)), 0.2) | |
| 1198 | shed.Weld.C0 = Lerp(shed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-10),math.rad(-80),0), 0.2) | |
| 1199 | storso.Weld.C0 = Lerp(storso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(0, math.rad(-25), 0), 0.2) | |
| 1200 | slleg.Weld.C0 = Lerp(slleg.Weld.C0, CFrame.new(-0.8, -1, 0.3) * CFrame.Angles(math.rad(-20), math.rad(0), math.rad(0)), 0.2) | |
| 1201 | srleg.Weld.C0 = Lerp(srleg.Weld.C0, CFrame.new(0.7, -1, -.5) * CFrame.Angles(math.rad(0), math.rad(-80), math.rad(0)), 0.2) | |
| 1202 | rs:wait(0) | |
| 1203 | sroot.CFrame = torso.CFrame | |
| 1204 | end | |
| 1205 | for i=1,10 do | |
| 1206 | --wait(0.01) | |
| 1207 | srarm.Weld.C0 = Lerp(srarm.Weld.C0, CFrame.new(1.5,0.65,0)*CFrame.Angles(math.rad(-90),math.rad(-60),math.rad(120)), 0.7) | |
| 1208 | slarm.Weld.C0 = Lerp(slarm.Weld.C0, CFrame.new(-1.5,0.65,0)*CFrame.Angles(math.rad(20),math.rad(0),math.rad(-30)), 0.7) | |
| 1209 | shed.Weld.C0 = Lerp(shed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-10),math.rad(-80),0), 0.7) | |
| 1210 | storso.Weld.C0 = Lerp(storso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(0, math.rad(-20), 0), 0.7) | |
| 1211 | slleg.Weld.C0 = Lerp(slleg.Weld.C0, CFrame.new(-0.8, -1, 0.3) * CFrame.Angles(math.rad(-20), math.rad(0), math.rad(0)), 0.7) | |
| 1212 | srleg.Weld.C0 = Lerp(srleg.Weld.C0, CFrame.new(0.7, -1, -.5) * CFrame.Angles(math.rad(0), math.rad(-80), math.rad(0)), 0.7) | |
| 1213 | rs:wait(0) | |
| 1214 | sroot.CFrame = torso.CFrame | |
| 1215 | end | |
| 1216 | sroot.Anchored = true | |
| 1217 | end)) | |
| 1218 | for i=1,10 do | |
| 1219 | --wait(0.01) | |
| 1220 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.65,0)*CFrame.Angles(math.rad(-90),math.rad(0),math.rad(120)), 0.2) | |
| 1221 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.65,0)*CFrame.Angles(math.rad(20),math.rad(0),math.rad(-20)), 0.2) | |
| 1222 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-10),math.rad(-80),0), 0.2) | |
| 1223 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(0, math.rad(65), 0), 0.2) | |
| 1224 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.8, -1, 0.3) * CFrame.Angles(math.rad(-20), math.rad(0), math.rad(0)), 0.2) | |
| 1225 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.7, -1, -.5) * CFrame.Angles(math.rad(0), math.rad(-80), math.rad(0)), 0.2) | |
| 1226 | rs:wait(0) | |
| 1227 | end | |
| 1228 | for i=1,10 do | |
| 1229 | --wait(0.01) | |
| 1230 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.65,0)*CFrame.Angles(math.rad(-90),math.rad(-60),math.rad(120)), 0.7) | |
| 1231 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.65,0)*CFrame.Angles(math.rad(20),math.rad(0),math.rad(-30)), 0.7) | |
| 1232 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-10),math.rad(-80),0), 0.7) | |
| 1233 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(0, math.rad(55), 0), 0.7) | |
| 1234 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.8, -1, 0.3) * CFrame.Angles(math.rad(-20), math.rad(0), math.rad(0)), 0.7) | |
| 1235 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.7, -1, -.5) * CFrame.Angles(math.rad(0), math.rad(-80), math.rad(0)), 0.7) | |
| 1236 | rs:wait(0) | |
| 1237 | end | |
| 1238 | MagicBlock(brickcolor, cf(rarm.CFrame.p), 10, 10, 10, -1, -1, -1, 0.08, 1) | |
| 1239 | for i,v in pairs(modes) do | |
| 1240 | if v == true and i == 'cannon' then | |
| 1241 | print(i) | |
| 1242 | Lightning(rarm.Position, mouse.Hit.p, 1, 5, "Bright yellow", 2, 0.1, 0.03) | |
| 1243 | end | |
| 1244 | if v == true and i == 'lightning' then | |
| 1245 | print(i) | |
| 1246 | Lightning(rarm.Position, mouse.Hit.p, 5, 5, "Bright yellow", 0.4, 0.1, 0.03) | |
| 1247 | MagicBlock(brickcolor, cf(mouse.Hit.p), 40, 40, 40, -1, -1, -1, 0.08, 1) | |
| 1248 | if mouse.Target.className ~= 'Terrain' then | |
| 1249 | mouse.Target:BreakJoints() | |
| 1250 | fly(mouse.Target, 100) | |
| 1251 | end | |
| 1252 | end | |
| 1253 | if v == true and i == 'beam' then | |
| 1254 | print(i) | |
| 1255 | Lightning(rarm.Position, mouse.Hit.p, 1, 5, "Bright yellow", 0.5, 0.1, 0.03) | |
| 1256 | end | |
| 1257 | end | |
| 1258 | Debounces.CanAttack = true | |
| 1259 | Debounces.NoIdl = false | |
| 1260 | Debounces.on = false | |
| 1261 | end | |
| 1262 | function handcannon(brickcolor) | |
| 1263 | Debounces.CanAttack = false | |
| 1264 | Debounces.NoIdl = true | |
| 1265 | Debounces.on = true | |
| 1266 | sroot.Anchored = false | |
| 1267 | coroutine.resume(coroutine.create(function() | |
| 1268 | for i = 1, 10 do | |
| 1269 | srarm.Weld.C0 = Lerp(srarm.Weld.C0, CFrame.new(1.5,0.62,0)*CFrame.Angles(math.rad(-40),math.rad(0),math.rad(-20)), 0.4) | |
| 1270 | slarm.Weld.C0 = Lerp(slarm.Weld.C0, CFrame.new(-1.2,0.62,-.2)*CFrame.Angles(math.rad(90),math.rad(0),math.rad(-40)), 0.4) | |
| 1271 | shed.Weld.C0 = Lerp(shed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-14),math.rad(50),0), 0.4) | |
| 1272 | storso.Weld.C0 = Lerp(storso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(0, math.rad(-20), math.rad(0)), 0.4) | |
| 1273 | slleg.Weld.C0 = Lerp(slleg.Weld.C0, CFrame.new(-0.5, -1, -.3) * CFrame.Angles(0, 0, math.rad(-8)), 0.4) | |
| 1274 | srleg.Weld.C0 = Lerp(srleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(-30), 0, math.rad(8)), 0.4) | |
| 1275 | if Debounces.on == false then break end | |
| 1276 | rs:wait() | |
| 1277 | sroot.CFrame = torso.CFrame | |
| 1278 | end | |
| 1279 | for i = 1, 10 do | |
| 1280 | srarm.Weld.C0 = Lerp(srarm.Weld.C0, CFrame.new(1.5,0.62,0)*CFrame.Angles(math.rad(-40),math.rad(0),math.rad(-20)), 0.4) | |
| 1281 | slarm.Weld.C0 = Lerp(slarm.Weld.C0, CFrame.new(-1.2,0.62,-.2)*CFrame.Angles(math.rad(120),math.rad(0),math.rad(-10)), 0.4) | |
| 1282 | shed.Weld.C0 = Lerp(shed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-14),math.rad(50),0), 0.4) | |
| 1283 | storso.Weld.C0 = Lerp(storso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(0, math.rad(-20), math.rad(0)), 0.4) | |
| 1284 | slleg.Weld.C0 = Lerp(slleg.Weld.C0, CFrame.new(-0.5, -1, -.3) * CFrame.Angles(0, 0, math.rad(-8)), 0.4) | |
| 1285 | srleg.Weld.C0 = Lerp(srleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(-20), 0, math.rad(8)), 0.4) | |
| 1286 | if Debounces.on == false then break end | |
| 1287 | rs:wait() | |
| 1288 | sroot.CFrame = torso.CFrame | |
| 1289 | end | |
| 1290 | sroot.Anchored = true | |
| 1291 | end)) | |
| 1292 | for i = 1, 10 do | |
| 1293 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.62,0)*CFrame.Angles(math.rad(-40),math.rad(0),math.rad(-20)), 0.4) | |
| 1294 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.2,0.62,-.2)*CFrame.Angles(math.rad(90),math.rad(0),math.rad(-40)), 0.4) | |
| 1295 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-14),math.rad(50),0), 0.4) | |
| 1296 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(0, math.rad(-50), math.rad(0)), 0.4) | |
| 1297 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, -.3) * CFrame.Angles(0, 0, math.rad(-8)), 0.4) | |
| 1298 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(-30), 0, math.rad(8)), 0.4) | |
| 1299 | if Debounces.on == false then break end | |
| 1300 | rs:wait() | |
| 1301 | end | |
| 1302 | --(Part0,Part1,Times,Offset,Color,Thickness,Trans) | |
| 1303 | for i = 1, 10 do | |
| 1304 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.62,0)*CFrame.Angles(math.rad(-40),math.rad(0),math.rad(-20)), 0.4) | |
| 1305 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.2,0.62,-.2)*CFrame.Angles(math.rad(120),math.rad(0),math.rad(-10)), 0.4) | |
| 1306 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-14),math.rad(50),0), 0.4) | |
| 1307 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(0, math.rad(-70), math.rad(0)), 0.4) | |
| 1308 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, -.3) * CFrame.Angles(0, 0, math.rad(-8)), 0.4) | |
| 1309 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(-20), 0, math.rad(8)), 0.4) | |
| 1310 | if Debounces.on == false then break end | |
| 1311 | rs:wait() | |
| 1312 | end | |
| 1313 | for i,v in pairs(modes) do | |
| 1314 | if v == true and i == 'cannon' then | |
| 1315 | print(i) | |
| 1316 | Lightning(larm.Position, mouse.Hit.p, 1, 5, "Bright yellow", 2, 0.1, 0.03) | |
| 1317 | end | |
| 1318 | if v == true and i == 'lightning' then | |
| 1319 | print(i) | |
| 1320 | Lightning(larm.Position, mouse.Hit.p, 5, 5, "Bright yellow", 0.4, 0.1, 0.03) | |
| 1321 | MagicBlock(brickcolor, cf(mouse.Hit.p), 40, 40, 40, -1, -1, -1, 0.08, 1) | |
| 1322 | if mouse.Target.className ~= 'Terrain' then | |
| 1323 | mouse.Target:BreakJoints() | |
| 1324 | fly(mouse.Target, 100) | |
| 1325 | end | |
| 1326 | end | |
| 1327 | if v == true and i == 'beam' then | |
| 1328 | print(i) | |
| 1329 | Lightning(larm.Position, mouse.Hit.p, 1, 5, "Bright yellow", 0.5, 0.1, 0.03) | |
| 1330 | end | |
| 1331 | end | |
| 1332 | Debounces.CanAttack = true | |
| 1333 | Debounces.NoIdl = false | |
| 1334 | Debounces.on = false | |
| 1335 | end | |
| 1336 | function transform() | |
| 1337 | if not Debounces.Doe then | |
| 1338 | Debounces.CanAttack = false | |
| 1339 | Debounces.NoIdl = true | |
| 1340 | Debounces.on = true | |
| 1341 | --charge up | |
| 1342 | for i = 1, 10 do | |
| 1343 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.62,0)*CFrame.Angles(math.rad(50),math.rad(0),math.rad(-40)), 0.4) | |
| 1344 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.62,-.2)*CFrame.Angles(math.rad(70),math.rad(0),math.rad(40)), 0.4) | |
| 1345 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(0),math.rad(50),0), 0.4) | |
| 1346 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-40), math.rad(0), math.rad(0)), 0.1) | |
| 1347 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.1) | |
| 1348 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, -.3) * CFrame.Angles(math.rad(40), 0, math.rad(-4)), 0.4) | |
| 1349 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.4) | |
| 1350 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, 0) * CFrame.Angles(math.rad(40), 0, math.rad(4)), 0.4) | |
| 1351 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.4) | |
| 1352 | if Debounces.on == false then break end | |
| 1353 | rs:wait() | |
| 1354 | end | |
| 1355 | wait(0.05) | |
| 1356 | --transform | |
| 1357 | for i = 1, 10 do | |
| 1358 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.62,0)*CFrame.Angles(math.rad(-20),math.rad(0),math.rad(40)), 0.4) | |
| 1359 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.62,-.2)*CFrame.Angles(math.rad(-15),math.rad(0),math.rad(-40)), 0.4) | |
| 1360 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(0),math.rad(50),0), 0.4) | |
| 1361 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(40), math.rad(0), math.rad(0)), 0.1) | |
| 1362 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.1) | |
| 1363 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1.3, -.3) * CFrame.Angles(math.rad(-50), 0, math.rad(-4)), 0.4) | |
| 1364 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.4) | |
| 1365 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1.3, 0) * CFrame.Angles(math.rad(-50), 0, math.rad(4)), 0.4) | |
| 1366 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), 0, math.rad(0)), 0.4) | |
| 1367 | if Debounces.on == false then break end | |
| 1368 | rs:wait() | |
| 1369 | end | |
| 1370 | Debounces.CanAttack = true | |
| 1371 | Debounces.NoIdl = false | |
| 1372 | Debounces.on = false | |
| 1373 | do2(BrickColor.new("Bright yellow"))
| |
| 1374 | for i=0,#forms do | |
| 1375 | ap(i) | |
| 1376 | end | |
| 1377 | else | |
| 1378 | for i=0,#forms do | |
| 1379 | dap(i) | |
| 1380 | end | |
| 1381 | do2(BrickColor.new("Institutional white"))
| |
| 1382 | end | |
| 1383 | end | |
| 1384 | ---------------------------------------------------- | |
| 1385 | mouse.KeyDown:connect(function(key) | |
| 1386 | if key == "0" then | |
| 1387 | if myVars[4] ~= true then | |
| 1388 | myVars[4] = true | |
| 1389 | char.Humanoid.WalkSpeed = 50 | |
| 1390 | end | |
| 1391 | end | |
| 1392 | end) | |
| 1393 | mouse.KeyUp:connect(function(key) | |
| 1394 | if key == "0" then | |
| 1395 | if myVars[4] ~= true then | |
| 1396 | return | |
| 1397 | else | |
| 1398 | myVars[4] = false | |
| 1399 | char.Humanoid.WalkSpeed = 25 | |
| 1400 | end | |
| 1401 | end | |
| 1402 | end) | |
| 1403 | ||
| 1404 | mouse.KeyDown:connect(function(key) | |
| 1405 | if key == "k" then | |
| 1406 | transform() | |
| 1407 | end | |
| 1408 | end) | |
| 1409 | mouse.KeyDown:connect(function(key) | |
| 1410 | if key == "p" then | |
| 1411 | for i,v in pairs(modes) do | |
| 1412 | if v == true and i == 'cannon' then | |
| 1413 | print(i) | |
| 1414 | modes['cannon'] = false | |
| 1415 | modes['lightning'] = true | |
| 1416 | return | |
| 1417 | end | |
| 1418 | if v == true and i == 'lightning' then | |
| 1419 | print(i) | |
| 1420 | modes['lightning'] = false | |
| 1421 | modes['beam'] = true | |
| 1422 | return | |
| 1423 | end | |
| 1424 | if v == true and i == 'beam' then | |
| 1425 | print(i) | |
| 1426 | modes['beam'] = false | |
| 1427 | modes['cannon'] = true | |
| 1428 | return | |
| 1429 | end | |
| 1430 | end | |
| 1431 | end | |
| 1432 | end) | |
| 1433 | mouse.Button1Down:connect(function(key) | |
| 1434 | if Debounces.Doe then | |
| 1435 | if not myVars[5] then | |
| 1436 | myVars[5] = true | |
| 1437 | attack1(BrickColor.new("Bright yellow"))
| |
| 1438 | end | |
| 1439 | end | |
| 1440 | end) | |
| 1441 | ||
| 1442 | mouse.Button1Up:connect(function(key) | |
| 1443 | if Debounces.Doe then | |
| 1444 | if myVars[5] then | |
| 1445 | myVars[5] = false | |
| 1446 | end | |
| 1447 | end | |
| 1448 | end) | |
| 1449 | ---------------------------------------------------- | |
| 1450 | local jump = false | |
| 1451 | cf = CFrame.new | |
| 1452 | char.Humanoid.MaxHealth = math.huge | |
| 1453 | char.Humanoid.Health = math.huge | |
| 1454 | local rara = 0 | |
| 1455 | local ffing = false | |
| 1456 | game:GetService("RunService"):BindToRenderStep("anims", Enum.RenderPriority.Camera.Value+1, function()
| |
| 1457 | if myVars[5] then | |
| 1458 | --handcannon(BrickColor.new("Bright yellow"))
| |
| 1459 | end | |
| 1460 | if char.Humanoid.Jump == true then | |
| 1461 | if not jump then | |
| 1462 | jump = true | |
| 1463 | end | |
| 1464 | else | |
| 1465 | jump = false | |
| 1466 | end | |
| 1467 | char.Humanoid.FreeFalling:connect(function(f) | |
| 1468 | if f then | |
| 1469 | ffing = true | |
| 1470 | else | |
| 1471 | if ffing then | |
| 1472 | ffing = false | |
| 1473 | animpose = "Walking" | |
| 1474 | end | |
| 1475 | end | |
| 1476 | end) | |
| 1477 | sine = sine + change | |
| 1478 | if jump == true then | |
| 1479 | animpose = "Jumping" | |
| 1480 | elseif ffing == true then | |
| 1481 | animpose = "Freefalling" | |
| 1482 | elseif (torso.Velocity*Vector3.new(1, 0, 1)).magnitude < 2 then | |
| 1483 | animpose = "Idle" | |
| 1484 | elseif (torso.Velocity*Vector3.new(1, 0, 1)).magnitude < 40 then | |
| 1485 | animpose = "Walking" | |
| 1486 | elseif (torso.Velocity*Vector3.new(1, 0, 1)).magnitude > 60 then | |
| 1487 | animpose = "Running" | |
| 1488 | end | |
| 1489 | RightLeg = CFrame.new(0.5,-1,0) | |
| 1490 | LeftLeg = CFrame.new(-0.5,-1,0) | |
| 1491 | ||
| 1492 | lefth = (torso.CFrame*LeftLeg) | |
| 1493 | righth = (torso.CFrame*RightLeg) | |
| 1494 | ||
| 1495 | speed = Vector3.new(torso.Velocity.X,0,torso.Velocity.Z) | |
| 1496 | ||
| 1497 | TiltOnAxis = (torso.CFrame-torso.CFrame.p):vectorToObjectSpace(speed/100) | |
| 1498 | ||
| 1499 | local AngleThetaR = (righth-righth.p):vectorToObjectSpace(speed/100) | |
| 1500 | local AngleThetaL = (lefth-lefth.p):vectorToObjectSpace(speed/100) | |
| 1501 | if animpose ~= lastanimpose then | |
| 1502 | sine = 0 | |
| 1503 | if Debounces.NoIdl == false then | |
| 1504 | if stanceToggle == "Idle1" then | |
| 1505 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.6,0.2)*CFrame.Angles(math.rad(-12-4*math.cos(sine/22)),math.rad(-12-2*math.cos(sine/22)),math.rad(12+2*math.cos(sine/22))), 0.3) | |
| 1506 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.6,-0.2)*CFrame.Angles(math.rad(20+4*math.cos(sine/22)),math.rad(-22-2*math.cos(sine/22)),math.rad(-15-2*math.cos(sine/22))), 0.3) | |
| 1507 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(-12+2.5*math.cos(sine/22)),math.rad(0),math.rad(0)), 0.2) | |
| 1508 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-2+2*math.cos(sine/22)), math.rad(0), 0), 0.2) | |
| 1509 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, -0.06) * CFrame.Angles(math.rad(0-2*math.cos(sine/22)), math.rad(5), math.rad(-5)), 0.2) | |
| 1510 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, -0.06) * CFrame.Angles(math.rad(0-2*math.cos(sine/22)), math.rad(-5), math.rad(5)), 0.2) | |
| 1511 | elseif stanceToggle == "Idle2" then | |
| 1512 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.6,0.2)*CFrame.Angles(math.rad(-22-4*math.cos(sine/12)),math.rad(-40-2*math.cos(sine/12)),math.rad(24+2*math.cos(sine/12))), 0.3) | |
| 1513 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.2,0.6,-0.6)*CFrame.Angles(math.rad(90+4*math.cos(sine/12)),math.rad(0),math.rad(50-2*math.cos(sine/12))), 0.3) | |
| 1514 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(-6+2.5*math.cos(sine/12)),math.rad(0),math.rad(0)), 0.2) | |
| 1515 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1.5, 0) * CFrame.Angles(math.rad(-20+2*math.cos(sine/12)), math.rad(0), 0), 0.2) | |
| 1516 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -0.4, -1) * CFrame.Angles(math.rad(-7-2*math.cos(sine/12)), math.rad(7), math.rad(-5)), 0.2) | |
| 1517 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -0.8, -0.2) * CFrame.Angles(math.rad(-30-2*math.cos(sine/12)), math.rad(-9), math.rad(5)), 0.2) | |
| 1518 | end | |
| 1519 | --fat.Event:wait() | |
| 1520 | end | |
| 1521 | else | |
| 1522 | end | |
| 1523 | lastanimpose = animpose | |
| 1524 | if Debounces.NoIdl == false then | |
| 1525 | if animpose == "Idle" then | |
| 1526 | change = 0.5 | |
| 1527 | if stanceToggle == "Idle1" then | |
| 1528 | if not myVars[6] then | |
| 1529 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.6+0.05*math.cos(sine/10),0.6+0.1*math.cos(sine/10),-0.2-0.1*math.cos(sine/10))*CFrame.Angles(math.rad(8+2.5*math.cos(sine/10)),math.rad(22+7*math.cos(sine/10)),math.rad(15+2*math.cos(sine/10))), 0.8) | |
| 1530 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1531 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.6-0.05*math.cos(sine/10),0.6+0.1*math.cos(sine/10),0.2+0.1*math.cos(sine/10))*CFrame.Angles(math.rad(-8-2.5*math.cos(sine/10)),math.rad(12+5*math.cos(sine/10)),math.rad(-12-3*math.cos(sine/10))), 0.8) | |
| 1532 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1533 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-0.1+0.05*math.cos(sine/10))*CFrame.Angles(math.rad(-15+3*math.cos(sine/10)),math.rad(0),math.rad(0)), 0.5) | |
| 1534 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(20-3*math.cos(sine/10)),math.rad(0)), 0.1) | |
| 1535 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-6+3*math.cos(sine/10)), math.rad(0), 0), 0.1) | |
| 1536 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0-0.08*math.cos(sine/10), -1, 0) * CFrame.Angles(math.rad(0), math.rad(-20+3*math.cos(sine/10)), 0), 0.1) | |
| 1537 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, -0.14+0.06*math.cos(sine/10)) * CFrame.Angles(math.rad(-3-3*math.cos(sine/10)), math.rad(0), math.rad(0)), 0.1) | |
| 1538 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(-10-3*math.cos(sine/10)), math.rad(5+3*math.cos(sine/10))), 0.1) | |
| 1539 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, -0.06) * CFrame.Angles(math.rad(8-3*math.cos(sine/10)), math.rad(0), math.rad(0)), 0.1) | |
| 1540 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(10-3*math.cos(sine/10)), math.rad(-5+3*math.cos(sine/10))), 0.1) | |
| 1541 | if Debounces.Doe then | |
| 1542 | --yellow:MoveTo(torso.CFrame.p) | |
| 1543 | storso.CFrame = torso.CFrame | |
| 1544 | srarm.Weld.C0 = Lerp(srarm.Weld.C0, CFrame.new(1.6+0.05*math.cos(sine/10),0.6+0.1*math.cos(sine/10),-0.2-0.1*math.cos(sine/10))*CFrame.Angles(math.rad(8+2.5*math.cos(sine/10)),math.rad(22+7*math.cos(sine/10)),math.rad(15+2*math.cos(sine/10))), 0.8) | |
| 1545 | srarm.Weld.C1 = Lerp(srarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1546 | slarm.Weld.C0 = Lerp(slarm.Weld.C0, CFrame.new(-1.6-0.05*math.cos(sine/10),0.6+0.1*math.cos(sine/10),0.2+0.1*math.cos(sine/10))*CFrame.Angles(math.rad(-8-2.5*math.cos(sine/10)),math.rad(12+5*math.cos(sine/10)),math.rad(-12-3*math.cos(sine/10))), 0.8) | |
| 1547 | slarm.Weld.C1 = Lerp(slarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1548 | shed.Weld.C0 = Lerp(shed.Weld.C0, CFrame.new(0,1.5,-0.1+0.05*math.cos(sine/10))*CFrame.Angles(math.rad(-15+3*math.cos(sine/10)),math.rad(0),math.rad(0)), 0.5) | |
| 1549 | shed.Weld.C1 = Lerp(shed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(20-3*math.cos(sine/10)),math.rad(0)), 0.1) | |
| 1550 | storso.Weld.C0 = Lerp(storso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-6+3*math.cos(sine/10)), math.rad(0), 0), 0.1) | |
| 1551 | storso.Weld.C1 = Lerp(storso.Weld.C1, CFrame.new(0-0.08*math.cos(sine/10), -1, 0) * CFrame.Angles(math.rad(0), math.rad(-20+3*math.cos(sine/10)), 0), 0.1) | |
| 1552 | slleg.Weld.C0 = Lerp(slleg.Weld.C0, CFrame.new(-0.5, -1, -0.14+0.06*math.cos(sine/10)) * CFrame.Angles(math.rad(-3-3*math.cos(sine/10)), math.rad(0), math.rad(0)), 0.1) | |
| 1553 | slleg.Weld.C1 = Lerp(slleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(-10-3*math.cos(sine/10)), math.rad(5+3*math.cos(sine/10))), 0.1) | |
| 1554 | srleg.Weld.C0 = Lerp(srleg.Weld.C0, CFrame.new(0.5, -1, -0.06) * CFrame.Angles(math.rad(8-3*math.cos(sine/10)), math.rad(0), math.rad(0)), 0.1) | |
| 1555 | srleg.Weld.C1 = Lerp(srleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(10-3*math.cos(sine/10)), math.rad(-5+3*math.cos(sine/10))), 0.1) | |
| 1556 | end | |
| 1557 | else --if giant | |
| 1558 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.6+0.05*math.cos(sine/10),0.6+0.1*math.cos(sine/10),-0.2-0.1*math.cos(sine/10))*CFrame.Angles(math.rad(12+2.5*math.cos(sine/10)),math.rad(22+7*math.cos(sine/10)),math.rad(15+2*math.cos(sine/10))), 0.8) | |
| 1559 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(-.6, 0.5, -.2)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1560 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.6-0.05*math.cos(sine/10),0.6+0.1*math.cos(sine/10),0.2+0.1*math.cos(sine/10))*CFrame.Angles(math.rad(-12-2.5*math.cos(sine/10)),math.rad(12+5*math.cos(sine/10)),math.rad(-12-3*math.cos(sine/10))), 0.8) | |
| 1561 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(.6, 0.5, .2)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1562 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,2.3,-0.1+0.05*math.cos(sine/10))*CFrame.Angles(math.rad(-15+3*math.cos(sine/10)),math.rad(0),math.rad(0)), 0.5) | |
| 1563 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(20-3*math.cos(sine/10)),math.rad(0)), 0.1) | |
| 1564 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1.4, 0) * CFrame.Angles(math.rad(-6+3*math.cos(sine/10)), math.rad(0), 0), 0.1) | |
| 1565 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0-0.08*math.cos(sine/10), -1.5, 0) * CFrame.Angles(math.rad(0), math.rad(-20+3*math.cos(sine/10)), 0), 0.1) | |
| 1566 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.7, -2.2, -0.14+0.06*math.cos(sine/10)) * CFrame.Angles(math.rad(-3-3*math.cos(sine/10)), math.rad(0), math.rad(0)), 0.1) | |
| 1567 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(-10-3*math.cos(sine/10)), math.rad(5+3*math.cos(sine/10))), 0.1) | |
| 1568 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.7, -2.2, -0.06) * CFrame.Angles(math.rad(8-3*math.cos(sine/10)), math.rad(0), math.rad(0)), 0.1) | |
| 1569 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(10-3*math.cos(sine/10)), math.rad(-5+3*math.cos(sine/10))), 0.1) | |
| 1570 | end | |
| 1571 | elseif stanceToggle == "Idle2" then | |
| 1572 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.65-0.1*math.cos(sine/3),0)*CFrame.Angles(math.rad(10),math.rad(0),math.rad(20-2*math.cos(sine/3))), 0.1) | |
| 1573 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0,0.5,0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.2) | |
| 1574 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.23, 0.5, -.56) * CFrame.Angles(math.rad(88+4*math.cos(sine/3)), 0, math.rad(45)), 0.6) | |
| 1575 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0,0.5,0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.2) | |
| 1576 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -2-0.05*math.cos(sine/3), 0) * CFrame.Angles(math.rad(-10+2*math.cos(sine/6)), 0, 0), 0.8) | |
| 1577 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.1) | |
| 1578 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, -.2) * CFrame.Angles(math.rad(-10), 0, 0), 0.3) | |
| 1579 | --hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0, 1.5, -.2) * CFrame.Angles(math.rad(-5-10*math.cos(sine/18)), math.sin(sine/36)/3, 0), 0.3) | |
| 1580 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1581 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, 0, -1.15) * CFrame.Angles(math.rad(-9-2*math.cos(sine/6)), 0, 0), 0.8) | |
| 1582 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1-0.1*math.cos(sine/3), 0+0.04*math.cos(sine/6)) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(5)), 0.8) | |
| 1583 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, -.1) * CFrame.Angles(math.rad(-56-2*math.cos(sine/6)), 0, 0), 0.8) | |
| 1584 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1-0.05*math.cos(sine/3), 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(-5)), 0.8) | |
| 1585 | elseif stanceToggle == "Grabbed" then | |
| 1586 | grab = true | |
| 1587 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.65-0.1*math.cos(sine/3),0)*CFrame.Angles(math.rad(175),math.rad(0),math.rad(15-2*math.cos(sine/3))), 0.1) | |
| 1588 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.23, 0.5, 0) * CFrame.Angles(math.rad(175), 0, math.rad(-15+2*math.cos(sine/3))), 0.1) | |
| 1589 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0,-1, 0) * CFrame.Angles(math.rad(-10+2*math.cos(sine/6)), 0, 0), 0.8) | |
| 1590 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.1) | |
| 1591 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-0.1+0.05*math.cos(sine/10))*CFrame.Angles(math.rad(-15+3*math.cos(sine/10)),math.rad(0),math.rad(0)), 0.5) | |
| 1592 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(20-3*math.cos(sine/10)),math.rad(0)), 0.1) | |
| 1593 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-6+3*math.cos(sine/10)), math.rad(0), 0), 0.1) | |
| 1594 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0-0.08*math.cos(sine/10), -1, 0) * CFrame.Angles(math.rad(0), math.rad(-20+3*math.cos(sine/10)), 0), 0.1) | |
| 1595 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1, -0.14+0.06*math.cos(sine/10)) * CFrame.Angles(math.rad(-3-3*math.cos(sine/10)), math.rad(0), math.rad(0)), 0.1) | |
| 1596 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(-10-3*math.cos(sine/10)), math.rad(5+3*math.cos(sine/10))), 0.1) | |
| 1597 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1, -0.06) * CFrame.Angles(math.rad(8-3*math.cos(sine/10)), math.rad(0), math.rad(0)), 0.1) | |
| 1598 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(10-3*math.cos(sine/10)), math.rad(-5+3*math.cos(sine/10))), 0.1) | |
| 1599 | end | |
| 1600 | elseif animpose == "Walking" then | |
| 1601 | if stanceToggle == "Grabbed" then | |
| 1602 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.5-.05*math.cos(sine/2), math.sin(sine/4)/4) * CFrame.Angles(-math.sin(sine/4)/2.8, -math.sin(sine/4)/3, (math.rad(10+7*math.cos(sine/2))+root.RotVelocity.Y/30)), 0.4) | |
| 1603 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.7) | |
| 1604 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.65,0)*CFrame.Angles(math.rad(120+4*math.cos(sine/2)),math.rad(0),math.rad(-30+4*math.cos(sine/4))), 0.3) | |
| 1605 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0,0.5, 0)*CFrame.Angles(math.rad(0), math.rad(0),math.rad(0)), 0.2) | |
| 1606 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-0.1+0.1*math.cos(sine/2))*CFrame.Angles(math.rad(-10+4*math.cos(sine/2)), math.rad(0-8*math.cos(sine/4)/2.3), math.rad(0)),0.4) | |
| 1607 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(0)-root.RotVelocity.Y/10,math.rad(0)), 0.7) | |
| 1608 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1+0.12*math.cos(sine/2), 0) * CFrame.Angles(math.rad(-4+2*math.cos(sine/2)), math.rad(0+10*math.cos(sine/4)/2.3)+root.RotVelocity.Y/30, math.rad(0)+root.RotVelocity.Y/30), 0.4) | |
| 1609 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.8) | |
| 1610 | lleg.Weld.C0 = lleg.Weld.C0:lerp(CFrame.new(-0.5,-1-math.cos(sine/4)*.3,0+math.sin(sine/4)*.1)*CFrame.Angles(math.sin(sine/4)*3*AngleThetaL.Z,AngleThetaL.X,(math.sin(sine/4)*3*-AngleThetaL.X)-root.RotVelocity.Y/20),0.8) | |
| 1611 | lleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.8) | |
| 1612 | rleg.Weld.C0 = rleg.Weld.C0:lerp(CFrame.new(0.5,-1+math.cos(sine/4)*.3,0-math.sin(sine/4)*.1)*CFrame.Angles(math.sin(sine/4)*3*-AngleThetaR.Z,AngleThetaR.X,(math.sin(sine/4)*3*AngleThetaR.X)-root.RotVelocity.Y/20),0.8) | |
| 1613 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.8) | |
| 1614 | ||
| 1615 | elseif stanceToggle ~= "Grabbed" then | |
| 1616 | if myVars[4] then --if running | |
| 1617 | if Debounces.Doe then | |
| 1618 | --yellow:MoveTo(torso.CFrame.p) | |
| 1619 | storso.CFrame = torso.CFrame | |
| 1620 | srarm.Weld.C0 = Lerp(srarm.Weld.C0, CFrame.new(1.24+.6*math.cos(sine/4)/1.4, 0.54, 0+0.8*math.cos(sine/4)) * CFrame.Angles(math.rad(6-140*math.cos(sine/4)/1.2), math.rad(0), math.rad(-20+70*math.cos(sine/4))), 0.2) | |
| 1621 | srarm.Weld.C1 = Lerp(srarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.36) | |
| 1622 | slarm.Weld.C0 = Lerp(slarm.Weld.C0, CFrame.new(-1.24+.6*math.cos(sine/4)/1.4, 0.54, 0-0.8*math.cos(sine/4))*CFrame.Angles(math.rad(6+140*math.cos(sine/4)/1.2), math.rad(0), math.rad(20+70*math.cos(sine/4))), 0.2) | |
| 1623 | slarm.Weld.C1 = Lerp(slarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1624 | shed.Weld.C0 = Lerp(shed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-8+12*math.cos(sine/2)/1.5), math.rad(0+12*math.cos(sine/4)), math.rad(0)),0.2) | |
| 1625 | shed.Weld.C1 = Lerp(shed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(0)-root.RotVelocity.Y/10,math.rad(0)), 0.5) | |
| 1626 | storso.Weld.C0 = Lerp(storso.Weld.C0, CFrame.new(0, -1+0.2*math.cos(sine/2)/1.7, 0) * CFrame.Angles(math.rad(-14+10*math.cos(sine/2)/1.5), math.rad(0-12*math.cos(sine/4))-root.RotVelocity.Y/10, math.rad(0)+root.RotVelocity.Y/20), 0.2) | |
| 1627 | storso.Weld.C1 = Lerp(storso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.4) | |
| 1628 | slleg.Weld.C0 = Lerp(slleg.Weld.C0, CFrame.new(-0.5, -.8-0.4*math.cos(sine/4)/2, math.sin(sine/4)/2) * CFrame.Angles(math.rad(-10) + -math.sin(sine/4)/1.2, math.rad(0+12*math.cos(sine/4))+root.RotVelocity.Y/10, 0), .8) | |
| 1629 | slleg.Weld.C1 = Lerp(slleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
| 1630 | srleg.Weld.C0 = Lerp(srleg.Weld.C0, CFrame.new(0.5, -.8+0.4*math.cos(sine/4)/2, -math.sin(sine/4)/2) * CFrame.Angles(math.rad(-10) + math.sin(sine/4)/1.2, math.rad(0+12*math.cos(sine/4))+root.RotVelocity.Y/10, 0), .8) | |
| 1631 | srleg.Weld.C1 = Lerp(srleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
| 1632 | end | |
| 1633 | change = 1 | |
| 1634 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.24+.6*math.cos(sine/4)/1.4, 0.54, 0+0.8*math.cos(sine/4)) * CFrame.Angles(math.rad(6-140*math.cos(sine/4)/1.2), math.rad(0), math.rad(-20+70*math.cos(sine/4))), 0.2) | |
| 1635 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.36) | |
| 1636 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.24+.6*math.cos(sine/4)/1.4, 0.54, 0-0.8*math.cos(sine/4))*CFrame.Angles(math.rad(6+140*math.cos(sine/4)/1.2), math.rad(0), math.rad(20+70*math.cos(sine/4))), 0.2) | |
| 1637 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1638 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-8+12*math.cos(sine/2)/1.5), math.rad(0+12*math.cos(sine/4)), math.rad(0)),0.2) | |
| 1639 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(0)-root.RotVelocity.Y/10,math.rad(0)), 0.5) | |
| 1640 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1+0.2*math.cos(sine/2)/1.7, 0) * CFrame.Angles(math.rad(-14+10*math.cos(sine/2)/1.5), math.rad(0-12*math.cos(sine/4))-root.RotVelocity.Y/10, math.rad(0)+root.RotVelocity.Y/20), 0.2) | |
| 1641 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.4) | |
| 1642 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -.8-0.4*math.cos(sine/4)/2, math.sin(sine/4)/2) * CFrame.Angles(math.rad(-10) + -math.sin(sine/4)/1.2, math.rad(0+12*math.cos(sine/4))+root.RotVelocity.Y/10, 0), .8) | |
| 1643 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
| 1644 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -.8+0.4*math.cos(sine/4)/2, -math.sin(sine/4)/2) * CFrame.Angles(math.rad(-10) + math.sin(sine/4)/1.2, math.rad(0+12*math.cos(sine/4))+root.RotVelocity.Y/10, 0), .8) | |
| 1645 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
| 1646 | ||
| 1647 | else --if not running | |
| 1648 | if Debounces.Doe then | |
| 1649 | --yellow:MoveTo(torso.CFrame.p) | |
| 1650 | storso.CFrame = torso.CFrame | |
| 1651 | srarm.Weld.C0 = Lerp(srarm.Weld.C0, CFrame.new(1.5, 0.5-.05*math.cos(sine/2), math.sin(sine/4)/4) * CFrame.Angles(-math.sin(sine/4)/2.8, -math.sin(sine/4)/3, (math.rad(10+7*math.cos(sine/2))+root.RotVelocity.Y/30)), 0.4) | |
| 1652 | srarm.Weld.C1 = Lerp(srarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.7) | |
| 1653 | slarm.Weld.C0 = Lerp(slarm.Weld.C0, CFrame.new(-1.5, 0.5+.05*math.cos(sine/2), -math.sin(sine/4)/4)*CFrame.Angles(math.sin(sine/4)/2.8, -math.sin(sine/4)/3, (math.rad(-10-7*math.cos(sine/2))+root.RotVelocity.Y/30)), 0.4) | |
| 1654 | slarm.Weld.C1 = Lerp(slarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.7) | |
| 1655 | shed.Weld.C0 = Lerp(shed.Weld.C0, CFrame.new(0,1.5,-0.1+0.1*math.cos(sine/2))*CFrame.Angles(math.rad(-10+4*math.cos(sine/2)), math.rad(0-8*math.cos(sine/4)/2.3), math.rad(0)),0.4) | |
| 1656 | shed.Weld.C1 = Lerp(shed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(0)-root.RotVelocity.Y/10,math.rad(0)), 0.7) | |
| 1657 | storso.Weld.C0 = Lerp(storso.Weld.C0, CFrame.new(0, -1+0.12*math.cos(sine/2), 0) * CFrame.Angles(math.rad(-4+2*math.cos(sine/2)), math.rad(0+10*math.cos(sine/4)/2.3)+root.RotVelocity.Y/30, math.rad(0)+root.RotVelocity.Y/30), 0.4) | |
| 1658 | storso.Weld.C1 = Lerp(storso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.8) | |
| 1659 | slleg.Weld.C0 = slleg.Weld.C0:lerp(CFrame.new(-0.5,-1-math.cos(sine/4)*.3,0+math.sin(sine/4)*.1)*CFrame.Angles(math.sin(sine/4)*3*AngleThetaL.Z,AngleThetaL.X,(math.sin(sine/4)*3*-AngleThetaL.X)-root.RotVelocity.Y/20),0.8) | |
| 1660 | slleg.Weld.C1 = Lerp(srleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.8) | |
| 1661 | srleg.Weld.C0 = srleg.Weld.C0:lerp(CFrame.new(0.5,-1+math.cos(sine/4)*.3,0-math.sin(sine/4)*.1)*CFrame.Angles(math.sin(sine/4)*3*-AngleThetaR.Z,AngleThetaR.X,(math.sin(sine/4)*3*AngleThetaR.X)-root.RotVelocity.Y/20),0.8) | |
| 1662 | srleg.Weld.C1 = Lerp(srleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.8) | |
| 1663 | end | |
| 1664 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.5-.05*math.cos(sine/2), math.sin(sine/4)/4) * CFrame.Angles(-math.sin(sine/4)/2.8, -math.sin(sine/4)/3, (math.rad(10+7*math.cos(sine/2))+root.RotVelocity.Y/30)), 0.4) | |
| 1665 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.7) | |
| 1666 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.5+.05*math.cos(sine/2), -math.sin(sine/4)/4)*CFrame.Angles(math.sin(sine/4)/2.8, -math.sin(sine/4)/3, (math.rad(-10-7*math.cos(sine/2))+root.RotVelocity.Y/30)), 0.4) | |
| 1667 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.7) | |
| 1668 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-0.1+0.1*math.cos(sine/2))*CFrame.Angles(math.rad(-10+4*math.cos(sine/2)), math.rad(0-8*math.cos(sine/4)/2.3), math.rad(0)),0.4) | |
| 1669 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(0)-root.RotVelocity.Y/10,math.rad(0)), 0.7) | |
| 1670 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1+0.12*math.cos(sine/2), 0) * CFrame.Angles(math.rad(-4+2*math.cos(sine/2)), math.rad(0+10*math.cos(sine/4)/2.3)+root.RotVelocity.Y/30, math.rad(0)+root.RotVelocity.Y/30), 0.4) | |
| 1671 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.8) | |
| 1672 | lleg.Weld.C0 = lleg.Weld.C0:lerp(CFrame.new(-0.5,-1-math.cos(sine/4)*.3,0+math.sin(sine/4)*.1)*CFrame.Angles(math.sin(sine/4)*3*AngleThetaL.Z,AngleThetaL.X,(math.sin(sine/4)*3*-AngleThetaL.X)-root.RotVelocity.Y/20),0.8) | |
| 1673 | lleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.8) | |
| 1674 | rleg.Weld.C0 = rleg.Weld.C0:lerp(CFrame.new(0.5,-1+math.cos(sine/4)*.3,0-math.sin(sine/4)*.1)*CFrame.Angles(math.sin(sine/4)*3*-AngleThetaR.Z,AngleThetaR.X,(math.sin(sine/4)*3*AngleThetaR.X)-root.RotVelocity.Y/20),0.8) | |
| 1675 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.8) | |
| 1676 | end | |
| 1677 | end | |
| 1678 | elseif animpose == "Running" then | |
| 1679 | change = 1 | |
| 1680 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.24+.6*math.cos(sine/4)/1.4, 0.54, 0+0.8*math.cos(sine/4)) * CFrame.Angles(math.rad(6-140*math.cos(sine/4)/1.2), math.rad(0), math.rad(-20+70*math.cos(sine/4))), 0.2) | |
| 1681 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.36) | |
| 1682 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.24+.6*math.cos(sine/4)/1.4, 0.54, 0-0.8*math.cos(sine/4))*CFrame.Angles(math.rad(6+140*math.cos(sine/4)/1.2), math.rad(0), math.rad(20+70*math.cos(sine/4))), 0.2) | |
| 1683 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1684 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-8+12*math.cos(sine/2)/1.5), math.rad(0+12*math.cos(sine/4)), math.rad(0)),0.2) | |
| 1685 | hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.new(0,0,0)*CFrame.Angles(math.rad(0),math.rad(0)-root.RotVelocity.Y/10,math.rad(0)), 0.5) | |
| 1686 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1+0.2*math.cos(sine/2)/1.7, 0) * CFrame.Angles(math.rad(-14+10*math.cos(sine/2)/1.5), math.rad(0-12*math.cos(sine/4))-root.RotVelocity.Y/10, math.rad(0)+root.RotVelocity.Y/20), 0.2) | |
| 1687 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.4) | |
| 1688 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -.8-0.4*math.cos(sine/4)/2, math.sin(sine/4)/2) * CFrame.Angles(math.rad(-10) + -math.sin(sine/4)/1.2, math.rad(0+12*math.cos(sine/4))+root.RotVelocity.Y/10, 0), .8) | |
| 1689 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
| 1690 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -.8+0.4*math.cos(sine/4)/2, -math.sin(sine/4)/2) * CFrame.Angles(math.rad(-10) + math.sin(sine/4)/1.2, math.rad(0+12*math.cos(sine/4))+root.RotVelocity.Y/10, 0), .8) | |
| 1691 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
| 1692 | elseif animpose == "Jumping" then | |
| 1693 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5, 0.6, 0)*CFrame.Angles(math.rad(-10),math.rad(0),math.rad(20)), 0.2) | |
| 1694 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.36) | |
| 1695 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5, 0.6, 0)*CFrame.Angles(math.rad(-10),math.rad(0),math.rad(-20)), 0.2) | |
| 1696 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(0, 0.5, 0)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1697 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,0)*CFrame.Angles(math.rad(30),math.rad(0),0), 0.2) | |
| 1698 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(-10), math.rad(0), 0), 0.2) | |
| 1699 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.4) | |
| 1700 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5, -1.1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2) | |
| 1701 | lleg.Weld.C1 = Lerp(lleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
| 1702 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5, -1.1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.2) | |
| 1703 | rleg.Weld.C1 = Lerp(rleg.Weld.C1, CFrame.new(0, 1, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4) | |
| 1704 | elseif animpose == "Freefalling" then | |
| 1705 | if myVars[6] then | |
| 1706 | rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.7+0.05*math.cos(sine/10),1.3+0.1*math.cos(sine/10),-0.2-0.1*math.cos(sine/10))*CFrame.Angles(math.rad(120+2.5*math.cos(sine/10)),math.rad(22+7*math.cos(sine/10)),math.rad(30+2*math.cos(sine/10))), 0.8) | |
| 1707 | rarm.Weld.C1 = Lerp(rarm.Weld.C1, CFrame.new(-.6, 0.5, -.2)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1708 | larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.7-0.05*math.cos(sine/10),1.3+0.1*math.cos(sine/10),0.2+0.1*math.cos(sine/10))*CFrame.Angles(math.rad(120-2.5*math.cos(sine/10)),math.rad(12+5*math.cos(sine/10)),math.rad(-26-3*math.cos(sine/10))), 0.8) | |
| 1709 | larm.Weld.C1 = Lerp(larm.Weld.C1, CFrame.new(.6, 0.5, .2)*CFrame.Angles(math.rad(0),math.rad(0),math.rad(0)), 0.5) | |
| 1710 | hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,2.3,-0.1+0.05*math.cos(sine/10))*CFrame.Angles(math.rad(-30+1*math.cos(sine/10)),math.rad(0),math.rad(0)), 0.2) | |
| 1711 | torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1.4, 0) * CFrame.Angles(math.rad(-10), math.rad(0), math.rad(0)), 0.3) | |
| 1712 | torso.Weld.C1 = Lerp(torso.Weld.C1, CFrame.new(0, -1, 0) * CFrame.Angles(math.rad(0), math.rad(0), 0), 0.3) | |
| 1713 | lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-.6, -1.8, -.6) * CFrame.Angles(math.rad(60), 0, math.rad(-5)), 0.3) | |
| 1714 | rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(.6, -2.2, 0) * CFrame.Angles(math.rad(10), 0, math.rad(5)), 0.3) | |
| 1715 | end | |
| 1716 | end | |
| 1717 | if #Effects>0 then | |
| 1718 | --table.insert(Effects,{prt,"Block1",delay})
| |
| 1719 | for e=1,#Effects do | |
| 1720 | if Effects[e]~=nil then | |
| 1721 | --for j=1,#Effects[e] do | |
| 1722 | local Thing=Effects[e] | |
| 1723 | if Thing~=nil then | |
| 1724 | local Part=Thing[1] | |
| 1725 | local Mode=Thing[2] | |
| 1726 | local Delay=Thing[3] | |
| 1727 | local IncX=Thing[4] | |
| 1728 | local IncY=Thing[5] | |
| 1729 | local IncZ=Thing[6] | |
| 1730 | if Thing[1].Transparency<=1 then | |
| 1731 | ||
| 1732 | if Thing[2] == "Block1" then | |
| 1733 | Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
| 1734 | Mesh = Thing[1].Mesh | |
| 1735 | print('RAN!')
| |
| 1736 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 1737 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1738 | elseif Thing[2] == "Block2" then | |
| 1739 | Thing[1].CFrame = Thing[1].CFrame | |
| 1740 | Mesh = Thing[7] | |
| 1741 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 1742 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1743 | elseif Thing[2] == "SatelliteStrike2" then | |
| 1744 | if Thing[5] < 100 then | |
| 1745 | Thing[5] = Thing[5] + 2 | |
| 1746 | Thing[6] = Thing[6] + 1 | |
| 1747 | if 2 < Thing[6] then | |
| 1748 | Thing[6] = 0 | |
| 1749 | if Thing[3].BrickColor == BrickColor.new("New Yeller") then
| |
| 1750 | Thing[3].Transparency = 0.8 | |
| 1751 | Thing[3].BrickColor = BrickColor.new("Really red")
| |
| 1752 | else | |
| 1753 | Thing[3].Transparency = 0.8 | |
| 1754 | Thing[3].BrickColor = BrickColor.new("New Yeller")
| |
| 1755 | end | |
| 1756 | end | |
| 1757 | else | |
| 1758 | refda = part(3, effects, 0, 1, BrickColor.new("Black"), "Reference", vt())
| |
| 1759 | refda.Anchored = true | |
| 1760 | refda.CFrame = cf(Thing[1].Position) * cf(0, 500, 0) | |
| 1761 | game:GetService("Debris"):AddItem(refda, 1)
| |
| 1762 | local mag = (refda.Position - Thing[1].Position).magnitude | |
| 1763 | MagicCylinder(BrickColor.new("White"), CFrame.new((refda.Position + Thing[1].Position) / 2, Thing[1].Position) * angles(1.57, 0, 0), 60, mag * 5, 60, 0, 0, 0, 0.1)
| |
| 1764 | Lightning(refda.Position, Thing[1].Position, 25, 5, "Bright yellow", 5, 0.2, 0.03) | |
| 1765 | MagicBlock2(BrickColor.new("Bright yellow"), cf(Thing[1].Position), 80, 80, 80, -1, -1, -1, 0.06, 1)
| |
| 1766 | refda.CFrame = cf(Thing[1].Position) | |
| 1767 | --MagniDamage(refda, 10, 14, 16, 0, "Knockdown2", refda, 0.1, 1, (math.random(14, 18)), nil, nil, true) | |
| 1768 | refda.CFrame = cf(Thing[1].Position) * cf(0, 3, 0) | |
| 1769 | --MagniDamage(refda, 10, 14, 16, 0, "Knockdown2", refda, 0.1, 1, (math.random(14, 18)), nil, nil, true) | |
| 1770 | refda.CFrame = cf(Thing[1].Position) | |
| 1771 | so("341336446", refda, 1, math.random(70, 90) / 100)
| |
| 1772 | so("341336459", refda, 1, math.random(50, 80) / 100)
| |
| 1773 | Thing[1].Parent = nil | |
| 1774 | table.remove(Effects, e) | |
| 1775 | end | |
| 1776 | elseif Thing[2]=="Block1" then | |
| 1777 | Thing[1].CFrame=Thing[1].CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 1778 | Mesh=Thing[1]:FindFirstChild("Mesh")
| |
| 1779 | if not Mesh then | |
| 1780 | Mesh = Instance.new("BlockMesh")
| |
| 1781 | end | |
| 1782 | Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6]) | |
| 1783 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 1784 | elseif Thing[2]=="Block2" then | |
| 1785 | Thing[1].CFrame = Thing[1].CFrame | |
| 1786 | Mesh = Thing[7] | |
| 1787 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 1788 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1789 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 1790 | elseif Thing[2]=="Cylinder" then | |
| 1791 | Mesh=Thing[1]:FindFirstChild("Mesh")
| |
| 1792 | if not Mesh then | |
| 1793 | Mesh = Instance.new("BlockMesh")
| |
| 1794 | end | |
| 1795 | Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6]) | |
| 1796 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 1797 | elseif Thing[2] == "Cylinder1" then | |
| 1798 | Mesh = Thing[7] | |
| 1799 | Mesh.Scale = Mesh.Scale + vt(Thing[4], Thing[5], Thing[6]) | |
| 1800 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1801 | elseif Thing[2]=="Blood" then | |
| 1802 | Mesh=Thing[1]:FindFirstChild("Mesh")
| |
| 1803 | if not Mesh then | |
| 1804 | Mesh = Instance.new("BlockMesh")
| |
| 1805 | end | |
| 1806 | Thing[1].CFrame=Thing[1].CFrame*cf(0,.5,0) | |
| 1807 | Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6]) | |
| 1808 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 1809 | elseif Thing[2]=="Elec" then | |
| 1810 | Mesh=Thing[1]:FindFirstChild("Mesh")
| |
| 1811 | if not Mesh then | |
| 1812 | Mesh = Instance.new("BlockMesh")
| |
| 1813 | end | |
| 1814 | Mesh.Scale=Mesh.Scale+vt(Thing[7],Thing[8],Thing[9]) | |
| 1815 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 1816 | elseif Thing[2]=="Disappear" then | |
| 1817 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 1818 | end | |
| 1819 | else | |
| 1820 | Part.Parent=nil | |
| 1821 | game:GetService("Debris"):AddItem(Part, 0)
| |
| 1822 | table.remove(Effects,e) | |
| 1823 | end | |
| 1824 | end | |
| 1825 | end | |
| 1826 | end | |
| 1827 | end | |
| 1828 | end | |
| 1829 | end) | |
| 1830 | char:FindFirstChild("Humanoid").Died:connect(function()
| |
| 1831 | game:GetService("RunService"):UnbindFromRenderStep("anims")
| |
| 1832 | print("John Doe died!!!")
| |
| 1833 | end) |