diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-02-28 16:42:34 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-02-28 16:42:34 +0000 |
commit | f4e33de65bca782f34061cd9610792dbffad8b08 (patch) | |
tree | 94488ff4b586e6b878da347b82f4f7dac1328219 /src/char_sql | |
parent | b31f1a4805c6119e7463f1cb8dd5933b7d68e101 (diff) | |
download | hercules-f4e33de65bca782f34061cd9610792dbffad8b08.tar.gz hercules-f4e33de65bca782f34061cd9610792dbffad8b08.tar.bz2 hercules-f4e33de65bca782f34061cd9610792dbffad8b08.tar.xz hercules-f4e33de65bca782f34061cd9610792dbffad8b08.zip |
- Made it possible to modify the server packet version from the Makefile.
- Merged packet 2b22 (from my server) to handle quick fame updates whenever someone's fame in the ranking changes, but no position swaps take place (prevents having to resend the whole fame list in such events, you lazy Draco <.<)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9936 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/char_sql')
-rw-r--r-- | src/char_sql/char.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/char_sql/char.c b/src/char_sql/char.c index c6a8e606e..4db97be38 100644 --- a/src/char_sql/char.c +++ b/src/char_sql/char.c @@ -2399,6 +2399,16 @@ int char_send_fame_list(int fd) { return 0; } +void char_update_fame_list(int type, int index, int fame) +{ + char buf[9]; + WBUFW(buf,0) = 0x2b22; + WBUFB(buf,2) = type; + WBUFB(buf,3) = index; + WBUFL(buf,4) = fame; + mapif_sendall(buf, 8); +} + int search_mapserver(unsigned short map, long ip, short port); //Loads a character's name and stores it in the buffer given (must be NAME_LENGTH in size) @@ -2964,7 +2974,7 @@ int parse_frommap(int fd) { (pos == size-1 || fame > list[pos+1].fame) ) { //No change in order. list[(int)pos].fame = fame; - char_send_fame_list(fd); + char_update_fame_list(type, pos, fame); break; } // If the player's already in the list, remove the entry and shift the following ones 1 step up |