ULX

Author Topic: Hook for when somebody's user group is changed?  (Read 2160 times)

0 Members and 1 Guest are viewing this topic.

Offline [ LittleBigBug_ ]

  • Newbie
  • *
  • Posts: 11
  • Karma: 5
Hook for when somebody's user group is changed?
« on: April 07, 2016, 08:17:42 AM »
Hey, on my server I've modified gForum to sync my players ranks to my forums, but only does it on initial spawn. I don't want to do a think loop unless I have to but I was wondering if there was some hook that is called when a players rank is changed that I could use. Thanks :) I tried looking on the documentation but I might've missed it

Offline Megiddo

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 6214
  • Karma: 394
  • Project Lead
Re: Hook for when somebody's user group is changed?
« Reply #1 on: April 07, 2016, 10:14:36 AM »
http://ulyssesmod.net/docs/index/Hooks.html

You want UCLChanged, but you'll have to have your own logic to figure out if what changed is of interest to you.
Experiencing God's grace one day at a time.

Offline [ LittleBigBug_ ]

  • Newbie
  • *
  • Posts: 11
  • Karma: 5
Re: Hook for when somebody's user group is changed?
« Reply #2 on: April 07, 2016, 10:32:15 AM »
Perfect sounds good thank you :D

Offline MrPresident

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 2728
  • Karma: 430
    • |G4P| Gman4President
Re: Hook for when somebody's user group is changed?
« Reply #3 on: April 07, 2016, 11:12:51 AM »
Maybe we should add (or add to our list for ULX4) a hook that returns more specific info for this kind of event.
It could be useful for authors to know when a player's group change and info like: the player, group they were in, group they are changing to.

Offline Megiddo

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 6214
  • Karma: 394
  • Project Lead
Re: Hook for when somebody's user group is changed?
« Reply #4 on: April 07, 2016, 02:40:58 PM »
All true, Mr. P. At the time, I couldn't figure out a good way to provide that level of complexity for the context, and I wasn't sure if enough people would use it to make it worthwhile.
Experiencing God's grace one day at a time.