diff options
-rw-r--r-- | db/pre-re/item_db.txt | 2 | ||||
-rw-r--r-- | db/re/item_db.txt | 2 | ||||
-rw-r--r-- | sql-files/item_db.sql | 2 | ||||
-rw-r--r-- | sql-files/item_db_re.sql | 2 | ||||
-rw-r--r-- | src/char/int_elemental.c | 3 | ||||
-rw-r--r-- | src/char/int_guild.h | 4 | ||||
-rw-r--r-- | src/char/int_party.h | 2 | ||||
-rw-r--r-- | src/map/atcommand.c | 28 | ||||
-rw-r--r-- | src/map/battle.c | 6 | ||||
-rw-r--r-- | src/map/elemental.c | 10 | ||||
-rw-r--r-- | src/map/elemental.h | 3 | ||||
-rw-r--r-- | src/map/homunculus.c | 2 | ||||
-rw-r--r-- | src/map/homunculus.h | 2 | ||||
-rw-r--r-- | src/map/mail.c | 1 | ||||
-rw-r--r-- | src/map/mercenary.c | 10 | ||||
-rw-r--r-- | src/map/mercenary.h | 3 | ||||
-rw-r--r-- | src/map/mob.h | 2 | ||||
-rw-r--r-- | src/map/skill.c | 4 | ||||
-rw-r--r-- | src/map/status.c | 10 | ||||
-rwxr-xr-x | tools/backup.pl | 100 | ||||
-rw-r--r-- | tools/vs9-to-vs8.php | 46 |
21 files changed, 29 insertions, 215 deletions
diff --git a/db/pre-re/item_db.txt b/db/pre-re/item_db.txt index 410ed82c4..89808919d 100644 --- a/db/pre-re/item_db.txt +++ b/db/pre-re/item_db.txt @@ -1888,7 +1888,7 @@ 4260,Wootan_Shooter_Card,Wootan Shooter Card,6,20,,10,,,,,,,,769,,,,,{ bonus bDef,1; bonus2 bResEff,Eff_Confusion,2000; },{},{} 4261,Wootan_Fighter_Card,Wootan Fighter Card,6,20,,10,,,,,,,,769,,,,,{ bonus bDef,1; bonus2 bResEff,Eff_Bleeding,2000; },{},{} 4262,Evil_Cloud_Hermit_Card,Cloud Hermit Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAddMonsterDropItem,12029,RC_Plant,100; },{},{} -4263,Incant_Samurai_Card,Samurai Spector Card,6,20,,10,,,,,,,,2,,,,,{ bonus bIgnoreDefRace,RC_NonBoss; bonus bHPrecovRate,-100; bonus2 bHPLossRate,666,10000; },{},{ heal -999,0; } +4263,Incant_Samurai_Card,Samurai Spector Card,6,20,,10,,,,,,,,2,,,,,{ bonus bIgnoreDefRace,RC_NonBoss; bonus bHPrecovRate,-100; bonus2 bHPLossRate,666,10000; },{},{ if( (Hp <= 999) && !getmapflag(strcharinfo(3),6) && !getmapflag(strcharinfo(3),7) && !getmapflag(strcharinfo(3),8) ) { heal (1 - Hp), 0; } else { heal -999, 0; } } 4264,Wind_Ghost_Card,Wind Ghost Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAutoSpell,"WZ_JUPITEL",3+7*(getskilllv("WZ_JUPITEL")==10),20; },{},{} 4265,Li_Me_Mang_Ryang_Card,Jing Guai Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAddMonsterDropItem,12033,RC_Angel,100; },{},{} 4266,Eclipse_Card,Eclipse Card,6,20,,10,,,,,,,,4,,,,,{ bonus bVit,1; },{},{} diff --git a/db/re/item_db.txt b/db/re/item_db.txt index 4aca0c4d0..3e0a84410 100644 --- a/db/re/item_db.txt +++ b/db/re/item_db.txt @@ -2168,7 +2168,7 @@ 4260,Wootan_Shooter_Card,Wootan Shooter Card,6,20,,10,,,,,,,,769,,,,,{ bonus bDef,1; bonus2 bResEff,Eff_Confusion,2000; },{},{} 4261,Wootan_Fighter_Card,Wootan Fighter Card,6,20,,10,,,,,,,,769,,,,,{ bonus bDef,1; bonus2 bResEff,Eff_Bleeding,2000; },{},{} 4262,Evil_Cloud_Hermit_Card,Cloud Hermit Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAddMonsterDropItem,12029,RC_Plant,100; },{},{} -4263,Incant_Samurai_Card,Samurai Spector Card,6,20,,10,,,,,,,,2,,,,,{ bonus bIgnoreDefRace,RC_NonBoss; bonus bHPrecovRate,-100; bonus2 bHPLossRate,666,10000; },{},{ heal -999,0; } +4263,Incant_Samurai_Card,Samurai Spector Card,6,20,,10,,,,,,,,2,,,,,{ bonus bIgnoreDefRace,RC_NonBoss; bonus bHPrecovRate,-100; bonus2 bHPLossRate,666,10000; },{},{ if( (Hp <= 999) && !getmapflag(strcharinfo(3),6) && !getmapflag(strcharinfo(3),7) && !getmapflag(strcharinfo(3),8) ) { heal (1 - Hp), 0; } else { heal -999, 0; } } 4264,Wind_Ghost_Card,Wind Ghost Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAutoSpell,"WZ_JUPITEL",3+7*(getskilllv("WZ_JUPITEL")==10),20; },{},{} 4265,Li_Me_Mang_Ryang_Card,Jing Guai Card,6,20,,10,,,,,,,,136,,,,,{ bonus3 bAddMonsterDropItem,12033,RC_Angel,100; },{},{} 4266,Eclipse_Card,Eclipse Card,6,20,,10,,,,,,,,4,,,,,{ bonus bVit,1; },{},{} diff --git a/sql-files/item_db.sql b/sql-files/item_db.sql index 6d39d1a22..27a7a7024 100644 --- a/sql-files/item_db.sql +++ b/sql-files/item_db.sql @@ -1919,7 +1919,7 @@ REPLACE INTO `item_db` VALUES (4259,'Wooden_Golem_Card','Wooden Golem Card',6,20 REPLACE INTO `item_db` VALUES (4260,'Wootan_Shooter_Card','Wootan Shooter Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,769,NULL,NULL,NULL,NULL,'bonus bDef,1; bonus2 bResEff,Eff_Confusion,2000;',NULL,NULL); REPLACE INTO `item_db` VALUES (4261,'Wootan_Fighter_Card','Wootan Fighter Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,769,NULL,NULL,NULL,NULL,'bonus bDef,1; bonus2 bResEff,Eff_Bleeding,2000;',NULL,NULL); REPLACE INTO `item_db` VALUES (4262,'Evil_Cloud_Hermit_Card','Cloud Hermit Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,136,NULL,NULL,NULL,NULL,'bonus3 bAddMonsterDropItem,12029,RC_Plant,100;',NULL,NULL); -REPLACE INTO `item_db` VALUES (4263,'Incant_Samurai_Card','Samurai Spector Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL,NULL,'bonus bIgnoreDefRace,RC_NonBoss; bonus bHPrecovRate,-100; bonus2 bHPLossRate,666,10000;',NULL,'heal -999,0;'); +REPLACE INTO `item_db` VALUES (4263,'Incant_Samurai_Card','Samurai Spector Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL,NULL,'bonus bIgnoreDefRace,RC_NonBoss; bonus bHPrecovRate,-100; bonus2 bHPLossRate,666,10000;',NULL,'if( (Hp <= 999) && !getmapflag(strcharinfo(3),6) && !getmapflag(strcharinfo(3),7) && !getmapflag(strcharinfo(3),8) ) { heal (1 - Hp), 0; } else { heal -999, 0; }'); REPLACE INTO `item_db` VALUES (4264,'Wind_Ghost_Card','Wind Ghost Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,136,NULL,NULL,NULL,NULL,'bonus3 bAutoSpell,"WZ_JUPITEL",3+7*(getskilllv("WZ_JUPITEL")==10),20;',NULL,NULL); REPLACE INTO `item_db` VALUES (4265,'Li_Me_Mang_Ryang_Card','Jing Guai Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,136,NULL,NULL,NULL,NULL,'bonus3 bAddMonsterDropItem,12033,RC_Angel,100;',NULL,NULL); REPLACE INTO `item_db` VALUES (4266,'Eclipse_Card','Eclipse Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,4,NULL,NULL,NULL,NULL,'bonus bVit,1;',NULL,NULL); diff --git a/sql-files/item_db_re.sql b/sql-files/item_db_re.sql index 176812c1c..dbbf2500b 100644 --- a/sql-files/item_db_re.sql +++ b/sql-files/item_db_re.sql @@ -2199,7 +2199,7 @@ REPLACE INTO `item_db_re` VALUES (4259,'Wooden_Golem_Card','Wooden Golem Card',6 REPLACE INTO `item_db_re` VALUES (4260,'Wootan_Shooter_Card','Wootan Shooter Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,769,NULL,NULL,NULL,NULL,'bonus bDef,1; bonus2 bResEff,Eff_Confusion,2000;',NULL,NULL); REPLACE INTO `item_db_re` VALUES (4261,'Wootan_Fighter_Card','Wootan Fighter Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,769,NULL,NULL,NULL,NULL,'bonus bDef,1; bonus2 bResEff,Eff_Bleeding,2000;',NULL,NULL); REPLACE INTO `item_db_re` VALUES (4262,'Evil_Cloud_Hermit_Card','Cloud Hermit Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,136,NULL,NULL,NULL,NULL,'bonus3 bAddMonsterDropItem,12029,RC_Plant,100;',NULL,NULL); -REPLACE INTO `item_db_re` VALUES (4263,'Incant_Samurai_Card','Samurai Spector Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL,NULL,'bonus bIgnoreDefRace,RC_NonBoss; bonus bHPrecovRate,-100; bonus2 bHPLossRate,666,10000;',NULL,'heal -999,0;'); +REPLACE INTO `item_db_re` VALUES (4263,'Incant_Samurai_Card','Samurai Spector Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL,NULL,'bonus bIgnoreDefRace,RC_NonBoss; bonus bHPrecovRate,-100; bonus2 bHPLossRate,666,10000;',NULL,'if( (Hp <= 999) && !getmapflag(strcharinfo(3),6) && !getmapflag(strcharinfo(3),7) && !getmapflag(strcharinfo(3),8) ) { heal (1 - Hp), 0; } else { heal -999, 0; }'); REPLACE INTO `item_db_re` VALUES (4264,'Wind_Ghost_Card','Wind Ghost Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,136,NULL,NULL,NULL,NULL,'bonus3 bAutoSpell,"WZ_JUPITEL",3+7*(getskilllv("WZ_JUPITEL")==10),20;',NULL,NULL); REPLACE INTO `item_db_re` VALUES (4265,'Li_Me_Mang_Ryang_Card','Jing Guai Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,136,NULL,NULL,NULL,NULL,'bonus3 bAddMonsterDropItem,12033,RC_Angel,100;',NULL,NULL); REPLACE INTO `item_db_re` VALUES (4266,'Eclipse_Card','Eclipse Card',6,20,NULL,10,NULL,NULL,NULL,NULL,NULL,NULL,NULL,4,NULL,NULL,NULL,NULL,'bonus bVit,1;',NULL,NULL); diff --git a/src/char/int_elemental.c b/src/char/int_elemental.c index d81e10f84..7c76c4496 100644 --- a/src/char/int_elemental.c +++ b/src/char/int_elemental.c @@ -90,8 +90,6 @@ bool mapif_elemental_delete(int ele_id) { return true; } -#ifndef TXT_SQL_CONVERT - static void mapif_elemental_send(int fd, struct s_elemental *ele, unsigned char flag) { int size = sizeof(struct s_elemental) + 5; @@ -161,4 +159,3 @@ int inter_elemental_parse_frommap(int fd) { } return 1; } -#endif //TXT_SQL_CONVERT diff --git a/src/char/int_guild.h b/src/char/int_guild.h index 202b9b512..47c42dcc5 100644 --- a/src/char/int_guild.h +++ b/src/char/int_guild.h @@ -34,8 +34,4 @@ int inter_guild_charname_changed(int guild_id,int account_id, int char_id, char int inter_guild_CharOnline(int char_id, int guild_id); int inter_guild_CharOffline(int char_id, int guild_id); -//For the TXT->SQL converter. -int inter_guild_tosql(struct guild *g,int flag); -int inter_guildcastle_tosql(struct guild_castle *gc); - #endif /* _INT_GUILD_SQL_H_ */ diff --git a/src/char/int_party.h b/src/char/int_party.h index 703cd5bd5..d8cdcdc6a 100644 --- a/src/char/int_party.h +++ b/src/char/int_party.h @@ -22,7 +22,5 @@ void inter_party_sql_final(void); int inter_party_leave(int party_id,int account_id, int char_id); int inter_party_CharOnline(int char_id, int party_id); int inter_party_CharOffline(int char_id, int party_id); -//Required for the TXT->SQL converter -int inter_party_tosql(struct party *p, int flag, int index); #endif /* _INT_PARTY_SQL_H_ */ diff --git a/src/map/atcommand.c b/src/map/atcommand.c index 45f14be6f..b7b59940e 100644 --- a/src/map/atcommand.c +++ b/src/map/atcommand.c @@ -2179,12 +2179,11 @@ static int atkillmonster_sub(struct block_list *bl, va_list ap) return 1; } -void atcommand_killmonster_sub(const int fd, struct map_session_data* sd, const char* message, const int drop) +ACMD_FUNC(killmonster) { - int map_id; + int map_id, drop_flag; char map_name[MAP_NAME_LENGTH_EXT]; - - if (!sd) return; + nullpo_retr(-1, sd); memset(map_name, '\0', sizeof(map_name)); @@ -2194,26 +2193,13 @@ void atcommand_killmonster_sub(const int fd, struct map_session_data* sd, const if ((map_id = map_mapname2mapid(map_name)) < 0) map_id = sd->bl.m; } + + drop_flag = strcmp(command+1, "killmonster2"); - map_foreachinmap(atkillmonster_sub, map_id, BL_MOB, drop); + map_foreachinmap(atkillmonster_sub, map_id, BL_MOB, -drop_flag); clif_displaymessage(fd, msg_txt(165)); // All monsters killed! - return; -} - -ACMD_FUNC(killmonster) -{ - atcommand_killmonster_sub(fd, sd, message, 1); - return 0; -} - -/*========================================== - * - *------------------------------------------*/ -ACMD_FUNC(killmonster2) -{ - atcommand_killmonster_sub(fd, sd, message, 0); return 0; } @@ -8866,7 +8852,7 @@ void atcommand_basecommands(void) { ACMD_DEF2("monstersmall", monster), ACMD_DEF2("monsterbig", monster), ACMD_DEF(killmonster), - ACMD_DEF(killmonster2), + ACMD_DEF2("killmonster2", killmonster), ACMD_DEF(refine), ACMD_DEF(produce), ACMD_DEF(memo), diff --git a/src/map/battle.c b/src/map/battle.c index 47f18e881..18aadf0ac 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -5230,8 +5230,10 @@ int battle_check_target( struct block_list *src, struct block_list *target,int f if( !md->special_state.ai ) { //Normal mobs - if( (target->type == BL_MOB && t_bl->type == BL_PC && ((TBL_MOB*)target)->special_state.ai < 4) || - ( t_bl->type == BL_MOB && !((TBL_MOB*)t_bl)->special_state.ai ) ) + if( + ( target->type == BL_MOB && t_bl->type == BL_PC && ( ((TBL_MOB*)target)->special_state.ai != 4 && ((TBL_MOB*)target)->special_state.ai != 1 ) ) || + ( t_bl->type == BL_MOB && !((TBL_MOB*)t_bl)->special_state.ai ) + ) state |= BCT_PARTY; //Normal mobs with no ai are friends. else state |= BCT_ENEMY; //However, all else are enemies. diff --git a/src/map/elemental.c b/src/map/elemental.c index 3abab157f..1157e851e 100644 --- a/src/map/elemental.c +++ b/src/map/elemental.c @@ -457,13 +457,6 @@ int elemental_change_mode(struct elemental_data *ed, int mode) { return 1; } -void elemental_damage(struct elemental_data *ed, int hp, int sp) { - if( hp ) - clif_elemental_updatestatus(ed->master, SP_HP); - if( sp ) - clif_elemental_updatestatus(ed->master, SP_SP); -} - void elemental_heal(struct elemental_data *ed, int hp, int sp) { if( hp ) clif_elemental_updatestatus(ed->master, SP_HP); @@ -471,7 +464,7 @@ void elemental_heal(struct elemental_data *ed, int hp, int sp) { clif_elemental_updatestatus(ed->master, SP_SP); } -int elemental_dead(struct elemental_data *ed, struct block_list *src) { +int elemental_dead(struct elemental_data *ed) { elemental_delete(ed, 1); return 0; } @@ -645,7 +638,6 @@ static int elemental_ai_sub_foreachclient(struct map_session_data *sd, va_list a static int elemental_ai_timer(int tid, unsigned int tick, int id, intptr_t data) { map_foreachpc(elemental_ai_sub_foreachclient,tick); - return 0; } diff --git a/src/map/elemental.h b/src/map/elemental.h index 124c7ff83..698cf6fb9 100644 --- a/src/map/elemental.h +++ b/src/map/elemental.h @@ -67,9 +67,8 @@ int elemental_save(struct elemental_data *ed); int elemental_change_mode_ack(struct elemental_data *ed, int mode); int elemental_change_mode(struct elemental_data *ed, int mode); -void elemental_damage(struct elemental_data *ed, int hp, int sp); void elemental_heal(struct elemental_data *ed, int hp, int sp); -int elemental_dead(struct elemental_data *ed, struct block_list *src); +int elemental_dead(struct elemental_data *ed); int elemental_delete(struct elemental_data *ed, int reply); void elemental_summon_stop(struct elemental_data *ed); diff --git a/src/map/homunculus.c b/src/map/homunculus.c index 46da045a4..081e7078e 100644 --- a/src/map/homunculus.c +++ b/src/map/homunculus.c @@ -85,7 +85,7 @@ void merc_damage(struct homun_data *hd) { clif_hominfo(hd->master,hd,0); } -int merc_hom_dead(struct homun_data *hd, struct block_list *src) +int merc_hom_dead(struct homun_data *hd) { //There's no intimacy penalties on death (from Tharis) struct map_session_data *sd = hd->master; diff --git a/src/map/homunculus.h b/src/map/homunculus.h index 3470cd5f5..7ad9268b2 100644 --- a/src/map/homunculus.h +++ b/src/map/homunculus.h @@ -80,7 +80,7 @@ int merc_hom_recv_data(int account_id, struct s_homunculus *sh, int flag); //alb struct view_data* merc_get_hom_viewdata(int class_); int hom_class2mapid(int hom_class); void merc_damage(struct homun_data *hd); -int merc_hom_dead(struct homun_data *hd, struct block_list *src); +int merc_hom_dead(struct homun_data *hd); void merc_hom_skillup(struct homun_data *hd,int skillnum); int merc_hom_calc_skilltree(struct homun_data *hd); int merc_hom_checkskill(struct homun_data *hd,int skill_id); diff --git a/src/map/mail.c b/src/map/mail.c index ce099d0a1..70c73c0a4 100644 --- a/src/map/mail.c +++ b/src/map/mail.c @@ -20,7 +20,6 @@ void mail_clear(struct map_session_data *sd) sd->mail.index = 0; sd->mail.amount = 0; sd->mail.zeny = 0; - sd->auction.amount = 0; return; } diff --git a/src/map/mercenary.c b/src/map/mercenary.c index 45e8e04ce..832cc835b 100644 --- a/src/map/mercenary.c +++ b/src/map/mercenary.c @@ -344,14 +344,6 @@ int merc_data_received(struct s_mercenary *merc, bool flag) return 1; } -void mercenary_damage(struct mercenary_data *md, int hp, int sp) -{ - if( hp ) - clif_mercenary_updatestatus(md->master, SP_HP); - if( sp ) - clif_mercenary_updatestatus(md->master, SP_SP); -} - void mercenary_heal(struct mercenary_data *md, int hp, int sp) { if( hp ) @@ -360,7 +352,7 @@ void mercenary_heal(struct mercenary_data *md, int hp, int sp) clif_mercenary_updatestatus(md->master, SP_SP); } -int mercenary_dead(struct mercenary_data *md, struct block_list *src) +int mercenary_dead(struct mercenary_data *md) { merc_delete(md, 1); return 0; diff --git a/src/map/mercenary.h b/src/map/mercenary.h index 340ab1462..014bd8937 100644 --- a/src/map/mercenary.h +++ b/src/map/mercenary.h @@ -56,9 +56,8 @@ int merc_create(struct map_session_data *sd, int class_, unsigned int lifetime); int merc_data_received(struct s_mercenary *merc, bool flag); int mercenary_save(struct mercenary_data *md); -void mercenary_damage(struct mercenary_data *md, int hp, int sp); void mercenary_heal(struct mercenary_data *md, int hp, int sp); -int mercenary_dead(struct mercenary_data *md, struct block_list *src); +int mercenary_dead(struct mercenary_data *md); int merc_delete(struct mercenary_data *md, int reply); void merc_contract_stop(struct mercenary_data *md); diff --git a/src/map/mob.h b/src/map/mob.h index 797d2484b..d45962163 100644 --- a/src/map/mob.h +++ b/src/map/mob.h @@ -121,7 +121,7 @@ struct mob_data { char name[NAME_LENGTH]; struct { unsigned int size : 2; //Small/Big monsters. - unsigned int ai : 3; //Special ai for summoned monsters. + unsigned int ai : 4; //Special ai for summoned monsters. //0: Normal mob. //1: Standard summon, attacks mobs. //2: Alchemist Marine Sphere diff --git a/src/map/skill.c b/src/map/skill.c index 86516e337..7dcfa2552 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -11902,8 +11902,8 @@ static int skill_unit_effect (struct block_list* bl, va_list ap) skill_id = group->skill_id; //Target-type check. - if( !(group->bl_flag&bl->type && battle_check_target(&unit->bl,bl,group->target_flag)>0) && (flag&4) ) { - if( group->state.song_dance&0x1 || (group->src_id == bl->id && group->state.song_dance&0x2) ) + if( !(group->bl_flag&bl->type && battle_check_target(&unit->bl,bl,group->target_flag)>0) ) { + if( flag&4 && ((group->src_id == bl->id && group->state.song_dance&0x2) || skill_get_inf2(skill_id)&INF2_SONG_DANCE) ) skill_unit_onleft(skill_id, bl, tick);//Ensemble check to terminate it. } else { if( flag&1 ) diff --git a/src/map/status.c b/src/map/status.c index eff787956..e097dcdb1 100644 --- a/src/map/status.c +++ b/src/map/status.c @@ -1224,8 +1224,8 @@ int status_damage(struct block_list *src,struct block_list *target,int hp, int s case BL_PC: pc_damage((TBL_PC*)target,src,hp,sp); break; case BL_MOB: mob_damage((TBL_MOB*)target, src, hp); break; case BL_HOM: merc_damage((TBL_HOM*)target); break; - case BL_MER: mercenary_damage((TBL_MER*)target,hp,sp); break; - case BL_ELEM: elemental_damage((TBL_ELEM*)target,hp,sp); break; + case BL_MER: mercenary_heal((TBL_MER*)target,hp,sp); break; + case BL_ELEM: elemental_heal((TBL_ELEM*)target,hp,sp); break; } if( src && target->type == BL_PC && ((TBL_PC*)target)->disguise ) {// stop walking when attacked in disguise to prevent walk-delay bug @@ -1248,9 +1248,9 @@ int status_damage(struct block_list *src,struct block_list *target,int hp, int s switch (target->type) { case BL_PC: flag = pc_dead((TBL_PC*)target,src); break; case BL_MOB: flag = mob_dead((TBL_MOB*)target, src, flag&4?3:0); break; - case BL_HOM: flag = merc_hom_dead((TBL_HOM*)target,src); break; - case BL_MER: flag = mercenary_dead((TBL_MER*)target,src); break; - case BL_ELEM: flag = elemental_dead((TBL_ELEM*)target,src); break; + case BL_HOM: flag = merc_hom_dead((TBL_HOM*)target); break; + case BL_MER: flag = mercenary_dead((TBL_MER*)target); break; + case BL_ELEM: flag = elemental_dead((TBL_ELEM*)target); break; default: //Unhandled case, do nothing to object. flag = 0; break; diff --git a/tools/backup.pl b/tools/backup.pl deleted file mode 100755 index 939c7eee7..000000000 --- a/tools/backup.pl +++ /dev/null @@ -1,100 +0,0 @@ -#!/usr/bin/perl - -########################################################################## -# Athena�p�f�[�^�o�b�N�A�b�v�c�[�� -# -# �@Athena�̊e��f�[�^�t�@�C��*.txt���o�b�N�A�b�v����c�[�� -# -#------------------------------------------------------------------------- -# �ݒ���@ -# �@���s���鎞�̃J�����g�t�H���_����̃f�[�^�ւ̃p�X�A�t�@�C���̃��X�g�� -# �@�������ݒ肵�܂��B�o�b�N�A�b�v��̃t�H���_�͎����쐬����Ȃ��̂ŁA -# �@�����ō쐬���Ă����K�v������܂��B -# �@�t�H���_�̍Ō�́u/�v�͏ȗ��ł��܂���B -# -# �@�t�H���_�͈����ł��w��ł��܂��B�၄./backup ../save/ ./backup_data/ -# �@�t�H���_�̍Ō�́u/�v�͏ȗ��ł��܂���B -# -# �@���s����ƃo�b�N�A�b�v��̃t�H���_�ցA�t�@�C�����Ɍ��݂̓��t�Ǝ����� -# �@���ăt�@�C�����R�s�[���܂��B -# -# * tool�t�H���_����backup_data�t�H���_���쐬���A -# �@ athena.sh�̒��Ɂu./tool/backup ./save/ ./tool/backup_data/�v -# �Ƃ����s��lj�����ƁAathena���N�����邽�тɃo�b�N�A�b�v�����܂� -# -# ��������Ƃ��͈����Ɂu-r ���t�Ǝ����v���w�肵�܂��B -# �@�܂����̌��Ƀt�H���_���w�肷�邱�Ƃ��o���܂� -# �@��P�� ./backup -r 200309191607 -# �@��Q�� ./backup -r 200309191607 ../save ./backup_data/ -# �@���̗�ł�2003/09/19��16:07���Ƀo�b�N�A�b�v�����f�[�^�����Ă��܂� -# -# �@��������Ƃ��AAthena�f�B���N�g���ɂ���f�[�^�� *.bak �ɖ��O��ύX���� -# �@�c���Ă���̂ŁA����Ȃ��ꍇ�� rm *.bak �Ȃǂŏ����Ă��������B -# -########################################################################## - -$sdir="../save/"; #�o�b�N�A�b�v��(Athena�̃f�B���N�g��/save/) -$tdir="./backup_data/"; #�o�b�N�A�b�v�� - -@files=( #�t�@�C���̃��X�g - "account","athena","storage","party","guild","castle","pet" -); - - -#-------------------------------�ݒ肱���܂�----------------------------- - - - - - - - - - - - -if($ARGV[0]=~/^\-r$/i || $ARGV[0]=~/\-\-(recover|restore)/i){ - #�������� - - $file=$ARGV[1]; - $sdir=$ARGV[2]||$sdir; - $tdir=$ARGV[3]||$tdir; - &restorecopy($_) foreach @files; - exit(0); -} - -#�o�b�N�A�b�v���� -$sdir=$ARGV[0]||$sdir; -$tdir=$ARGV[1]||$tdir; - -unless( -d $tdir ){ - print "$0: \"$tdir\" : No such directory\n"; - exit(1); -} - -(undef,$min,$hour,$day,$month,$year)=localtime; - -$file=sprintf("%04d%02d%02d%02d%02d", - $year+1900, $month+1, $day, $hour, $min ); - -&backupcopy($_) foreach @files; -exit(0); - -sub backupcopy { - my($name)= @_; - system("cp $sdir$name.txt $tdir$name$file.txt"); -} - -sub restorecopy { - my($name)= @_; - unless( -f "$sdir$name.txt" ){ - printf("$0: \"$sdir$name.txt\" not found!\n"); - return 0; - } - unless( -f "$tdir$name$file.txt" ){ - printf("$0: \"$tdir$name$file.txt\" not found!\n"); - return 0; - } - rename "$sdir$name.txt","$sdir$name.bak"; - system("cp $tdir$name$file.txt $sdir$name.txt"); -} diff --git a/tools/vs9-to-vs8.php b/tools/vs9-to-vs8.php deleted file mode 100644 index 9cc05fb76..000000000 --- a/tools/vs9-to-vs8.php +++ /dev/null @@ -1,46 +0,0 @@ -<?php - // Visual Studio 9 to Visual Studio 8 project file converter - // author : theultramage - // version: 16. august 2008 -?> -<?php - fwrite(STDERR, "VS9 to VS8 project file converter".PHP_EOL); - fwrite(STDERR, "---------------------------------".PHP_EOL); - if( @$_SERVER["argc"] < 2 ) - { - fwrite(STDERR, "Usage: {$_SERVER["argv"][0]} file.vcproj".PHP_EOL); - exit(); - } - - $input = @$_SERVER["argv"][1]; - $data = file($input); - if( $data === FALSE ) - die("invalid input file '".$input."'"); - - fwrite(STDERR, "Converting {$input}...".PHP_EOL); - - $eol = ( strstr($data[0], "\r\n") !== FALSE ) ? "\r\n" : "\n"; - define("EOL", $eol); - - foreach( $data as $line ) - { - if( strstr($line,'Version="9,00"') !== FALSE ) - fwrite(STDOUT, "\t".'Version="8,00"'.EOL); - else - if( strstr($line,'Version="9.00"') !== FALSE ) - fwrite(STDOUT, "\t".'Version="8.00"'.EOL); - else - if( strstr($line,'TargetFrameworkVersion') !== FALSE ) - ; - else - if( strstr($line,'RandomizedBaseAddress') !== FALSE ) - ; - else - if( strstr($line,'DataExecutionPrevention') !== FALSE ) - ; - else // default - fwrite(STDOUT, $line); - } - - fwrite(STDERR, "done.".PHP_EOL); -?> |