Jump to content

Gm acces per realm

Recommended Posts

  • 39 years later...

GetSecurity() is not used to determine the security level of a character/account on login.

It is just used to:

- one in AuctionHouseMgr.cpp (don't know what it does there)

- and to find out about the targets security level when applying GM commands; you can't use GM commands on a character that has a higher security level

What you need to "manipulate" is the variable "AccountTypes _security;" (around line 640; Mangos-0.12) in WorldSession.h.

This value and its getter "GetSecurity()" (around line 93 in WorldSession.h) holds your security level that has to be overwritten somewhere.

I would guess you have to change the call of the constructor, defined in WorldSession.cpp (around line 41), but I have no idea where WorldSession objects are actually created.


       uint32 sec = (*result)[0].GetUInt32();
       delete result;
       if(sec > 0)
           [b][i]return sec;[/i][/b]

Maybe the second part of your code gets never adressed. If you RETURN "sec" you leave the complete code block and return to the caller. I guess every account has an entry in the accounts table, so you never get the chance to ask for an exception.

Swap the two db access blocks around, then you ask first for the current realm and then for the generall case.

Link to comment
Share on other sites

This topic is now closed to further replies.

  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use