diff options
author | Jared Adams <jaxad0127@gmail.com> | 2009-08-16 09:57:14 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-08-16 10:01:12 -0600 |
commit | 4fcb38d69d1b61cc79b6b9af06918e5c228b242b (patch) | |
tree | 6195f898ee1a5493e1a1ab73c65afd9a19f0d45e /src | |
parent | 70faeb3733a9a5c39acb75c2c8765e8c2acd1dd5 (diff) | |
download | tmwa-4fcb38d69d1b61cc79b6b9af06918e5c228b242b.tar.gz tmwa-4fcb38d69d1b61cc79b6b9af06918e5c228b242b.tar.bz2 tmwa-4fcb38d69d1b61cc79b6b9af06918e5c228b242b.tar.xz tmwa-4fcb38d69d1b61cc79b6b9af06918e5c228b242b.zip |
Send GM flag to clients
Diffstat (limited to 'src')
-rw-r--r-- | src/map/clif.c | 6 | ||||
-rw-r--r-- | src/map/pc.c | 3 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index 908e9ff..050c1c9 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -756,8 +756,7 @@ static int clif_set0078(struct map_session_data *sd, unsigned char *buf) { WBUFB(buf,45)=sd->sex; WBUFPOS(buf,46,sd->bl.x,sd->bl.y); WBUFB(buf,48)|=sd->dir&0x0f; - WBUFB(buf,49)=5; - WBUFB(buf,50)=5; + WBUFW(buf,49)=pc_isGM(sd) >= 60 ? 0x80 : 0; WBUFB(buf,51)=sd->state.dead_sit; WBUFW(buf,52)=((level = battle_get_lv(&sd->bl)) > battle_config.max_lv) ? battle_config.max_lv : level; @@ -830,8 +829,7 @@ static int clif_set007b(struct map_session_data *sd,unsigned char *buf) { WBUFB(buf,48)=sd->status.karma; WBUFB(buf,49)=sd->sex; WBUFPOS2(buf,50,sd->bl.x,sd->bl.y,sd->to_x,sd->to_y); - WBUFB(buf,55)=0; - WBUFB(buf,56)=5; + WBUFW(buf,55)=pc_isGM(sd) >= 60 ? 0x80 : 0; WBUFB(buf,57)=5; WBUFW(buf,58)=(sd->status.base_level>battle_config.max_lv)?battle_config.max_lv:sd->status.base_level; diff --git a/src/map/pc.c b/src/map/pc.c index e0b4c89..7aec359 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -790,7 +790,10 @@ int pc_authok(int id, int login_id2, time_t connect_until_time, short tmw_versio pc_calcstatus(sd,1); if (pc_isGM(sd)) + { printf("Connection accepted: character '%s' (account: %d; GM level %d).\n", sd->status.name, sd->status.account_id, pc_isGM(sd)); + clif_updatestatus(sd, SP_GM); + } else printf("Connection accepted: Character '%s' (account: %d).\n", sd->status.name, sd->status.account_id); |