Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

trying to get weapon name when equipped to display on a TextLabel but doesnt work?

Asked by 8 years ago

i have a gui


|TextLabel|

when i equip a weapon, i need the name to show there, i tried a few different scripts

(even changing the weapon name when equipped to see if it worked (that did) )

but i cant figure out how to get the weapon name to show in the gui

well i tried a different approach \

still didnt work

local tool = script.Parent
local Name = game.Players.LocalPlayer.PlayerGui.ScreenGui.AttackStyles.ImageLabel.WeaponName

function onEquip(mouse)
    Name.Text = tool.Name

this is a script inside the tool itself. piece of the script i didnt post changes a gui already

1
Have a script that checks if an object was added to the player's character. If that object is a tool, then have the script change the textlabel to the name of the tool. Without an attempt at a script, we can not really help you. M39a9am3R 3210 — 8y
0
is this a localscript wackem 50 — 8y
0
yea User#12356 0 — 8y

Answer this question