Closed salix5 closed 6 months ago
As we have seen before, dividing the reason into effect/cost is not enough.
The reason for release now:
REASON_ACTION "This card cannot declare an attack unless"... (Panther Warrior)
REASON_ACTION
REASON_COST The card is released by the cost of effect activation. Prohibited by Ritual Beast Ulti-Reirautari.
REASON_COST
Ritual Beast Ulti-Reirautari
REASON_EFFECT The card is released by effect. (Ritual Summon)
REASON_EFFECT
REASON_MAINTENANCE The maintenance cost. (Aerial Recharge)
REASON_MAINTENANCE
REASON_SPSUMMON The card is released by the Special Summon procedure. (Blue-Eyes Toon Dragon)
REASON_SPSUMMON
REASON_SUMMON The card is released by Tribute Summon.
REASON_SUMMON
REASON_RULE The card is is released by non-effect actions. (痛み分け/Share the Pain)
REASON_RULE
They should be applied to Duel.Sendto*, as @465uytrewq suggested in https://github.com/Fluorohydride/ygopro-scripts/pull/2366 .
Duel.Sendto*
Now it will check pcard->is_affect_by_effect only when the move is marked by REASON_EFFECT.
pcard->is_affect_by_effect
Test script:
--[[message #580]] Debug.ReloadFieldBegin(DUEL_ATTACK_FIRST_TURN+DUEL_SIMPLE_AI) Debug.SetPlayerInfo(0,8000,0,0) Debug.SetPlayerInfo(1,8000,0,0) Debug.AddCard(16886617,0,0,LOCATION_HAND,0,POS_FACEDOWN) Debug.AddCard(72270339,0,0,LOCATION_HAND,1,POS_FACEDOWN) Debug.AddCard(27240101,0,0,LOCATION_MZONE,0,POS_FACEUP_ATTACK) Debug.AddCard(27240101,0,0,LOCATION_MZONE,1,POS_FACEUP_ATTACK) Debug.AddCard(66570171,0,0,LOCATION_DECK,0,POS_FACEDOWN) Debug.AddCard(40044918,0,0,LOCATION_DECK,1,POS_FACEDOWN) Debug.AddCard(66570171,0,0,LOCATION_DECK,2,POS_FACEDOWN) Debug.AddCard(66570171,1,1,LOCATION_DECK,0,POS_FACEDOWN) Debug.AddCard(40044918,1,1,LOCATION_DECK,1,POS_FACEDOWN) Debug.AddCard(27660735,1,1,LOCATION_DECK,2,POS_FACEDOWN) Debug.ReloadFieldEnd() --aux.BeginPuzzle()
@mercury233 @purerosefallen
merged as a workaround
334
516
As we have seen before, dividing the reason into effect/cost is not enough.
The reason for release now:
REASON_ACTION
"This card cannot declare an attack unless"... (Panther Warrior)REASON_COST
The card is released by the cost of effect activation. Prohibited byRitual Beast Ulti-Reirautari
.REASON_EFFECT
The card is released by effect. (Ritual Summon)REASON_MAINTENANCE
The maintenance cost. (Aerial Recharge)REASON_SPSUMMON
The card is released by the Special Summon procedure. (Blue-Eyes Toon Dragon)REASON_SUMMON
The card is released by Tribute Summon.REASON_RULE
The card is is released by non-effect actions. (痛み分け/Share the Pain)They should be applied to
Duel.Sendto*
, as @465uytrewq suggested in https://github.com/Fluorohydride/ygopro-scripts/pull/2366 .Now it will check
pcard->is_affect_by_effect
only when the move is marked byREASON_EFFECT
.Test script:
@mercury233 @purerosefallen