Jump to content
  • 0
Yuno

How to add Endure, Auto Guard and Reflect Shield stateicon to character under influence of devotion?

Question

Hi rAthena, long time no see!!

After a few hours of research, i found that devotion skill give shield buff and other buff like Endure.
I don't know if i have a real information but according to iro wiki and ratemyserver.
 

Quote

Ratemyserver : (https://ratemyserver.net/index.php?page=skill_db&jid=14)
If the caster has any self casted, class native enhancements on him, e.g. Endure (Endure transfer is disabled in WoE), Providence or Reflect Shield, the party member(s) will share these benefits, too.

iRO WikiI: (https://irowiki.org/classic/Sacrifice)

  • Certain abilities function through Sacrifice: Guard, Shield Reflect, and Defending Aura. Guard works as if the sacrificed target had the skill active, also inducing physical attack delay when activated. Shield Reflect only works on melee skills when applied through Sacrifice. This includes Guillotine Fist, as well as Arrow Shower cast by a monster. Defending Aura currently will slow all sacrificed targets when activated, but only apply a reduced damage reduction compared to the 80% reduction on the caster.

So I tried adding a stateicon for the Devotion skill, successful as you can see.
devo_eg.png.676eca2bec7a02ad526807dd883f6448.png

And I said to myself ok, now I'm going to see if the icons for Endure, Auto Guard and Reflect Shield appears when I am under the influence of Devotion and it looks like only the Defender icon is displayed. Could someone have an explanation for me?
devotion2.png.c4af3156767c529715762687bd6e8640.png

Thank you for the time you take to answer me!

Share this post


Link to post
Share on other sites

8 answers to this question

Recommended Posts

  • 0
Posted (edited)

Okay. To mirror Endure to devoted party

status.c
look for this line:
 

	case SC_IMPOSITIO:
	case SC_KAAHI:
		//These status changes always overwrite themselves even when a lower level is cast
		status_change_end(bl, type, INVALID_TIMER);
		break;
	case SC_ENDURE:
		if (sd && sd->special_state.no_walk_delay)
			return 1;
		break;
	}

change it to

	case SC_IMPOSITIO:
	case SC_KAAHI:
		//These status changes always overwrite themselves even when a lower level is cast
		status_change_end(bl, type, INVALID_TIMER);
		break;
	case SC_ENDURE:
		if (sd) {
			struct map_session_data *tsd;
			int i;
			for (i = 0; i < MAX_DEVOTION; i++) { // See if there are devoted characters, and pass the status to them. [Skotlex]
				if (sd->devotion[i] && (tsd = map_id2sd(sd->devotion[i])))
					status_change_start(src,&tsd->bl,type,10000,val1,val2,val3,val4,tick,SCSTART_NOAVOID);
			}
		}
		if (sd && sd->special_state.no_walk_delay)
			return 1;
		break;
	}



For the reflect shield

status.c
look for this line:
 

		case SC_PROVIDENCE:
			val2 = val1*5; // Race/Ele resist
			break;
		case SC_REFLECTSHIELD:
			val2 = 10+val1*3; // %Dmg reflected
			// val4 used to mark if reflect shield is an inheritance bonus from Devotion
			if( !(flag&SCSTART_NOAVOID) && (bl->type&(BL_PC|BL_MER)) ) {
				struct map_session_data *tsd;
				if( sd ) {
					int i;
					for( i = 0; i < MAX_DEVOTION; i++ ) {
						if( sd->devotion[i] && (tsd = map_id2sd(sd->devotion[i])) )
							status_change_start(src,&tsd->bl, type, 10000, val1, val2, 0, 1, tick, SCSTART_NOAVOID|SCSTART_NOICON);
					}
				}
				else if( bl->type == BL_MER && ((TBL_MER*)bl)->devotion_flag && (tsd = ((TBL_MER*)bl)->master) )
					status_change_start(src,&tsd->bl, type, 10000, val1, val2, 0, 1, tick, SCSTART_NOAVOID|SCSTART_NOICON);
			}

