SHOW:
|
|
- or go back to the newest paste.
| 1 | if game:GetService("RunService"):IsClient()then error("Please run as a server script. Use h/ instead of hl/.")end;print("FE Compatibility: by WaverlyCole");InternalData = {}
| |
| 2 | do | |
| 3 | script.Parent = owner.Character | |
| 4 | local Event = Instance.new("RemoteEvent");Event.Name = "UserInput"
| |
| 5 | local function NewFakeEvent() | |
| 6 | local Bind = Instance.new("BindableEvent")
| |
| 7 | local Fake;Fake = {Connections = {},
| |
| 8 | fakeEvent=true; | |
| 9 | Connect=function(self,Func) | |
| 10 | Bind.Event:connect(Func) | |
| 11 | self.Connections[Bind] = true | |
| 12 | return setmetatable({Connected = true},{
| |
| 13 | __index = function (self,Index) | |
| 14 | if Index:lower() == "disconnect" then | |
| 15 | return function() Fake.Connections[Bind] = false;self.Connected = false end | |
| 16 | end | |
| 17 | return Fake[Index] | |
| 18 | end; | |
| 19 | __tostring = function() return "Connection" end; | |
| 20 | }) | |
| 21 | end} | |
| 22 | Fake.connect = Fake.Connect;return Fake; | |
| 23 | end | |
| 24 | local Mouse = {Target=nil,Hit=CFrame.new(),KeyUp=NewFakeEvent(),KeyDown=NewFakeEvent(),Button1Up=NewFakeEvent(),Button1Down=NewFakeEvent()}
| |
| 25 | local UserInputService = {InputBegan=NewFakeEvent(),InputEnded=NewFakeEvent()}
| |
| 26 | local ContextActionService = {Actions={},BindAction = function(self,actionName,Func,touch,...)
| |
| 27 | self.Actions[actionName] = Func and {Name=actionName,Function=Func,Keys={...}} or nil
| |
| 28 | end};ContextActionService.UnBindAction = ContextActionService.BindAction | |
| 29 | local function TriggerEvent(self,Event,...) | |
| 30 | local Trigger = Mouse[Event] | |
| 31 | if Trigger and Trigger.fakeEvent and Trigger.Connections then | |
| 32 | for Connection,Active in pairs(Trigger.Connections) do if Active then Connection:Fire(...) end end | |
| 33 | end | |
| 34 | end | |
| 35 | Mouse.TrigEvent = TriggerEvent;UserInputService.TrigEvent = TriggerEvent | |
| 36 | Event.OnServerEvent:Connect(function(FiredBy,Input) | |
| 37 | if FiredBy.Name ~= owner.Name then return end | |
| 38 | if Input.MouseEvent then | |
| 39 | Mouse.Target = Input.Target;Mouse.Hit = Input.Hit | |
| 40 | else | |
| 41 | local Begin = Input.UserInputState == Enum.UserInputState.Begin | |
| 42 | if Input.UserInputType == Enum.UserInputType.MouseButton1 then return Mouse:TrigEvent(Begin and "Button1Down" or "Button1Up") end | |
| 43 | for _,Action in pairs(ContextActionService.Actions) do | |
| 44 | for _,Key in pairs(Action.Keys) do if Key==Input.KeyCode then Action.Function(Action.Name,Input.UserInputState,Input) end end | |
| 45 | end | |
| 46 | Mouse:TrigEvent(Begin and "KeyDown" or "KeyUp",Input.KeyCode.Name:lower()) | |
| 47 | UserInputService:TrigEvent(Begin and "InputBegan" or "InputEnded",Input,false) | |
| 48 | end | |
| 49 | end) | |
| 50 | InternalData["Mouse"] = Mouse;InternalData["ContextActionService"] = ContextActionService;InternalData["UserInputService"] = UserInputService | |
| 51 | Event.Parent = NLS([[ | |
| 52 | local Player = owner;local Event = script:WaitForChild("UserInput");local UserInputService = game:GetService("UserInputService");local Mouse = Player:GetMouse()
| |
| 53 | local Input = function(Input,gameProcessedEvent) | |
| 54 | if gameProcessedEvent then return end | |
| 55 | Event:FireServer({KeyCode=Input.KeyCode,UserInputType=Input.UserInputType,UserInputState=Input.UserInputState})
| |
| 56 | end | |
| 57 | UserInputService.InputBegan:Connect(Input);UserInputService.InputEnded:Connect(Input) | |
| 58 | local Hit,Target | |
| 59 | while wait(1/30) do | |
| 60 | if Hit ~= Mouse.Hit or Target ~= Mouse.Target then | |
| 61 | Hit,Target = Mouse.Hit,Mouse.Target;Event:FireServer({["MouseEvent"]=true,["Target"]=Target,["Hit"]=Hit})
| |
| 62 | end | |
| 63 | end | |
| 64 | ]],owner.Character) | |
| 65 | end | |
| 66 | RealGame = game;game = setmetatable({},{
| |
| 67 | __index = function (self,Index) | |
| 68 | local Sandbox = function (Thing) | |
| 69 | if Thing:IsA("Player") then
| |
| 70 | local RealPlayer = Thing | |
| 71 | return setmetatable({},{
| |
| 72 | __index = function (self,Index) | |
| 73 | local Type = type(RealPlayer[Index]) | |
| 74 | if Type == "function" then | |
| 75 | if Index:lower() == "getmouse" or Index:lower() == "mouse" then | |
| 76 | return function (self)return InternalData["Mouse"] end | |
| 77 | end | |
| 78 | return function (self,...)return RealPlayer[Index](RealPlayer,...) end | |
| 79 | end | |
| 80 | return RealPlayer[Index] | |
| 81 | end; | |
| 82 | __tostring = function(self) return RealPlayer.Name end | |
| 83 | }) | |
| 84 | end | |
| 85 | end | |
| 86 | if RealGame[Index] then | |
| 87 | local Type = type(RealGame[Index]) | |
| 88 | if Type == "function" then | |
| 89 | if Index:lower() == "getservice" or Index:lower() == "service" then | |
| 90 | return function (self,Service) | |
| 91 | local FakeServices = {
| |
| 92 | ["players"] = function() | |
| 93 | return setmetatable({},{
| |
| 94 | __index = function (self2,Index2) | |
| 95 | local RealService = RealGame:GetService(Service) | |
| 96 | local Type2 = type(Index2) | |
| 97 | if Type2 == "function" then | |
| 98 | return function (self,...) return RealService[Index2](RealService,...)end | |
| 99 | else | |
| 100 | if Index2:lower() == "localplayer" then return Sandbox(owner) end | |
| 101 | return RealService[Index2] | |
| 102 | end | |
| 103 | end; | |
| 104 | __tostring = function(self) return RealGame:GetService(Service).Name end | |
| 105 | }) | |
| 106 | end; | |
| 107 | ["contextactionservice"] = function() return InternalData["ContextActionService"] end; | |
| 108 | ["userinputservice"] = function() return InternalData["UserInputService"] end; | |
| 109 | ["runservice"] = function() | |
| 110 | return setmetatable({},{
| |
| 111 | __index = function(self2,Index2) | |
| 112 | local RealService = RealGame:GetService(Service) | |
| 113 | local Type2 = type(Index2) | |
| 114 | if Type2 == "function" then | |
| 115 | return function (self,...) return RealService[Index2](RealService,...) end | |
| 116 | else | |
| 117 | local RunServices = {
| |
| 118 | ["bindtorenderstep"] = function() return function (self,Name,Priority,Function) return RealGame:GetService("RunService").Stepped:Connect(Function) end end;
| |
| 119 | ["renderstepped"] = function() return RealService["Stepped"] end | |
| 120 | } | |
| 121 | if RunServices[Index2:lower()] then return RunServices[Index2:lower()]() end | |
| 122 | return RealService[Index2] | |
| 123 | end | |
| 124 | end | |
| 125 | }) | |
| 126 | end | |
| 127 | } | |
| 128 | if FakeServices[Service:lower()] then return FakeServices[Service:lower()]() end | |
| 129 | return RealGame:GetService(Service) | |
| 130 | end | |
| 131 | end | |
| 132 | return function (self,...) return RealGame[Index](RealGame,...) end | |
| 133 | else | |
| 134 | if game:GetService(Index) then return game:GetService(Index) end | |
| 135 | return RealGame[Index] | |
| 136 | end | |
| 137 | end | |
| 138 | return nil | |
| 139 | end | |
| 140 | });Game = game;owner = game:GetService("Players").LocalPlayer;script = Instance.new("Script");print("Complete! Running...")
| |
| 141 | ||
| 142 | repeat wait() until game:service'Players'.LocalPlayer.Character | |
| 143 | --[[ | |
| 144 | ||
| 145 | - Added new color scheme. | |
| 146 | - Some minor edits. | |
| 147 | - New engine type, for your faster speed requirements. | |
| 148 | - Camera bug fix. | |
| 149 | ]]-- | |
| 150 | do --CFrame lerp | |
| 151 | local function QuaternionFromCFrame(cf) | |
| 152 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
| 153 | local trace = m00 + m11 + m22 | |
| 154 | if trace > 0 then | |
| 155 | local s = math.sqrt(1 + trace) | |
| 156 | local recip = 0.5/s | |
| 157 | return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5 | |
| 158 | else | |
| 159 | local i = 0 | |
| 160 | if m11 > m00 then | |
| 161 | i = 1 | |
| 162 | end | |
| 163 | if m22 > (i == 0 and m00 or m11) then | |
| 164 | i = 2 | |
| 165 | end | |
| 166 | if i == 0 then | |
| 167 | local s = math.sqrt(m00-m11-m22+1) | |
| 168 | local recip = 0.5/s | |
| 169 | return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip | |
| 170 | elseif i == 1 then | |
| 171 | local s = math.sqrt(m11-m22-m00+1) | |
| 172 | local recip = 0.5/s | |
| 173 | return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip | |
| 174 | elseif i == 2 then | |
| 175 | local s = math.sqrt(m22-m00-m11+1) | |
| 176 | local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip | |
| 177 | end | |
| 178 | end | |
| 179 | end | |
| 180 | local function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
| 181 | local xs, ys, zs = x + x, y + y, z + z | |
| 182 | local wx, wy, wz = w*xs, w*ys, w*zs | |
| 183 | local xx = x*xs | |
| 184 | local xy = x*ys | |
| 185 | local xz = x*zs | |
| 186 | local yy = y*ys | |
| 187 | local yz = y*zs | |
| 188 | local zz = z*zs | |
| 189 | return CFrame.new(px, py, pz,1-(yy+zz), xy - wz, xz + wy,xy + wz, 1-(xx+zz), yz - wx, xz - wy, yz + wx, 1-(xx+yy)) | |
| 190 | end | |
| 191 | local function QuaternionSlerp(a, b, t) | |
| 192 | local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4] | |
| 193 | local startInterp, finishInterp; | |
| 194 | if cosTheta >= 0.0001 then | |
| 195 | if (1 - cosTheta) > 0.0001 then | |
| 196 | local theta = math.acos(cosTheta) | |
| 197 | local invSinTheta = 1/math.sin(theta) | |
| 198 | startInterp = math.sin((1-t)*theta)*invSinTheta | |
| 199 | finishInterp = math.sin(t*theta)*invSinTheta | |
| 200 | else | |
| 201 | startInterp = 1-t | |
| 202 | finishInterp = t | |
| 203 | end | |
| 204 | else | |
| 205 | if (1+cosTheta) > 0.0001 then | |
| 206 | local theta = math.acos(-cosTheta) | |
| 207 | local invSinTheta = 1/math.sin(theta) | |
| 208 | startInterp = math.sin((t-1)*theta)*invSinTheta | |
| 209 | finishInterp = math.sin(t*theta)*invSinTheta | |
| 210 | else | |
| 211 | startInterp = t-1 | |
| 212 | finishInterp = t | |
| 213 | end | |
| 214 | end | |
| 215 | return a[1]*startInterp + b[1]*finishInterp, a[2]*startInterp + b[2]*finishInterp, a[3]*startInterp + b[3]*finishInterp, a[4]*startInterp + b[4]*finishInterp | |
| 216 | end | |
| 217 | function clerp(a,b,t) | |
| 218 | local qa = {QuaternionFromCFrame(a)}
| |
| 219 | local qb = {QuaternionFromCFrame(b)}
| |
| 220 | local ax, ay, az = a.x, a.y, a.z | |
| 221 | local bx, by, bz = b.x, b.y, b.z | |
| 222 | local _t = 1-t | |
| 223 | return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t)) | |
| 224 | end | |
| 225 | ||
| 226 | end | |
| 227 | ||
| 228 | plr = game:service'Players'.LocalPlayer | |
| 229 | char = plr.Character | |
| 230 | mouse = plr:GetMouse() | |
| 231 | humanoid = char:findFirstChild("Humanoid")
| |
| 232 | torso = char:findFirstChild("Torso")
| |
| 233 | head = char.Head | |
| 234 | ra = char:findFirstChild("Right Arm")
| |
| 235 | la = char:findFirstChild("Left Arm")
| |
| 236 | rl = char:findFirstChild("Right Leg")
| |
| 237 | ll = char:findFirstChild("Left Leg")
| |
| 238 | rs = torso:findFirstChild("Right Shoulder")
| |
| 239 | ls = torso:findFirstChild("Left Shoulder")
| |
| 240 | rh = torso:findFirstChild("Right Hip")
| |
| 241 | lh = torso:findFirstChild("Left Hip")
| |
| 242 | neck = torso:findFirstChild("Neck")
| |
| 243 | rj = char:findFirstChild("HumanoidRootPart"):findFirstChild("RootJoint")
| |
| 244 | anim = char:findFirstChild("Animate")
| |
| 245 | rootpart = char:findFirstChild("HumanoidRootPart")
| |
| 246 | camera = workspace.CurrentCamera | |
| 247 | modelforparts = char:findFirstChild("ModelForParts") or Instance.new("Model", char)
| |
| 248 | modelforparts.Name = "ModelForParts" | |
| 249 | equipped = false | |
| 250 | local MAXSPEED = 90 | |
| 251 | local SPEED = 0 | |
| 252 | bg = Instance.new("BodyGyro")
| |
| 253 | bg.maxTorque = Vector3.new(9e6,9e6,9e6) | |
| 254 | bg.D = 800 | |
| 255 | bv = Instance.new("BodyVelocity")
| |
| 256 | bv.maxForce = Vector3.new(9e6,9e6,9e6) | |
| 257 | ||
| 258 | local sound = Instance.new("Sound", head)
| |
| 259 | sound.Volume = 1 | |
| 260 | sound.Pitch = 2 | |
| 261 | sound.SoundId = "http://www.roblox.com/asset/?id=142782429" | |
| 262 | sound.Looped = true | |
| 263 | wait() | |
| 264 | sound:play() | |
| 265 | ||
| 266 | ||
| 267 | ColorScheme1 = BrickColor.new(106) | |
| 268 | ColorScheme2 = BrickColor.new(40) | |
| 269 | ColorScheme3 = BrickColor.new(199) | |
| 270 | ANGLE = 0 | |
| 271 | equipped = true | |
| 272 | ||
| 273 | rs.Parent = nil | |
| 274 | ls.Parent = nil | |
| 275 | rh.Parent = nil | |
| 276 | lh.Parent = nil | |
| 277 | anim.Parent = nil | |
| 278 | wait() | |
| 279 | local rm = Instance.new("Weld", modelforparts)
| |
| 280 | rm.C0 = CFrame.new(1.5, 0.5, 0) | |
| 281 | rm.C1 = CFrame.new(0, 0.5, 0) | |
| 282 | rm.Part0 = torso | |
| 283 | rm.Part1 = ra | |
| 284 | local lm = Instance.new("Weld", modelforparts)
| |
| 285 | lm.C0 = CFrame.new(-1.5, 0.5, 0) | |
| 286 | lm.C1 = CFrame.new(0, 0.5, 0) | |
| 287 | lm.Part0 = torso | |
| 288 | lm.Part1 = la | |
| 289 | local rlegm = Instance.new("Weld", modelforparts)
| |
| 290 | rlegm.C0 = CFrame.new(0.5, -1, 0) | |
| 291 | rlegm.C1 = CFrame.new(0, 1, 0) | |
| 292 | rlegm.Part0 = torso | |
| 293 | rlegm.Part1 = rl | |
| 294 | local llegm = Instance.new("Weld", modelforparts)
| |
| 295 | llegm.C0 = CFrame.new(-0.5, -1, 0) | |
| 296 | llegm.C1 = CFrame.new(0, 1, 0) | |
| 297 | llegm.Part0 = torso | |
| 298 | llegm.Part1 = ll | |
| 299 | ||
| 300 | --grey part | |
| 301 | local part = Instance.new("Part", modelforparts)
| |
| 302 | part.Size = Vector3.new(2.2, .85, 2.2) | |
| 303 | part.FormFactor = 'Custom' | |
| 304 | part.BrickColor = ColorScheme3 | |
| 305 | part.Locked = true | |
| 306 | part.TopSurface = 10 | |
| 307 | part.BottomSurface = 10 | |
| 308 | part.LeftSurface = 10 | |
| 309 | part.RightSurface = 10 | |
| 310 | part.FrontSurface = 10 | |
| 311 | part.BackSurface = 10 | |
| 312 | part:breakJoints() | |
| 313 | part.Material = "SmoothPlastic" | |
| 314 | part.CanCollide = false | |
| 315 | Instance.new("CylinderMesh", part)
| |
| 316 | local weld = Instance.new("Weld", part)
| |
| 317 | weld.Part0 = part | |
| 318 | weld.Part1 = torso | |
| 319 | weld.C1 = CFrame.new(0, -2.1, 0) | |
| 320 | weld.C0 = CFrame.Angles(math.pi/2, math.pi/2, 0) * CFrame.new(0, 0, .95) | |
| 321 | --orange part | |
| 322 | local part2 = part:clone() | |
| 323 | part2.Parent = modelforparts | |
| 324 | part2.Size = Vector3.new(2.5, 1.05, 2.5) | |
| 325 | part2.BrickColor = ColorScheme1 | |
| 326 | local wld2 = Instance.new("Weld", part)
| |
| 327 | wld2.Part0 = part2 | |
| 328 | wld2.Part1 = part | |
| 329 | wld2.C1 = CFrame.new() | |
| 330 | wld2.C0 = CFrame.new() | |
| 331 | --white part | |
| 332 | local part3 = part:clone() | |
| 333 | part3.Parent = modelforparts | |
| 334 | part3.Size = Vector3.new(2.62, .5, 2.62) | |
| 335 | part3.BrickColor = ColorScheme2 | |
| 336 | local wld3 = Instance.new("Weld", part)
| |
| 337 | wld3.Part0 = part3 | |
| 338 | wld3.Part1 = part | |
| 339 | wld3.C1 = CFrame.new() | |
| 340 | wld3.C0 = CFrame.new() | |
| 341 | --airblower | |
| 342 | local airblowercyl = part:clone() | |
| 343 | airblowercyl.Parent = modelforparts | |
| 344 | airblowercyl.Size = Vector3.new(.95, 3.5, .95) | |
| 345 | airblowercyl.BrickColor = ColorScheme3 | |
| 346 | local smoke = Instance.new("Smoke", airblowercyl)
| |
| 347 | smoke.Color = Color3.new(.3, .3, .3) | |
| 348 | smoke.RiseVelocity = 10 | |
| 349 | smoke.Opacity = .1 | |
| 350 | local cwld = Instance.new("Weld", airblowercyl)
| |
| 351 | cwld.Part0 = airblowercyl | |
| 352 | cwld.Part1 = part | |
| 353 | cwld.C1 = CFrame.Angles(0, 0, -math.pi/2) | |
| 354 | cwld.C0 = CFrame.new(0, -1.85-0.925, -.6) * CFrame.Angles(math.pi/14, 0, 0) | |
| 355 | ||
| 356 | --handles | |
| 357 | local hndl = part:clone() | |
| 358 | hndl.Parent = modelforparts | |
| 359 | hndl.Size = Vector3.new(.2, .4, .2) | |
| 360 | hndl.BrickColor = BrickColor.new(26) | |
| 361 | hndl.Mesh:Destroy() | |
| 362 | local hwld = Instance.new("Weld", hndl)
| |
| 363 | hwld.Part1 = part | |
| 364 | hwld.Part0 = hndl | |
| 365 | hwld.C1 = CFrame.new(.1, 0, 0) * CFrame.Angles(math.pi/2, 0, 0) | |
| 366 | hwld.C0 = CFrame.new(0, -.82 - .4, 0) | |
| 367 | Instance.new("BlockMesh", hndl).Scale = Vector3.new(.5, 1, .5)
| |
| 368 | local hndl2 = hndl:clone() | |
| 369 | hndl2.Parent = modelforparts | |
| 370 | hndl2.Size = Vector3.new(.8, .2, .2) | |
| 371 | local hwld2 = Instance.new("Weld", hndl2)
| |
| 372 | hwld2.Part0 = hndl2 | |
| 373 | hwld2.Part1 = part | |
| 374 | hwld2.C1 = CFrame.new(-.25, 0, 0) * CFrame.Angles(math.pi/2, 0, 0) | |
| 375 | hwld2.C0 = CFrame.new(0, -1 - .4, 0) | |
| 376 | hndl2.Mesh.Scale = Vector3.new(1, .5, .5) | |
| 377 | local hndl3 = hndl:clone() | |
| 378 | hndl3.Parent = modelforparts | |
| 379 | hndl3.Size = Vector3.new(.2, .4, .2) | |
| 380 | local hwld3 = Instance.new("Weld", hndl3)
| |
| 381 | hwld3.Part0 = hndl3 | |
| 382 | hwld3.Part1 = part | |
| 383 | hwld3.C1 = CFrame.new(-.6, 0, 0) * CFrame.Angles(math.pi/2, 0, 0) | |
| 384 | hwld3.C0 = CFrame.new(0, -.82 - .4, 0) | |
| 385 | --balloon ropes | |
| 386 | local blnrope = part:clone() | |
| 387 | blnrope.Parent = modelforparts | |
| 388 | blnrope.Size = Vector3.new(.2, 3.8, .2) | |
| 389 | blnrope.BrickColor = BrickColor.new(1) | |
| 390 | blnrope.Mesh:Destroy() | |
| 391 | local blnwld = Instance.new("Weld", blnrope)
| |
| 392 | blnwld.Part0 = blnrope | |
| 393 | blnwld.Part1 = airblowercyl | |
| 394 | blnwld.C1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.pi/2, math.pi/7, -math.pi/8) | |
| 395 | blnwld.C0 = CFrame.new(0, -2, 0) | |
| 396 | Instance.new("BlockMesh", blnrope).Scale = Vector3.new(.2, 1, .2)
| |
| 397 | local blnrope2 = blnrope:clone() | |
| 398 | blnrope2.Parent = modelforparts | |
| 399 | blnrope2.Size = Vector3.new(.2, 4, .2) | |
| 400 | local blnwld2 = Instance.new("Weld", blnrope2)
| |
| 401 | blnwld2.Part0 = blnrope2 | |
| 402 | blnwld2.Part1 = airblowercyl | |
| 403 | blnwld2.C1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.pi/2, math.pi/4, -math.pi/74) | |
| 404 | blnwld2.C0 = CFrame.new(0, -2.2, 0) | |
| 405 | local blnrope3 = blnrope:clone() | |
| 406 | blnrope3.Parent = modelforparts | |
| 407 | local blnwld3 = Instance.new("Weld", blnrope3)
| |
| 408 | blnwld3.Part0 = blnrope3 | |
| 409 | blnwld3.Part1 = airblowercyl | |
| 410 | blnwld3.C0 = CFrame.new(0, -2, 0) | |
| 411 | ||
| 412 | ||
| 413 | --Stored balloon rope welds | |
| 414 | blnwldC1 = blnwld.C1 | |
| 415 | blnwld2C1 = blnwld2.C1 | |
| 416 | blnwld3C1 = blnwld3.C1 | |
| 417 | --balloons | |
| 418 | local bln = part:clone() | |
| 419 | bln.Parent = modelforparts | |
| 420 | bln.Size = Vector3.new(1.65, 1.8, 1.65) | |
| 421 | bln.BrickColor = BrickColor.new(119) | |
| 422 | bln.Mesh:Destroy() | |
| 423 | bln.Transparency = .1 | |
| 424 | local balnwld = Instance.new("Weld", bln)
| |
| 425 | balnwld.Part0 = bln | |
| 426 | balnwld.Part1 = blnrope | |
| 427 | balnwld.C1 = CFrame.new(0, 0, 0) | |
| 428 | balnwld.C0 = CFrame.new(0, -2.6, 0) | |
| 429 | Instance.new("SpecialMesh", bln).MeshType = "Sphere"
| |
| 430 | local bln2 = bln:clone() | |
| 431 | bln2.Parent = modelforparts | |
| 432 | bln2.BrickColor = BrickColor.new(23) | |
| 433 | local balnwld2 = Instance.new("Weld", bln2)
| |
| 434 | balnwld2.Part0 = bln2 | |
| 435 | balnwld2.Part1 = blnrope2 | |
| 436 | balnwld2.C1 = CFrame.new(0, 0, 0) | |
| 437 | balnwld2.C0 = CFrame.new(0, -2.8, 0) | |
| 438 | local bln3 = bln:clone() | |
| 439 | bln3.Parent = modelforparts | |
| 440 | bln3.BrickColor = BrickColor.new(21) | |
| 441 | local balnwld3 = Instance.new("Weld", bln3)
| |
| 442 | balnwld3.Part0 = bln3 | |
| 443 | balnwld3.Part1 = blnrope3 | |
| 444 | balnwld3.C0 = CFrame.new(0, -2.6, 0) | |
| 445 | ||
| 446 | --Controls | |
| 447 | bg.Parent = rootpart | |
| 448 | bv.Parent = rootpart | |
| 449 | forwards = false | |
| 450 | backwards = false | |
| 451 | mouse.KeyDown:connect(function(k) | |
| 452 | if k == "w" then | |
| 453 | forwards = true | |
| 454 | coroutine.wrap(function() | |
| 455 | while forwards do wait() | |
| 456 | if SPEED >= MAXSPEED then SPEED = MAXSPEED forwards = false break end | |
| 457 | sound.Volume = sound.Volume + .05 | |
| 458 | if sound.Volume >= .5 then sound.Volume = .5 end | |
| 459 | SPEED = SPEED + 5 | |
| 460 | end | |
| 461 | end)() | |
| 462 | end | |
| 463 | end) | |
| 464 | mouse.KeyUp:connect(function(k) | |
| 465 | if k == "w" then | |
| 466 | forwards = false | |
| 467 | coroutine.wrap(function() | |
| 468 | while SPEED >= 0 do wait() | |
| 469 | sound.Volume = sound.Volume - .05 | |
| 470 | if sound.Volume <= 0.25 then sound.Volume = 0.25 end | |
| 471 | SPEED = SPEED - 5 | |
| 472 | if forward then break end | |
| 473 | if SPEED <= 0 then SPEED = 0 break end | |
| 474 | end | |
| 475 | end)() | |
| 476 | end | |
| 477 | end) | |
| 478 | --BALLONS MOOOOVEEE :DDD | |
| 479 | game:service'RunService'.RenderStepped:connect(function() | |
| 480 | if not equipped then return end | |
| 481 | blnwldC1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.pi/2 - math.rad(SPEED/1.7) + math.sin(ANGLE)*.025, math.pi/7 + math.sin(ANGLE)*.105, -math.pi/8 - math.sin(ANGLE)*.018) | |
| 482 | blnwld2C1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.pi/2 - math.rad(SPEED/1.7) + math.sin(ANGLE)*.015, math.pi/4 - math.sin(ANGLE)*.065, -math.pi/74 + math.sin(ANGLE)*.021) | |
| 483 | blnwld3C1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.pi/2 - math.rad(SPEED/1.7) - math.sin(ANGLE)*.02, math.pi/16 - math.sin(ANGLE)*.125, math.pi/9 - math.sin(ANGLE)*.078) | |
| 484 | blnwld.C1 = clerp(blnwld.C1, blnwldC1, 0.05) | |
| 485 | blnwld2.C1 = clerp(blnwld2.C1, blnwld2C1, 0.05) | |
| 486 | blnwld3.C1 = clerp(blnwld3.C1, blnwld3C1, 0.05) | |
| 487 | end) | |
| 488 | ||
| 489 | --positioning welds | |
| 490 | lm.C0 = CFrame.new(-1.25, .05, -.5) * CFrame.Angles(math.rad(35), 0, math.rad(45)) | |
| 491 | rm.C0 = CFrame.new(1.25, .05, -.5) * CFrame.Angles(math.rad(35), 0, -math.rad(45)) | |
| 492 | llegm.C0 = CFrame.new(-0.5, -1, 0) * CFrame.Angles(0, 0, -math.rad(15)) | |
| 493 | rlegm.C0 = CFrame.new(0.5, -1, 0) * CFrame.Angles(0, 0, math.rad(15)) | |
| 494 | ||
| 495 | ||
| 496 | ||
| 497 | game:service'RunService'.RenderStepped:connect(function() | |
| 498 | for i,v in pairs(torso:children()) do if v and v:IsA'BodyGyro' then v:Destroy() end end | |
| 499 | ANGLE = (ANGLE % 360) + math.random(1, 10)/100 | |
| 500 | humanoid.PlatformStand = true | |
| 501 | local rotpos = Vector3.new(camera.CoordinateFrame.x, camera.CoordinateFrame.y, camera.CoordinateFrame.z) | |
| 502 | bg.cframe = CFrame.new(torso.Position,rotpos) * CFrame.Angles(0, math.pi, 0) | |
| 503 | bv.velocity = (torso.CFrame * CFrame.Angles(math.pi/14, 0, 0)).lookVector * SPEED | |
| 504 | end) |