TheoDev_

btools

Jan 3rd, 2018
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.54 KB | None | 0 0
  1. --https://pastebin.com/raw/nfNvBJqg--
  2. --fe cafe hammertool script only works for Chicken Express Restaurant!--
  3. maind = nil
  4. if workspace:FindFirstChild'GiveSystem' then
  5.     if workspace.GiveSystem:FindFirstChild'GiveItem' then
  6.         maind = workspace.GiveSystem.GiveItem
  7.     end
  8. end
  9. if workspace:FindFirstChild'HandToCentre' then
  10.     if workspace.HandToCentre:FindFirstChild'SendItem' then
  11.         maind = workspace.HandToCentre.SendItem
  12.     end
  13. end
  14. if maind == nil then
  15.     print'could not find give event :('
  16.     return
  17. end
  18. tool = Instance.new'Tool'
  19. me = game:GetService'Players'.LocalPlayer
  20. tool.RequiresHandle = false
  21. tool.TextureId = 'http://www.roblox.com/asset/?id=12223874'
  22. tool.Name = 'ya like jazz?'
  23. tool.Parent = me.Backpack
  24. buttonf = nil
  25. tool.Equipped:connect(function()
  26.     local m = game:GetService'Players'.LocalPlayer:GetMouse()
  27.     m.Icon = 'rbxasset://textures/HammerCursor.png'
  28.     buttonf = m.Button1Down:connect(function()
  29.         if m.Target == nil then return end
  30.         local ob = m.Target
  31.         if ob:IsA'BasePart' or ob:IsA'WedgePart' then
  32.             if ob:IsDescendantOf(me.Character) then return end
  33.             m.Icon = 'rbxasset://textures/HammerOverCursor.png'
  34.             local ex = Instance.new'Explosion'
  35.             ex.BlastRadius = 0
  36.             ex.Position = ob.Position
  37.             ex.Parent = workspace
  38.             maind:FireServer(workspace, ob)
  39.             wait(0.3)
  40.             m.Icon = 'rbxasset://textures/HammerCursor.png'
  41.         end
  42.     end)
  43. end)
  44. tool.Unequipped:connect(function()
  45.     if buttonf ~= nil then
  46.         buttonf:Disconnect()
  47.         buttonf = nil
  48.     end
  49.     local m = game:GetService'Players'.LocalPlayer:GetMouse()
  50.     m.Icon = ''
  51. end)
Add Comment
Please, Sign In to add comment