diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-11-08 19:14:03 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-11-08 19:14:03 +0000 |
commit | aa347aa90770cefe877651f5820631bc1dcf77c1 (patch) | |
tree | 13ea6f2b6f3e658f333a8c45373b6ac9a1d1ef67 /src/map/pc.c | |
parent | 2ed2a3789299211c5c9b9d675586e41eecfc25f0 (diff) | |
download | hercules-aa347aa90770cefe877651f5820631bc1dcf77c1.tar.gz hercules-aa347aa90770cefe877651f5820631bc1dcf77c1.tar.bz2 hercules-aa347aa90770cefe877651f5820631bc1dcf77c1.tar.xz hercules-aa347aa90770cefe877651f5820631bc1dcf77c1.zip |
- Did some cleaning in pc_authok and clif_parse_LoadEndAck
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9175 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r-- | src/map/pc.c | 36 |
1 files changed, 25 insertions, 11 deletions
diff --git a/src/map/pc.c b/src/map/pc.c index c68b5b2ff..492cd11f1 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -706,13 +706,22 @@ int pc_authok(struct map_session_data *sd, int login_id2, time_t connect_until_t sd->state.event_disconnect = 1; sd->state.event_kill_mob = 1; - sd->state.auth = 1; //Do not auth him until the initial stats have been placed. + sd->state.auth = 1; { //Add IP field unsigned char *ip = (unsigned char *) &session[sd->fd]->client_addr.sin_addr; if (pc_isGM(sd)) - ShowInfo("GM Character '"CL_WHITE"%s"CL_RESET"' logged in. (Acc. ID: '"CL_WHITE"%d"CL_RESET"', Connection: '"CL_WHITE"%d"CL_RESET"', Packet Ver: '"CL_WHITE"%d"CL_RESET"', IP: '"CL_WHITE"%d.%d.%d.%d"CL_RESET"', GM Level '"CL_WHITE"%d"CL_RESET"').\n", sd->status.name, sd->status.account_id, sd->fd, sd->packet_ver, ip[0],ip[1],ip[2],ip[3], pc_isGM(sd)); + ShowInfo("GM '"CL_WHITE"%s"CL_RESET"' logged in." + " (AID/CID: '"CL_WHITE"%d/%d"CL_RESET"'," + " Packet Ver: '"CL_WHITE"%d"CL_RESET"', IP: '"CL_WHITE"%d.%d.%d.%d"CL_RESET"'," + " GM Level '"CL_WHITE"%d"CL_RESET"').\n", + sd->status.name, sd->status.account_id, sd->status.char_id, + sd->packet_ver, ip[0],ip[1],ip[2],ip[3], pc_isGM(sd)); else - ShowInfo("Character '"CL_WHITE"%s"CL_RESET"' logged in. (Account ID: '"CL_WHITE"%d"CL_RESET"', Connection: '"CL_WHITE"%d"CL_RESET"', Packet Ver: '"CL_WHITE"%d"CL_RESET"', IP: '"CL_WHITE"%d.%d.%d.%d"CL_RESET"').\n", sd->status.name, sd->status.account_id, sd->fd, sd->packet_ver, ip[0],ip[1],ip[2],ip[3]); + ShowInfo("'"CL_WHITE"%s"CL_RESET"' logged in." + " (AID/CID: '"CL_WHITE"%d/%d"CL_RESET"'," + " Packet Ver: '"CL_WHITE"%d"CL_RESET"', IP: '"CL_WHITE"%d.%d.%d.%d"CL_RESET"').\n", + sd->status.name, sd->status.account_id, sd->status.char_id, + sd->packet_ver, ip[0],ip[1],ip[2],ip[3]); } // Send friends list @@ -725,14 +734,11 @@ int pc_authok(struct map_session_data *sd, int login_id2, time_t connect_until_t } // Message of the Day [Valaris] - { - int ln; - for(ln=0; motd_text[ln][0] && ln < MOTD_LINE_SIZE; ln++) { - if (battle_config.motd_type) - clif_disp_onlyself(sd,motd_text[ln],strlen(motd_text[ln])); - else - clif_displaymessage(sd->fd, motd_text[ln]); - } + for(i=0; motd_text[i][0] && i < MOTD_LINE_SIZE; i++) { + if (battle_config.motd_type) + clif_disp_onlyself(sd,motd_text[i],strlen(motd_text[i])); + else + clif_displaymessage(sd->fd, motd_text[i]); } #ifndef TXT_ONLY @@ -747,6 +753,14 @@ int pc_authok(struct map_session_data *sd, int login_id2, time_t connect_until_t clif_wis_message(sd->fd, wisp_server_name, tmpstr, strlen(tmpstr)+1); } + //Night message + if (night_flag) + { + char tmpstr[1024]; + strcpy(tmpstr, msg_txt(500)); // Actually, it's the night... + clif_wis_message(sd->fd, wisp_server_name, tmpstr, strlen(tmpstr)+1); + } + return 0; } |