SHARE
TWEET

manti

HenloMyDude Jul 19th, 2019 (edited) 76 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  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. _G.mantisReload = function()
  143.  
  144. local plr = game:service'Players'.LocalPlayer
  145. local pg = plr:WaitForChild("PlayerGui")
  146. local mouse = plr:GetMouse()
  147. local char = plr.Character
  148. local root = char:WaitForChild'HumanoidRootPart'
  149. local head = char:WaitForChild'Head'
  150. local tor = char:WaitForChild'Torso'
  151. local la,ra = char["Left Arm"],char["Right Arm"]
  152. local ll,rl = char["Left Leg"],char["Right Leg"]
  153. tor.CFrame = tor.CFrame + Vector3.new(0,5,0)
  154.  
  155.  
  156. local hum = char.Humanoid
  157. local step = game:GetService("RunService").RenderStepped
  158.  
  159.  
  160. pcall(function() workspace["vmodel"..plr.Name]:Destroy() end)
  161. pcall(function() pg.bgui:Destroy() end)
  162. if not script:IsA("ModuleScript") then
  163. pcall(function() script.Parent.vehicularScript:Destroy() end)
  164. script.Name = "vehicularScript"
  165. end
  166.  
  167.  
  168. local sg = Instance.new("ScreenGui",pg)
  169. sg.Name = "bgui"
  170. local p = Instance.new("ImageLabel",sg)
  171. p.Size = UDim2.new(0,6,0,6)
  172. p.Position = UDim2.new(.5,-3,.5,-3)
  173. p.BackgroundColor3 = Color3.new(1,1,1)
  174. p.BackgroundTransparency = .6
  175. local p2 = p:Clone()
  176. p2.Parent = sg
  177. p2.Rotation = 45
  178. local m = Instance.new("Model",workspace)
  179. m.Name = "vmodel"..plr.Name
  180. Instance.new("Humanoid",m).Name = "Shadow"
  181. local hval = Instance.new("NumberValue",m)
  182. hval.Value = 100
  183. hval.Name = "hp"
  184.  
  185.  
  186. function weld(a,b,c,d)
  187. local w = Instance.new("Motor6D",a)
  188. w.Part0,w.Part1,w.C0,w.C1 = a,b,c or CFrame.new(),d or CFrame.new()
  189. return w
  190. end
  191.  
  192.  
  193. do
  194. local function QuaternionFromCFrame(cf)
  195. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  196. local trace = m00 + m11 + m22
  197. if trace > 0 then
  198. local s = math.sqrt(1 + trace)
  199. local recip = 0.5/s
  200. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  201. else
  202. local i = 0
  203. if m11 > m00 then
  204. i = 1
  205. end
  206. if m22 > (i == 0 and m00 or m11) then
  207. i = 2
  208. end
  209. if i == 0 then
  210. local s = math.sqrt(m00-m11-m22+1)
  211. local recip = 0.5/s
  212. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  213. elseif i == 1 then
  214. local s = math.sqrt(m11-m22-m00+1)
  215. local recip = 0.5/s
  216. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  217. elseif i == 2 then
  218. local s = math.sqrt(m22-m00-m11+1)
  219. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  220. end
  221. end
  222. end
  223. local function QuaternionToCFrame(px, py, pz, x, y, z, w)
  224. local xs, ys, zs = x + x, y + y, z + z
  225. local wx, wy, wz = w*xs, w*ys, w*zs
  226. local xx = x*xs
  227. local xy = x*ys
  228. local xz = x*zs
  229. local yy = y*ys
  230. local yz = y*zs
  231. local zz = z*zs
  232. 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))
  233. end
  234. local function QuaternionSlerp(a, b, t)
  235. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  236. local startInterp, finishInterp;
  237. if cosTheta >= 0.0001 then
  238. if (1 - cosTheta) > 0.0001 then
  239. local theta = math.acos(cosTheta)
  240. local invSinTheta = 1/math.sin(theta)
  241. startInterp = math.sin((1-t)*theta)*invSinTheta
  242. finishInterp = math.sin(t*theta)*invSinTheta
  243. else
  244. startInterp = 1-t
  245. finishInterp = t
  246. end
  247. else
  248. if (1+cosTheta) > 0.0001 then
  249. local theta = math.acos(-cosTheta)
  250. local invSinTheta = 1/math.sin(theta)
  251. startInterp = math.sin((t-1)*theta)*invSinTheta
  252. finishInterp = math.sin(t*theta)*invSinTheta
  253. else
  254. startInterp = t-1
  255. finishInterp = t
  256. end
  257. end
  258. 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
  259. end
  260. function clerp(a,b,t)
  261. local qa = {QuaternionFromCFrame(a)}
  262. local qb = {QuaternionFromCFrame(b)}
  263. local ax, ay, az = a.x, a.y, a.z
  264. local bx, by, bz = b.x, b.y, b.z
  265. local _t = 1-t
  266. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  267. end
  268. end
  269.  
  270.  
  271. function lerp(a,b,t)
  272. return a+(b-a)*t
  273. end
  274.  
  275.  
  276. local cancollide = true
  277. local par = m
  278. function Part(Part0,C0,C1,Size,Color,Ref,Trans,Mesh,Material)
  279. local p = Instance.new("Part",par)
  280. p.FormFactor = "Custom"
  281. p.TopSurface,p.BottomSurface,p.BackSurface,p.FrontSurface,p.RightSurface,p.LeftSurface = 10,10,10,10,10,10
  282. p.Size = Size or Vector3.new()
  283. p.Material = "SmoothPlastic"
  284. p.CanCollide = cancollide
  285. p.Locked = true
  286. if p.Size ~= Size or Mesh then
  287. local bm = Mesh or Instance.new("BlockMesh")
  288. bm.Parent = p
  289. bm.Scale = Size/p.Size*bm.Scale
  290. bm.Parent = p
  291. end
  292. p.BrickColor = Color or BrickColor.new(1001)
  293. p.Reflectance = Ref or 0
  294. p.Transparency = Trans or 0
  295. p.Material = Material or p.Material
  296. local w;
  297. if Part0 then
  298. w = weld(Part0,p,C0,C1)
  299. end
  300. return p,w
  301. end
  302.  
  303.  
  304. function Mesh(type,scale,arg1,arg2,arg3,arg4,arg5)
  305. local m = Instance.new(type)
  306. m.Scale = scale or Vector3.new(1,1,1)
  307. if type == "SpecialMesh" then
  308. m.MeshType = arg1
  309. if arg1=="FileMesh" then
  310. m.MeshId = arg2 or m.MeshId
  311. m.TextureId = arg3 or m.TextureId
  312. m.Offset = arg4 or m.Offset
  313. m.VertexColor = arg5 or m.VertexColor
  314. else
  315. m.VertexColor = arg3 or m.VertexColor
  316. m.Offset = arg2 or m.Offset
  317. end
  318. else
  319. m.Offset = arg1 or m.Offset
  320. m.VertexColor = arg2 or m.VertexColor
  321. end
  322. return m
  323. end
  324.  
  325.  
  326. local b = BrickColor.new
  327. local cols = {b(21),b(23),b(141),b(104),b(106),b(24),b(9),b(5)}
  328. function gcol(plr)
  329. if teamColorsEnabled and pcall(function() assert(plr.AccountAge ~= nil) end) and not plr.Neutral then
  330. return plr.TeamColor.Color
  331. else
  332. local v=0;
  333. local n=tostring(plr);
  334. local a=#n;
  335. for i in n:gmatch(".") do
  336. v = v + ((a+(#n%2==1 and -1 or 0))%4 > 1 and -1 or 1)*i:byte()
  337. a = a - 1
  338. end
  339. return cols[(v%8)+1].Color
  340. end
  341. end
  342.  
  343.  
  344.  
  345. local body = BrickColor.new("Really black")
  346. local body2 = BrickColor.new("Institutional white")
  347. local body3 = BrickColor.new("Really black")
  348. local bodyref = .2
  349. local body2ref = .2
  350. local body3ref = .5
  351.  
  352.  
  353. local pipe = BrickColor.new("Dark stone grey")
  354. local pipe2 = body2--BrickColor.new("Institutional white")
  355. local pipe3 = body--BrickColor.new("Really black")
  356. local piperef = .25
  357. local pipe2ref = .2
  358. local pipe3ref = .25
  359.  
  360.  
  361. hum.Sit = true
  362.  
  363.  
  364.  
  365. local fc = Instance.new("Model",m)
  366. par = fc
  367. local tr = Part(tor,CFrame.new(),CFrame.new(),Vector3.new(),BrickColor.new(),0,1)
  368. tr.Name = "Torso"
  369. Part(tr,CFrame.new(),CFrame.new(),Vector3.new(),BrickColor.new(),0,1).Name = "Head"
  370. Part(ra,CFrame.new(),CFrame.new(),Vector3.new(),ra.BrickColor,0,0).Name = "Right Arm"
  371. Part(la,CFrame.new(),CFrame.new(),Vector3.new(),la.BrickColor,0,0).Name = "Left Arm"
  372. Part(rl,CFrame.new(),CFrame.new(),Vector3.new(),rl.BrickColor,0,0).Name = "Right Leg"
  373. Part(ll,CFrame.new(),CFrame.new(),Vector3.new(),ll.BrickColor,0,0).Name = "Left Leg"
  374. local hm = Instance.new("Humanoid",fc)
  375. hm.MaxHealth = math.huge
  376. hm.PlatformStand = true
  377. for i,v in pairs(char:GetChildren()) do
  378. if v:IsA("Clothing") or v:IsA("CharacterMesh") then
  379. v:Clone().Parent = fc
  380. if v:IsA("Shirt") then
  381. pcall(game.Destroy,tr:FindFirstChild("Mesh"))
  382. pcall(game.Destroy,fc["Right Arm"]:FindFirstChild("Mesh"))
  383. pcall(game.Destroy,fc["Left Arm"]:FindFirstChild("Mesh"))
  384. elseif v:IsA("Pants") then
  385. pcall(game.Destroy,tr:FindFirstChild("Mesh"))
  386. pcall(game.Destroy,fc["Right Leg"]:FindFirstChild("Mesh"))
  387. pcall(game.Destroy,fc["Left Leg"]:FindFirstChild("Mesh"))
  388. end
  389. end
  390. end
  391. local h = Instance.new("Hat",fc)
  392. par = h
  393. Part(tr,CFrame.new(),CFrame.new(),Vector3.new(),BrickColor.new(),0,1).Name = "Handle"
  394. par = m
  395.  
  396.  
  397. local main,mainweld = Part(tor,CFrame.new(0,-2.25,0)*CFrame.Angles(0,0,0),CFrame.new(0,0,0),Vector3.new(3,1,2),body,bodyref,0)
  398. Part(main,CFrame.new(0,.5,-.4),CFrame.new(),Vector3.new(2.3,.2,1.3),body2,0,0)
  399. local p = Part(main,CFrame.new(0,-.5,1)*CFrame.Angles(-1.4,0,0)*CFrame.new(0,.5,1.25),CFrame.new(),Vector3.new(2.3,.75,2.5),body,bodyref)
  400. Part(p,CFrame.new(0,.375,0),CFrame.new(),Vector3.new(2.2,.2,1.4),body2,0,0)
  401. p = Part(p,CFrame.new(0,-.375,1.25)*CFrame.Angles(-.15,0,0)*CFrame.new(0,.375,.8),CFrame.new(),Vector3.new(2.3,.75,1.6),body,bodyref)
  402. p.CanCollide = false
  403. Part(p,CFrame.new(0,.375,0),CFrame.new(),Vector3.new(2.2,.2,1.2),body2,0,0).CanCollide = false
  404. local back = Part(main,CFrame.new(0,1.4,1)*CFrame.Angles(.15,math.pi,0),CFrame.new(),Vector3.new(2,2,3),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(3,3.8,6.5),"FileMesh","rbxassetid://9944765"))
  405. Part(main,CFrame.new(0,-.5,1.75)*CFrame.Angles(-1.1,0,0)*CFrame.new(0,.5,1.25),CFrame.new(),Vector3.new(1.75,1.5,2.25),body,bodyref)
  406. Part(main,CFrame.new(0,0,1.25),CFrame.new(),Vector3.new(1.75,1.1,1.5),body,bodyref)
  407. local p = Part(main,CFrame.new(0,.5,-1)*CFrame.Angles(-.2,0,0)*CFrame.new(0,-.375,-.5),CFrame.new(),Vector3.new(2.75,.75,1),body,bodyref)
  408. Part(p,CFrame.new(0,.375,.05),CFrame.new(),Vector3.new(2.3,.2,.95),body2,0,0)
  409. Part(p,CFrame.new(0,.8,-.45),CFrame.new(),Vector3.new(2.3,1,.3),body2,0,0)
  410. Part(p,CFrame.new(0,1.5,-.4)*CFrame.Angles(.2,0,0),CFrame.new(),Vector3.new(2.3,.5,.3),body2,0,0)
  411. local p = Part(main,CFrame.new(0,2.1,-2.9)*CFrame.Angles(.9,0,0),CFrame.new(),Vector3.new(1.5,2.5,1),body,bodyref,0)
  412. local p = Part(p,CFrame.new(0,1.25,.5)*CFrame.Angles(-.9,0,0)*CFrame.new(0,.5,-.7),CFrame.new(),Vector3.new(1.501,1,1.4),body,bodyref,0)
  413. local h = Part(p,CFrame.new(.4,-.2,.7)*CFrame.Angles(0,1.425,0)*CFrame.new(.175,0,.9),CFrame.new(),Vector3.new(.35,.35,1.8),body,bodyref,0)
  414. Part(h,CFrame.new(0,0,.225),CFrame.new(),Vector3.new(.4,.4,1.3),body2,body2ref,0)
  415. Part(h,CFrame.new(0,0,.9),CFrame.new(),Vector3.new(.45,.45,.1),body3,body3ref,0)
  416. Part(h,CFrame.new(0,0,-.45),CFrame.new(),Vector3.new(.425,.425,.1),body3,body3ref,0)
  417. Part(h,CFrame.new(0,0,.75),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  418. Part(h,CFrame.new(0,0,.6),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  419. Part(h,CFrame.new(0,0,.45),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  420. Part(h,CFrame.new(0,0,.3),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  421. Part(h,CFrame.new(0,0,.15),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  422. Part(h,CFrame.new(0,0,0),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  423. Part(h,CFrame.new(0,0,-.15),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  424. Part(h,CFrame.new(0,0,-.3),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  425. local h = Part(p,CFrame.new(-.4,-.2,.7)*CFrame.Angles(0,-1.425,0)*CFrame.new(-.175,0,.9),CFrame.new(),Vector3.new(.35,.35,1.8),body,bodyref,0)
  426. Part(h,CFrame.new(0,0,.225),CFrame.new(),Vector3.new(.4,.4,1.3),body2,body2ref,0)
  427. Part(h,CFrame.new(0,0,.9),CFrame.new(),Vector3.new(.45,.45,.1),body3,body3ref,0)
  428. Part(h,CFrame.new(0,0,-.45),CFrame.new(),Vector3.new(.425,.425,.1),body3,body3ref,0)
  429. Part(h,CFrame.new(0,0,.75),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  430. Part(h,CFrame.new(0,0,.6),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  431. Part(h,CFrame.new(0,0,.45),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  432. Part(h,CFrame.new(0,0,.3),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  433. Part(h,CFrame.new(0,0,.15),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  434. Part(h,CFrame.new(0,0,0),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  435. Part(h,CFrame.new(0,0,-.15),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  436. Part(h,CFrame.new(0,0,-.3),CFrame.new(),Vector3.new(.415,.415,.025),body3,body3ref,0)
  437.  
  438.  
  439. local e = Part(main,CFrame.new(0,1,-4.6)*CFrame.Angles(-.2,-math.pi/2,0)*CFrame.new(0,-.2,0),CFrame.new(),Vector3.new(5,5,5),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  440. p = Part(e,CFrame.new(-2.25,2.25,0)*CFrame.Angles(0,-math.pi/2,0)*CFrame.Angles(-.05,0,0),CFrame.new(),Vector3.new(2,2,3),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(2,1.75,9.5),"FileMesh","rbxassetid://9944765"))
  441. p = Part(p,CFrame.new(0,-.2,.4)*CFrame.Angles(0,0,0)*CFrame.Angles(-.175,0,0),CFrame.new(),Vector3.new(1,1,1),body2,body2ref,0,Mesh("SpecialMesh",Vector3.new(2.3,2.3,2),"FileMesh","rbxassetid://9944765"))
  442.  
  443.  
  444. p = Part(e,CFrame.new(2,.25,2)*CFrame.Angles(1.35,math.pi/2,0)*CFrame.Angles(0,0,0),CFrame.new(),Vector3.new(2,2,3),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(2.5,2.5,9.5),"FileMesh","rbxassetid://9944765"))
  445. p = Part(p,CFrame.new(0,.2,-4.55)*CFrame.Angles(0,math.pi,-.1),CFrame.new(),Vector3.new(1,1,1),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(1.6,1.1,9),"FileMesh","rbxassetid://9944765"))
  446.  
  447.  
  448. p = Part(e,CFrame.new(2,.25,-2)*CFrame.Angles(-1.35,math.pi/2,0)*CFrame.Angles(0,0,0),CFrame.new(),Vector3.new(2,2,3),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(2.5,2.5,9.5),"FileMesh","rbxassetid://9944765"))
  449. p = Part(p,CFrame.new(0,.2,-4.55)*CFrame.Angles(0,math.pi,-.1),CFrame.new(),Vector3.new(1,1,1),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(1.6,1.1,9),"FileMesh","rbxassetid://9944765"))
  450.  
  451.  
  452.  
  453.  
  454.  
  455. local e2 = Part(e,CFrame.new(-2.5,0,0)*CFrame.Angles(0,math.pi/2,0),CFrame.new(),Vector3.new(5,5,1),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Sphere"))
  456. local et = Part(e2,CFrame.new(0,.05,-.6)*CFrame.Angles(-math.pi/2+.05,0,0),CFrame.new(),Vector3.new(5,5,1),body,bodyref,0,Mesh("SpecialMesh",Vector3.new(3.45,5,3.45),"FileMesh","rbxassetid://16659502"))
  457. local g1 = Part(et,CFrame.new(0,-.5,0)*CFrame.Angles(math.pi/2,0,0),CFrame.new(),Vector3.new(2.5,2.5,2.5),body2,body2ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Sphere"))
  458. local g2 = Part(g1,CFrame.new(0,0,-1)*CFrame.Angles(.15,math.pi/2,0),CFrame.new(),Vector3.new(.75,.6,.6),body2,body2ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  459. local t1 = Part(g2,CFrame.new(.9,.05,0)*CFrame.Angles(0,0,0),CFrame.new(),Vector3.new(1,.4,.4),body3,body3ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  460. local t1s = Instance.new("Sound",t1)
  461. t1s.SoundId = "rbxassetid://78498351"
  462. t1s.Volume = 0.5
  463. t1s.Pitch = 1.5
  464.  
  465.  
  466. Part(t1,CFrame.Angles(.75,0,0)*CFrame.new(.3,.2,0)*CFrame.Angles(0,0,math.pi/2),CFrame.new(),Vector3.new(.025,.15,.15),BrickColor.new(1003),0,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  467. Part(t1,CFrame.Angles(.75,0,0)*CFrame.new(0,.2,0)*CFrame.Angles(0,0,math.pi/2),CFrame.new(),Vector3.new(.025,.15,.15),BrickColor.new(1003),0,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  468. Part(t1,CFrame.Angles(.75,0,0)*CFrame.new(-.3,.2,0)*CFrame.Angles(0,0,math.pi/2),CFrame.new(),Vector3.new(.025,.15,.15),BrickColor.new(1003),0,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  469. Part(t1,CFrame.Angles(-.75,0,0)*CFrame.new(.3,.2,0)*CFrame.Angles(0,0,math.pi/2),CFrame.new(),Vector3.new(.025,.15,.15),BrickColor.new(1003),0,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  470. Part(t1,CFrame.Angles(-.75,0,0)*CFrame.new(0,.2,0)*CFrame.Angles(0,0,math.pi/2),CFrame.new(),Vector3.new(.025,.15,.15),BrickColor.new(1003),0,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  471. Part(t1,CFrame.Angles(-.75,0,0)*CFrame.new(-.3,.2,0)*CFrame.Angles(0,0,math.pi/2),CFrame.new(),Vector3.new(.025,.15,.15),BrickColor.new(1003),0,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  472. Part(t1,CFrame.new(.5,0,0),CFrame.new(),Vector3.new(.01,.225,.225),BrickColor.new(1003),0,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  473.  
  474.  
  475. local b = Part(main,CFrame.new(0,-.65,-2.9),CFrame.new(),Vector3.new(2.8,2,7.9),body,bodyref,0)
  476. local b2 = Part(b,CFrame.new(0,-.5,-2.5),CFrame.new(),Vector3.new(7,1,2),body,bodyref,0)
  477.  
  478.  
  479. local w = Part(b2,CFrame.new(-3.5,0,0),CFrame.new(),Vector3.new(1.2,1.05,2),body,bodyref,0)
  480. local w = Part(w,CFrame.new(.6,0,-1)*CFrame.Angles(0,.5,0)*CFrame.new(-.6,0,-1),CFrame.new(),Vector3.new(1.2,1.049,2),body,bodyref,0)
  481. Part(w,CFrame.new(.6,0,0),CFrame.new(),Vector3.new(.5,1.1,2.07),body2,body2ref,0)
  482. local w = Part(w,CFrame.new(.6,0,-1)*CFrame.Angles(0,.5,0)*CFrame.new(-.6,0,-.95),CFrame.new(),Vector3.new(1.2,1.05,1.9),body,bodyref,0)
  483. Part(w,CFrame.new(.6,0,0),CFrame.new(),Vector3.new(.5,1.095,2.05),body2,body2ref,0)
  484. local w = Part(w,CFrame.new(.6,0,-.95)*CFrame.Angles(0,.57,0)*CFrame.new(-.65,0,-1.2),CFrame.new(),Vector3.new(1.3,1.049,2.4),body,bodyref,0)
  485. Part(w,CFrame.new(.65,0,.8),CFrame.new(),Vector3.new(.5,1.1,.95),body2,body2ref,0)
  486. local w = Part(w,CFrame.new(-.6,0,-1.2)*CFrame.Angles(0,-1.57,0)*CFrame.new(.8,0,-1.25),CFrame.new(),Vector3.new(1.6,1.05,2.5),body,bodyref,0)
  487. local w = Part(w,CFrame.new(-.8,0,-1.25)*CFrame.Angles(0,-.4,0)*CFrame.new(.7,0,1.25),CFrame.new(),Vector3.new(1.4,1.049,2.5),body,bodyref,0)
  488. local w = Part(w,CFrame.new(.7,0,1.25)*CFrame.Angles(0,-.45,0)*CFrame.new(-.7,0,1),CFrame.new(),Vector3.new(1.4,1.05,2),body,bodyref,0)
  489. local w = Part(w,CFrame.new(-.7,0,1)*CFrame.Angles(0,.6,0)*CFrame.new(.7,0,1),CFrame.new(),Vector3.new(1.4,1.049,2),body,bodyref,0)
  490. local w = Part(w,CFrame.new(-.7,0,1)*CFrame.Angles(0,.55,0)*CFrame.new(.7,0,1),CFrame.new(),Vector3.new(1.4,1.05,2),body,bodyref,0)
  491. local w = Part(w,CFrame.new(-.7,0,1)*CFrame.Angles(0,.5,0)*CFrame.new(.7,0,1),CFrame.new(),Vector3.new(1.4,1.049,2),body,bodyref,0)
  492. local w = Part(w,CFrame.new(-.7,0,1)*CFrame.Angles(0,.45,0)*CFrame.new(.6,0,.5),CFrame.new(),Vector3.new(1.5,1.05,1),body,bodyref,0)
  493. local w = Part(w,CFrame.new(-.75,0,.5)*CFrame.Angles(0,.325,0)*CFrame.new(.5,0,1.3),CFrame.new(),Vector3.new(1.6,1.049,2.6),body,bodyref,0)
  494. local w = Part(w,CFrame.new(-.2,0,1.3)*CFrame.Angles(0,.65,0)*CFrame.new(.5,0,.8),CFrame.new(),Vector3.new(1,1.05,1.6),body,bodyref,0)
  495. local w = Part(w,CFrame.new(-.5,0,.8)*CFrame.Angles(0,.45,0)*CFrame.new(.5,0,1),CFrame.new(),Vector3.new(1,1.05,2),body,bodyref,0)
  496.  
  497.  
  498.  
  499. cancollide = false
  500. Part(b2,CFrame.new(-3.5-3,.125,0)*CFrame.Angles(-math.pi/2,0,0),CFrame.new(),Vector3.new(3,3,1),body2,body2ref,0,Mesh("SpecialMesh",Vector3.new(5,5,6),"FileMesh","rbxassetid://3270017"),"DiamondPlate")
  501. Part(b2,CFrame.new(-3.5-3,-.125,0)*CFrame.Angles(-math.pi/2,0,0),CFrame.new(),Vector3.new(3,3,1),body2,body2ref,0,Mesh("SpecialMesh",Vector3.new(5,5,6),"FileMesh","rbxassetid://3270017"))
  502. cancollide = true
  503.  
  504.  
  505. local propl,proplw = Part(b2,CFrame.new(-6.5,0,0),CFrame.new(),Vector3.new(.4,.75,.4),body2,body2ref,0,Mesh("CylinderMesh",Vector3.new(1,1,1)),"DiamondPlate")
  506. Part(propl,CFrame.new(0,.35,0),CFrame.new(),Vector3.new(.6,.25,.6),body3,body3ref,0,Mesh("CylinderMesh",Vector3.new(1,1,1)),"DiamondPlate")
  507. Part(propl,CFrame.new(0,-.35,0),CFrame.new(),Vector3.new(.5,.15,.5),body3,body3ref,0,Mesh("CylinderMesh",Vector3.new(1,1,1)),"DiamondPlate")
  508. Part(propl,CFrame.Angles(0,0*math.pi*2/3,0)*CFrame.new(0,0,.3),CFrame.new(),Vector3.new(.15,.65,.3),body3,body3ref,0,nil,"DiamondPlate")
  509. Part(propl,CFrame.Angles(0,1*math.pi*2/3,0)*CFrame.new(0,0,.3),CFrame.new(),Vector3.new(.15,.65,.3),body3,body3ref,0,nil,"DiamondPlate")
  510. Part(propl,CFrame.Angles(0,2*math.pi*2/3,0)*CFrame.new(0,0,.3),CFrame.new(),Vector3.new(.15,.65,.3),body3,body3ref,0,nil,"DiamondPlate")
  511. propl.Name = "SoundPlayer1"
  512. local ps2 = Instance.new("Sound",propl)
  513. ps2.SoundId = "rbxassetid://134145308"
  514. ps2.Pitch = 2
  515. ps2.Volume = 1
  516. ps2.Looped = true
  517. ps2:Play()
  518.  
  519.  
  520.  
  521. local p = Part(propl,CFrame.Angles(0,0*math.pi*2/3,0)*CFrame.new(0,0,.35+.8)*CFrame.Angles(0,0,-1.3),CFrame.new(),Vector3.new(.05,.5,1.7),body2,body2ref,0,nil,"Plastic")
  522. Part(p,CFrame.Angles(0,0,1.3)*CFrame.new(-.125,0,.85),CFrame.new(),Vector3.new(.7,.25,.05),body2,body2ref,0,nil,"Plastic")
  523. local p = Part(propl,CFrame.Angles(0,1*math.pi*2/3,0)*CFrame.new(0,0,.35+.8)*CFrame.Angles(0,0,-1.3),CFrame.new(),Vector3.new(.05,.5,1.7),body2,body2ref,0,nil,"Plastic")
  524. Part(p,CFrame.Angles(0,0,1.3)*CFrame.new(-.125,0,.85),CFrame.new(),Vector3.new(.7,.25,.05),body2,body2ref,0,nil,"Plastic")
  525. local p = Part(propl,CFrame.Angles(0,2*math.pi*2/3,0)*CFrame.new(0,0,.35+.8)*CFrame.Angles(0,0,-1.3),CFrame.new(),Vector3.new(.05,.5,1.7),body2,body2ref,0,nil,"Plastic")
  526. Part(p,CFrame.Angles(0,0,1.3)*CFrame.new(-.125,0,.85),CFrame.new(),Vector3.new(.7,.25,.05),body2,body2ref,0,nil,"Plastic")
  527.  
  528.  
  529.  
  530. local w = Part(b2,CFrame.new(3.5,0,0),CFrame.new(),Vector3.new(1.2,1.05,2),body,bodyref,0)
  531. local w = Part(w,CFrame.new(-.6,0,-1)*CFrame.Angles(0,-.5,0)*CFrame.new(.6,0,-1),CFrame.new(),Vector3.new(1.2,1.049,2),body,bodyref,0)
  532. Part(w,CFrame.new(-.6,0,0),CFrame.new(),Vector3.new(.5,1.1,2.07),body2,body2ref,0)
  533. local w = Part(w,CFrame.new(-.6,0,-1)*CFrame.Angles(0,-.5,0)*CFrame.new(.6,0,-.95),CFrame.new(),Vector3.new(1.2,1.05,1.9),body,bodyref,0)
  534. Part(w,CFrame.new(-.6,0,0),CFrame.new(),Vector3.new(.5,1.095,2.05),body2,body2ref,0)
  535. local w = Part(w,CFrame.new(-.6,0,-.95)*CFrame.Angles(0,-.57,0)*CFrame.new(.65,0,-1.2),CFrame.new(),Vector3.new(1.3,1.049,2.4),body,bodyref,0)
  536. Part(w,CFrame.new(-.65,0,.8),CFrame.new(),Vector3.new(.5,1.1,.95),body2,body2ref,0)
  537. local w = Part(w,CFrame.new(.6,0,-1.2)*CFrame.Angles(0,1.57,0)*CFrame.new(-.8,0,-1.25),CFrame.new(),Vector3.new(1.6,1.05,2.5),body,bodyref,0)
  538. local w = Part(w,CFrame.new(.8,0,-1.25)*CFrame.Angles(0,.4,0)*CFrame.new(-.7,0,1.25),CFrame.new(),Vector3.new(1.4,1.049,2.5),body,bodyref,0)
  539. local w = Part(w,CFrame.new(-.7,0,1.25)*CFrame.Angles(0,.45,0)*CFrame.new(.7,0,1),CFrame.new(),Vector3.new(1.4,1.05,2),body,bodyref,0)
  540. local w = Part(w,CFrame.new(.7,0,1)*CFrame.Angles(0,-.6,0)*CFrame.new(-.7,0,1),CFrame.new(),Vector3.new(1.4,1.049,2),body,bodyref,0)
  541. local w = Part(w,CFrame.new(.7,0,1)*CFrame.Angles(0,-.55,0)*CFrame.new(-.7,0,1),CFrame.new(),Vector3.new(1.4,1.05,2),body,bodyref,0)
  542. local w = Part(w,CFrame.new(.7,0,1)*CFrame.Angles(0,-.5,0)*CFrame.new(-.7,0,1),CFrame.new(),Vector3.new(1.4,1.049,2),body,bodyref,0)
  543. local w = Part(w,CFrame.new(.7,0,1)*CFrame.Angles(0,-.45,0)*CFrame.new(-.6,0,.5),CFrame.new(),Vector3.new(1.5,1.05,1),body,bodyref,0)
  544. local w = Part(w,CFrame.new(.75,0,.5)*CFrame.Angles(0,-.325,0)*CFrame.new(-.5,0,1.3),CFrame.new(),Vector3.new(1.6,1.049,2.6),body,bodyref,0)
  545. local w = Part(w,CFrame.new(.2,0,1.3)*CFrame.Angles(0,-.65,0)*CFrame.new(-.5,0,.8),CFrame.new(),Vector3.new(1,1.05,1.6),body,bodyref,0)
  546. local w = Part(w,CFrame.new(.5,0,.8)*CFrame.Angles(0,-.45,0)*CFrame.new(-.5,0,1),CFrame.new(),Vector3.new(1,1.05,2),body,bodyref,0)
  547.  
  548.  
  549.  
  550. cancollide = false
  551. Part(b2,CFrame.new(3.5+3,.125,0)*CFrame.Angles(-math.pi/2,0,0),CFrame.new(),Vector3.new(3,3,1),body2,body2ref,0,Mesh("SpecialMesh",Vector3.new(5,5,6),"FileMesh","rbxassetid://3270017"),"DiamondPlate")
  552. Part(b2,CFrame.new(3.5+3,-.125,0)*CFrame.Angles(-math.pi/2,0,0),CFrame.new(),Vector3.new(3,3,1),body2,body2ref,0,Mesh("SpecialMesh",Vector3.new(5,5,6),"FileMesh","rbxassetid://3270017"))
  553. cancollide = true
  554.  
  555.  
  556. local propr,proprw = Part(b2,CFrame.new(6.5,0,0),CFrame.new(),Vector3.new(.4,.75,.4),body2,body2ref,0,Mesh("CylinderMesh",Vector3.new(1,1,1)),"DiamondPlate")
  557. Part(propr,CFrame.new(0,.35,0),CFrame.new(),Vector3.new(.6,.25,.6),body3,body3ref,0,Mesh("CylinderMesh",Vector3.new(1,1,1)),"DiamondPlate")
  558. Part(propr,CFrame.new(0,-.35,0),CFrame.new(),Vector3.new(.5,.15,.5),body3,body3ref,0,Mesh("CylinderMesh",Vector3.new(1,1,1)),"DiamondPlate")
  559. Part(propr,CFrame.Angles(0,0*math.pi*2/3,0)*CFrame.new(0,0,.3),CFrame.new(),Vector3.new(.15,.65,.3),body3,body3ref,0,nil,"DiamondPlate")
  560. Part(propr,CFrame.Angles(0,1*math.pi*2/3,0)*CFrame.new(0,0,.3),CFrame.new(),Vector3.new(.15,.65,.3),body3,body3ref,0,nil,"DiamondPlate")
  561. Part(propr,CFrame.Angles(0,2*math.pi*2/3,0)*CFrame.new(0,0,.3),CFrame.new(),Vector3.new(.15,.65,.3),body3,body3ref,0,nil,"DiamondPlate")
  562. propr.Name = "SoundPlayer2"
  563. local ps = Instance.new("Sound",propr)
  564. ps.SoundId = "rbxassetid://134145308"
  565. ps.Pitch = 2
  566. ps.Volume = 1
  567. ps.Looped = true
  568. ps:Play()
  569.  
  570.  
  571. local p = Part(propr,CFrame.Angles(0,0*math.pi*2/3,0)*CFrame.new(0,0,.35+.8)*CFrame.Angles(0,0,1.3),CFrame.new(),Vector3.new(.05,.5,1.7),body2,body2ref,0,nil,"Plastic")
  572. Part(p,CFrame.Angles(0,0,-1.3)*CFrame.new(.125,0,.85),CFrame.new(),Vector3.new(.7,.25,.05),body2,body2ref,0,nil,"Plastic")
  573. local p = Part(propr,CFrame.Angles(0,1*math.pi*2/3,0)*CFrame.new(0,0,.35+.8)*CFrame.Angles(0,0,1.3),CFrame.new(),Vector3.new(.05,.5,1.7),body2,body2ref,0,nil,"Plastic")
  574. Part(p,CFrame.Angles(0,0,-1.3)*CFrame.new(.125,0,.85),CFrame.new(),Vector3.new(.7,.25,.05),body2,body2ref,0,nil,"Plastic")
  575. local p = Part(propr,CFrame.Angles(0,2*math.pi*2/3,0)*CFrame.new(0,0,.35+.8)*CFrame.Angles(0,0,1.3),CFrame.new(),Vector3.new(.05,.5,1.7),body2,body2ref,0,nil,"Plastic")
  576. Part(p,CFrame.Angles(0,0,-1.3)*CFrame.new(.125,0,.85),CFrame.new(),Vector3.new(.7,.25,.05),body2,body2ref,0,nil,"Plastic")
  577.  
  578.  
  579.  
  580.  
  581.  
  582. local p1 = Part(main,CFrame.new(-1.85,.35,-1.1)*CFrame.Angles(0,math.pi/2,0),CFrame.new(),Vector3.new(1.25,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  583. Part(p1,CFrame.new(.5,0,.025),CFrame.new(),Vector3.new(1.5,1,1),pipe2,pipe2ref,0,Mesh("SpecialMesh",Vector3.new(.7,.85,.85),"Cylinder"),"DiamondPlate")
  584. Part(p1,CFrame.new(-.625,0,0),CFrame.new(),Vector3.new(.7,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Sphere"))
  585. local p1 = Part(p1,CFrame.new(-.625,0,0)*CFrame.Angles(0,0,-1)*CFrame.new(-.95,0,0),CFrame.new(),Vector3.new(1.9,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  586. Part(p1,CFrame.new(-.95,0,0),CFrame.new(),Vector3.new(.7,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Sphere"))
  587. local p1 = Part(p1,CFrame.new(-.95,0,0)*CFrame.Angles(0,0,1)*CFrame.new(-1.25,0,0),CFrame.new(),Vector3.new(2.5,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  588. local p = Part(p1,CFrame.new(-.3,0,.01),CFrame.new(),Vector3.new(1.5,1,1),pipe2,pipe2ref,0,Mesh("SpecialMesh",Vector3.new(1,.8,.8),"Cylinder"),"DiamondPlate")
  589. Part(p,CFrame.new(.6,0,0),CFrame.new(),Vector3.new(.15,.9,.9),pipe3,pipe3ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  590. Part(p,CFrame.new(-.6,0,0),CFrame.new(),Vector3.new(.15,.9,.9),pipe3,pipe3ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  591. Part(p,CFrame.new(0,0,.65),CFrame.new(),Vector3.new(1.3,.3,.5),pipe3,pipe3ref,0)
  592. Part(p1,CFrame.new(-1.25,0,0),CFrame.new(),Vector3.new(.15,.65,.65),pipe3,pipe3ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  593. local p = Part(p1,CFrame.new(-1.35,0,0)*CFrame.Angles(math.pi/2,0,math.pi/2),CFrame.new(),Vector3.new(1,1,1),pipe3,pipe3ref,0,Mesh("SpecialMesh",Vector3.new(.5,2,.5),"FileMesh","rbxassetid://16659502"))
  594. local firel = Instance.new("Fire",p)
  595. local lightl = Instance.new("PointLight",p)
  596.  
  597.  
  598. local p1 = Part(main,CFrame.new(1.85,.35,-1.1)*CFrame.Angles(0,math.pi/2,0),CFrame.new(),Vector3.new(1.25,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  599. Part(p1,CFrame.new(.5,0,-.025),CFrame.new(),Vector3.new(1.5,1,1),pipe2,pipe2ref,0,Mesh("SpecialMesh",Vector3.new(.7,.85,.85),"Cylinder"),"DiamondPlate")
  600. Part(p1,CFrame.new(-.625,0,0),CFrame.new(),Vector3.new(.7,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Sphere"))
  601. local p1 = Part(p1,CFrame.new(-.625,0,0)*CFrame.Angles(0,0,-1)*CFrame.new(-.95,0,0),CFrame.new(),Vector3.new(1.9,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  602. Part(p1,CFrame.new(-.95,0,0),CFrame.new(),Vector3.new(.7,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Sphere"))
  603. local p1 = Part(p1,CFrame.new(-.95,0,0)*CFrame.Angles(0,0,1)*CFrame.new(-1.25,0,0),CFrame.new(),Vector3.new(2.5,.7,.7),pipe,piperef,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  604. local p = Part(p1,CFrame.new(-.3,0,-.01),CFrame.new(),Vector3.new(1.5,1,1),pipe2,pipe2ref,0,Mesh("SpecialMesh",Vector3.new(1,.8,.8),"Cylinder"),"DiamondPlate")
  605. Part(p,CFrame.new(.6,0,0),CFrame.new(),Vector3.new(.15,.9,.9),pipe3,pipe3ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  606. Part(p,CFrame.new(-.6,0,0),CFrame.new(),Vector3.new(.15,.9,.9),pipe3,pipe3ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  607. Part(p,CFrame.new(0,0,-.65),CFrame.new(),Vector3.new(1.3,.3,.5),pipe3,pipe3ref,0)
  608. Part(p1,CFrame.new(-1.25,0,0),CFrame.new(),Vector3.new(.15,.65,.65),pipe3,pipe3ref,0,Mesh("SpecialMesh",Vector3.new(1,1,1),"Cylinder"))
  609. local p = Part(p1,CFrame.new(-1.35,0,0)*CFrame.Angles(math.pi/2,0,math.pi/2),CFrame.new(),Vector3.new(1,1,1),pipe3,pipe3ref,0,Mesh("SpecialMesh",Vector3.new(.5,2,.5),"FileMesh","rbxassetid://16659502"))
  610. local firer = Instance.new("Fire",p)
  611. local lightr = Instance.new("PointLight",p)
  612.  
  613.  
  614. cancollide = false
  615. local s = Part(main,CFrame.new(1.05,3,-2.7)*CFrame.Angles(-.5,0,0)*CFrame.new(0,0,.75),CFrame.new(),Vector3.new(.3,.3,1.5),body,bodyref,0)
  616. local s = Part(s,CFrame.new(0,.15,.75)*CFrame.Angles(.55,0,0)*CFrame.new(0,-.15,1.5),CFrame.new(),Vector3.new(.299,.3,3),body,bodyref,0)
  617. local s = Part(s,CFrame.new(0,.15,1.5)*CFrame.Angles(1.05,0,0)*CFrame.new(0,-.15,1),CFrame.new(),Vector3.new(.3,.3,2),body,bodyref,0)
  618. Part(s,CFrame.new(0,0,.75),CFrame.new(),Vector3.new(.4,.4,.4),pipe3,pipe3ref,0)
  619.  
  620.  
  621. local s = Part(main,CFrame.new(-1.05,3,-2.7)*CFrame.Angles(-.5,0,0)*CFrame.new(0,0,.75),CFrame.new(),Vector3.new(.3,.3,1.5),body,bodyref,0)
  622. local s = Part(s,CFrame.new(0,.15,.75)*CFrame.Angles(.55,0,0)*CFrame.new(0,-.15,1.5),CFrame.new(),Vector3.new(.299,.3,3),body,bodyref,0)
  623. local s = Part(s,CFrame.new(0,.15,1.5)*CFrame.Angles(1.05,0,0)*CFrame.new(0,-.15,1),CFrame.new(),Vector3.new(.3,.3,2),body,bodyref,0)
  624. Part(s,CFrame.new(0,0,.75),CFrame.new(),Vector3.new(.4,.4,.4),pipe3,pipe3ref,0)
  625. cancollide = true
  626.  
  627.  
  628. local hp = Instance.new("Part",m)
  629. hp.Anchored = true
  630. hp.TopSurface,hp.BottomSurface =0,0
  631. hp.BrickColor = BrickColor.new("Dark red")
  632. hp.FormFactor = "Custom"
  633. hp.CanCollide = false
  634. hp.Size = Vector3.new(8,1.5,.5)
  635.  
  636.  
  637. local hptop = hp:Clone()
  638. hptop.Parent = m
  639. hptop.BrickColor = BrickColor.new("Dark green")
  640.  
  641.  
  642. firer.Size = .01
  643. firer.Heat = 1000
  644. firel.Size = .01
  645. firel.Heat = 1000
  646.  
  647.  
  648. local hm = Instance.new("Sound",sg)
  649. hm.SoundId = "rbxassetid://131864673"
  650. hm.Pitch = .8
  651.  
  652.  
  653. --[[coroutine.wrap(function()
  654. wait(.2)
  655. while wait(.6) do
  656. ps.Pitch = -ps.Pitch
  657. ps2.Pitch = -ps2.Pitch
  658. end
  659. end)()]]
  660.  
  661.  
  662. local bvel = Instance.new("BodyVelocity",main)
  663. bvel.maxForce = Vector3.new()
  664. bvel.velocity = Vector3.new()
  665. bvel.P = 5000
  666.  
  667.  
  668. local bgyro = Instance.new("BodyGyro",main)
  669. bgyro.maxTorque = Vector3.new()
  670. bgyro.cframe = main.CFrame
  671. bgyro.D = 800
  672.  
  673.  
  674. do
  675. local vecs = {}
  676. for i,v in pairs(Enum.NormalId:GetEnumItems()) do
  677. table.insert(vecs,Vector3.FromNormalId(v))
  678. end
  679. function getSide(h,r)
  680.  
  681. local ob = h.CFrame:pointToObjectSpace(r)
  682. if h:IsA("Part") and h.Shape == Enum.PartType.Ball then
  683. return (r-h.Position).unit
  684. elseif h:IsA("Part") and h.Shape == Enum.PartType.Cylinder then
  685. if isClose(math.abs(ob.y),h.Size.Y/2) then -- top
  686. return h.CFrame:vectorToWorldSpace((ob*Vector3.new(0,1,0)).unit)
  687. else
  688. return h.CFrame:vectorToWorldSpace(CFrame.new(Vector3.new(),ob*Vector3.new(1,0,1)).lookVector)
  689. end
  690. elseif h:IsA("WedgePart") then
  691. vecs = {Vector3.new(0,-1,0),Vector3.new(1,0,0),Vector3.new(-1,0,0),Vector3.new(0,0,1)}
  692. end
  693. for i,v in pairs(vecs) do
  694. if (ob*v/(h.Size/2)*v):isClose(v) then
  695. return h.CFrame:vectorToWorldSpace(v)
  696. end
  697. end
  698. if h:IsA("WedgePart") then
  699. return h.CFrame:vectorToWorldSpace(Vector3.new(0,h.Size.Z,h.Size.Y).unit)
  700. end
  701. end
  702. end
  703.  
  704.  
  705. local function Raycast(ray,ign)
  706. local ign = ign or {m,char}
  707. local h,p = workspace:FindPartOnRayWithIgnoreList(ray,ign)
  708. if h and not h.CanCollide then
  709. table.insert(ign,h)
  710. return Raycast(ray,ign)
  711. else
  712. return h,p
  713. end
  714. end
  715.  
  716.  
  717. local cam = workspace.CurrentCamera
  718. local vehicleOn = true
  719. local lastVehicleOn = false
  720. local acc = 0
  721. local maxSpeed = 180
  722. local spd = 0
  723. local jump = false
  724.  
  725.  
  726. local kd = {}
  727. local function isDown(k)
  728. return kd[k:byte()] and 1 or 0
  729. end
  730. mouse.KeyDown:connect(function(k)
  731. kd[k:byte()] = true
  732. if k == "f" then
  733. vehicleOn = not vehicleOn
  734. elseif k == "r" then
  735. -- hval.Value = 0
  736. end
  737. end)
  738. mouse.KeyUp:connect(function(k)
  739. kd[k:byte()] = false
  740. end)
  741.  
  742.  
  743. mouse.Button1Down:connect(function()
  744. b1d = true
  745. end)
  746. mouse.Button1Up:connect(function()
  747. b1d = false
  748. end)
  749.  
  750. mouse.KeyDown:connect(function(key)
  751. key=key:lower()
  752. if key == "e" then
  753. b2d = true
  754. end
  755. if key == "q" then
  756. b2d = false
  757. end
  758. end)
  759.  
  760.  
  761.  
  762. hum.Changed:connect(function()
  763. if hum.Jump then
  764. jump = true
  765. hum.Jump = false
  766. hum.Sit = true
  767. end
  768. end)
  769.  
  770. warn("I had to change some controls, so here")
  771. warn("if q then b2d = false")
  772. warn("if e then b2d = true")
  773.  
  774.  
  775. local fire = {}
  776.  
  777.  
  778. mouse.TargetFilter = m
  779.  
  780.  
  781. local t,delta = tick(),0
  782. local smokers = {}
  783.  
  784.  
  785. local guntimer = 0
  786. local scon;
  787. local lastjump = 0
  788. scon = step:connect(function()
  789.  
  790.  
  791. local now = tick()
  792. delta,t = now-t,now
  793.  
  794.  
  795. if hval.Value <= 0 then
  796. game:service'Debris':AddItem(m,5)
  797. coroutine.wrap(function()
  798. bvel:Destroy()
  799. local parts = {}
  800. local function a(b)
  801. for i,v in pairs(b:GetChildren()) do
  802. if v:IsA("BasePart") then
  803. table.insert(parts,v)
  804. end
  805. a(v)
  806. end
  807. end
  808. a(m)
  809. bvel:Destroy()
  810. bgyro:Destroy()
  811. local aTouched = false
  812. for i,v in pairs(parts) do
  813. v.Touched:connect(function()
  814. if aTouched then return end
  815. aTouched = true
  816. local exp = Instance.new("Explosion",workspace)
  817. exp.Position = v.Position
  818. exp.BlastRadius = 0
  819. exp.BlastPressure = .5
  820. m:BreakJoints()
  821. char:BreakJoints()
  822. for i,x in pairs(m:GetChildren()) do
  823. if x:IsA("BasePart") and v ~= x then
  824. local diff = (x.Position-v.Position)
  825. x.Velocity = x.Velocity + diff.unit * diff.magnitude/0.25/v:GetMass()
  826. end
  827. end
  828. script.Disabled = true
  829. end)
  830. end
  831. wait(5)
  832. script.Disabled = true
  833. end)()
  834. scon:disconnect()
  835. return
  836. else
  837. hp.Transparency = hval.Value == 100 and math.min(1,hp.Transparency+.05) or math.max(0,hp.Transparency-.05)
  838. hptop.Transparency = hp.Transparency
  839. hp.CFrame = CFrame.new(head.Position+Vector3.new(0,9,0))*CFrame.Angles(0,(tick()/2)%(math.pi*2),0)
  840. hptop.Size = Vector3.new(hval.Value/100*(hp.Size.X+.05),hp.Size.Y+.1,hp.Size.Z+.1)
  841. hptop.CFrame = hp.CFrame * CFrame.new(-hp.Size.X/2-.025+hptop.Size.X/2,0,0)
  842. end
  843.  
  844.  
  845. if b1d and vehicleOn then
  846. guntimer = guntimer + delta
  847. if guntimer > .1 then
  848. t1s:Play()
  849. t1s.Pitch = 1.5 + (math.random()-.5)*.1
  850. guntimer = guntimer - .1
  851. local b = Instance.new("Part",m)
  852. b.Anchored = true
  853. b.FormFactor = "Custom"
  854. b.TopSurface,b.BottomSurface = 0,0
  855. b.CanCollide = false
  856. b.BrickColor = BrickColor.new("Bright yellow")
  857. b.Size = Vector3.new(.2,.2,.8)
  858. local sm = Instance.new("SpecialMesh",b)
  859. sm.MeshId = "rbxassetid://2697549"
  860. sm.Scale = Vector3.new(.5,.5,.25)
  861. local orig = t1.CFrame*CFrame.new(.5,0,0)*CFrame.Angles(0,-math.pi/2,0)
  862. local vel = (mouse.Hit.p-orig.p).unit*250 + main.Velocity*delta
  863. b.CFrame = orig
  864. coroutine.wrap(function()
  865. local t = tick()
  866. while true do
  867. step:wait()
  868. local n = tick()
  869. local d,t = n-t,n
  870. local ocf = b.CFrame
  871. local h,r = Raycast(Ray.new(ocf.p,vel*d),{char,m})
  872. if h then
  873. b:Destroy()
  874. local hit = false
  875. local hp = h.Parent:FindFirstChild("hp") or h.Parent.Parent:FindFirstChild("hp")
  876. if hp and hp:IsA("NumberValue") then
  877. hp.Value = hp.Value - 3
  878. hit = "rbxassetid://142082170"
  879. end
  880. local hp = h.Parent:FindFirstChild("Humanoid") or h.Parent.Parent:FindFirstChild("Humanoid")
  881. if hp and hp:IsA("Humanoid") then
  882. hp.Health = hp.Health - 3
  883. hit = "rbxassetid://133758570"
  884. end
  885. if hit then
  886. hm:Play()
  887. local sp = Instance.new("Part",m)
  888. sp.FormFactor = "Custom"
  889. sp.Size = Vector3.new()
  890. sp.Transparency = 1
  891. sp.Anchored = true
  892. sp.CanCollide = false
  893. sp.CFrame = CFrame.new(r)
  894. local s = Instance.new("Sound",sp)
  895. s.SoundId = hit
  896. s.Volume = 1
  897. s.Pitch = 1.1+math.random()*.2
  898. wait()
  899. s:Play()
  900. game:service'Debris':AddItem(sp,5)
  901. end
  902. break
  903. end
  904. b.CFrame = CFrame.new(ocf.p+vel*d,ocf.p+vel*d*2)
  905. sm.Scale = Vector3.new(.5-vel.magnitude*d/100,.5-vel.magnitude*d/100,vel.magnitude*d/3)
  906. vel = vel - Vector3.new(0,4*d,0)
  907. if ocf.Y < -100 then
  908. b:Destroy()
  909. break
  910. end
  911. end
  912. end)()
  913. end
  914. else
  915. guntimer = 0
  916. end
  917.  
  918.  
  919. local mcfr = main.CFrame
  920. local mpos = mcfr.p
  921.  
  922.  
  923. local raydir = Vector3.new(0,-100,0)--mcfr:vectorToWorldSpace(Vector3.new(0,-100,0))
  924.  
  925.  
  926. local dhit,dray = Raycast(Ray.new(mpos,raydir),{char,m})
  927. local diff = dray-mpos
  928.  
  929.  
  930. local rays = {
  931. tip = Ray.new((mcfr*CFrame.new(0,0,-11.5)).p,raydir),
  932. Ray.new((mcfr*CFrame.new(7,0,-11)).p,raydir),
  933. Ray.new((mcfr*CFrame.new(-7,0,-11)).p,raydir),
  934. Ray.new((mcfr*CFrame.new(1,0,-10.5)).p,raydir),
  935. Ray.new((mcfr*CFrame.new(-1,0,-10.5)).p,raydir),
  936. Ray.new((mcfr*CFrame.new(2.5,0,-6)).p,raydir),
  937. Ray.new((mcfr*CFrame.new(-2.5,0,-6)).p,raydir),
  938. rtip = Ray.new((mcfr*CFrame.new(10.5,0,-3)).p,raydir),
  939. ltip = Ray.new((mcfr*CFrame.new(-10.5,0,-3)).p,raydir),
  940. rprop = Ray.new((mcfr*CFrame.new(6.5,0,-3)).p,raydir),
  941. lprop = Ray.new((mcfr*CFrame.new(-6.5,0,-3)).p,raydir),
  942. Ray.new((mcfr*CFrame.new(2.5,0,-3)).p,raydir),
  943. Ray.new((mcfr*CFrame.new(-2.5,0,-3)).p,raydir),
  944. Ray.new((mcfr*CFrame.new(6.5,0,-1)).p,raydir),
  945. Ray.new((mcfr*CFrame.new(-6.5,0,-1)).p,raydir),
  946. Ray.new((mcfr*CFrame.new(2.5,0,4)).p,raydir),
  947. Ray.new((mcfr*CFrame.new(-2.5,0,4)).p,raydir),
  948. Ray.new((mcfr*CFrame.new(2.5,0,2)).p,raydir),
  949. Ray.new((mcfr*CFrame.new(-2.5,0,2)).p,raydir),
  950. }
  951. for i,v in pairs(rays) do
  952. local h,r = Raycast(v,{char,m})
  953. local df = r-v.Origin
  954. if df.Y > diff.Y then
  955. diff = df
  956. end
  957. rays[i] = {r=r,d=df,h=h}
  958. end
  959.  
  960. local moving = false
  961. local movdir = Vector3.new()
  962. local hoverHeight = 7 + math.sin(now)/2
  963. local vel = Vector3.new(0,(hoverHeight+diff.Y)*3,0)
  964. if isDown'w'+isDown's'+isDown'd'+isDown'a' > 0 then
  965. moving = true
  966. movdir = Vector3.new(isDown'd'-isDown'a',0,isDown's'-isDown'w')
  967. if movdir.magnitude < .001 then
  968. moving = false
  969. else
  970. movdir = movdir.unit
  971. end
  972. end
  973. bgyro.maxTorque = Vector3.new(1,1,1)*1e5
  974.  
  975.  
  976. if vehicleOn then
  977. if not lastVehicleOn or not lastDown then
  978. lastDown = tick()
  979. end
  980. if not lastVehicleOn then
  981. local ray = rays.rprop
  982. for a,ray in pairs({rays.rprop,rays.lprop}) do
  983. if ray.h and -ray.d.Y < 5 then
  984. local x = a==1 and 1 or -1
  985. local am = 0
  986. for i=math.pi/4*x,x*(-math.pi-math.pi/4),x*-math.pi/8 do
  987. local p = Instance.new("Part",m)
  988. p.Anchored = true
  989. p.Transparency = 1
  990. p.CanCollide = false
  991. p.FormFactor = "Custom"
  992. p.Size = Vector3.new()
  993. local smoke = Instance.new("Smoke",p)
  994. smoke.Color = Color3.new(.5,.5,.5)--Color3.new(lerp(.5,ray.h.Color.r,.8),lerp(.5,ray.h.Color.g,.8),lerp(.5,ray.h.Color.b,.8))
  995. smoke.Size = .1
  996. smoke.Opacity = .04
  997. smoke.RiseVelocity = 10
  998. p.CFrame = CFrame.new(ray.r,ray.r+mcfr.lookVector*Vector3.new(1,0,1))*CFrame.Angles(math.pi/2,0,i+.2*x)*CFrame.new(0,2.5,0)
  999. local add = am/13
  1000. if add > .5 then
  1001. add = 1-add
  1002. end
  1003. am = am + 1
  1004. game.Debris:AddItem(p,.75+add*14)
  1005. end
  1006. end
  1007. end
  1008. end
  1009. local ovel = main.CFrame:vectorToObjectSpace(main.Velocity)
  1010.  
  1011. local xrot = math.max(-1,math.min(1,ovel.Z/maxSpeed*2))*.25
  1012. local zrot = math.max(-1,math.min(1,-ovel.X/maxSpeed*2))*.25
  1013. local xadd,zadd = 0,0
  1014. if rays.tip.h and dhit and (-rays.tip.d.Y < hoverHeight+10 or -diff.Y < hoverHeight+10) then
  1015. local ydiff = rays.tip.r.Y-dray.Y
  1016. --print(ydiff)
  1017. xadd = math.max(-.75,math.min(.75,math.asin(ydiff/11.5)))
  1018. xrot = xrot*math.cos(xadd) + xadd
  1019. --print("x",movdir,xadd)
  1020. movdir = CFrame.Angles(xadd,0,0)*movdir
  1021. --print("x2",movdir)
  1022. end
  1023.  
  1024.  
  1025. if rays.lprop.h and rays.rprop.h and rays.lprop.h == rays.rprop.h and (-rays.lprop.d.Y < hoverHeight+10 or -rays.rprop.d.Y < hoverHeight+10) then
  1026. local xdiff = rays.rprop.r.Y-rays.lprop.r.Y
  1027. zadd = math.max(-.75,math.min(.75,math.asin(xdiff/22)))
  1028. zrot = zrot*math.cos(zadd) + zadd
  1029. --print("z",movdir,zadd)
  1030. movdir = CFrame.Angles(0,0,zadd)*movdir
  1031. --print("z2",movdir)
  1032. end
  1033. --[[
  1034. if movdir.magnitude > .001 then
  1035. local p = Instance.new("Part",m)
  1036. p.Anchored = true
  1037. p.FormFactor = "Custom"
  1038. p.CanCollide = false
  1039. p.FrontSurface = "Hinge"
  1040. p.Size = Vector3.new(1,1,3)
  1041. p.CFrame = CFrame.new(head.Position+Vector3.new(0,5,0),head.Position+Vector3.new(0,5,0)+CFrame.new(cam.CoordinateFrame.p,cam.CoordinateFrame.p+cam.CoordinateFrame.lookVector*Vector3.new(1,0,1)):vectorToWorldSpace(movdir))
  1042. game.Debris:AddItem(p,.1)
  1043. end
  1044. ]]
  1045. local windup = math.min(1,(tick()-lastDown))
  1046.  
  1047.  
  1048. if windup < .25 then
  1049. moving = false
  1050. elseif windup < 1 then
  1051. bgyro.maxTorque = Vector3.new(1,1,1)*50000
  1052. end
  1053. local ldir = windup >= .25 and cam.CoordinateFrame.lookVector*Vector3.new(1,0,1) or main.CFrame.lookVector*Vector3.new(1,0,1)
  1054. bgyro.cframe = CFrame.new(main.CFrame.p,main.CFrame.p+ldir)*CFrame.Angles(xrot,0,zrot)
  1055. proplw.C1 = proplw.C1 * CFrame.Angles(0,windup*-(.8+main.Velocity.magnitude/maxSpeed*.75)*(moving and 1.5 or 1)+math.random()*.05,0)
  1056. proprw.C1 = proprw.C1 * CFrame.Angles(0,windup*(.8+main.Velocity.magnitude/maxSpeed*.75)*(moving and 1.5 or 1)+math.random()*.05,0)
  1057.  
  1058.  
  1059. local odir = main.CFrame:vectorToObjectSpace(bgyro.cframe.lookVector)
  1060. firer.Enabled = ovel.Z < -1 or odir.X < -.1
  1061. firel.Enabled = ovel.Z < -1 or odir.X > .1
  1062. bvel.maxForce = Vector3.new(70000,-diff.Y < hoverHeight+1+math.max(0,-main.Velocity.Y*delta*40) and 400000 or 40000,70000)
  1063.  
  1064.  
  1065. windup = windup + main.Velocity.magnitude/maxSpeed*.35*(moving and 1.5 or 1)
  1066. ps.Volume = windup*.07
  1067. ps2.Volume = ps.Volume
  1068. ps.Pitch = ps.Pitch
  1069. ps2.Pitch = ps2.Pitch
  1070. else
  1071. if lastVehicleOn or not lastUp then
  1072. lastUp = tick()
  1073. end
  1074. firel.Enabled,firer.Enabled = false,false
  1075. bvel.maxForce = Vector3.new(40000,-diff.Y > 1 and 1e5 or 0,40000)
  1076. vel = Vector3.new(0,-100-((tick()-lastUp)*9.81*10)^2,0)
  1077. bgyro.cframe = clerp(bgyro.cframe,CFrame.new(mpos,mpos+mcfr.lookVector*Vector3.new(1,0,1)),.2)
  1078.  
  1079.  
  1080. local windup = 1-math.min(1,(tick()-lastUp)/5)
  1081. vel = Vector3.new(0,(1-windup)*-25,0)
  1082. proplw.C1 = proplw.C1 * CFrame.Angles(0,-.8*windup,0)
  1083. proprw.C1 = proprw.C1 * CFrame.Angles(0,.8*windup,0)
  1084. ps.Volume = windup*.07
  1085. ps2.Volume = ps.Volume
  1086. ps.Pitch = ps.Pitch
  1087. ps2.Pitch = ps2.Pitch
  1088.  
  1089.  
  1090. moving = false
  1091.  
  1092.  
  1093. if tick()-lastUp > 2 then
  1094. hval.Value = math.min(100,hval.Value + .1)
  1095. end
  1096. end
  1097.  
  1098.  
  1099. if moving then
  1100. local od = movdir
  1101. movdir = CFrame.new(cam.CoordinateFrame.p,cam.CoordinateFrame.p+cam.CoordinateFrame.lookVector*Vector3.new(1,0,1)):vectorToWorldSpace(movdir*Vector3.new(1,.25,1))
  1102.  
  1103. if movdir.magnitude < 0.001 or tostring(movdir):lower():find("nan") then
  1104. moving = false
  1105. --print(od)
  1106. else
  1107. movdir = movdir.unit
  1108. acc = acc + delta*70
  1109. spd = math.min(maxSpeed,spd + acc)
  1110. vel = vel + movdir*spd
  1111. end
  1112. end
  1113. if not moving then
  1114. spd = 0
  1115. acc = 0
  1116. end
  1117.  
  1118.  
  1119. bvel.velocity = vel
  1120. if jump then
  1121. if vehicleOn and -diff.Y < hoverHeight + 1 and tick()-lastjump > 2 then
  1122. tor.Velocity = tor.Velocity + Vector3.new(0,110,0)
  1123. lastjump = tick()
  1124. end
  1125. jump = false
  1126. end
  1127. lightr.Range = 5+math.sin(tick()*50)
  1128. lightl.Range = 5+math.cos(tick()*50)
  1129.  
  1130.  
  1131. lightr.Color = firer.Color
  1132. lightl.Color = firel.Color
  1133.  
  1134.  
  1135. lightr.Enabled = firer.Enabled
  1136. lightl.Enabled = firel.Enabled
  1137. lastVehicleOn = vehicleOn
  1138. end)
  1139.  
  1140.  
  1141. char.AncestryChanged:connect(function()
  1142. m:Destroy()
  1143. scon:disconnect()
  1144. end)
  1145.  
  1146.  
  1147. end
  1148. return _G.mantisReload()
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top