• Gmod Scoreboard -- How can I add an icon signifying whose mic is open?
    6 replies, posted
Hello, I'm running a dedicated murder server. I've seen other servers that have a speaker-looking icon next to a person's name on the scoreboard whenever their mic is open (for easy muting purposes). Does anyone know how to recreate this?
Doesn't the gmod default scoreboard already have that functionality? [url]https://github.com/garrynewman/garrysmod/blob/master/garrysmod/gamemodes/base/gamemode/cl_scoreboard.lua[/url] You might just want to look at the implementation there. The interesting lines are around line 37 and 113.
[QUOTE=Lolle;49964109]Doesn't the gmod default scoreboard already have that functionality? [url]https://github.com/garrynewman/garrysmod/blob/master/garrysmod/gamemodes/base/gamemode/cl_scoreboard.lua[/url] You might just want to look at the implementation there. The interesting lines are around line 37 and 113.[/QUOTE] The default scoreboard has a speaker icon that indicates whether or not you have their microphone muted - and gives you the option to mute and unmute - what OP wants is an icon that signals whether or not a player is using their mic currently. I'd write something up but I'm lazy, I'm sure somebody else will.
[QUOTE=Minteh Fresh;49964139]The default scoreboard has a speaker icon that indicates whether or not you have their microphone muted - and gives you the option to mute and unmute - what OP wants is an icon that signals whether or not a player is using their mic currently. I'd write something up but I'm lazy, I'm sure somebody else will.[/QUOTE] Okay then, but still the OP could pretty easily modify the lines i pointed out to use [img]http://wiki.garrysmod.com/favicon.ico[/img] [url=http://wiki.garrysmod.com/page/Player/IsSpeaking]Player:IsSpeaking[/url] instead of [img]http://wiki.garrysmod.com/favicon.ico[/img] [url=http://wiki.garrysmod.com/page/Player/IsMuted]Player:IsMuted[/url]
Hey, thanks guys! I'm new to lua coding so I didn't even know Player:IsSpeaking was a thing! I'll mess around with this :) Thank you!!!
For future reference, the [URL="http://wiki.garrysmod.com/page/Main_Page"]Garry's Mod wiki[/URL] helps a lot with Lua. I'm new too and it's been a huge help.
[QUOTE=redpr1sm;49977408]For future reference, the [URL="http://wiki.garrysmod.com/page/Main_Page"]Garry's Mod wiki[/URL] helps a lot with Lua. I'm new too and it's been a huge help.[/QUOTE] Im re adding the toybox into gmod and i still use the wiki
Sorry, you need to Log In to post a reply to this thread.