change it to
 

		case SC_PROVIDENCE:
			val2 = val1*5; // Race/Ele resist
			break;
		case SC_REFLECTSHIELD:
			val2 = 10+val1*3; // %Dmg reflected
			// val4 used to mark if reflect shield is an inheritance bonus from Devotion
			if( !(flag&SCSTART_NOAVOID) && (bl->type&(BL_PC|BL_MER)) ) {
				struct map_session_data *tsd;
				if( sd ) {
					int i;
					for( i = 0; i < MAX_DEVOTION; i++ ) {
						if( sd->devotion[i] && (tsd = map_id2sd(sd->devotion[i])) )
							status_change_start(src,&tsd->bl, type, 10000, val1, val2, 0, 1, tick, SCSTART_NOAVOID);
					}
				}
				else if( bl->type == BL_MER && ((TBL_MER*)bl)->devotion_flag && (tsd = ((TBL_MER*)bl)->master) )
					status_change_start(src,&tsd->bl, type, 10000, val1, val2, 0, 1, tick, SCSTART_NOAVOID|SCSTART_NOICON);
			}
			break;


To be honest im not sure about to reflect shield. I might delete some function. But it works upon testing it.  Nevermind. I edit it. 🙂

Limitations i found:
The Devo caster should recast (Endure & Reflect Shield)  buffs to appear the state icons to devoted party member.

P.S
I wonder why recasting is needed.

Edited by Gidz Cross
modified some stuff
  • MVP 1

Share this post


Link to post
Share on other sites
  • 0

Its me again! 
I would like to provide additional information regarding my request. 

From the LGP presentation video in @Functor services, we can see what it would seem a High Wizard (we can see Energie Coat on stateicon) which also displays auto guard and reflect shield when under the influence of devotion. Maybe it is my client's problem, but I still haven't found the solution.

2064801316_eg2.thumb.png.3740e46ce91f12d8ac6b6191a417e2fd.png

Share this post


Link to post
Share on other sites
  • 0
On 7/22/2021 at 10:01 AM, Yuno said:

Hi rAthena, long time no see!!

After a few hours of research, i found that devotion skill give shield buff and other buff like Endure.
I don't know if i have a real information but according to iro wiki and ratemyserver.
 

So I tried adding a stateicon for the Devotion skill, successful as you can see.
devo_eg.png.676eca2bec7a02ad526807dd883f6448.png

And I said to myself ok, now I'm going to see if the icons for Endure, Auto Guard and Reflect Shield appears when I am under the influence of Devotion and it looks like only the Defender icon is displayed. Could someone have an explanation for me?
devotion2.png.c4af3156767c529715762687bd6e8640.png

Thank you for the time you take to answer me!

Oh why didnt i think of this. I have custom state icons too. Like when you stepped on land protector or you cast ecall. But ive done it in a very long time. Now i forgot. I want to help with this. Since the defender state can be mirrored in the devo'ed party. Mirroring Endure and Reflect Shield is doable i guess.

First. I have to refresh my memory how to add customs state icons.

Share this post


Link to post
Share on other sites
  • 0

Work perfectly! Many thanks once again for this help!

endofdevo.png.e3808112b7045483b8a1f74927bfc625.png

Share this post


Link to post
Share on other sites
  • 0
19 hours ago, Frost Diver said:

How to make it work for devotion sir?

It was already declared in SRC so you only need to do it via client. And it's easy.

efstids.lub

EFST_DEVOTION = 60,


stateimgiconinfo.lub

[EFST_IDs.EFST_DEVOTION] = "devotion.tga"

 

finally in stateiconinfo.lub

StateIconList[EFST_IDs.EFST_DEVOTION] = {
    haveTimeLimit = 1,
    posTimeLimitStr = 2,
    descript = {
        { "Devotion", COLOR_TITLE_BUFF },
        { "%s", COLOR_TIME },
        { "Under influence of devotion." },
        { "Received shield buff." },
    }
}

 

  • Upvote 1

Share this post


Link to post
Share on other sites
  • 0
1 hour ago, Gidz Cross said:

It was already declared in SRC so you only need to do it via client. And it's easy.

efstids.lub

EFST_DEVOTION = 60,


stateimgiconinfo.lub

[EFST_IDs.EFST_DEVOTION] = "devotion.tga"

 

finally in stateiconinfo.lub

StateIconList[EFST_IDs.EFST_DEVOTION] = {
    haveTimeLimit = 1,
    posTimeLimitStr = 2,
    descript = {
        { "Devotion", COLOR_TITLE_BUFF },
        { "%s", COLOR_TIME },
        { "Under influence of devotion." },
        { "Received shield buff." },
    }
}

 

thanks alot sir for the guides

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.