Commit bf517793 authored by salix5's avatar salix5

EVENT_BATTLE_DESTROYING

parent 4f70efe3
...@@ -3702,14 +3702,7 @@ int32 field::process_battle_command(uint16 step) { ...@@ -3702,14 +3702,7 @@ int32 field::process_battle_command(uint16 step) {
return FALSE; return FALSE;
} }
case 30: { case 30: {
//raise_single_event(core.attacker, 0, EVENT_BATTLE_END, 0, 0, PLAYER_NONE, 0, 0);
//if(core.attack_target)
// raise_single_event(core.attack_target, 0, EVENT_BATTLE_END, 0, 0, PLAYER_NONE, 0, 1);
//raise_event((card*)0, EVENT_BATTLE_END, 0, 0, PLAYER_NONE, 0, 0);
//process_single_event();
//process_instant_event();
if(!core.effect_damage_step || (core.effect_damage_step != 3)) { if(!core.effect_damage_step || (core.effect_damage_step != 3)) {
//add_process(PROCESSOR_POINT_EVENT, 0, 0, 0, FALSE, TRUE);
core.units.begin()->arg1 = 1; core.units.begin()->arg1 = 1;
} else { } else {
break_effect(); break_effect();
...@@ -3756,13 +3749,15 @@ int32 field::process_battle_command(uint16 step) { ...@@ -3756,13 +3749,15 @@ int32 field::process_battle_command(uint16 step) {
core.units.begin()->ptarget = 0; core.units.begin()->ptarget = 0;
card_set ing; card_set ing;
card_set ed; card_set ed;
if(core.attacker->is_status(STATUS_BATTLE_DESTROYED) && (core.attacker->current.reason & REASON_BATTLE)) { if(core.attacker->is_status(STATUS_BATTLE_DESTROYED)
&& !((core.attacker->current.reason & REASON_EFFECT + REASON_DESTROY) == REASON_EFFECT + REASON_DESTROY)) {
raise_single_event(core.attack_target, 0, EVENT_BATTLE_DESTROYING, 0, core.attacker->current.reason, core.attack_target->current.controler, 0, 1); raise_single_event(core.attack_target, 0, EVENT_BATTLE_DESTROYING, 0, core.attacker->current.reason, core.attack_target->current.controler, 0, 1);
raise_single_event(core.attacker, 0, EVENT_BATTLE_DESTROYED, 0, core.attacker->current.reason, core.attack_target->current.controler, 0, 0); raise_single_event(core.attacker, 0, EVENT_BATTLE_DESTROYED, 0, core.attacker->current.reason, core.attack_target->current.controler, 0, 0);
ing.insert(core.attack_target); ing.insert(core.attack_target);
ed.insert(core.attacker); ed.insert(core.attacker);
} }
if(core.attack_target && core.attack_target->is_status(STATUS_BATTLE_DESTROYED) && (core.attack_target->current.reason & REASON_BATTLE)) { if(core.attack_target && core.attack_target->is_status(STATUS_BATTLE_DESTROYED)
&& !((core.attack_target->current.reason & REASON_EFFECT + REASON_DESTROY) == REASON_EFFECT + REASON_DESTROY)) {
raise_single_event(core.attacker, 0, EVENT_BATTLE_DESTROYING, 0, core.attack_target->current.reason, core.attacker->current.controler, 0, 0); raise_single_event(core.attacker, 0, EVENT_BATTLE_DESTROYING, 0, core.attack_target->current.reason, core.attacker->current.controler, 0, 0);
raise_single_event(core.attack_target, 0, EVENT_BATTLE_DESTROYED, 0, core.attack_target->current.reason, core.attacker->current.controler, 0, 1); raise_single_event(core.attack_target, 0, EVENT_BATTLE_DESTROYED, 0, core.attack_target->current.reason, core.attacker->current.controler, 0, 1);
ing.insert(core.attacker); ing.insert(core.attacker);
......
...@@ -79,7 +79,7 @@ end ...@@ -79,7 +79,7 @@ end
function c40737112.rmop(e,tp,eg,ep,ev,re,r,rp) function c40737112.rmop(e,tp,eg,ep,ev,re,r,rp)
local bc=e:GetLabelObject() local bc=e:GetLabelObject()
if bc:IsRelateToBattle() and bc:IsAbleToRemove() then if bc:IsRelateToBattle() and bc:IsAbleToRemove() then
Duel.Remove(bc,POS_FACEUP,REASON_EFFECT+REASON_BATTLE) Duel.Remove(bc,POS_FACEUP,REASON_EFFECT)
end end
end end
function c40737112.recon(e) function c40737112.recon(e)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment