|
| 14 Oct 2013 06:12 PM |
function onButton1Down(mouse) Tool = script.Parent b = Instance.new("Part", game.Workspace) b.FormFactor = "Ball" b.TopSurface = "Smooth" b.BottomSurface = "Smooth" b.BrickColor = BrickColor.new("Really black") b.Anchored = false b.Position = Tool.Handle.Position wait(4) e = Instance.new("Explosion", b) e.BlastPressure = 100 e.BlastRadius = 10 end
Tool.Equipped:connect(onEquippedLocal)
Output: Position is not a valid member of Tool |
|
|
| Report Abuse |
|
|
|
| 14 Oct 2013 06:14 PM |
You may have a Tool inside your Tool that you named Handle. Handle should be a part. Also, where is your onEquippedLocal function? |
|
|
| Report Abuse |
|
|
|
| 14 Oct 2013 06:16 PM |
you mean this?
local Tool = script.Parent;
enabled = true function onButton1Down(mouse) if not enabled then return end
enabled = false mouse.Icon = "rbxasset://textures\\GunWaitCursor.png"
wait(7) mouse.Icon = "rbxasset://textures\\GunCursor.png" enabled = true
end
function onEquippedLocal(mouse)
if mouse == nil then print("Mouse not found") return end
mouse.Icon = "rbxasset://textures\\GunCursor.png" mouse.Button1Down:connect(function() onButton1Down(mouse) end) end
Tool.Equipped:connect(onEquippedLocal) |
|
|
| Report Abuse |
|
|
|
| 14 Oct 2013 06:18 PM |
| Do you have two onButton1Down functions ... ? |
|
|
| Report Abuse |
|
|