Issue information

Issue ID
#458
Status
Fixed
Severity
None
Started
Hercules Elf Bot
Nov 20, 2007 18:38
Last Post
Hercules Elf Bot
Nov 20, 2007 18:38
Confirmation
N/A

Hercules Elf Bot - Nov 20, 2007 18:38

Originally posted by [b]theultramage[/b]
http://www.eathena.ws/board/index.php?autocom=bugtracker&showbug=458

It is probably known that if you create a new account (using _M/_F or via database insert), it will run as gm level 0 until @reloadgmdb or login server restart.

The chain looks like this:
- login server loads gm account list (consists only of accounts that already exist!)
- login server spams all charservers
- charservers spam all mapservers

Now, when you create a new acc, it will end up as level 0 even though it was a gm acc - because no update was sent to the servers. The obvious hack is to perform a gm-db reload every time a new acc is created (won't help external updates though).

Here are some ways how to improve this.
* Get rid of gm-account.txt and add a 'level' column to the TXT savefile. SQL does it like this, and if TXT/SQL are to sync, this has to be done sooner or later.
* Get rid of this...separate... gm level transfer thing. A GM level is an attribute of an account (and from that, of all chars on that account) and should be treated as such. It should be loaded by the login server when someone logs to the corresponding account, then sent as part of login->char auth data, recorded as part of the charserver session, and transferred as part of char-map auth data to the mapserver where it would be associated with the player session.

My reasoning is that NOTHING needs the entire existing gm list; only the list of people that are online. Having it like this makes gm code ridiculously complex and slow (gm levels are checked on many occasions). The only thing to sort out here is how to do a realtime gm level refresh (but that shouldn't be hard to do either).