summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
Diffstat (limited to 'src/map')
-rw-r--r--src/map/battle.c3
-rw-r--r--src/map/clif.c22
-rw-r--r--src/map/map.h1
-rw-r--r--src/map/pc.c11
4 files changed, 35 insertions, 2 deletions
diff --git a/src/map/battle.c b/src/map/battle.c
index 973878529..d152a5e31 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -2926,7 +2926,8 @@ static struct Damage battle_calc_pc_weapon_attack(
}
//三段掌
- if(skill_num == 0 && skill_lv >= 0 && (skill = pc_checkskill(sd,MO_TRIPLEATTACK)) > 0 && sd->status.weapon <= 16 && !sd->state.arrow_atk) {
+ //if(skill_num == 0 && skill_lv >= 0 && (skill = pc_checkskill(sd,MO_TRIPLEATTACK)) > 0 && sd->status.weapon <= 16 && !sd->state.arrow_atk) {
+ if(skill_num == 0 && skill_lv >= 0 && (skill = pc_checkskill(sd,MO_TRIPLEATTACK)) > 0 && sd->status.weapon <= 16) { // triple blow works with bows ^^ [celest]
da = (rand()%100 < (30 - skill)) ? 2:0;
}
diff --git a/src/map/clif.c b/src/map/clif.c
index 54fd7d9a9..716eb28ac 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -7728,6 +7728,28 @@ void clif_parse_GlobalMessage(int fd, struct map_session_data *sd) { // S 008c <
WFIFOW(fd,0) = 0x8e;
WFIFOSET(fd, WFIFOW(fd,2));
+ // Celest
+ if (pc_calc_base_job2 (sd->status.class) == 23 && (sd->status.base_exp*100/pc_nextbaseexp(sd))%10 == 0) {
+ estr_lower(RFIFOP(fd,4));
+ if (sd->state.snovice_flag == 0 && strstr(RFIFOP(fd,4), "guardian angel, can you hear my voice? ^^;"))
+ sd->state.snovice_flag = 1;
+ else if (sd->state.snovice_flag == 1) {
+ sprintf(message, "my name is %s, and i'm a super novice~", sd->status.name);
+ estr_lower(message);
+ if (strstr(RFIFOP(fd,4), message))
+ sd->state.snovice_flag = 2;
+ }
+ else if (sd->state.snovice_flag == 2 && strstr(RFIFOP(fd,4), "please help me~ t.t"))
+ sd->state.snovice_flag = 3;
+ else if (sd->state.snovice_flag == 3) {
+ int i;
+ skill_status_change_start(&sd->bl,SkillStatusChangeTable[MO_EXPLOSIONSPIRITS],1,0,0,0,skill_get_time(MO_EXPLOSIONSPIRITS,1),0 );
+ for(i=0;i<5;i++)
+ pc_addspiritball(sd,skill_get_time(MO_CALLSPIRITS,1),5);
+ sd->state.snovice_flag = 0;
+ }
+ }
+
if(message) free(message);
if(buf) free(buf);
diff --git a/src/map/map.h b/src/map/map.h
index 1a1353983..e05b6d125 100644
--- a/src/map/map.h
+++ b/src/map/map.h
@@ -137,6 +137,7 @@ struct map_session_data {
unsigned make_arrow_flag : 1;
unsigned potionpitcher_flag : 1;
unsigned storage_flag : 1;
+ unsigned snovice_flag : 4;
} state;
struct {
unsigned killer : 1;
diff --git a/src/map/pc.c b/src/map/pc.c
index d0563937a..ca8d3b602 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -280,9 +280,14 @@ int pc_setrestartvalue(struct map_session_data *sd,int type) {
//-----------------------
// 死亡した
- if(sd->special_state.restart_full_recover) { // オシリスカ?ド
+ if(sd->special_state.restart_full_recover || // オシリスカ?ド
+ sd->state.snovice_flag == 4) { // [Celest]
sd->status.hp=sd->status.max_hp;
sd->status.sp=sd->status.max_sp;
+ if (sd->state.snovice_flag == 4) {
+ sd->state.snovice_flag = 0;
+ skill_status_change_start(&sd->bl,SkillStatusChangeTable[MO_STEELBODY],1,0,0,0,skill_get_time(MO_STEELBODY,1),0 );
+ }
}
else {
if(s_class.job == 0 && battle_config.restart_hp_rate < 50) { //ノビは半分回復
@@ -5427,6 +5432,10 @@ int pc_damage(struct block_list *src,struct map_session_data *sd,int damage)
clif_updatestatus(sd,SP_HP);
pc_calcstatus(sd,0);
+ // activate Steel body if a super novice dies at 99+% exp [celest]
+ if (s_class.job == 23 && (i=sd->status.base_exp*1000/pc_nextbaseexp(sd))>=990 && i<=1000)
+ sd->state.snovice_flag = 4;
+
for(i=0;i<5;i++)
if(sd->dev.val1[i]){
skill_status_change_end(&map_id2sd(sd->dev.val1[i])->bl,SC_DEVOTION,-1);