Facepunch / garrysmod-requests

Feature requests for Garry's Mod
86 stars 24 forks source link

Add teamonly to gameevent `player_say` #2276

Closed anormaltwig closed 10 months ago

anormaltwig commented 10 months ago

Details

its already available to where the event is called from

robotboy655 commented 10 months ago

Done.

RaphaelIT7 commented 9 months ago

I think you forgot to add it to the resource/serverevents.res file. Because of this the teamonly field won't be networked?

    "player_say"
    {
        "userid"    "short"     // user ID on server
        "text"      "string"    // the say text
        "teamonly"  "bool"      // is it teamonly <-- This line needs to be added
    }

Or is it intentional that it's only serverside?

robotboy655 commented 9 months ago

No I did not, but you can open a separate issue for that if you really need to.

I am not sure whether that would break network compatibility with existing servers is all.

RaphaelIT7 commented 9 months ago

I just tested it and it doesn't break network compatibility. The teamonly field also works on the client if only the server has the entry, so it seems like it's only required serverside to send it.