Hi, I’m trying to make tags for a scoreboard, and when a player joins, an essential function called update_tags() is supposed to run, this function sets their tag to either what they set it to, or the default if they haven’t done so. At the moment when anyone joins their tag is NIL, until someone on the server changes their tag, which in that function calls update_tags.
When this happens everything gets set ok, but then when more people join they’re tag is nil.
So my question is, how do I call this function each time a player joins? This is my try …
hook.Add( "PlayerIntitialSpawn", "scoreboard_tag_spawn", function( ply ) ply.sb_tag = ply:GetPData( "sb_tag", "") update_tags() end )