REQ[Shield fix]

Submit your code requests, and if you are good at coding come help others with their requests.
Post Reply
tester
Outpost bitch
Posts: 544
Joined: Wed Jan 07, 2004 8:58 pm

Post by tester »

Yo i made a new magic type that absorbs magical dmg but only for a preset amount then it should break.

Code: Select all

case 7: //Magic DMG absorbing Shield
        SetMagicProtectionFlag(sOwnerH, DEF_OWNERTYPE_PLAYER, TRUE);

Code: Select all

case 7: //Magic DMG absorbing Shield
        SetMagicProtectionFlag(sOwnerH, DEF_OWNERTYPE_NPC, TRUE);


I got this code

Code: Select all

if (m_pClientList[sTargetH]->m_cMagicEffectStatus[ DEF_MAGICTYPE_PROTECT ] == 7) {
  
  	iTeller += iDamage;
  	if (iTeller <= 150) {  //MagicShield Absorbs 150 damage
    	iDamage = 0; }
    	else { iDamage = iDamage;}

  	}
in
Effect_Damage_Spot

Effect_Damage_Spot_Type2

and in Effect_Damage_Spot_DamageMove


The shield works will, it absorbs 150 dmg magical dmg before I can get hit with magic, with spells that only have 1 hit tough. My question is now, all those different effects are like blizzards 1st hit,2nd hit, 3rd hit?
Becuz then my shield would absorb 450 dmg and then I should make my counter global variable.

Another question is when the shield is all done absorbing dmg, the aura stays there, and i cant reshield myself, how do I remove the aura and the cooldown? but only for that spell, I dont want to cancellate berserk and all other buffs as well.


Final question is, this only absorbs magical dmg since I searched for Protection from magic, but how can I make it absorb psych dmg as well?

yes im nub lol :(


Cheers Tester
I support a woman's right to choose<br><br>- In the Mouth?<br>- In the Ass ?<br>- In the Vagina?<br>- Between the Tits?
Sentinel
Loyal fan
Posts: 462
Joined: Thu Jan 11, 2007 4:16 pm

Post by Sentinel »

Why are you even bothing? I'll see if Jehovah will give me his snippet. He made it into a spell, if thats what you're trying to do.
<!--QuoteBegin--></div><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> </td></tr><tr><td id='QUOTE'><!--QuoteEBegin-->charlie says:<br>i may own outpost but im not a nerd<!--QuoteEnd--></td></tr></table><div class='signature'><!--QuoteEEnd--><br><!--QuoteBegin--></div><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> </td></tr><tr><td id='QUOTE'><!--QuoteEBegin-->(locobans @ Mar 12 2007, 10:48 PM) <br>"Remember while peeing, If you shake it more than twice you playing with it..." <br><!--QuoteEnd--></td></tr></table><div class='signature'><!--QuoteEEnd-->
Post Reply