Prephy

toolpack

May 17th, 2021 (edited)
692
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function hamburger()
  2. local Tool = Instance.new("Tool") Tool.TextureId='rbxassetid://5640902458'
  3. local Handle = Instance.new("Part",Tool) Handle.Name='Handle' Handle.Size=Vector3.new(1.176, 0.797, 1.25) local CRA = Instance.new("Smoke",Handle)
  4. CRA.Color=Color3.new(0, 1, 0) CRA.Size=.1 CRA.Opacity=.1 CRA.RiseVelocity=.1
  5. handlemesh = Instance.new("SpecialMesh",Handle) handlemesh.MeshId='rbxassetid://2642591171' handlemesh.TextureId='rbxassetid://1243440181'
  6. Tool.GripUp=Vector3.new(0,1,0) Tool.GripForward=Vector3.new(-1,0,0) Tool.GripPos=Vector3.new(0.5,-0.1,0) Tool.GripRight=Vector3.new(0,0,-1)
  7. Tool.Parent=owner.Backpack
  8.  
  9.  
  10.  
  11. enabled = true
  12.  
  13.  
  14.  
  15.  
  16. function onActivated()
  17.     if not enabled  then
  18.         return
  19.     end
  20.  
  21.     enabled = false
  22.     Tool.GripForward = Vector3.new(-.981, .196, 0)
  23.     Tool.GripPos = Vector3.new(-.5, -0.6, -1.5)
  24.     Tool.GripRight = Vector3.new(0, -0, -1)
  25.     Tool.GripUp = Vector3.new(0.196, .981, 0)
  26.    
  27.     local i_must_now_eat = Handle:FindFirstChild('Crazy')
  28.     if i_must_now_eat then
  29.         i_must_now_eat:Play()
  30.     else
  31.         local eating = Instance.new("Sound",Handle) eating.Name='Crazy' eating.SoundId='rbxassetid://131314452' eating.Volume=4 eating:Play()
  32.     end
  33.    
  34.  
  35.     wait(.2)
  36.     Tool.Parent:BreakJoints()
  37.     wait(.4)
  38.     Tool.Parent=workspace
  39.     wait(.2)
  40.  
  41.  
  42.     Tool.GripForward = Vector3.new(-1, 0, 0)
  43.     Tool.GripPos = Vector3.new(-.5, -.1, 0)
  44.     Tool.GripRight = Vector3.new(0, 0, 1)
  45.     Tool.GripUp = Vector3.new(0,1,0)
  46.  
  47.  
  48.     enabled = true
  49.  
  50. end
  51.  
  52. function Unequipped()
  53.     local throws_away = Handle:FindFirstChild('CrAZy')
  54.     if throws_away then
  55.         --throws_away:Pause()
  56.     end
  57. end
  58.  
  59. function onEquipped()
  60.     local CRRAZY = Handle:FindFirstChild('CrAZy')
  61.     if CRRAZY then
  62.         CRRAZY:Play()
  63.     else
  64.         local ham = Instance.new("Sound",Handle) ham.Name='CrAZy' ham.SoundId='rbxassetid://5752104931' ham.Volume=2 ham:Play()
  65.         local Crazy = Instance.new("FlangeSoundEffect",ham) Crazy.Mix=1 Crazy.Rate=5 Crazy.Depth=0.703
  66.     end
  67. end
  68.  
  69. Tool.Activated:connect(onActivated)
  70. Tool.Equipped:connect(onEquipped)
  71. Tool.Unequipped:connect(Unequipped)
  72. end
  73.  
  74. function cola()
  75. local Tool = Instance.new("Tool",owner.Backpack)
  76. Tool.TextureId="http://www.roblox.com/asset/?id=6049537884"
  77. Tool.Name="Cola"
  78. local COLA = Instance.new("Part",Tool)
  79. COLA.Name= "Handle"
  80. COLA.Size = Vector3.new(1, 1.2, 1)
  81. local mesh = Instance.new("SpecialMesh",COLA)
  82. mesh.MeshId = "http://www.roblox.com/asset/?id=28501599"
  83. mesh.TextureId = "http://www.roblox.com/asset/?id=34136088"
  84.  
  85.  
  86. enabled = true
  87.  
  88.  
  89. function onActivated()
  90.     if not enabled  then
  91.         return
  92.     end
  93.  
  94.     enabled = false
  95.     Tool.GripForward = Vector3.new(0,-.759,-.651)
  96.     Tool.GripPos = Vector3.new(1.5,-.5,.3)
  97.     Tool.GripRight = Vector3.new(1,0,0)
  98.     Tool.GripUp = Vector3.new(0,.651,-.759)
  99.  
  100.    
  101.     local dr = COLA:FindFirstChild("Drink")
  102.     if dr then
  103.         dr:Play()
  104.     else
  105.         local drinks = Instance.new("Sound",COLA) drinks.SoundId='http://www.roblox.com/asset/?id=10722059' drinks.Name='Drink'
  106.         drinks:Play()
  107.     end
  108.  
  109.     wait(3)
  110.  
  111.     local h = Tool.Parent:FindFirstChild("Humanoid")
  112.     if (h ~= nil) then
  113.         if (h.MaxHealth > h.Health + 5) then
  114.             h.Health = h.Health + 5
  115.         else   
  116.             h.Health = h.MaxHealth
  117.         end
  118.     end
  119.  
  120.     Tool.GripForward = Vector3.new(-.976,0,-0.217)
  121.     Tool.GripPos = Vector3.new(0.03,0,0)
  122.     Tool.GripRight = Vector3.new(.217,0,-.976)
  123.     Tool.GripUp = Vector3.new(0,1,0)
  124.  
  125.     enabled = true
  126.  
  127. end
  128.  
  129. function onEquipped()
  130.     local dre = COLA:FindFirstChild("open")
  131.     if dre then
  132.         dre:Play()
  133.     else
  134.         local open = Instance.new("Sound",COLA) open.SoundId='http://www.roblox.com/asset/?id=10721950'
  135.         open:Play() open.Name='open'
  136.     end
  137. end
  138.  
  139. Tool.Activated:connect(onActivated)
  140. Tool.Equipped:connect(onEquipped)
  141.  
  142. end
  143.  
  144. function rocket()
  145. --ROBLOX's rocket launcher tool remade and converted by Protofer_S, feel free to use it!
  146.  
  147.  
  148.  
  149. local tool = Instance.new("Tool")
  150. tool.Archivable=true
  151. tool.CanBeDropped=false tool.RequiresHandle=true
  152. local handle = Instance.new("Part",tool)  handle.Name='Handle'
  153. handle.Size=Vector3.new(4.92, 0.74, 0.84)
  154. tool.GripForward=Vector3.new(1,0,0)
  155. tool.GripPos=Vector3.new(0.7, 0, -0.5)
  156. tool.GripRight=Vector3.new(0, -1, 0)
  157. tool.GripUp=Vector3.new(0,0,1)
  158.  
  159. print('Made by Protofer_S')
  160.  
  161. local handle_mesh = Instance.new("SpecialMesh",handle) handle_mesh.MeshId='rbxasset://fonts/rocketlauncher.mesh'
  162. handle_mesh.TextureId='rbxasset://textures/rocketlaunchertex.png' handle_mesh.Scale=Vector3.new(0.75, 0.75, 0.75)
  163. tool.TextureId='http://www.roblox.com/asset/?id=90021376'
  164.  
  165. tool.Parent=owner.Backpack
  166.  
  167.  
  168.  
  169.  
  170.  
  171. function functions()
  172.  
  173.     NLS([[
  174.  
  175.    
  176.     local Tool = script.Parent
  177.  
  178. local Remote = Tool:WaitForChild("MouseLoc")
  179.  
  180. local Mouse = game.Players.LocalPlayer:GetMouse()
  181.  
  182. function Remote.OnClientInvoke()
  183.     return Mouse.Hit.p
  184. end
  185.    
  186.    
  187.    
  188.    
  189.    
  190.    
  191.    
  192.     ]],handle.Parent)
  193.  
  194.     NLS([[
  195.    
  196.     local MOUSE_ICON = 'rbxasset://textures/GunCursor.png'
  197. local RELOADING_ICON = 'rbxasset://textures/GunWaitCursor.png'
  198.  
  199. local Tool = script.Parent
  200.  
  201. local Mouse = nil
  202.  
  203. local function UpdateIcon()
  204.     if Mouse then
  205.         Mouse.Icon = Tool.Enabled and MOUSE_ICON or RELOADING_ICON
  206.     end
  207. end
  208.  
  209. local function OnEquipped(mouse)
  210.     Mouse = mouse
  211.     UpdateIcon()
  212. end
  213.  
  214. local function OnChanged(property)
  215.     if property == 'Enabled' then
  216.         UpdateIcon()
  217.     end
  218. end
  219.  
  220. Tool.Equipped:Connect(OnEquipped)
  221. Tool.Changed:Connect(OnChanged)
  222.  
  223.    
  224.    
  225.    
  226.    
  227.     ]],handle.Parent)
  228.  
  229.  
  230. end
  231.  
  232. functions()
  233. -----------------
  234. --| Constants |--
  235. -----------------
  236.  
  237. local GRAVITY_ACCELERATION = workspace.Gravity
  238.  
  239. local RELOAD_TIME = 1 -- Seconds until tool can be used again
  240. local ROCKET_SPEED = 100 -- Speed of the projectile
  241.  
  242. local ROCKET_PART_SIZE = Vector3.new(1,1,4)
  243. --local MISSILE_MESH_ID = 'http://www.roblox.com/asset/?id=2251534'
  244. --local MISSILE_MESH_SCALE = Vector3.new(0.35, 0.35, 0.25)
  245.  
  246. -----------------
  247. --| Variables |--
  248. -----------------
  249.  
  250. local DebrisService = game:GetService('Debris')
  251. local PlayersService = game:GetService('Players')
  252.  
  253. local MyPlayer
  254.  
  255. local Tool = tool
  256. local ToolHandle = handle
  257. local MouseLoc = Instance.new("RemoteFunction",tool) MouseLoc.Name='MouseLoc'
  258.  
  259. --local RocketScript = script:WaitForChild('Rocket')
  260. --local SwooshSound = Instance.new("Sound") SwooshSound.SoundId='rbxasset://sounds/Rocket whoosh 01.wav' SwooshSound.Looped=true
  261. --local BoomSound = Instance.new("Sound") BoomSound.PlayOnRemove=true BoomSound.Volume=0.7 BoomSound.SoundId='rbxasset://sounds/Rocket whoosh 01.wav'
  262.  
  263. --NOTE: We create the rocket once and then clone it when the player fires
  264. local Rocket = Instance.new('FlagStand') do
  265.     -- Set up the rocket part
  266.     Rocket.Name = 'Rocket'
  267.     Rocket.FormFactor = Enum.FormFactor.Custom --NOTE: This must be done before changing Size
  268.     Rocket.Size = ROCKET_PART_SIZE
  269.     Rocket.CanCollide =  true--false
  270.  
  271.     -- Add the mesh
  272.     --local mesh = Instance.new('SpecialMesh', Rocket)
  273.     --mesh.MeshId = MISSILE_MESH_ID
  274.     --mesh.Scale = MISSILE_MESH_SCALE
  275.  
  276.     -- Add fire
  277.     --local fire = Instance.new('Fire', Rocket)
  278.     --fire.Heat = 5
  279.     --fire.Size = 2
  280.  
  281.     -- Add a force to counteract gravity
  282.     local bodyForce = Instance.new('BodyForce', Rocket)
  283.     bodyForce.Name = 'Antigravity'
  284.     bodyForce.Force = Vector3.new(0, Rocket:GetMass() * GRAVITY_ACCELERATION, 0)
  285.  
  286.     -- Clone the sounds and set Boom to PlayOnRemove
  287.     local swooshSoundClone = Instance.new("Sound") swooshSoundClone.SoundId='rbxasset://sounds/Rocket whoosh 01.wav' swooshSoundClone.Looped=true swooshSoundClone.Name='Swoosh' swooshSoundClone.Volume=0.7--SwooshSound:Clone()
  288.     swooshSoundClone.Parent = Rocket swooshSoundClone:Play()
  289.     local boomSoundClone =   Instance.new("Sound")  boomSoundClone.Volume=0.7 boomSoundClone.SoundId='rbxasset://sounds/collide.wav'    boomSoundClone.Name='Boom' boomSoundClone.Volume=1 --BoomSound:Clone()
  290.     boomSoundClone.PlayOnRemove = true
  291.     boomSoundClone.Parent = Rocket
  292.  
  293.     -- Attach creator tags to the rocket early on
  294.     local creatorTag = Instance.new('ObjectValue', Rocket)
  295.     creatorTag.Value = MyPlayer
  296.     creatorTag.Name = 'creator' --NOTE: Must be called 'creator' for website stats
  297.     local iconTag = Instance.new('StringValue', creatorTag)
  298.     iconTag.Value = Tool.TextureId
  299.     iconTag.Name = 'icon'
  300.  
  301.  
  302.  
  303.     function rocketfunctions(rocket)
  304.         local BLAST_RADIUS = 10 -- Blast radius of the explosion
  305.         local BLAST_FORCE = 600000 -- Amount of force applied to parts
  306.         local swoosh=rocket:waitForChild('Swoosh')
  307.         local function explode(victim)
  308.            
  309.             local beam= Instance.new("Explosion",workspace) beam.Position=rocket.Position
  310.             beam.BlastRadius = BLAST_RADIUS
  311.             beam.BlastPressure=BLAST_FORCE
  312.             beam.ExplosionType = Enum.ExplosionType.Craters
  313.             beam.Hit:Connect(function(part,distance)
  314.                
  315.                 local hum = part.Parent:FindFirstChildOfClass('Humanoid')
  316.                 if hum then
  317.                if hum.MaxHealth>110 then
  318.          hum.Health=0 hum.MaxHealth=-20
  319.            hum.Parent:BreakJoints()
  320.  
  321.        end
  322.                     local bad = hum.Parent:FindFirstChildOfClass('ForceField')
  323.                     if bad then
  324.                         bad:Destroy()
  325.                         hum.Parent:BreakJoints()
  326.                         wait(.2)
  327.                         hum:Destroy()
  328.                     end
  329.                 end
  330.             end)
  331.             swoosh:Pause()
  332.             rocket:Destroy()
  333.            
  334.            
  335.         end
  336.        
  337.        
  338.        
  339.         rocket.Touched:Connect(explode)
  340.        
  341.     end
  342.  
  343.     -- Finally, clone the rocket script and enable it
  344.     --local rocketScriptClone = RocketScript:Clone()
  345.     --rocketScriptClone.Parent = Rocket
  346.     --rocketScriptClone.Disabled = false
  347. end
  348.  
  349. -----------------
  350. --| Functions |--
  351. -----------------
  352.  
  353. local function OnActivated()
  354.     local myModel = MyPlayer.Character
  355.     if Tool.Enabled and myModel and myModel:FindFirstChildOfClass("Humanoid") and myModel.Humanoid.Health > 0 then
  356.         Tool.Enabled = false
  357.         local Pos = MouseLoc:InvokeClient(MyPlayer)
  358.         -- Create a clone of Rocket and set its color
  359.         local rocketClone = Rocket:Clone()
  360.         rocketfunctions(rocketClone)
  361.         DebrisService:AddItem(rocketClone, 30)
  362.         rocketClone.BrickColor = BrickColor.new("Bright blue")
  363.  
  364.         -- Position the rocket clone and launch!
  365.         local spawnPosition = (ToolHandle.CFrame * CFrame.new(5, 0, 0)).p
  366.         rocketClone.CFrame = CFrame.new(spawnPosition, Pos) --NOTE: This must be done before assigning Parent
  367.         rocketClone.Velocity = rocketClone.CFrame.lookVector * ROCKET_SPEED --NOTE: This should be done before assigning Parent
  368.         rocketClone.Parent = workspace
  369.         rocketClone:SetNetworkOwner(nil)
  370.         rocketClone.Material=Enum.Material.Plastic
  371.  
  372.         wait(RELOAD_TIME)
  373.  
  374.         Tool.Enabled = true
  375.     end
  376. end
  377.  
  378. function OnEquipped()
  379.     MyPlayer = PlayersService:GetPlayerFromCharacter(Tool.Parent)
  380. end
  381.  
  382. --------------------
  383. --| Script Logic |--
  384. --------------------
  385.  
  386.  
  387.  
  388.  
  389.  
  390. tool.Equipped:Connect(OnEquipped)
  391. tool.Activated:Connect(OnActivated)
  392.  
  393. end
  394.  
  395.  
  396.  
  397. hamburger()
  398. cola()
  399. rocket()
  400.  
RAW Paste Data