Osiris
Osiris copied to clipboard
hook user chat and overwrite it
hello,
im kinda new to this language and im wondering if someone could tell me how to hook the chat messages and overwrite them. for example, i type something else and it changes the text to caps or something.
thank you
You can hook IVEngineClient::ClientCmd (https://github.com/perilouswithadollarsign/cstrike15_src/blob/master/public/cdll_int.h#L332) and check if szCmdString starts with "say". If yes, the rest of the string is the chat message. You can then change the string to whatever you want and return the original with it.