ULX

Author Topic: Silent chat.  (Read 1885 times)

0 Members and 1 Guest are viewing this topic.

Offline Chrissy

  • Newbie
  • *
  • Posts: 1
  • Karma: 0
Silent chat.
« on: December 31, 2013, 07:18:53 AM »
Hi,
I'm currently trying to work some commands into being silent. I can get them to do the whole
Code: [Select]
(SILENT) Chrissy ran Y on Z  thing however you can still see
Code: [Select]
Chrissy: !cexec Y ZI know !spectate already does not hide in chat, what hook is called to hide it from chat?
Thanks

Offline Decicus

  • Hero Member
  • *****
  • Posts: 552
  • Karma: 81
    • Alex Thomassen
Re: Silent chat.
« Reply #1 on: December 31, 2013, 11:26:19 AM »
How about you use the console command instead? Or the ULX menu.
Every ULX chat command also has a console command that works the same way, "!cexec" would be "ulx cexec" in console.

Or, if you really want to, use the hook PlayerSay and return empty quotes, if it finds "!cexec" in the first 6 letters.


Cobalt suggested something a lot better.
« Last Edit: December 31, 2013, 12:48:21 PM by Decicus »
Contact information:
E-mail: alex@thomassen.xyz.
You can also send a PM.

Offline Cobalt

  • Full Member
  • ***
  • Posts: 216
  • Karma: 44
  • http://steamcommunity.com/id/__yvl/
Re: Silent chat.
« Reply #2 on: December 31, 2013, 12:22:55 PM »
local cexec = ulx.command( CATEGORY_NAME, "ulx cexec", ulx.cexec, "!cexec", true )
Add the true to hide the chat command.

Offline Decicus

  • Hero Member
  • *****
  • Posts: 552
  • Karma: 81
    • Alex Thomassen
Re: Silent chat.
« Reply #3 on: December 31, 2013, 12:47:27 PM »
local cexec = ulx.command( CATEGORY_NAME, "ulx cexec", ulx.cexec, "!cexec", true )
Add the true to hide the chat command.

I had no idea that's a thing.
Contact information:
E-mail: alex@thomassen.xyz.
You can also send a PM.

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: Silent chat.
« Reply #4 on: December 31, 2013, 11:43:48 PM »
Though the ULX command setup does a bit of combo work (category setup, etc), the 'silent' boolean is explained here.
http://ulyssesmod.net/docs/files/lua/ulib/shared/commands-lua.html#cmds.TranslateCommand.cmds.TranslateCommand:instantiate

Edit by Megiddo: Fixed link
« Last Edit: January 01, 2014, 12:21:43 PM by Megiddo »
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming