Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
REIKAI
ygopro
Commits
0126a14a
Commit
0126a14a
authored
Sep 15, 2013
by
VanillaSalt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
51a9000a
Changes
38
Hide whitespace changes
Inline
Side-by-side
Showing
38 changed files
with
124 additions
and
85 deletions
+124
-85
ocgcore/effect.h
ocgcore/effect.h
+1
-0
ocgcore/processor.cpp
ocgcore/processor.cpp
+8
-6
script/c18517177.lua
script/c18517177.lua
+2
-1
script/c2137678.lua
script/c2137678.lua
+1
-1
script/c21954587.lua
script/c21954587.lua
+1
-1
script/c22888900.lua
script/c22888900.lua
+10
-2
script/c24137081.lua
script/c24137081.lua
+8
-2
script/c26285788.lua
script/c26285788.lua
+4
-2
script/c28150174.lua
script/c28150174.lua
+3
-3
script/c34815282.lua
script/c34815282.lua
+9
-5
script/c38730226.lua
script/c38730226.lua
+7
-10
script/c39402797.lua
script/c39402797.lua
+2
-2
script/c42155488.lua
script/c42155488.lua
+2
-3
script/c42421606.lua
script/c42421606.lua
+1
-1
script/c43694481.lua
script/c43694481.lua
+1
-1
script/c440556.lua
script/c440556.lua
+1
-1
script/c45462639.lua
script/c45462639.lua
+1
-1
script/c46820049.lua
script/c46820049.lua
+1
-0
script/c4941482.lua
script/c4941482.lua
+2
-2
script/c49456901.lua
script/c49456901.lua
+1
-1
script/c50527144.lua
script/c50527144.lua
+14
-16
script/c50766506.lua
script/c50766506.lua
+4
-1
script/c60930169.lua
script/c60930169.lua
+2
-2
script/c68786330.lua
script/c68786330.lua
+1
-1
script/c70908596.lua
script/c70908596.lua
+2
-2
script/c71315423.lua
script/c71315423.lua
+1
-1
script/c72302403.lua
script/c72302403.lua
+2
-1
script/c73414375.lua
script/c73414375.lua
+4
-2
script/c75733063.lua
script/c75733063.lua
+1
-1
script/c7625614.lua
script/c7625614.lua
+3
-2
script/c76419637.lua
script/c76419637.lua
+1
-1
script/c76721030.lua
script/c76721030.lua
+0
-1
script/c78009994.lua
script/c78009994.lua
+3
-0
script/c78540593.lua
script/c78540593.lua
+3
-2
script/c81907872.lua
script/c81907872.lua
+1
-1
script/c88190790.lua
script/c88190790.lua
+7
-1
script/c90810762.lua
script/c90810762.lua
+8
-2
script/c99902789.lua
script/c99902789.lua
+1
-3
No files found.
ocgcore/effect.h
View file @
0126a14a
...
@@ -415,6 +415,7 @@ public:
...
@@ -415,6 +415,7 @@ public:
#define EVENT_TURN_END 1210
#define EVENT_TURN_END 1210
#define EVENT_PHASE 0x1000
#define EVENT_PHASE 0x1000
#define EVENT_PHASE_START 0x2000
#define EVENT_PHASE_START 0x2000
#define EVENT_PHASE_PRESTART 0x2100
#define EVENT_ADD_COUNTER 0x10000
#define EVENT_ADD_COUNTER 0x10000
#define EVENT_REMOVE_COUNTER 0x20000
#define EVENT_REMOVE_COUNTER 0x20000
...
...
ocgcore/processor.cpp
View file @
0126a14a
...
@@ -3833,17 +3833,12 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
...
@@ -3833,17 +3833,12 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
//Standby Phase
//Standby Phase
infos
.
phase
=
PHASE_STANDBY
;
infos
.
phase
=
PHASE_STANDBY
;
core
.
phase_action
=
FALSE
;
core
.
phase_action
=
FALSE
;
raise_event
((
card
*
)
0
,
EVENT_PHASE_START
+
PHASE_STANDBY
,
0
,
0
,
0
,
turn_player
,
0
);
raise_event
((
card
*
)
0
,
EVENT_PHASE_
PRE
START
+
PHASE_STANDBY
,
0
,
0
,
0
,
turn_player
,
0
);
process_instant_event
();
process_instant_event
();
adjust_all
();
adjust_all
();
return
FALSE
;
return
FALSE
;
}
}
case
4
:
{
case
4
:
{
if
(
core
.
new_fchain
.
size
()
||
core
.
new_ochain
.
size
()
||
core
.
flip_chain
.
size
())
add_process
(
PROCESSOR_POINT_EVENT
,
0
,
0
,
0
,
0
,
0
);
return
FALSE
;
}
case
5
:
{
core
.
new_fchain
.
clear
();
core
.
new_fchain
.
clear
();
core
.
new_ochain
.
clear
();
core
.
new_ochain
.
clear
();
core
.
quick_f_chain
.
clear
();
core
.
quick_f_chain
.
clear
();
...
@@ -3855,6 +3850,13 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
...
@@ -3855,6 +3850,13 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
}
}
pduel
->
write_buffer8
(
MSG_NEW_PHASE
);
pduel
->
write_buffer8
(
MSG_NEW_PHASE
);
pduel
->
write_buffer8
(
infos
.
phase
);
pduel
->
write_buffer8
(
infos
.
phase
);
raise_event
((
card
*
)
0
,
EVENT_PHASE_START
+
PHASE_STANDBY
,
0
,
0
,
0
,
turn_player
,
0
);
process_instant_event
();
return
FALSE
;
}
case
5
:
{
if
(
core
.
new_fchain
.
size
()
||
core
.
new_ochain
.
size
()
||
core
.
flip_chain
.
size
()
||
core
.
instant_event
.
back
().
event_code
!=
EVENT_PHASE_START
+
PHASE_STANDBY
)
add_process
(
PROCESSOR_POINT_EVENT
,
0
,
0
,
0
,
0
,
0
);
add_process
(
PROCESSOR_PHASE_EVENT
,
0
,
0
,
0
,
PHASE_STANDBY
,
0
);
add_process
(
PROCESSOR_PHASE_EVENT
,
0
,
0
,
0
,
PHASE_STANDBY
,
0
);
return
FALSE
;
return
FALSE
;
}
}
...
...
script/c18517177.lua
View file @
0126a14a
...
@@ -22,7 +22,8 @@ function c18517177.cfilter(c)
...
@@ -22,7 +22,8 @@ function c18517177.cfilter(c)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x1d
)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x1d
)
end
end
function
c18517177
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c18517177
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_MZONE
,
0
)
<
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
return
Duel
.
GetTurnPlayer
()
==
tp
and
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_MZONE
,
0
)
<
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
and
Duel
.
IsExistingMatchingCard
(
c18517177
.
cfilter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
)
and
Duel
.
IsExistingMatchingCard
(
c18517177
.
cfilter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
)
end
end
function
c18517177
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c18517177
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
...
...
script/c2137678.lua
View file @
0126a14a
...
@@ -23,7 +23,7 @@ function c2137678.atkfilter(c)
...
@@ -23,7 +23,7 @@ function c2137678.atkfilter(c)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x13
)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x13
)
end
end
function
c2137678
.
val
(
e
,
c
)
function
c2137678
.
val
(
e
,
c
)
return
Duel
.
GetMatchingGroupCount
(
c2137678
.
atkfilter
,
c
:
GetControler
(),
LOCATION_MZONE
,
0
,
c
)
*
100
return
Duel
.
GetMatchingGroupCount
(
c2137678
.
atkfilter
,
0
,
LOCATION_MZONE
,
LOCATION_MZONE
,
c
)
*
100
end
end
function
c2137678
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c2137678
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsControler
(
1
-
tp
)
and
chkc
:
IsFaceup
()
and
chkc
:
IsLocation
(
LOCATION_MZONE
)
end
if
chkc
then
return
chkc
:
IsControler
(
1
-
tp
)
and
chkc
:
IsFaceup
()
and
chkc
:
IsLocation
(
LOCATION_MZONE
)
end
...
...
script/c21954587.lua
View file @
0126a14a
...
@@ -69,7 +69,7 @@ function c21954587.thop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -69,7 +69,7 @@ function c21954587.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c21954587
.
atkcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c21954587
.
atkcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetCurrentPhase
()
==
PHASE_MAIN1
return
Duel
.
Get
TurnCount
()
~=
1
and
Duel
.
Get
CurrentPhase
()
==
PHASE_MAIN1
end
end
function
c21954587
.
rfilter
(
c
)
function
c21954587
.
rfilter
(
c
)
return
c
:
IsPosition
(
POS_FACEUP_ATTACK
)
and
c
:
IsAttribute
(
ATTRIBUTE_WATER
)
return
c
:
IsPosition
(
POS_FACEUP_ATTACK
)
and
c
:
IsAttribute
(
ATTRIBUTE_WATER
)
...
...
script/c22888900.lua
View file @
0126a14a
...
@@ -22,7 +22,11 @@ function c22888900.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -22,7 +22,11 @@ function c22888900.operation(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetTargetRange
(
LOCATION_MZONE
,
LOCATION_MZONE
)
e1
:
SetTargetRange
(
LOCATION_MZONE
,
LOCATION_MZONE
)
e1
:
SetTarget
(
c22888900
.
tg
)
e1
:
SetTarget
(
c22888900
.
tg
)
e1
:
SetCode
(
EFFECT_DISABLE
)
e1
:
SetCode
(
EFFECT_DISABLE
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
+
RESET_OPPO_TURN
)
if
Duel
.
GetTurnPlayer
()
~=
tp
then
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
+
RESET_OPPO_TURN
,
2
)
else
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
+
RESET_OPPO_TURN
)
end
Duel
.
RegisterEffect
(
e1
,
tp
)
Duel
.
RegisterEffect
(
e1
,
tp
)
local
e2
=
e1
:
Clone
()
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_CANNOT_ATTACK
)
e2
:
SetCode
(
EFFECT_CANNOT_ATTACK
)
...
@@ -34,7 +38,11 @@ function c22888900.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -34,7 +38,11 @@ function c22888900.operation(e,tp,eg,ep,ev,re,r,rp)
e3
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e3
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e3
:
SetTargetRange
(
1
,
1
)
e3
:
SetTargetRange
(
1
,
1
)
e3
:
SetTarget
(
c22888900
.
splimit
)
e3
:
SetTarget
(
c22888900
.
splimit
)
e3
:
SetReset
(
RESET_PHASE
+
PHASE_END
+
RESET_OPPO_TURN
)
if
Duel
.
GetTurnPlayer
()
~=
tp
then
e3
:
SetReset
(
RESET_PHASE
+
PHASE_END
+
RESET_OPPO_TURN
,
2
)
else
e3
:
SetReset
(
RESET_PHASE
+
PHASE_END
+
RESET_OPPO_TURN
)
end
Duel
.
RegisterEffect
(
e3
,
tp
)
Duel
.
RegisterEffect
(
e3
,
tp
)
end
end
function
c22888900
.
tg
(
e
,
c
)
function
c22888900
.
tg
(
e
,
c
)
...
...
script/c24137081.lua
View file @
0126a14a
...
@@ -7,14 +7,20 @@ function c24137081.initial_effect(c)
...
@@ -7,14 +7,20 @@ function c24137081.initial_effect(c)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
--atkup
--atkup
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e2
:
SetDescription
(
aux
.
Stringid
(
24137081
,
0
))
e2
:
SetCategory
(
CATEGORY_ATKCHANGE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e2
:
SetCode
(
EVENT_BATTLE_DAMAGE
)
e2
:
SetCode
(
EVENT_BATTLE_DAMAGE
)
e2
:
SetCondition
(
c24137081
.
atkcon
)
e2
:
SetOperation
(
c24137081
.
atkop
)
e2
:
SetOperation
(
c24137081
.
atkop
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
function
c24137081
.
atkcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
ep
~=
tp
and
Duel
.
GetAttackTarget
()
==
nil
end
function
c24137081
.
atkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c24137081
.
atkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
if
ep
~=
tp
and
Duel
.
GetAttackTarget
()
==
nil
then
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
then
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
...
...
script/c26285788.lua
View file @
0126a14a
...
@@ -19,8 +19,10 @@ end
...
@@ -19,8 +19,10 @@ end
function
c26285788
.
addcount
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c26285788
.
addcount
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
eg
:
GetFirst
()
local
c
=
eg
:
GetFirst
()
while
c
~=
nil
do
while
c
~=
nil
do
local
p
=
c
:
GetPreviousControler
()
if
not
c
:
IsType
(
TYPE_TOKEN
)
then
Duel
.
RegisterFlagEffect
(
p
,
26285789
,
RESET_PHASE
+
PHASE_END
,
0
,
1
)
local
p
=
c
:
GetReasonPlayer
()
Duel
.
RegisterFlagEffect
(
p
,
26285789
,
RESET_PHASE
+
PHASE_END
,
0
,
1
)
end
c
=
eg
:
GetNext
()
c
=
eg
:
GetNext
()
end
end
end
end
...
...
script/c28150174.lua
View file @
0126a14a
...
@@ -21,10 +21,10 @@ function c28150174.poscost(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -21,10 +21,10 @@ function c28150174.poscost(e,tp,eg,ep,ev,re,r,rp,chk)
e
:
GetHandler
():
RemoveOverlayCard
(
tp
,
1
,
1
,
REASON_COST
)
e
:
GetHandler
():
RemoveOverlayCard
(
tp
,
1
,
1
,
REASON_COST
)
end
end
function
c28150174
.
postg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c28150174
.
postg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
Is
Position
(
POS_DEFENCE
)
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
Is
DefencePos
(
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
Card
.
Is
Position
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
nil
,
POS_DEFENCE
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
Card
.
Is
DefencePos
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DEFENCE
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DEFENCE
)
local
g
=
Duel
.
SelectTarget
(
tp
,
Card
.
Is
Position
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
nil
,
POS_DEFENCE
)
local
g
=
Duel
.
SelectTarget
(
tp
,
Card
.
Is
DefencePos
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_POSITION
,
g
,
g
:
GetCount
(),
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_POSITION
,
g
,
g
:
GetCount
(),
0
,
0
)
end
end
function
c28150174
.
posop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c28150174
.
posop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c34815282.lua
View file @
0126a14a
...
@@ -2,11 +2,12 @@
...
@@ -2,11 +2,12 @@
function
c34815282
.
initial_effect
(
c
)
function
c34815282
.
initial_effect
(
c
)
--Activate
--Activate
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetCategory
(
CATEGORY_
DISABL
E
)
e1
:
SetCategory
(
CATEGORY_
ATKCHANG
E
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetHintTiming
(
0
,
0x1c0
)
e1
:
SetHintTiming
(
TIMING_DAMAGE_STEP
,
TIMING_DAMAGE_STEP
+
0x1c0
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
+
EFFECT_FLAG_DAMAGE_STEP
)
e1
:
SetCondition
(
c34815282
.
condition
)
e1
:
SetTarget
(
c34815282
.
target
)
e1
:
SetTarget
(
c34815282
.
target
)
e1
:
SetOperation
(
c34815282
.
operation
)
e1
:
SetOperation
(
c34815282
.
operation
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
...
@@ -19,8 +20,11 @@ function c34815282.initial_effect(c)
...
@@ -19,8 +20,11 @@ function c34815282.initial_effect(c)
e2
:
SetOperation
(
c34815282
.
desop
)
e2
:
SetOperation
(
c34815282
.
desop
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
function
c34815282
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetCurrentPhase
()
~=
PHASE_DAMAGE
or
not
Duel
.
IsDamageCalculated
()
end
function
c34815282
.
filter
(
c
)
function
c34815282
.
filter
(
c
)
return
c
:
IsFaceup
()
and
c
:
GetBaseAttack
()
>
1000
return
c
:
IsFaceup
()
and
c
:
GetBaseAttack
()
>
1000
and
c
:
GetLevel
()
>
0
end
end
function
c34815282
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c34815282
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
c34815282
.
filter
(
chkc
)
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
c34815282
.
filter
(
chkc
)
end
...
@@ -58,5 +62,5 @@ function c34815282.descon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -58,5 +62,5 @@ function c34815282.descon(e,tp,eg,ep,ev,re,r,rp)
return
tc
and
eg
:
IsContains
(
tc
)
return
tc
and
eg
:
IsContains
(
tc
)
end
end
function
c34815282
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c34815282
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_EFFECT
)
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_EFFECT
)
end
end
script/c38730226.lua
View file @
0126a14a
...
@@ -4,39 +4,36 @@ function c38730226.initial_effect(c)
...
@@ -4,39 +4,36 @@ function c38730226.initial_effect(c)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
38730226
,
0
))
e1
:
SetDescription
(
aux
.
Stringid
(
38730226
,
0
))
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetProperty
(
EFFECT_FLAG_REPEAT
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetCountLimit
(
1
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCondition
(
c38730226
.
con
)
e1
:
SetCondition
(
c38730226
.
con
)
e1
:
SetTarget
(
c38730226
.
tg
)
e1
:
SetOperation
(
c38730226
.
op
)
e1
:
SetOperation
(
c38730226
.
op
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
function
c38730226
.
con
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c38730226
.
con
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
return
Duel
.
GetTurnPlayer
()
~=
tp
and
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_HAND
,
0
)
==
0
return
Duel
.
GetTurnPlayer
()
~=
tp
and
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_HAND
,
0
)
==
0
end
end
function
c38730226
.
tg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
GetFlagEffect
(
91345518
)
==
0
end
e
:
GetHandler
():
RegisterFlagEffect
(
91345518
,
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
,
EFFECT_FLAG_OATH
,
1
)
end
function
c38730226
.
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c38730226
.
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetDescription
(
aux
.
Stringid
(
38730226
,
1
))
e1
:
SetDescription
(
aux
.
Stringid
(
38730226
,
1
))
e1
:
SetCategory
(
CATEGORY_DRAW
)
e1
:
SetCategory
(
CATEGORY_DRAW
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
+
EFFECT_FLAG_REPEAT
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_DRAW
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_STANDBY
)
e1
:
SetCountLimit
(
1
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetTarget
(
c38730226
.
dtg
)
e1
:
SetTarget
(
c38730226
.
dtg
)
e1
:
SetOperation
(
c38730226
.
dop
)
e1
:
SetOperation
(
c38730226
.
dop
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_
DRAW
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_
STANDBY
)
e
:
GetHandler
():
RegisterEffect
(
e1
)
e
:
GetHandler
():
RegisterEffect
(
e1
)
end
end
function
c38730226
.
dtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c38730226
.
dtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
GetFlagEffect
(
91345518
)
==
0
end
if
chk
==
0
then
return
true
end
Duel
.
SetTargetPlayer
(
tp
)
Duel
.
SetTargetPlayer
(
tp
)
Duel
.
SetTargetParam
(
1
)
Duel
.
SetTargetParam
(
1
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DRAW
,
nil
,
0
,
tp
,
1
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DRAW
,
nil
,
0
,
tp
,
1
)
e
:
GetHandler
():
RegisterFlagEffect
(
91345518
,
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
,
EFFECT_FLAG_OATH
,
1
)
end
end
function
c38730226
.
dop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c38730226
.
dop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
...
...
script/c39402797.lua
View file @
0126a14a
...
@@ -26,9 +26,9 @@ function c39402797.descon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -26,9 +26,9 @@ function c39402797.descon(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c39402797
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c39402797
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsOnField
()
and
chkc
:
IsControler
(
tp
)
and
chkc
:
IsDestructable
()
end
if
chkc
then
return
chkc
:
IsOnField
()
and
chkc
:
IsControler
(
tp
)
and
chkc
:
IsDestructable
()
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
Card
.
IsDestructable
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
Card
.
IsDestructable
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
e
:
GetHandler
()
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
g
=
Duel
.
SelectTarget
(
tp
,
Card
.
IsDestructable
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
2
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
Card
.
IsDestructable
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
2
,
e
:
GetHandler
()
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
g
:
GetCount
(),
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
g
:
GetCount
(),
0
,
0
)
end
end
function
c39402797
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c39402797
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c42155488.lua
View file @
0126a14a
...
@@ -39,8 +39,7 @@ function c42155488.ntop(e,tp,eg,ep,ev,re,r,rp,c)
...
@@ -39,8 +39,7 @@ function c42155488.ntop(e,tp,eg,ep,ev,re,r,rp,c)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
function
c42155488
.
dectg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c42155488
.
dectg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
if
chk
==
0
then
return
true
end
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
563
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
563
)
local
rc
=
Duel
.
AnnounceRace
(
tp
,
1
,
0xffffff
)
local
rc
=
Duel
.
AnnounceRace
(
tp
,
1
,
0xffffff
)
e
:
SetLabel
(
rc
)
e
:
SetLabel
(
rc
)
...
@@ -77,4 +76,4 @@ function c42155488.decop(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -77,4 +76,4 @@ function c42155488.decop(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function
c42155488
.
syncheck
(
e
,
c
)
function
c42155488
.
syncheck
(
e
,
c
)
c
:
AssumeProperty
(
ASSUME_RACE
,
e
:
GetLabel
())
c
:
AssumeProperty
(
ASSUME_RACE
,
e
:
GetLabel
())
end
end
\ No newline at end of file
script/c42421606.lua
View file @
0126a14a
...
@@ -36,7 +36,7 @@ function c42421606.efop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -36,7 +36,7 @@ function c42421606.efop(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Draw
(
tp
,
1
,
REASON_EFFECT
)
Duel
.
Draw
(
tp
,
1
,
REASON_EFFECT
)
elseif
dc
==
3
then
elseif
dc
==
3
then
if
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_HAND
)
>
0
then
if
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_HAND
)
>
0
then
Duel
.
DiscardHand
(
1
-
tp
,
nil
,
1
,
1
,
REASON_EFFECT
)
Duel
.
DiscardHand
(
1
-
tp
,
nil
,
1
,
1
,
REASON_EFFECT
+
REASON_DISCARD
)
end
end
elseif
dc
==
4
then
elseif
dc
==
4
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
...
...
script/c43694481.lua
View file @
0126a14a
...
@@ -25,7 +25,7 @@ function c43694481.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -25,7 +25,7 @@ function c43694481.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
1500
)
Duel
.
SetTargetParam
(
1500
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
150
0
)
end
end
function
c43694481
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c43694481
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
...
...
script/c440556.lua
View file @
0126a14a
...
@@ -44,7 +44,7 @@ function c440556.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -44,7 +44,7 @@ function c440556.spop(e,tp,eg,ep,ev,re,r,rp)
elseif
cp
~=
tp
then
elseif
cp
~=
tp
then
local
cg
=
Duel
.
GetFieldGroup
(
cp
,
LOCATION_EXTRA
,
0
)
local
cg
=
Duel
.
GetFieldGroup
(
cp
,
LOCATION_EXTRA
,
0
)
if
cg
and
cg
:
GetCount
()
>
0
then
if
cg
and
cg
:
GetCount
()
>
0
then
Duel
.
ConfirmCards
(
cg
,
tp
)
Duel
.
ConfirmCards
(
cg
,
tp
)
end
end
end
end
end
end
script/c45462639.lua
View file @
0126a14a
...
@@ -58,7 +58,7 @@ function c45462639.descost(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -58,7 +58,7 @@ function c45462639.descost(e,tp,eg,ep,ev,re,r,rp,chk)
e
:
GetHandler
():
RemoveCounter
(
tp
,
0x3001
,
2
,
REASON_COST
)
e
:
GetHandler
():
RemoveCounter
(
tp
,
0x3001
,
2
,
REASON_COST
)
end
end
function
c45462639
.
destarg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c45462639
.
destarg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_HAND
)
>
0
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
0
,
0
,
1
-
tp
,
1
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
0
,
0
,
1
-
tp
,
1
)
end
end
function
c45462639
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c45462639
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c46820049.lua
View file @
0126a14a
...
@@ -25,6 +25,7 @@ function c46820049.target(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -25,6 +25,7 @@ function c46820049.target(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function
c46820049
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c46820049
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetFieldGroup
(
ep
,
LOCATION_HAND
,
0
,
nil
)
local
g
=
Duel
.
GetFieldGroup
(
ep
,
LOCATION_HAND
,
0
,
nil
)
if
g
:
GetCount
()
==
0
then
return
end
local
sg
=
g
:
RandomSelect
(
ep
,
1
)
local
sg
=
g
:
RandomSelect
(
ep
,
1
)
Duel
.
SendtoGrave
(
sg
,
REASON_DISCARD
+
REASON_EFFECT
)
Duel
.
SendtoGrave
(
sg
,
REASON_DISCARD
+
REASON_EFFECT
)
end
end
script/c4941482.lua
View file @
0126a14a
...
@@ -17,7 +17,7 @@ function c4941482.condition(e,tp,eg,ep,ev,re,r,rp)
...
@@ -17,7 +17,7 @@ function c4941482.condition(e,tp,eg,ep,ev,re,r,rp)
return
c
:
IsPreviousLocation
(
LOCATION_ONFIELD
)
and
c
:
IsReason
(
REASON_EFFECT
)
return
c
:
IsPreviousLocation
(
LOCATION_ONFIELD
)
and
c
:
IsReason
(
REASON_EFFECT
)
end
end
function
c4941482
.
filter
(
c
)
function
c4941482
.
filter
(
c
)
return
c
:
Is
Position
(
POS_DEFENCE
)
and
c
:
IsControlerCanBeChanged
()
return
c
:
Is
DefencePos
(
)
and
c
:
IsControlerCanBeChanged
()
end
end
function
c4941482
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c4941482
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
IsControler
(
1
-
tp
)
and
c4941482
.
filter
(
chkc
)
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
IsControler
(
1
-
tp
)
and
c4941482
.
filter
(
chkc
)
end
...
@@ -28,7 +28,7 @@ function c4941482.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -28,7 +28,7 @@ function c4941482.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
end
end
function
c4941482
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c4941482
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
and
tc
:
Is
Position
(
POS_DEFENCE
)
and
tc
:
IsRelateToEffect
(
e
)
and
not
Duel
.
GetControl
(
tc
,
tp
)
then
if
tc
and
tc
:
Is
DefencePos
(
)
and
tc
:
IsRelateToEffect
(
e
)
and
not
Duel
.
GetControl
(
tc
,
tp
)
then
if
not
tc
:
IsImmuneToEffect
(
e
)
and
tc
:
IsAbleToChangeControler
()
then
if
not
tc
:
IsImmuneToEffect
(
e
)
and
tc
:
IsAbleToChangeControler
()
then
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
end
end
...
...
script/c49456901.lua
View file @
0126a14a
...
@@ -62,7 +62,7 @@ function c49456901.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -62,7 +62,7 @@ function c49456901.operation(e,tp,eg,ep,ev,re,r,rp)
if
Duel
.
NegateActivation
(
ev
)
and
Duel
.
GetFieldGroupCount
(
1
-
tp
,
LOCATION_HAND
,
0
)
>
0
if
Duel
.
NegateActivation
(
ev
)
and
Duel
.
GetFieldGroupCount
(
1
-
tp
,
LOCATION_HAND
,
0
)
>
0
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
49456901
,
2
))
then
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
49456901
,
2
))
then
local
g
=
Duel
.
GetFieldGroup
(
1
-
tp
,
LOCATION_HAND
,
0
):
RandomSelect
(
1
-
tp
,
1
)
local
g
=
Duel
.
GetFieldGroup
(
1
-
tp
,
LOCATION_HAND
,
0
):
RandomSelect
(
1
-
tp
,
1
)
Duel
.
SendtoGrave
(
g
,
REASON_
DISCARD
+
REASON_
EFFECT
)
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
Duel
.
SetLP
(
1
-
tp
,
Duel
.
GetLP
(
1
-
tp
)
/
2
)
Duel
.
SetLP
(
1
-
tp
,
Duel
.
GetLP
(
1
-
tp
)
/
2
)
end
end
end
end
script/c50527144.lua
View file @
0126a14a
...
@@ -19,21 +19,19 @@ function c50527144.cost(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -19,21 +19,19 @@ function c50527144.cost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel
.
ShuffleHand
(
tp
)
Duel
.
ShuffleHand
(
tp
)
end
end
function
c50527144
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c50527144
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetMatchingGroup
(
c50527144
.
tgfilter
,
tp
,
LOCATION_ONFIELD
,
0
,
nil
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
tc
=
g
:
GetFirst
()
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
while
tc
do
e1
:
SetCode
(
EFFECT_CANNOT_BE_EFFECT_TARGET
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetProperty
(
EFFECT_FLAG_SET_AVAILABLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetTargetRange
(
LOCATION_ONFIELD
,
0
)
e1
:
SetCode
(
EFFECT_INDESTRUCTABLE_EFFECT
)
e1
:
SetTarget
(
c50527144
.
tgfilter
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
RESET_END
)
e1
:
SetValue
(
1
)
e1
:
SetValue
(
1
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
tc
:
RegisterEffect
(
e1
)
Duel
.
RegisterEffect
(
e1
,
tp
)
local
e2
=
e1
:
Clone
()
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_CANNOT_BE_EFFECT_TARGET
)
e2
:
SetCode
(
EFFECT_INDESTRUCTABLE_EFFECT
)
tc
:
RegisterEffect
(
e2
)
Duel
.
RegisterEffect
(
e2
,
tp
)
tc
=
g
:
GetNext
()
end
end
end
function
c50527144
.
tgfilter
(
c
)
function
c50527144
.
tgfilter
(
e
,
c
)
return
(
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x8d
))
or
(
c
:
IsFacedown
()
and
c
:
IsLocation
(
LOCATION_MZONE
))
return
(
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x8d
))
or
(
c
:
IsFacedown
()
and
c
:
IsLocation
(
LOCATION_MZONE
))
end
end
\ No newline at end of file
script/c50766506.lua
View file @
0126a14a
--
̷ g
--
忍法 分身の術
function
c50766506
.
initial_effect
(
c
)
function
c50766506
.
initial_effect
(
c
)
--Activate
--Activate
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
...
@@ -45,17 +45,20 @@ function c50766506.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -45,17 +45,20 @@ function c50766506.operation(e,tp,eg,ep,ev,re,r,rp)
local
sg
=
Duel
.
GetMatchingGroup
(
c50766506
.
spfilter2
,
tp
,
LOCATION_DECK
,
0
,
nil
,
e
,
tp
)
local
sg
=
Duel
.
GetMatchingGroup
(
c50766506
.
spfilter2
,
tp
,
LOCATION_DECK
,
0
,
nil
,
e
,
tp
)
sg
:
Remove
(
Card
.
IsLevelAbove
,
nil
,
slv
+
1
)
sg
:
Remove
(
Card
.
IsLevelAbove
,
nil
,
slv
+
1
)
if
sg
:
GetCount
()
==
0
then
return
end
if
sg
:
GetCount
()
==
0
then
return
end
local
cg
=
Group
.
CreateGroup
()
repeat
repeat
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
tc
=
sg
:
Select
(
tp
,
1
,
1
,
nil
):
GetFirst
()
local
tc
=
sg
:
Select
(
tp
,
1
,
1
,
nil
):
GetFirst
()
sg
:
RemoveCard
(
tc
)
sg
:
RemoveCard
(
tc
)
slv
=
slv
-
tc
:
GetLevel
()
slv
=
slv
-
tc
:
GetLevel
()
Duel
.
SpecialSummonStep
(
tc
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP_ATTACK
+
POS_FACEDOWN_DEFENCE
)
Duel
.
SpecialSummonStep
(
tc
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP_ATTACK
+
POS_FACEDOWN_DEFENCE
)
if
tc
:
IsFacedown
()
then
cg
:
AddCard
(
tc
)
end
c
:
SetCardTarget
(
tc
)
c
:
SetCardTarget
(
tc
)
sg
:
Remove
(
Card
.
IsLevelAbove
,
nil
,
slv
+
1
)
sg
:
Remove
(
Card
.
IsLevelAbove
,
nil
,
slv
+
1
)
ft
=
ft
-
1
ft
=
ft
-
1
until
ft
<=
0
or
sg
:
GetCount
()
==
0
or
not
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
50766506
,
0
))
until
ft
<=
0
or
sg
:
GetCount
()
==
0
or
not
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
50766506
,
0
))
Duel
.
SpecialSummonComplete
()
Duel
.
SpecialSummonComplete
()
Duel
.
ConfirmCards
(
1
-
tp
,
cg
)
end
end
function
c50766506
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c50766506
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
e
:
GetHandler
():
GetCardTarget
():
Filter
(
Card
.
IsLocation
,
nil
,
LOCATION_MZONE
)
local
g
=
e
:
GetHandler
():
GetCardTarget
():
Filter
(
Card
.
IsLocation
,
nil
,
LOCATION_MZONE
)
...
...
script/c60930169.lua
View file @
0126a14a
...
@@ -21,10 +21,10 @@ end
...
@@ -21,10 +21,10 @@ end
function
c60930169
.
checkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c60930169
.
checkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
local
a
=
Duel
.
GetAttacker
()
local
t
=
Duel
.
GetAttackTarget
()
local
t
=
Duel
.
GetAttackTarget
()
if
a
and
a
:
Is
Position
(
POS_DEFENCE
)
and
a
:
GetDefence
()
>
a
:
GetAttack
()
and
a
:
IsStatus
(
STATUS_BATTLE_DESTROYED
)
then
if
a
and
a
:
Is
DefencePos
(
)
and
a
:
GetDefence
()
>
a
:
GetAttack
()
and
a
:
IsStatus
(
STATUS_BATTLE_DESTROYED
)
then
a
:
RegisterFlagEffect
(
60930169
,
RESET_PHASE
+
PHASE_DAMAGE
,
0
,
1
)
a
:
RegisterFlagEffect
(
60930169
,
RESET_PHASE
+
PHASE_DAMAGE
,
0
,
1
)
end
end
if
t
and
t
:
Is
Position
(
POS_DEFENCE
)
and
t
:
GetDefence
()
>
t
:
GetAttack
()
and
t
:
IsStatus
(
STATUS_BATTLE_DESTROYED
)
then
if
t
and
t
:
Is
DefencePos
(
)
and
t
:
GetDefence
()
>
t
:
GetAttack
()
and
t
:
IsStatus
(
STATUS_BATTLE_DESTROYED
)
then
t
:
RegisterFlagEffect
(
60930169
,
RESET_PHASE
+
PHASE_DAMAGE
,
0
,
1
)
t
:
RegisterFlagEffect
(
60930169
,
RESET_PHASE
+
PHASE_DAMAGE
,
0
,
1
)
end
end
end
end
...
...
script/c68786330.lua
View file @
0126a14a
...
@@ -19,7 +19,7 @@ end
...
@@ -19,7 +19,7 @@ end
function
c68786330
.
poscon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c68786330
.
poscon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
local
a
=
Duel
.
GetAttacker
()
local
d
=
Duel
.
GetAttackTarget
()
local
d
=
Duel
.
GetAttackTarget
()
return
a
and
d
and
a
:
IsRelateToBattle
()
and
d
:
IsRelateToBattle
()
and
a
:
IsRace
(
RACE_REPTILE
)
and
d
:
Is
Position
(
POS_DEFENCE
)
return
a
and
d
and
a
:
IsRelateToBattle
()
and
d
:
IsRelateToBattle
()
and
a
:
IsRace
(
RACE_REPTILE
)
and
d
:
Is
DefencePos
(
)
end
end
function
c68786330
.
posop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c68786330
.
posop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
not
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
return
end
if
not
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
return
end
...
...
script/c70908596.lua
View file @
0126a14a
...
@@ -22,8 +22,8 @@ function c70908596.filter(c)
...
@@ -22,8 +22,8 @@ function c70908596.filter(c)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x53
)
and
c
:
IsLevelAbove
(
1
)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x53
)
and
c
:
IsLevelAbove
(
1
)
end
end
function
c70908596
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c70908596
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
c
hkc
:
IsControler
(
tp
)
and
c
70908596
.
filter
(
chkc
)
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
c70908596
.
filter
(
chkc
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c70908596
.
filter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c70908596
.
filter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c70908596
.
filter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c70908596
.
filter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
tc
=
g
:
GetFirst
()
local
tc
=
g
:
GetFirst
()
...
...
script/c71315423.lua
View file @
0126a14a
...
@@ -59,6 +59,6 @@ end
...
@@ -59,6 +59,6 @@ end
function
c71315423
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c71315423
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tg
=
e
:
GetHandler
():
GetEquipTarget
()
local
tg
=
e
:
GetHandler
():
GetEquipTarget
()
if
tg
then
if
tg
then
Duel
.
Damage
(
tg
:
GetControler
(),
400
,
REASON_EFFECT
)
Duel
.
Damage
(
tg
:
GetControler
(),
400
,
REASON_EFFECT
)
end
end
end
end
script/c72302403.lua
View file @
0126a14a
...
@@ -34,7 +34,6 @@ function c72302403.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -34,7 +34,6 @@ function c72302403.activate(e,tp,eg,ep,ev,re,r,rp)
Duel
.
ChangePosition
(
sg
,
POS_FACEUP_ATTACK
,
POS_FACEUP_ATTACK
,
POS_FACEUP_DEFENCE
,
POS_FACEUP_DEFENCE
)
Duel
.
ChangePosition
(
sg
,
POS_FACEUP_ATTACK
,
POS_FACEUP_ATTACK
,
POS_FACEUP_DEFENCE
,
POS_FACEUP_DEFENCE
)
end
end
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
c
:
CancelToGrave
()
c
:
CancelToGrave
()
--cannot attack
--cannot attack
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
...
@@ -42,11 +41,13 @@ function c72302403.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -42,11 +41,13 @@ function c72302403.activate(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetCode
(
EFFECT_CANNOT_ATTACK_ANNOUNCE
)
e2
:
SetCode
(
EFFECT_CANNOT_ATTACK_ANNOUNCE
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetTargetRange
(
0
,
LOCATION_MZONE
)
e2
:
SetTargetRange
(
0
,
LOCATION_MZONE
)
e2
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
--remain field
--remain field
local
e3
=
Effect
.
CreateEffect
(
c
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetCode
(
EFFECT_REMAIN_FIELD
)
e3
:
SetCode
(
EFFECT_REMAIN_FIELD
)
e3
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
end
end
function
c72302403
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c72302403
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c73414375.lua
View file @
0126a14a
...
@@ -27,6 +27,8 @@ function c73414375.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -27,6 +27,8 @@ function c73414375.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_REMOVE
,
g
,
g
:
GetCount
(),
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_REMOVE
,
g
,
g
:
GetCount
(),
0
,
0
)
end
end
function
c73414375
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c73414375
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_CARDS
):
Filter
(
Card
.
IsRelateToEffect
,
nil
,
e
)
local
g
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_CARDS
)
Duel
.
Remove
(
g
,
POS_FACEUP
,
REASON_EFFECT
)
if
not
g
then
return
end
local
rg
=
g
:
Filter
(
Card
.
IsRelateToEffect
,
nil
,
e
)
Duel
.
Remove
(
rg
,
POS_FACEUP
,
REASON_EFFECT
)
end
end
script/c75733063.lua
View file @
0126a14a
...
@@ -23,7 +23,7 @@ function c75733063.atkfilter(c)
...
@@ -23,7 +23,7 @@ function c75733063.atkfilter(c)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x13
)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x13
)
end
end
function
c75733063
.
val
(
e
,
c
)
function
c75733063
.
val
(
e
,
c
)
return
Duel
.
GetMatchingGroupCount
(
c75733063
.
atkfilter
,
c
:
GetControler
(),
LOCATION_MZONE
,
0
,
c
)
*
200
return
Duel
.
GetMatchingGroupCount
(
c75733063
.
atkfilter
,
0
,
LOCATION_MZONE
,
LOCATION_MZONE
,
c
)
*
200
end
end
function
c75733063
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c75733063
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsLocation
(
LOCATION_GRAVE
)
and
e
:
GetHandler
():
IsReason
(
REASON_BATTLE
)
return
e
:
GetHandler
():
IsLocation
(
LOCATION_GRAVE
)
and
e
:
GetHandler
():
IsReason
(
REASON_BATTLE
)
...
...
script/c7625614.lua
View file @
0126a14a
...
@@ -41,8 +41,9 @@ function c7625614.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -41,8 +41,9 @@ function c7625614.operation(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Equip
(
tp
,
e
:
GetHandler
(),
tc
)
Duel
.
Equip
(
tp
,
e
:
GetHandler
(),
tc
)
end
end
end
end
function
c7625614
.
atkcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c7625614
.
atkcon
(
e
)
return
e
:
GetHandler
():
GetEquipTarget
():
GetControler
()
==
tp
local
ec
=
e
:
GetHandler
():
GetEquipTarget
()
return
ec
and
ec
:
GetControler
()
==
e
:
GetHandlerPlayer
()
end
end
function
c7625614
.
atktg
(
e
,
c
)
function
c7625614
.
atktg
(
e
,
c
)
return
c
~=
e
:
GetHandler
():
GetEquipTarget
()
return
c
~=
e
:
GetHandler
():
GetEquipTarget
()
...
...
script/c76419637.lua
View file @
0126a14a
...
@@ -39,7 +39,7 @@ function c76419637.dctg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -39,7 +39,7 @@ function c76419637.dctg(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function
c76419637
.
dcop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c76419637
.
dcop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
Duel
.
DiscardHand
(
1
-
tp
,
nil
,
1
,
1
,
REASON_EFFECT
)
Duel
.
DiscardHand
(
1
-
tp
,
nil
,
1
,
1
,
REASON_EFFECT
+
REASON_DISCARD
)
end
end
function
c76419637
.
damcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c76419637
.
damcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
GetOverlayGroup
():
IsExists
(
Card
.
IsCode
,
1
,
nil
,
40424929
)
return
e
:
GetHandler
():
GetOverlayGroup
():
IsExists
(
Card
.
IsCode
,
1
,
nil
,
40424929
)
...
...
script/c76721030.lua
View file @
0126a14a
...
@@ -9,7 +9,6 @@ function c76721030.initial_effect(c)
...
@@ -9,7 +9,6 @@ function c76721030.initial_effect(c)
--cannot trigger
--cannot trigger
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
)
e2
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e2
:
SetCode
(
EFFECT_CANNOT_TRIGGER
)
e2
:
SetCode
(
EFFECT_CANNOT_TRIGGER
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetTargetRange
(
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
+
LOCATION_HAND
)
e2
:
SetTargetRange
(
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
+
LOCATION_HAND
)
...
...
script/c78009994.lua
View file @
0126a14a
...
@@ -7,6 +7,9 @@ function c78009994.initial_effect(c)
...
@@ -7,6 +7,9 @@ function c78009994.initial_effect(c)
e1
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e1
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e1
:
SetOperation
(
c78009994
.
ctop
)
e1
:
SetOperation
(
c78009994
.
ctop
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EVENT_MSET
)
c
:
RegisterEffect
(
e2
)
--special summon
--special summon
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e2
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
...
...
script/c78540593.lua
View file @
0126a14a
...
@@ -15,8 +15,9 @@ function c78540593.initial_effect(c)
...
@@ -15,8 +15,9 @@ function c78540593.initial_effect(c)
end
end
function
c78540593
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c78540593
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
eg
:
GetFirst
()
local
tc
=
eg
:
GetFirst
()
return
eg
:
GetCount
()
==
1
and
tc
:
IsReason
(
REASON_DESTROY
)
and
tc
:
IsPreviousLocation
(
LOCATION_MZONE
)
return
eg
:
GetCount
()
==
1
and
tc
:
IsReason
(
REASON_DESTROY
)
and
tc
:
IsReason
(
REASON_BATTLE
+
REASON_EFFECT
)
and
tc
:
GetPreviousControler
()
==
tp
and
bit
.
band
(
tc
:
GetPreviousRaceOnField
(),
RACE_PLANT
)
~=
0
and
tc
:
IsPreviousLocation
(
LOCATION_MZONE
)
and
tc
:
GetPreviousControler
()
==
tp
and
bit
.
band
(
tc
:
GetPreviousRaceOnField
(),
RACE_PLANT
)
~=
0
end
end
function
c78540593
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c78540593
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsControler
(
1
-
tp
)
and
chkc
:
IsOnField
()
and
chkc
:
IsDestructable
()
end
if
chkc
then
return
chkc
:
IsControler
(
1
-
tp
)
and
chkc
:
IsOnField
()
and
chkc
:
IsDestructable
()
end
...
...
script/c81907872.lua
View file @
0126a14a
...
@@ -47,7 +47,7 @@ function c81907872.posop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -47,7 +47,7 @@ function c81907872.posop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c81907872
.
cfilter
(
c
,
tp
)
function
c81907872
.
cfilter
(
c
,
tp
)
return
c
:
IsControler
(
tp
)
and
c
:
IsPreviousPosition
(
POS_FACEUP
)
and
c
:
IsSetCard
(
0x8d
)
and
c
:
IsReason
(
REASON_DESTROY
)
and
c
:
IsType
(
TYPE_MONSTER
)
return
c
:
IsControler
(
tp
)
and
c
:
GetPreviousControler
()
==
tp
and
c
:
IsSetCard
(
0x8d
)
and
c
:
IsReason
(
REASON_DESTROY
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
(
not
c
:
IsReason
(
REASON_BATTLE
)
or
c
==
Duel
.
GetAttackTarget
())
and
(
not
c
:
IsReason
(
REASON_BATTLE
)
or
c
==
Duel
.
GetAttackTarget
())
end
end
function
c81907872
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c81907872
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c88190790.lua
View file @
0126a14a
...
@@ -21,7 +21,7 @@ function c88190790.initial_effect(c)
...
@@ -21,7 +21,7 @@ function c88190790.initial_effect(c)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetCode
(
EFFECT_EQUIP_LIMIT
)
e3
:
SetCode
(
EFFECT_EQUIP_LIMIT
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e3
:
SetValue
(
1
)
e3
:
SetValue
(
c88190790
.
eqlimit
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
--multi attack
--multi attack
local
e4
=
Effect
.
CreateEffect
(
c
)
local
e4
=
Effect
.
CreateEffect
(
c
)
...
@@ -33,6 +33,12 @@ function c88190790.initial_effect(c)
...
@@ -33,6 +33,12 @@ function c88190790.initial_effect(c)
e4
:
SetOperation
(
c88190790
.
maop
)
e4
:
SetOperation
(
c88190790
.
maop
)
c
:
RegisterEffect
(
e4
)
c
:
RegisterEffect
(
e4
)
end
end
function
c88190790
.
eqlimit
(
e
,
c
)
if
e
:
GetHandler
():
GetEquipTarget
()
==
c
then
return
true
end
local
g
=
Duel
.
GetFieldGroup
(
e
:
GetHandlerPlayer
(),
LOCATION_MZONE
,
0
)
local
tc
=
g
:
GetFirst
()
return
g
:
GetCount
()
==
1
and
tc
==
c
and
tc
:
IsRace
(
RACE_WARRIOR
)
end
function
c88190790
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c88190790
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_MZONE
,
0
)
local
g
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_MZONE
,
0
)
local
tc
=
g
:
GetFirst
()
local
tc
=
g
:
GetFirst
()
...
...
script/c90810762.lua
View file @
0126a14a
...
@@ -7,14 +7,20 @@ function c90810762.initial_effect(c)
...
@@ -7,14 +7,20 @@ function c90810762.initial_effect(c)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
--atkup
--atkup
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e2
:
SetDescription
(
aux
.
Stringid
(
90810762
,
0
))
e2
:
SetCategory
(
CATEGORY_ATKCHANGE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e2
:
SetCode
(
EVENT_BATTLE_DAMAGE
)
e2
:
SetCode
(
EVENT_BATTLE_DAMAGE
)
e2
:
SetCondition
(
c90810762
.
atkcon
)
e2
:
SetOperation
(
c90810762
.
atkop
)
e2
:
SetOperation
(
c90810762
.
atkop
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
function
c90810762
.
atkcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
ep
~=
tp
and
Duel
.
GetAttackTarget
()
==
nil
end
function
c90810762
.
atkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c90810762
.
atkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
if
Duel
.
GetAttackTarget
()
==
nil
then
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
then
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
...
...
script/c99902789.lua
View file @
0126a14a
...
@@ -14,9 +14,7 @@ function c99902789.initial_effect(c)
...
@@ -14,9 +14,7 @@ function c99902789.initial_effect(c)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
function
c99902789
.
discon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c99902789
.
discon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
return
Duel
.
CheckEvent
(
EVENT_ATTACK_ANNOUNCE
)
and
Duel
.
GetAttacker
():
IsControler
(
tp
)
and
Duel
.
GetAttackTarget
()
~=
nil
local
at
=
Duel
.
GetAttackTarget
()
return
Duel
.
CheckEvent
(
EVENT_ATTACK_ANNOUNCE
)
and
at
and
(
a
and
a
:
IsControler
(
tp
)
or
at
:
IsControler
(
tp
))
and
ep
~=
tp
and
re
:
GetActiveType
()
==
TYPE_TRAP
and
re
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
)
and
Duel
.
IsChainNegatable
(
ev
)
and
ep
~=
tp
and
re
:
GetActiveType
()
==
TYPE_TRAP
and
re
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
)
and
Duel
.
IsChainNegatable
(
ev
)
end
end
function
c99902789
.
discost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c99902789
.
discost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment