ULX

Author Topic: Ulx Custom Command for user groups  (Read 2518 times)

0 Members and 1 Guest are viewing this topic.

Offline proxzei

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Ulx Custom Command for user groups
« on: April 12, 2016, 02:32:06 PM »
Does anyone know hot to make a ulx command where by typing !vip a user would be added to that group. Just !vip though.

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: Ulx Custom Command for user groups
« Reply #1 on: April 12, 2016, 03:50:54 PM »
Yes.
Many here know how.
What particular challenge are you having with it?
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming

Offline proxzei

  • Newbie
  • *
  • Posts: 4
  • Karma: 0
Re: Ulx Custom Command for user groups
« Reply #2 on: April 13, 2016, 07:49:45 AM »
Uh, I don't know how to do it at all and would like the code if thats possible.

Offline Caustic Soda-Senpai

  • Sr. Member
  • ****
  • Posts: 469
  • Karma: 54
  • <Insert something clever here>
    • Steam Page
Re: Ulx Custom Command for user groups
« Reply #3 on: April 13, 2016, 10:59:46 AM »
it's basically a shortened version of ulx adduser.

so you basically want to write the command that gets called on !vip which runs the function to add the calling player to "vip".

RunConsoleCommand("ulx","adduser",calling_ply,"vip")
Once you get to know me, you'll find you'll have never met me at all.

An Error Has Occurred!

array_keys(): Argument #1 ($array) must be of type array, null given