* Fixed player keeps bleeding when dead.
- if battle_config.invincible_nodamage is true, reflected damage to targets in invincible status is now 1. * Fixed a script typo i made when i was fixing a typo... git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@14164 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
e7a9a5bf46
commit
cc02657862
@ -3,6 +3,9 @@ Date Added
|
|||||||
AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
|
AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
|
||||||
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
|
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
|
||||||
|
|
||||||
|
2009/11/23
|
||||||
|
* Fixed player keeps bleeding when dead. [Inkfish]
|
||||||
|
- If battle_config.invincible_nodamage is true, reflected damage to targets in invincible status is now 1.
|
||||||
2009/11/22
|
2009/11/22
|
||||||
* Added 'ipban_cleanup_interval' option which determines how often expired IP bans are cleaned from the database. (bugreport:3734) [Paradox924X]
|
* Added 'ipban_cleanup_interval' option which determines how often expired IP bans are cleaned from the database. (bugreport:3734) [Paradox924X]
|
||||||
* Modified ipban_check() to only include ipbans that haven't already expired. (bugreport:3734) [Paradox924X]
|
* Modified ipban_check() to only include ipbans that haven't already expired. (bugreport:3734) [Paradox924X]
|
||||||
|
@ -2219,7 +2219,7 @@ tur_dun03,104,171,4 script Knight#tur3 105,{
|
|||||||
mes "[Squall]";
|
mes "[Squall]";
|
||||||
mes "Am I the only one left? Where are all my comrades?! I... I'm about to go crazy!";
|
mes "Am I the only one left? Where are all my comrades?! I... I'm about to go crazy!";
|
||||||
next;
|
next;
|
||||||
if(select("Maybe they ran away?:What happened?")) {
|
if(select("Maybe they ran away?:What happened?") == 1) {
|
||||||
mes "[Squall]";
|
mes "[Squall]";
|
||||||
mes "No, we would never run away from the face of danger.";
|
mes "No, we would never run away from the face of danger.";
|
||||||
next;
|
next;
|
||||||
|
@ -7369,6 +7369,9 @@ void pc_bleeding (struct map_session_data *sd, unsigned int diff_tick)
|
|||||||
{
|
{
|
||||||
int hp = 0, sp = 0;
|
int hp = 0, sp = 0;
|
||||||
|
|
||||||
|
//if( pc_isdead(sd) )
|
||||||
|
// return;
|
||||||
|
|
||||||
if (sd->hp_loss.value) {
|
if (sd->hp_loss.value) {
|
||||||
sd->hp_loss.tick += diff_tick;
|
sd->hp_loss.tick += diff_tick;
|
||||||
while (sd->hp_loss.tick >= sd->hp_loss.rate) {
|
while (sd->hp_loss.tick >= sd->hp_loss.rate) {
|
||||||
|
@ -628,6 +628,7 @@ int status_charge(struct block_list* bl, int hp, int sp)
|
|||||||
//If flag&1, damage is passive and does not triggers cancelling status changes.
|
//If flag&1, damage is passive and does not triggers cancelling status changes.
|
||||||
//If flag&2, fail if target does not has enough to substract.
|
//If flag&2, fail if target does not has enough to substract.
|
||||||
//If flag&4, if killed, mob must not give exp/loot.
|
//If flag&4, if killed, mob must not give exp/loot.
|
||||||
|
//If flag&8, sp loss on dead target.
|
||||||
int status_damage(struct block_list *src,struct block_list *target,int hp, int sp, int walkdelay, int flag)
|
int status_damage(struct block_list *src,struct block_list *target,int hp, int sp, int walkdelay, int flag)
|
||||||
{
|
{
|
||||||
struct status_data *status;
|
struct status_data *status;
|
||||||
@ -653,9 +654,11 @@ int status_damage(struct block_list *src,struct block_list *target,int hp, int s
|
|||||||
return skill_unit_ondamaged((struct skill_unit *)target, src, hp, gettick());
|
return skill_unit_ondamaged((struct skill_unit *)target, src, hp, gettick());
|
||||||
|
|
||||||
status = status_get_status_data(target);
|
status = status_get_status_data(target);
|
||||||
|
if( status == &dummy_status )
|
||||||
|
return 0;
|
||||||
|
|
||||||
if( status == &dummy_status || (!status->hp && hp) )
|
if( !status->hp )
|
||||||
return 0; //Invalid targets: no damage or dead
|
flag |= 8;
|
||||||
|
|
||||||
// Let through. battle.c/skill.c have the whole logic of when it's possible or
|
// Let through. battle.c/skill.c have the whole logic of when it's possible or
|
||||||
// not to hurt someone (and this check breaks pet catching) [Skotlex]
|
// not to hurt someone (and this check breaks pet catching) [Skotlex]
|
||||||
@ -663,15 +666,10 @@ int status_damage(struct block_list *src,struct block_list *target,int hp, int s
|
|||||||
// return 0; //Cannot damage a bl not on a map, except when "charging" hp/sp
|
// return 0; //Cannot damage a bl not on a map, except when "charging" hp/sp
|
||||||
|
|
||||||
sc = status_get_sc(target);
|
sc = status_get_sc(target);
|
||||||
|
|
||||||
if( battle_config.invincible_nodamage && src && sc && sc->data[SC_INVINCIBLE] && !sc->data[SC_INVINCIBLEOFF] )
|
if( battle_config.invincible_nodamage && src && sc && sc->data[SC_INVINCIBLE] && !sc->data[SC_INVINCIBLEOFF] )
|
||||||
{
|
|
||||||
if( !sp )
|
|
||||||
return 0;
|
|
||||||
hp = 1;
|
hp = 1;
|
||||||
}
|
|
||||||
|
|
||||||
if( hp && !(flag&1) ) {
|
if( hp && !(flag&1|8) ) {
|
||||||
if( sc ) {
|
if( sc ) {
|
||||||
struct status_change_entry *sce;
|
struct status_change_entry *sce;
|
||||||
if( (sce = sc->data[SC_DEVOTION]) && src && battle_getcurrentskill(src) != PA_PRESSURE )
|
if( (sce = sc->data[SC_DEVOTION]) && src && battle_getcurrentskill(src) != PA_PRESSURE )
|
||||||
@ -751,8 +749,8 @@ int status_damage(struct block_list *src,struct block_list *target,int hp, int s
|
|||||||
case BL_MER: mercenary_damage((TBL_MER*)target,src,hp,sp); break;
|
case BL_MER: mercenary_damage((TBL_MER*)target,src,hp,sp); break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (status->hp)
|
if( status->hp || flag&8 )
|
||||||
{ //Still lives!
|
{ //Still lives or has been dead before this damage.
|
||||||
if (walkdelay)
|
if (walkdelay)
|
||||||
unit_set_walkdelay(target, gettick(), walkdelay, 0);
|
unit_set_walkdelay(target, gettick(), walkdelay, 0);
|
||||||
return hp+sp;
|
return hp+sp;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user