summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorcelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-11-20 11:42:58 +0000
committercelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-11-20 11:42:58 +0000
commit9d02f1a1b111f882ca824583b1380a96fdeb556d (patch)
tree5fab218d6a29a109d9141a022873ac40eabd0c10 /src/map/pc.c
parenta4756bb8123d607ed5c4b854653d2ddab814f555 (diff)
downloadhercules-9d02f1a1b111f882ca824583b1380a96fdeb556d.tar.gz
hercules-9d02f1a1b111f882ca824583b1380a96fdeb556d.tar.bz2
hercules-9d02f1a1b111f882ca824583b1380a96fdeb556d.tar.xz
hercules-9d02f1a1b111f882ca824583b1380a96fdeb556d.zip
Added night_darkness_level
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/athena@267 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 6b9148119..029bddeff 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -803,7 +803,11 @@ int pc_authok(int id, int login_id2, time_t connect_until_time, struct mmo_chars
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);
- sd->opt2 |= STATE_BLIND;
+ if (battle_config.night_darkness_level > 0)
+ clif_specialeffect(&sd->bl, 474 + battle_config.night_darkness_level, 0);
+ else
+ //clif_specialeffect(&sd->bl, 483, 0); // default darkness level
+ sd->opt2 |= STATE_BLIND;
}
// ステ?タス初期計算など
@@ -7227,8 +7231,13 @@ int map_night_timer(int tid, unsigned int tick, int id, int data) { // by [yor]
night_flag = 1; // 0=day, 1=night [Yor]
for(i = 0; i < fd_max; i++) {
if (session[i] && (pl_sd = session[i]->session_data) && pl_sd->state.auth && !map[pl_sd->bl.m].flag.indoors) {
- pl_sd->opt2 |= STATE_BLIND;
- clif_changeoption(&pl_sd->bl);
+ if (battle_config.night_darkness_level > 0)
+ clif_specialeffect(&pl_sd->bl, 474 + battle_config.night_darkness_level, 0);
+ else {
+ //clif_specialeffect(&pl_sd->bl, 483, 0); // default darkness level
+ pl_sd->opt2 |= STATE_BLIND;
+ clif_changeoption(&pl_sd->bl);
+ }
clif_wis_message(pl_sd->fd, wisp_server_name, tmpstr, strlen(tmpstr)+1);
}
}