@LabelIndex 52814
@StringIndex 0
class 0 party_private_physicalspecial_heal : party_private_physicalspecial {
parameter:
	int	MagicHeal = 458752001;

handler:
	EventHandler ATTACKED(attacker,damage) {
		if( myself.sm.hp <= ( myself.sm.max_hp / 2 ) && gg::Rand(100) < 33 ) {
			if( myself::Skill_GetConsumeMP(MagicHeal) < myself.sm.mp && myself::Skill_GetConsumeHP(MagicHeal) < myself.sm.hp && myself::Skill_InReuseDelay(MagicHeal) == 0 ) {
				myself::AddUseSkillDesire(myself.sm,MagicHeal,0,1,1000000);
			}
		}
		super;
	}

	EventHandler PARTY_ATTACKED(attacker,private,damage) {
		if( myself.sm.hp <= ( myself.sm.max_hp / 2 ) && private != myself.sm && gg::Rand(100) < 33 ) {
			if( myself::Skill_GetConsumeMP(MagicHeal) < myself.sm.mp && myself::Skill_GetConsumeHP(MagicHeal) < myself.sm.hp && myself::Skill_InReuseDelay(MagicHeal) == 0 ) {
				myself::AddUseSkillDesire(private,MagicHeal,1,1,1000000);
			}
		}
		if( myself.boss.hp <= ( myself.boss.max_hp / 2 ) && gg::Rand(100) < 33 ) {
			if( myself::Skill_GetConsumeMP(MagicHeal) < myself.sm.mp && myself::Skill_GetConsumeHP(MagicHeal) < myself.sm.hp && myself::Skill_InReuseDelay(MagicHeal) == 0 ) {
				myself::AddUseSkillDesire(myself.boss,MagicHeal,1,1,1000000);
			}
		}
		super;
	}

}
