Commit 37eabe3e authored by salix5's avatar salix5

edit

parent 5589807f
...@@ -143,7 +143,8 @@ void field::reload_field_info() { ...@@ -143,7 +143,8 @@ void field::reload_field_info() {
pduel->write_buffer32(peffect->description); pduel->write_buffer32(peffect->description);
} }
} }
// Debug.AddCard() will call this function directly
// check Fusion/S/X monster redirection by the rule
void field::add_card(uint8 playerid, card* pcard, uint8 location, uint8 sequence) { void field::add_card(uint8 playerid, card* pcard, uint8 location, uint8 sequence) {
if (pcard->current.location != 0) if (pcard->current.location != 0)
return; return;
...@@ -260,6 +261,8 @@ void field::remove_card(card* pcard) { ...@@ -260,6 +261,8 @@ void field::remove_card(card* pcard) {
pcard->current.location = 0; pcard->current.location = 0;
pcard->current.sequence = 0; pcard->current.sequence = 0;
} }
// check Fusion/S/X monster redirection by the rule
// it will call remove_card(), add_card()
void field::move_card(uint8 playerid, card* pcard, uint8 location, uint8 sequence) { void field::move_card(uint8 playerid, card* pcard, uint8 location, uint8 sequence) {
if (!is_location_useable(playerid, location, sequence)) if (!is_location_useable(playerid, location, sequence))
return; return;
......
...@@ -2998,6 +2998,8 @@ int32 field::send_to(uint16 step, group * targets, card * target) { ...@@ -2998,6 +2998,8 @@ int32 field::send_to(uint16 step, group * targets, card * target) {
return TRUE; return TRUE;
} }
// PROCESSOR_SENDTO goes here // PROCESSOR_SENDTO goes here
// step 1: call PROCESSOR_SENDTO_STEP
// step 6: move cards
int32 field::send_to(uint16 step, group * targets, effect * reason_effect, uint32 reason, uint8 reason_player) { int32 field::send_to(uint16 step, group * targets, effect * reason_effect, uint32 reason, uint8 reason_player) {
struct exargs { struct exargs {
group* targets; group* targets;
...@@ -3255,7 +3257,7 @@ int32 field::send_to(uint16 step, group * targets, effect * reason_effect, uint3 ...@@ -3255,7 +3257,7 @@ int32 field::send_to(uint16 step, group * targets, effect * reason_effect, uint3
} else if(dest == LOCATION_REMOVED) { } else if(dest == LOCATION_REMOVED) {
core.hint_timing[pcard->current.controler] |= TIMING_REMOVE; core.hint_timing[pcard->current.controler] |= TIMING_REMOVE;
} }
//move card //call move_card()
if(pcard->current.controler != playerid || pcard->current.location != dest) { if(pcard->current.controler != playerid || pcard->current.location != dest) {
pduel->write_buffer8(MSG_MOVE); pduel->write_buffer8(MSG_MOVE);
pduel->write_buffer32(pcard->data.code); pduel->write_buffer32(pcard->data.code);
......
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