Unsure how to use chat.addSolved

Hello. I am kind of a noob in these things but
Is it still possible to somehow use chat.add?
Because one of my plugin depends on it and wont send messages thanks to it.

invPlayer.sendConsoleCommand("chat.add", "", "You have been invited!");

Because so far i haven't got it to work.

player.SendConsoleCommand("chat.add", (object) 2, (object) 0, (object) MESSAGE);

Where:

  • player is player
  • 2 is chat channel
  • 0 is sender id (icon)
  • and MESSAGE is message
Locked automatically