Repair kit in f4 menu when nobody is on the mecanic job
Last read Never
Hi everyone ! All is in the title :p
I d'ont know how to do.
When the job of mecanic is empty i search to set automaticly the possibility to buy a repair kit in the f4 menu
Thanks you to read ! :)
customCheck = function() return #team.GetPlayers(TEAM_MECHANICS) == 0 end
replace "TEAM_MECHANICS" with whatever you set your team to
The solution posted above should work just fine. There is a function specifically for this however, that uses #team.GetPlayers internally:
https://wiki.facepunch.com/gmod/team.NumPlayers
customCheck = function() return (team.NumPlayers(TEAM_MECHANICS) == 0); end;
This function is not any faster performance wise, but it does provide more detail at glance.
Whoops, forgot about that function xD
Users viewing this thread
Nobody