Norse Posted November 26, 2013 Posted November 26, 2013 How to make this item bonus works on all monsters(including MVPs) and players? currently,this item bonus only work on players. Someone? Quote
Norse Posted November 29, 2013 Author Posted November 29, 2013 Really hope that someone could help me Quote
Discount Ninja Posted November 29, 2013 Posted November 29, 2013 I'm not sure you can do something like that. But you are able to add skills that do similar things. If you want a monster that hurts itself, self hurting skills like grand cross will injure the monster. This adds really cool affects on the monsters. My custom monsters like to give themselves buffs as their health gets low. Keep in mind the skills will only go off when the map has players on it. Quote
Norse Posted November 30, 2013 Author Posted November 30, 2013 (edited) What i mean here is bHPVanishRate and bSPVanishRate bonus only working if we hit players on pvp and gvg mapflags,i want it working on every mapflags & on every monster to(includiing MVPs). bonus2 bSPVanishRate,n,x; Add the (n/10)% chance of decreasing enemy's SP (player) amount by x% when attacking +bonus2 bHPVanishRate,n,x; Add the (n/10)% chance of decreasing enemy's HP (player) amount by x% when attacking which part do i have to edit? /*=========================================== * Perform battle drain effects (HP/SP loss) *-------------------------------------------*/ void battle_drain(TBL_PC *sd, struct block_list *tbl, int64 rdamage, int64 ldamage, int race, int boss) { struct weapon_data *wd; int64 *damage; int type, thp = 0, tsp = 0, rhp = 0, rsp = 0, hp, sp, i; for (i = 0; i < 4; i++) { //First two iterations: Right hand if (i < 2) { wd = &sd->right_weapon; damage = &rdamage; } else { wd = &sd->left_weapon; damage = &ldamage; } if (*damage <= 0) continue; //First and Third iterations: race, other two boss/nonboss state if (i == 0 || i == 2) type = race; else type = boss?RC_BOSS:RC_NONBOSS; hp = wd->hp_drain[type].value; if (wd->hp_drain[type].rate) hp += battle_calc_drain(*damage, wd->hp_drain[type].rate, wd->hp_drain[type].per); sp = wd->sp_drain[type].value; if (wd->sp_drain[type].rate) sp += battle_calc_drain(*damage, wd->sp_drain[type].rate, wd->sp_drain[type].per); if (hp) { if (wd->hp_drain[type].type) rhp += hp; thp += hp; } if (sp) { if (wd->sp_drain[type].type) rsp += sp; tsp += sp; } } if (sd->bonus.sp_vanish_rate && rnd()%1000 < sd->bonus.sp_vanish_rate) status_percent_damage(&sd->bl, tbl, 0, (unsigned char)sd->bonus.sp_vanish_per, false); if (sd->bonus.hp_vanish_rate && rnd()%1000 < sd->bonus.hp_vanish_rate && tbl->type == BL_PC && (map[sd->bl.m].flag.pvp || map[sd->bl.m].flag.gvg)) status_percent_damage(&sd->bl, tbl, (unsigned char)sd->bonus.hp_vanish_per, 0, false); if( sd->sp_gain_race_attack[race] ) tsp += sd->sp_gain_race_attack[race]; if( sd->hp_gain_race_attack[race] ) thp += sd->hp_gain_race_attack[race]; if (!thp && !tsp) return; status_heal(&sd->bl, thp, tsp, battle_config.show_hp_sp_drain?3:1); if (rhp || rsp) status_zap(tbl, rhp, rsp); } Edited November 30, 2013 by Norse Quote
Norse Posted December 5, 2013 Author Posted December 5, 2013 Can anyone help me? All i want is make this item bonus working on all kind of maps flag,not only on pvp and gvg map. And make it works on monsters & MVP,not only players. Quote
Critica Posted December 6, 2013 Posted December 6, 2013 like this..? bonus3 bHPDrainRatio,n,x,y; y/10% chance to drain x% current HP of the enemy of race n, and absorb it as health bonus3 bSPDrainRatio,n,x,y; y/10% chance to drain x% current SP of the enemy of race n, and absorb it as SP n: 0=Formless, 1=Undead, 2=Brute, 3=Plant, 4=Insect, 5=Fish, 6=Demon, 7=Demi-Human, 8=Angel, 9=Dragon, 10=Boss monster, 11=Other than (normal monster) boss monster Quote
Norse Posted December 6, 2013 Author Posted December 6, 2013 like this..? bonus3 bHPDrainRatio,n,x,y; y/10% chance to drain x% current HP of the enemy of race n, and absorb it as health bonus3 bSPDrainRatio,n,x,y; y/10% chance to drain x% current SP of the enemy of race n, and absorb it as SP n: 0=Formless, 1=Undead, 2=Brute, 3=Plant, 4=Insect, 5=Fish, 6=Demon, 7=Demi-Human, 8=Angel, 9=Dragon, 10=Boss monster, 11=Other than (normal monster) boss monster Yes,and can be use on any mapflags,not only the PVP and GVG maps. Quote
Evil Posted January 6, 2014 Posted January 6, 2014 like this..? bonus3 bHPDrainRatio,n,x,y; y/10% chance to drain x% current HP of the enemy of race n, and absorb it as health bonus3 bSPDrainRatio,n,x,y; y/10% chance to drain x% current SP of the enemy of race n, and absorb it as SP n: 0=Formless, 1=Undead, 2=Brute, 3=Plant, 4=Insect, 5=Fish, 6=Demon, 7=Demi-Human, 8=Angel, 9=Dragon, 10=Boss monster, 11=Other than (normal monster) boss monster RC_BOSS and RC_NONBOSS = all race monsters bonus3 bSPDrainRatio,RC_BOSS,1,1000; bonus3 bSPDrainRatio,RC_NONBOSS,1,1000; Quote
Question
Norse
How to make this item bonus works on all monsters(including MVPs) and players? currently,this item bonus only work on players.
Someone?
11 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.