class 1 royal_rush_bomb : warrior
{
parameter:
	int	SelfRangeDDMagic = 1083393;

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

	EventHandler USE_SKILL_FINISHED(target,skill_name_id)
	{
		myself::Despawn();
	}

}
