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
YGOPRO-520DIY
ygopro
Commits
8ed0d9ea
Commit
8ed0d9ea
authored
Sep 05, 2012
by
argon.sun
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of github.com:Fluorohydride/ygopro
parents
96a34610
9ac39ceb
Changes
61
Hide whitespace changes
Inline
Side-by-side
Showing
61 changed files
with
162 additions
and
143 deletions
+162
-143
ocgcore/libdebug.cpp
ocgcore/libdebug.cpp
+1
-0
ocgcore/operations.cpp
ocgcore/operations.cpp
+2
-1
script/c13574687.lua
script/c13574687.lua
+3
-2
script/c14089428.lua
script/c14089428.lua
+1
-1
script/c14550855.lua
script/c14550855.lua
+2
-2
script/c14745409.lua
script/c14745409.lua
+1
-1
script/c17189532.lua
script/c17189532.lua
+1
-1
script/c17377751.lua
script/c17377751.lua
+1
-2
script/c18807108.lua
script/c18807108.lua
+14
-12
script/c21420702.lua
script/c21420702.lua
+1
-2
script/c26016357.lua
script/c26016357.lua
+2
-2
script/c26205777.lua
script/c26205777.lua
+1
-1
script/c26285788.lua
script/c26285788.lua
+2
-2
script/c26732909.lua
script/c26732909.lua
+4
-0
script/c29228529.lua
script/c29228529.lua
+4
-2
script/c29343734.lua
script/c29343734.lua
+7
-2
script/c296499.lua
script/c296499.lua
+2
-2
script/c31849106.lua
script/c31849106.lua
+1
-2
script/c35220244.lua
script/c35220244.lua
+1
-1
script/c35514096.lua
script/c35514096.lua
+1
-1
script/c3897065.lua
script/c3897065.lua
+5
-5
script/c39284521.lua
script/c39284521.lua
+1
-1
script/c39751093.lua
script/c39751093.lua
+1
-1
script/c39751094.lua
script/c39751094.lua
+1
-1
script/c40101111.lua
script/c40101111.lua
+5
-12
script/c40230018.lua
script/c40230018.lua
+7
-0
script/c41639001.lua
script/c41639001.lua
+1
-2
script/c42386471.lua
script/c42386471.lua
+2
-2
script/c44763025.lua
script/c44763025.lua
+1
-1
script/c4694209.lua
script/c4694209.lua
+1
-1
script/c47506081.lua
script/c47506081.lua
+2
-4
script/c48579379.lua
script/c48579379.lua
+0
-6
script/c49681811.lua
script/c49681811.lua
+1
-1
script/c49771608.lua
script/c49771608.lua
+5
-11
script/c54704216.lua
script/c54704216.lua
+10
-8
script/c55171412.lua
script/c55171412.lua
+0
-1
script/c5861892.lua
script/c5861892.lua
+2
-2
script/c61777313.lua
script/c61777313.lua
+1
-1
script/c62878208.lua
script/c62878208.lua
+2
-1
script/c67959180.lua
script/c67959180.lua
+2
-2
script/c68722455.lua
script/c68722455.lua
+2
-2
script/c69537999.lua
script/c69537999.lua
+1
-2
script/c71395725.lua
script/c71395725.lua
+1
-1
script/c7165085.lua
script/c7165085.lua
+8
-2
script/c74117290.lua
script/c74117290.lua
+1
-1
script/c74923978.lua
script/c74923978.lua
+4
-2
script/c75524092.lua
script/c75524092.lua
+3
-4
script/c76224717.lua
script/c76224717.lua
+5
-3
script/c76895648.lua
script/c76895648.lua
+1
-1
script/c77910045.lua
script/c77910045.lua
+7
-5
script/c78663366.lua
script/c78663366.lua
+10
-1
script/c79229522.lua
script/c79229522.lua
+2
-2
script/c80513550.lua
script/c80513550.lua
+5
-1
script/c80885324.lua
script/c80885324.lua
+1
-1
script/c84080938.lua
script/c84080938.lua
+2
-2
script/c84080939.lua
script/c84080939.lua
+2
-2
script/c8487449.lua
script/c8487449.lua
+1
-2
script/c86170989.lua
script/c86170989.lua
+2
-4
script/c95096437.lua
script/c95096437.lua
+1
-1
script/c95308449.lua
script/c95308449.lua
+0
-1
script/c99594764.lua
script/c99594764.lua
+1
-1
No files found.
ocgcore/libdebug.cpp
View file @
8ed0d9ea
...
...
@@ -5,6 +5,7 @@
* Author: Argon
*/
#include <string.h>
#include "scriptlib.h"
#include "duel.h"
#include "field.h"
...
...
ocgcore/operations.cpp
View file @
8ed0d9ea
...
...
@@ -1087,7 +1087,8 @@ int32 field::summon(uint16 step, uint8 sumplayer, card * target, effect * proc,
if
(
target
->
current
.
location
==
LOCATION_MZONE
)
{
if
(
target
->
is_position
(
POS_FACEDOWN
))
return
TRUE
;
if
(
!
ignore_count
&&
core
.
summon_count
[
sumplayer
]
>=
get_summon_count_limit
(
sumplayer
))
if
(
!
ignore_count
&&
(
core
.
extra_summon
[
sumplayer
]
||
!
target
->
is_affected_by_effect
(
EFFECT_EXTRA_SUMMON_COUNT
))
&&
(
core
.
summon_count
[
sumplayer
]
>=
get_summon_count_limit
(
sumplayer
)))
return
TRUE
;
if
(
!
target
->
is_affected_by_effect
(
EFFECT_DUAL_SUMMONABLE
))
return
TRUE
;
...
...
script/c13574687.lua
View file @
8ed0d9ea
...
...
@@ -24,14 +24,15 @@ function c13574687.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c13574687
.
filter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
g
:
GetFirst
():
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
g
:
GetFirst
():
GetControler
()
,
g
:
GetFirst
():
GetAttack
()
/
2
)
end
function
c13574687
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
and
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
local
dam
=
tc
:
GetAttack
()
/
2
local
p
=
tc
:
GetControler
()
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
Duel
.
Damage
(
1
-
t
p
,
dam
,
REASON_EFFECT
)
Duel
.
Damage
(
p
,
dam
,
REASON_EFFECT
)
end
end
end
script/c14089428.lua
View file @
8ed0d9ea
...
...
@@ -10,7 +10,7 @@ function c14089428.initial_effect(c)
c
:
RegisterEffect
(
e1
)
end
function
c14089428
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
IsRelateToBattle
()
end
if
chk
==
0
then
return
true
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
nil
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOKEN
,
nil
,
1
,
0
,
0
)
end
...
...
script/c14550855.lua
View file @
8ed0d9ea
...
...
@@ -12,10 +12,10 @@ end
function
c14550855
.
filter
(
c
)
return
c
:
IsSetCard
(
0xb
)
and
c
:
IsAbleToGrave
()
end
function
c14550855
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
function
c14550855
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_HAND
,
0
)
>
0
and
Duel
.
IsExistingMatchingCard
(
c14550855
.
filter
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
nil
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
nil
,
0
,
tp
,
1
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOGRAVE
,
nil
,
1
,
tp
,
LOCATION_DECK
)
end
function
c14550855
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c14745409.lua
View file @
8ed0d9ea
...
...
@@ -36,7 +36,7 @@ function c14745409.initial_effect(c)
local
e5
=
Effect
.
CreateEffect
(
c
)
e5
:
SetDescription
(
aux
.
Stringid
(
14745409
,
0
))
e5
:
SetCategory
(
CATEGORY_EQUIP
)
e5
:
SetProperty
(
EFFECT_FLAG_DAMAGE_STEP
+
EFFECT_FLAG_CHAIN_UNIQUE
)
e5
:
SetProperty
(
EFFECT_FLAG_
CARD_TARGET
+
EFFECT_FLAG_
DAMAGE_STEP
+
EFFECT_FLAG_CHAIN_UNIQUE
)
e5
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e5
:
SetCode
(
EVENT_TO_GRAVE
)
e5
:
SetCondition
(
c14745409
.
eqcon
)
...
...
script/c17189532.lua
View file @
8ed0d9ea
...
...
@@ -20,7 +20,7 @@ function c17189532.filter(c)
end
function
c17189532
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c17189532
.
filter
,
tp
,
LOCATION_DECK
,
0
,
2
,
nil
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
1
,
tp
,
LOCATION_DECK
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
2
,
tp
,
LOCATION_DECK
)
end
function
c17189532
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
sg
=
Duel
.
GetMatchingGroup
(
c17189532
.
filter
,
tp
,
LOCATION_DECK
,
0
,
nil
)
...
...
script/c17377751.lua
View file @
8ed0d9ea
...
...
@@ -5,9 +5,8 @@ function c17377751.initial_effect(c)
c
:
EnableReviveLimit
()
--cannot special summon
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCode
(
EFFECT_SPSUMMON_CONDITION
)
c
:
RegisterEffect
(
e1
)
...
...
script/c18807108.lua
View file @
8ed0d9ea
...
...
@@ -17,24 +17,26 @@ function c18807108.initial_effect(c)
e2
:
SetCondition
(
c18807108
.
descon
)
e2
:
SetOperation
(
c18807108
.
desop
)
c
:
RegisterEffect
(
e2
)
e1
:
SetLabelObject
(
e2
)
end
function
c18807108
.
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
chkc
:
IsFaceup
()
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
Card
.
IsFaceup
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
FACEUP
)
local
g
=
Duel
.
SelectTarget
(
tp
,
Card
.
IsFaceup
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
IsControler
(
1
-
tp
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
nil
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
TARGET
)
Duel
.
SelectTarget
(
tp
,
nil
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
end
function
c18807108
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
tc
=
Duel
.
GetFirstTarget
()
if
c
:
IsRelateToEffect
(
e
)
and
tc
:
Is
Faceup
()
and
tc
:
Is
RelateToEffect
(
e
)
then
if
c
:
IsRelateToEffect
(
e
)
and
tc
:
IsRelateToEffect
(
e
)
then
c
:
SetCardTarget
(
tc
)
c
:
CreateRelation
(
tc
,
RESET_EVENT
+
0x1fe0000
)
e
:
GetLabelObject
():
SetLabelObject
(
tc
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
+
EFFECT_FLAG_OWNER_RELATE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetProperty
(
EFFECT_FLAG_OWNER_RELATE
)
e1
:
SetCode
(
EFFECT_CANNOT_CHANGE_POSITION
)
e1
:
SetReset
(
RESET_EVENT
+
0x1f
e
0000
)
e1
:
SetReset
(
RESET_EVENT
+
0x1f
c
0000
)
e1
:
SetCondition
(
c18807108
.
rcon
)
tc
:
RegisterEffect
(
e1
,
true
)
local
e2
=
e1
:
Clone
()
...
...
@@ -43,14 +45,14 @@ function c18807108.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c18807108
.
rcon
(
e
)
return
e
:
GetOwner
():
Is
HasCardTarget
(
e
:
GetHandler
())
return
e
:
GetOwner
():
Is
RelateToCard
(
e
:
GetHandler
())
end
function
c18807108
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsStatus
(
STATUS_DESTROY_CONFIRMED
)
then
return
false
end
local
tc
=
c
:
GetFirstCardTarge
t
()
return
tc
and
eg
:
IsContains
(
tc
)
and
tc
:
IsReason
(
REASON_DESTROY
)
local
tc
=
e
:
GetLabelObjec
t
()
return
tc
and
eg
:
IsContains
(
tc
)
and
tc
:
IsReason
(
REASON_DESTROY
)
and
c
:
IsRelateToCard
(
tc
)
end
function
c18807108
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_EFFECT
)
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_EFFECT
)
end
script/c21420702.lua
View file @
8ed0d9ea
...
...
@@ -32,9 +32,8 @@ function c21420702.descost(e,tp,eg,ep,ev,re,r,rp,chk)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_CANNOT_ATTACK_ANNOUNCE
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
+
EFFECT_FLAG_OATH
)
e1
:
SetTargetRange
(
1
,
0
)
e1
:
SetProperty
(
EFFECT_FLAG_OATH
)
e1
:
SetReset
(
RESET_PHASE
+
RESET_END
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
...
...
script/c26016357.lua
View file @
8ed0d9ea
...
...
@@ -40,13 +40,13 @@ end
function
c26016357
.
thtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_GRAVE
)
and
chkc
:
IsControler
(
tp
)
and
c26016357
.
filter
(
chkc
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c26016357
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
R
TOHAND
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
A
TOHAND
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c26016357
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
g
,
1
,
0
,
0
)
end
function
c26016357
.
thop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
if
tc
:
IsRelateToEffect
(
e
)
then
Duel
.
SendtoHand
(
tc
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
tc
)
end
...
...
script/c26205777.lua
View file @
8ed0d9ea
...
...
@@ -16,7 +16,7 @@ function c26205777.condition(e,tp,eg,ep,ev,re,r,rp)
end
function
c26205777
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
nil
,
1
,
1
-
tp
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
nil
,
0
,
1
-
tp
,
1
)
end
function
c26205777
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetFieldGroup
(
tp
,
0
,
LOCATION_HAND
)
...
...
script/c26285788.lua
View file @
8ed0d9ea
...
...
@@ -72,9 +72,9 @@ function c26285788.effectop(e,tp,eg,ep,ev,re,r,rp)
end
else
local
g
=
Duel
.
GetMatchingGroup
(
c26285788
.
filter2
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
nil
)
if
g
:
GetCount
()
>
2
then
if
g
:
GetCount
()
>
0
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
tg
=
g
:
Select
(
tp
,
3
,
3
,
nil
)
local
tg
=
g
:
Select
(
tp
,
1
,
3
,
nil
)
Duel
.
Destroy
(
tg
,
REASON_EFFECT
)
end
end
...
...
script/c26732909.lua
View file @
8ed0d9ea
...
...
@@ -7,6 +7,7 @@ function c26732909.initial_effect(c)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCondition
(
c26732909
.
thcon
)
e1
:
SetCost
(
c26732909
.
thcost
)
e1
:
SetTarget
(
c26732909
.
thtg
)
e1
:
SetOperation
(
c26732909
.
thop
)
...
...
@@ -46,6 +47,9 @@ function c26732909.clear(e,tp,eg,ep,ev,re,r,rp)
c26732909
[
0
]
=
0
c26732909
[
1
]
=
0
end
function
c26732909
.
thcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetTurnPlayer
()
==
tp
end
function
c26732909
.
thcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
c26732909
[
tp
]
>
0
and
Duel
.
GetFlagEffect
(
tp
,
26732909
)
==
0
and
e
:
GetHandler
():
IsAbleToRemoveAsCost
()
end
Duel
.
Remove
(
e
:
GetHandler
(),
POS_FACEUP
,
REASON_COST
)
...
...
script/c29228529.lua
View file @
8ed0d9ea
...
...
@@ -15,13 +15,15 @@ function c29228529.costfilter(c)
end
function
c29228529
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c29228529
.
costfilter
,
tp
,
LOCATION_HAND
,
0
,
2
,
e
:
GetHandler
())
end
Duel
.
DiscardHand
(
tp
,
c29228529
.
costfilter
,
2
,
2
,
REASON_COST
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TOGRAVE
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c29228529
.
costfilter
,
tp
,
LOCATION_HAND
,
0
,
2
,
2
,
nil
)
Duel
.
SendtoGrave
(
g
,
REASON_COST
)
end
function
c29228529
.
filter
(
c
)
return
c
:
IsType
(
TYPE_SPELL
)
and
c
:
IsAbleToHand
()
end
function
c29228529
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
GetLocation
()
==
LOCATION_GRAVE
and
chkc
:
GetControler
()
==
tp
and
c29228529
.
filter
(
chkc
)
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_GRAVE
)
and
chkc
:
IsControler
(
tp
)
and
c29228529
.
filter
(
chkc
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c29228529
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c29228529
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
)
...
...
script/c29343734.lua
View file @
8ed0d9ea
...
...
@@ -23,9 +23,9 @@ function c29343734.initial_effect(c)
e4
:
SetDescription
(
aux
.
Stringid
(
29343734
,
0
))
e4
:
SetCategory
(
CATEGORY_TODECK
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e4
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e4
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e4
:
SetCondition
(
c29343734
.
retcon
)
e4
:
SetTarget
(
c29343734
.
rettg
)
e4
:
SetOperation
(
c29343734
.
retop
)
c
:
RegisterEffect
(
e4
)
--atk
...
...
@@ -45,8 +45,13 @@ end
function
c29343734
.
retcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
bit
.
band
(
e
:
GetHandler
():
GetSummonType
(),
SUMMON_TYPE_FUSION
)
==
SUMMON_TYPE_FUSION
end
function
c29343734
.
rettg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
local
g
=
Duel
.
GetMatchingGroup
(
Card
.
IsAbleToDeck
,
tp
,
LOCATION_REMOVED
,
LOCATION_REMOVED
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TODECK
,
g
,
g
:
GetCount
(),
0
,
0
)
end
function
c29343734
.
retop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetMatchingGroup
(
aux
.
TRUE
,
tp
,
LOCATION_REMOVED
,
LOCATION_REMOVED
,
nil
)
local
g
=
Duel
.
GetMatchingGroup
(
nil
,
tp
,
LOCATION_REMOVED
,
LOCATION_REMOVED
,
nil
)
Duel
.
SendtoDeck
(
g
,
nil
,
2
,
REASON_EFFECT
)
end
function
c29343734
.
atkfilter
(
c
,
att
)
...
...
script/c296499.lua
View file @
8ed0d9ea
...
...
@@ -37,8 +37,8 @@ function c296499.atktarget(e,c)
end
function
c296499
.
mtop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
Duel
.
GetTurnPlayer
()
~=
tp
then
return
end
if
Duel
.
CheckReleaseGroup
(
tp
,
Card
.
IsReleasable
ByCost
,
1
,
nil
)
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
296499
,
0
))
then
local
g
=
Duel
.
SelectReleaseGroup
(
tp
,
Card
.
IsReleasable
ByCost
,
1
,
1
,
nil
)
if
Duel
.
CheckReleaseGroup
(
tp
,
Card
.
IsReleasable
,
1
,
nil
)
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
296499
,
0
))
then
local
g
=
Duel
.
SelectReleaseGroup
(
tp
,
Card
.
IsReleasable
,
1
,
1
,
nil
)
Duel
.
Release
(
g
,
REASON_COST
)
else
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_RULE
)
...
...
script/c31849106.lua
View file @
8ed0d9ea
...
...
@@ -10,9 +10,8 @@ end
function
c31849106
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetProperty
(
EFFECT_FLAG_SET_AVAILABLE
)
e1
:
SetProperty
(
EFFECT_FLAG_SET_AVAILABLE
+
EFFECT_FLAG_IGNORE_RANGE
)
e1
:
SetCode
(
EFFECT_TO_GRAVE_REDIRECT
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_RANGE
)
e1
:
SetTarget
(
c31849106
.
rmtarget
)
e1
:
SetValue
(
LOCATION_REMOVED
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
...
...
script/c35220244.lua
View file @
8ed0d9ea
...
...
@@ -66,7 +66,7 @@ function c35220244.atkop(e,tp,eg,ep,ev,re,r,rp)
end
function
c35220244
.
discon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
ec
=
e
:
GetHandler
():
GetEquipTarget
()
return
ec
and
(
ec
==
Duel
.
GetAttacker
()
or
ec
==
Duel
.
GetAttackTarget
())
and
ec
:
GetBattleTarget
()
:
IsFaceup
()
return
ec
and
(
ec
==
Duel
.
GetAttacker
()
or
ec
==
Duel
.
GetAttackTarget
())
and
ec
:
GetBattleTarget
()
end
function
c35220244
.
disop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
e
:
GetHandler
():
GetEquipTarget
():
GetBattleTarget
()
...
...
script/c35514096.lua
View file @
8ed0d9ea
...
...
@@ -13,7 +13,7 @@ function c35514096.filter(c)
end
function
c35514096
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsOnField
()
and
c35514096
.
filter
(
chkc
)
end
if
chk
==
0
then
return
e
:
GetHandler
():
IsRelateToBattle
()
end
if
chk
==
0
then
return
true
end
local
c
=
e
:
GetHandler
()
local
t1
=
c
:
IsChainAttackable
()
local
t2
=
Duel
.
IsExistingTarget
(
c35514096
.
filter
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
1
,
nil
)
...
...
script/c3897065.lua
View file @
8ed0d9ea
...
...
@@ -35,15 +35,15 @@ function c3897065.initial_effect(c)
end
c3897065
.
material_count
=
4
c3897065
.
material
=
{
61538782
,
98049038
,
71218746
,
984114
}
function
c3897065
.
eqfilter
(
c
)
return
c
:
IsFaceup
()
and
not
c
:
IsRace
(
RACE_MACHINE
)
and
c
:
IsAbleToChangeControler
(
)
function
c3897065
.
eqfilter
(
c
,
tp
)
return
c
:
IsFaceup
()
and
not
c
:
IsRace
(
RACE_MACHINE
)
and
(
c
:
IsControler
(
tp
)
or
c
:
IsAbleToChangeControler
()
)
end
function
c3897065
.
eqtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
c3897065
.
eqfilter
(
chkc
)
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
c3897065
.
eqfilter
(
chkc
,
tp
)
end
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
>
0
and
Duel
.
IsExistingTarget
(
c3897065
.
eqfilter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
e
:
GetHandler
()
)
end
and
Duel
.
IsExistingTarget
(
c3897065
.
eqfilter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
e
:
GetHandler
(),
tp
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_EQUIP
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c3897065
.
eqfilter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
e
:
GetHandler
()
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c3897065
.
eqfilter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
e
:
GetHandler
(),
tp
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_EQUIP
,
g
,
1
,
0
,
0
)
end
function
c3897065
.
eqlimit
(
e
,
c
)
...
...
script/c39284521.lua
View file @
8ed0d9ea
...
...
@@ -11,7 +11,7 @@ function c39284521.initial_effect(c)
e1
:
SetOperation
(
c39284521
.
spop
)
c
:
RegisterEffect
(
e1
)
end
function
c39284521
.
spfilter
(
c
,
ec
)
function
c39284521
.
spfilter
(
c
)
return
c
:
IsRace
(
RACE_MACHINE
)
and
c
:
IsAbleToGraveAsCost
()
end
function
c39284521
.
spcon
(
e
,
c
)
...
...
script/c39751093.lua
View file @
8ed0d9ea
...
...
@@ -22,7 +22,7 @@ function c39751093.initial_effect(c)
e4
:
SetDescription
(
aux
.
Stringid
(
39751093
,
1
))
e4
:
SetCategory
(
CATEGORY_POSITION
)
e4
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_
F
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_
O
)
e4
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e4
:
SetTarget
(
c39751093
.
target
)
e4
:
SetOperation
(
c39751093
.
operation
)
...
...
script/c39751094.lua
View file @
8ed0d9ea
...
...
@@ -22,7 +22,7 @@ function c39751094.initial_effect(c)
e4
:
SetDescription
(
aux
.
Stringid
(
39751094
,
1
))
e4
:
SetCategory
(
CATEGORY_POSITION
)
e4
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_
F
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_
O
)
e4
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e4
:
SetTarget
(
c39751094
.
target
)
e4
:
SetOperation
(
c39751094
.
operation
)
...
...
script/c40101111.lua
View file @
8ed0d9ea
...
...
@@ -45,21 +45,14 @@ function c40101111.ffilter(c)
end
function
c40101111
.
recon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
a
=
Duel
.
GetAttacker
()
local
d
=
Duel
.
GetAttackTarget
()
return
(
c
==
a
and
d
:
IsLocation
(
LOCATION_GRAVE
)
and
d
:
IsType
(
TYPE_MONSTER
))
or
(
c
==
d
and
a
:
IsLocation
(
LOCATION_GRAVE
)
and
a
:
IsType
(
TYPE_MONSTER
))
local
bc
=
c
:
GetBattleTarget
()
return
c
:
IsRelateToBattle
()
and
bc
:
IsLocation
(
LOCATION_GRAVE
)
and
bc
:
IsType
(
TYPE_MONSTER
)
end
function
c40101111
.
rectg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
if
chk
==
0
then
return
c
:
IsRelateToBattle
()
end
local
a
=
Duel
.
GetAttacker
()
local
d
=
Duel
.
GetAttackTarget
()
Duel
.
SetTargetPlayer
(
tp
)
local
rec
=
0
if
c
==
a
then
rec
=
d
:
GetAttack
()
else
rec
=
a
:
GetAttack
()
end
if
chk
==
0
then
return
true
end
local
rec
=
e
:
GetHandler
():
GetBattleTarget
():
GetAttack
()
if
rec
<
0
then
rec
=
0
end
Duel
.
SetTargetPlayer
(
tp
)
Duel
.
SetTargetParam
(
rec
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
rec
)
end
...
...
script/c40230018.lua
View file @
8ed0d9ea
...
...
@@ -6,6 +6,7 @@ function c40230018.initial_effect(c)
e1
:
SetCategory
(
CATEGORY_TOHAND
+
CATEGORY_SEARCH
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCondition
(
c40230018
.
condition
)
e1
:
SetCost
(
c40230018
.
cost
)
e1
:
SetTarget
(
c40230018
.
target
)
e1
:
SetOperation
(
c40230018
.
operation
)
...
...
@@ -35,6 +36,12 @@ function c40230018.clear(e,tp,eg,ep,ev,re,r,rp)
c40230018
[
0
]
=
true
c40230018
[
1
]
=
true
end
function
c40230018
.
cfilter
(
c
)
return
c
:
IsSetCard
(
0x106e
)
and
c
:
IsType
(
TYPE_SPELL
)
end
function
c40230018
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
not
Duel
.
IsExistingMatchingCard
(
c40230018
.
cfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
end
function
c40230018
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetFlagEffect
(
tp
,
40230018
)
==
0
and
c40230018
[
tp
]
end
Duel
.
RegisterFlagEffect
(
tp
,
40230018
,
RESET_PHASE
+
PHASE_END
,
EFFECT_FLAG_OATH
,
1
)
...
...
script/c41639001.lua
View file @
8ed0d9ea
...
...
@@ -18,8 +18,7 @@ function c41639001.spcon(e,tp,eg,ep,ev,re,r,rp)
local
c
=
e
:
GetHandler
()
if
not
re
:
IsHasProperty
(
EFFECT_FLAG_CARD_TARGET
)
then
return
false
end
local
g
=
Duel
.
GetChainInfo
(
ev
,
CHAININFO_TARGET_CARDS
)
if
not
g
or
not
g
:
IsContains
(
c
)
then
return
false
end
return
re
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
)
or
re
:
IsActiveType
(
TYPE_MONSTER
)
return
g
and
g
:
IsContains
(
c
)
end
function
c41639001
.
spfilter
(
c
,
e
,
tp
)
return
c
:
IsType
(
TYPE_NORMAL
)
and
c
:
IsRace
(
RACE_DRAGON
)
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
...
...
script/c42386471.lua
View file @
8ed0d9ea
...
...
@@ -64,10 +64,10 @@ function c42386471.dircon(e)
end
function
c42386471
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
nil
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
nil
,
0
,
1
-
tp
,
1
)
end
function
c42386471
.
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
)
if
g
:
GetCount
()
==
0
then
return
end
local
sg
=
g
:
RandomSelect
(
1
-
tp
,
1
)
Duel
.
SendtoGrave
(
sg
,
REASON_EFFECT
+
REASON_DISCARD
)
...
...
script/c44763025.lua
View file @
8ed0d9ea
...
...
@@ -25,7 +25,7 @@ function c44763025.activate(e,tp,eg,ep,ev,re,r,rp)
local
g
=
Duel
.
GetFieldGroup
(
p
,
0
,
LOCATION_HAND
)
if
g
:
GetCount
()
>
0
then
local
sg
=
g
:
RandomSelect
(
p
,
1
)
Duel
.
SendtoGrave
(
sg
,
REASON_EFFECT
)
Duel
.
SendtoGrave
(
sg
,
REASON_EFFECT
+
REASON_DISCARD
)
g
:
RemoveCard
(
sg
:
GetFirst
())
if
g
:
GetCount
()
>
0
then
Duel
.
Hint
(
HINT_SELECTMSG
,
1
-
p
,
HINTMSG_DISCARD
)
...
...
script/c4694209.lua
View file @
8ed0d9ea
...
...
@@ -48,7 +48,7 @@ function c4694209.addct2(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if
chkc
then
return
chkc
:
IsOnField
()
and
chkc
:
IsControler
(
tp
)
and
chkc
:
IsFaceup
()
end
if
chk
==
0
then
return
e
:
GetHandler
():
IsCanRemoveCounter
(
tp
,
0x21
,
1
,
REASON_EFFECT
)
and
Duel
.
IsExistingTarget
(
Card
.
IsFaceup
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
e
:
GetHandler
())
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
98162021
,
1
))
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
4694209
,
1
))
Duel
.
SelectTarget
(
tp
,
Card
.
IsFaceup
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
1
,
e
:
GetHandler
())
end
function
c4694209
.
addc2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c47506081.lua
View file @
8ed0d9ea
...
...
@@ -17,10 +17,8 @@ function c47506081.initial_effect(c)
end
function
c47506081
.
damcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
a
=
Duel
.
GetAttacker
()
local
d
=
Duel
.
GetAttackTarget
()
return
not
c
:
IsStatus
(
STATUS_BATTLE_DESTROYED
)
and
((
c
==
a
and
d
:
GetLocation
()
==
LOCATION_GRAVE
)
or
(
c
==
d
and
a
:
GetLocation
()
==
LOCATION_GRAVE
))
local
bc
=
c
:
GetBattleTarget
()
return
c
:
IsRelateToBattle
()
and
bc
:
IsLocation
(
LOCATION_GRAVE
)
and
bc
:
IsType
(
TYPE_MONSTER
)
end
function
c47506081
.
damcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
CheckRemoveOverlayCard
(
tp
,
1
,
REASON_COST
)
end
...
...
script/c48579379.lua
View file @
8ed0d9ea
--究極完全態·グレート·モス
function
c48579379
.
initial_effect
(
c
)
c
:
EnableReviveLimit
()
--cannot special summon
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetCode
(
EFFECT_SPSUMMON_CONDITION
)
c
:
RegisterEffect
(
e1
)
--special summon
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
)
...
...
script/c49681811.lua
View file @
8ed0d9ea
...
...
@@ -56,7 +56,7 @@ function c49681811.condition(e,tp,eg,ep,ev,re,r,rp)
and
Duel
.
GetDrawCount
(
tp
)
>
0
end
function
c49681811
.
filter
(
c
)
return
c
:
GetLevel
()
==
4
and
c
:
IsRace
(
RACE_WARRIOR
)
and
c
:
IsAbleToHand
()
return
c
:
IsLevelBelow
(
4
)
and
c
:
IsRace
(
RACE_WARRIOR
)
and
c
:
IsAbleToHand
()
end
function
c49681811
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c49681811
.
filter
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
end
...
...
script/c49771608.lua
View file @
8ed0d9ea
...
...
@@ -13,21 +13,15 @@ function c49771608.initial_effect(c)
end
function
c49771608
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
a
=
Duel
.
GetAttacker
()
local
d
=
Duel
.
GetAttackTarget
()
return
not
c
:
IsStatus
(
STATUS_BATTLE_DESTROYED
)
and
((
c
==
a
and
d
:
GetLocation
()
==
LOCATION_GRAVE
)
or
(
c
==
d
and
a
:
GetLocation
()
==
LOCATION_GRAVE
))
local
bc
=
c
:
GetBattleTarget
()
return
c
:
IsRelateToBattle
()
and
bc
:
IsLocation
(
LOCATION_GRAVE
)
and
bc
:
IsType
(
TYPE_MONSTER
)
end
function
c49771608
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
local
a
=
Duel
.
GetAttacker
()
local
d
=
Duel
.
GetAttackTarget
()
local
m
=
0
if
a
==
e
:
GetHandler
()
then
m
=
d
:
GetLevel
()
*
300
else
m
=
a
:
GetLevel
()
*
300
end
local
rec
=
e
:
GetHandler
():
GetBattleTarget
():
GetLevel
()
*
300
Duel
.
SetTargetPlayer
(
tp
)
Duel
.
SetTargetParam
(
m
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
m
)
Duel
.
SetTargetParam
(
rec
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
rec
)
end
function
c49771608
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
...
...
script/c54704216.lua
View file @
8ed0d9ea
...
...
@@ -30,6 +30,7 @@ function c54704216.initial_effect(c)
e3
:
SetCondition
(
c54704216
.
descon
)
e3
:
SetOperation
(
c54704216
.
desop
)
c
:
RegisterEffect
(
e3
)
e1
:
SetLabelObject
(
e3
)
end
function
c54704216
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
IsControler
(
1
-
tp
)
end
...
...
@@ -40,14 +41,15 @@ end
function
c54704216
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
tc
=
Duel
.
GetFirstTarget
()
if
c
:
IsRelateToEffect
(
e
)
and
tc
:
Is
Faceup
()
and
tc
:
Is
RelateToEffect
(
e
)
then
if
c
:
IsRelateToEffect
(
e
)
and
tc
:
IsRelateToEffect
(
e
)
then
c
:
SetCardTarget
(
tc
)
c
:
CreateRelation
(
tc
,
RESET_EVENT
+
0x1fe0000
)
e
:
GetLabelObject
():
SetLabelObject
(
tc
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
+
EFFECT_FLAG_OWNER_RELATE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetProperty
(
EFFECT_FLAG_OWNER_RELATE
)
e1
:
SetCode
(
EFFECT_CANNOT_ATTACK
)
e1
:
SetReset
(
RESET_EVENT
+
0x1f
e
0000
)
e1
:
SetReset
(
RESET_EVENT
+
0x1f
c
0000
)
e1
:
SetCondition
(
c54704216
.
rcon
)
tc
:
RegisterEffect
(
e1
,
true
)
local
e2
=
e1
:
Clone
()
...
...
@@ -56,16 +58,16 @@ function c54704216.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c54704216
.
rcon
(
e
)
return
e
:
GetOwner
():
Is
HasCardTarget
(
e
:
GetHandler
())
return
e
:
GetOwner
():
Is
RelateToCard
(
e
:
GetHandler
())
end
function
c54704216
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsStatus
(
STATUS_DESTROY_CONFIRMED
)
then
return
false
end
local
tc
=
c
:
GetFirstCardTarge
t
()
return
tc
and
eg
:
IsContains
(
tc
)
local
tc
=
e
:
GetLabelObjec
t
()
return
tc
and
eg
:
IsContains
(
tc
)
and
c
:
IsRelateToCard
(
tc
)
end
function
c54704216
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_EFFECT
)
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_EFFECT
)
end
function
c54704216
.
damcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
tp
==
Duel
.
GetTurnPlayer
()
...
...
script/c55171412.lua
View file @
8ed0d9ea
...
...
@@ -42,7 +42,6 @@ function c55171412.initial_effect(c)
e5
:
SetDescription
(
aux
.
Stringid
(
55171412
,
1
))
e5
:
SetCategory
(
CATEGORY_DESTROY
)
e5
:
SetType
(
EFFECT_TYPE_IGNITION
)
e5
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e5
:
SetRange
(
LOCATION_MZONE
)
e5
:
SetCountLimit
(
1
)
e5
:
SetCost
(
c55171412
.
descost
)
...
...
script/c5861892.lua
View file @
8ed0d9ea
...
...
@@ -52,7 +52,7 @@ end
function
c5861892
.
arcanareg
(
c
,
coin
)
--coin effect
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
34568403
,
1
))
e1
:
SetDescription
(
aux
.
Stringid
(
5861892
,
1
))
e1
:
SetCategory
(
CATEGORY_TOHAND
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
...
...
@@ -64,7 +64,7 @@ function c5861892.arcanareg(c,coin)
c
:
RegisterEffect
(
e1
)
--
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
34568403
,
2
))
e2
:
SetDescription
(
aux
.
Stringid
(
5861892
,
2
))
e2
:
SetCategory
(
CATEGORY_NEGATE
+
CATEGORY_DESTROY
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_QUICK_F
)
e2
:
SetCode
(
EVENT_CHAINING
)
...
...
script/c61777313.lua
View file @
8ed0d9ea
...
...
@@ -44,7 +44,7 @@ function c61777313.cfilter(c,lv)
return
c
:
IsSetCard
(
0x42
)
and
clv
>
0
and
clv
~=
lv
and
c
:
IsAbleToGraveAsCost
()
end
function
c61777313
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c61777313
.
cfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c61777313
.
cfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
,
e
:
GetHandler
():
GetLevel
()
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TOGRAVE
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c61777313
.
cfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
,
e
:
GetHandler
():
GetLevel
())
Duel
.
SendtoGrave
(
g
,
REASON_COST
)
...
...
script/c62878208.lua
View file @
8ed0d9ea
...
...
@@ -24,9 +24,10 @@ end
function
c62878208
.
eqtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
false
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c62878208
.
filter1
,
tp
,
LOCATION_SZONE
,
0
,
1
,
nil
,
e
,
tp
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
75886890
,
2
))
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
62878208
,
2
))
local
g1
=
Duel
.
SelectTarget
(
tp
,
c62878208
.
filter1
,
tp
,
LOCATION_SZONE
,
0
,
1
,
1
,
nil
,
e
,
tp
)
e
:
SetLabelObject
(
g1
:
GetFirst
())
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUPATTACK
)
local
g2
=
Duel
.
SelectTarget
(
tp
,
c62878208
.
filter2
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
,
g1
:
GetFirst
())
Duel
.
SetOperationInfo
(
0
,
CATEGORY_EQUIP
,
g1
,
1
,
0
,
0
)
end
...
...
script/c67959180.lua
View file @
8ed0d9ea
...
...
@@ -26,9 +26,9 @@ function c67959180.operation(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetProperty
(
EFFECT_FLAG_COPY_INHERIT
)
e1
:
SetReset
(
RESET_EVENT
+
0x1ff0000
)
if
opt
==
coin
then
e1
:
SetValue
(
c
:
GetAttack
()
/
2
)
e1
:
SetValue
(
c
:
Get
Base
Attack
()
/
2
)
else
e1
:
SetValue
(
c
:
GetAttack
()
*
2
)
e1
:
SetValue
(
c
:
Get
Base
Attack
()
*
2
)
end
c
:
RegisterEffect
(
e1
)
end
...
...
script/c68722455.lua
View file @
8ed0d9ea
...
...
@@ -18,9 +18,9 @@ end
function
c68722455
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c68722455
.
costfilter
,
tp
,
LOCATION_HAND
,
0
,
1
,
e
:
GetHandler
())
end
local
rt
=
Duel
.
GetTargetCount
(
Card
.
IsAbleToHand
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
DISCARD
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
TOGRAVE
)
local
cg
=
Duel
.
SelectMatchingCard
(
tp
,
c68722455
.
costfilter
,
tp
,
LOCATION_HAND
,
0
,
1
,
rt
,
nil
)
Duel
.
SendtoGrave
(
cg
,
REASON_COST
+
REASON_DISCARD
)
Duel
.
SendtoGrave
(
cg
,
REASON_COST
)
e
:
SetLabel
(
cg
:
GetCount
())
end
function
c68722455
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
...
...
script/c69537999.lua
View file @
8ed0d9ea
...
...
@@ -22,9 +22,8 @@ function c69537999.descost(e,tp,eg,ep,ev,re,r,rp,chk)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_CANNOT_ATTACK_ANNOUNCE
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
+
EFFECT_FLAG_OATH
)
e1
:
SetTargetRange
(
1
,
0
)
e1
:
SetProperty
(
EFFECT_FLAG_OATH
)
e1
:
SetReset
(
RESET_PHASE
+
RESET_END
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
...
...
script/c71395725.lua
View file @
8ed0d9ea
...
...
@@ -21,7 +21,7 @@ end
function
c71395725
.
chop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
Duel
.
GetCurrentChain
()
==
1
then
e
:
SetLabel
(
0
)
else
if
re
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
)
then
else
e
:
SetLabel
(
1
)
end
end
...
...
script/c7165085.lua
View file @
8ed0d9ea
...
...
@@ -20,8 +20,15 @@ function c7165085.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel
.
SelectTarget
(
tp
,
c7165085
.
filter
,
tp
,
LOCATION_SZONE
,
LOCATION_SZONE
,
1
,
1
,
e
:
GetHandler
())
end
function
c7165085
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
tc
=
Duel
.
GetFirstTarget
()
if
not
tc
:
IsRelateToEffect
(
e
)
or
tc
:
IsFaceup
()
then
return
end
if
not
tc
:
IsRelateToEffect
(
e
)
or
tc
:
IsFaceup
()
then
if
c
:
IsRelateToEffect
(
e
)
then
c
:
CancelToGrave
()
Duel
.
SendtoDeck
(
c
,
nil
,
2
,
REASON_EFFECT
)
end
return
end
Duel
.
ConfirmCards
(
tp
,
tc
)
if
tc
:
IsType
(
TYPE_TRAP
)
then
local
te
=
tc
:
GetActivateEffect
()
...
...
@@ -65,7 +72,6 @@ function c7165085.activate(e,tp,eg,ep,ev,re,r,rp)
end
end
end
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
then
c
:
CancelToGrave
()
Duel
.
SendtoDeck
(
c
,
nil
,
2
,
REASON_EFFECT
)
...
...
script/c74117290.lua
View file @
8ed0d9ea
...
...
@@ -2,7 +2,7 @@
function
c74117290
.
initial_effect
(
c
)
--Activate
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetCategory
(
CATEGORY_DRAW
)
e1
:
SetCategory
(
CATEGORY_
HANDES
+
CATEGORY_
DRAW
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetTarget
(
c74117290
.
target
)
...
...
script/c74923978.lua
View file @
8ed0d9ea
...
...
@@ -26,10 +26,12 @@ function c74923978.condition(e,tp,eg,ep,ev,re,r,rp)
end
function
c74923978
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
IsRelateToEffect
(
e
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
nil
,
0
,
1
-
tp
,
eg
:
GetCount
())
local
ct
=
eg
:
FilterCount
(
c74923978
.
cfilter
,
nil
,
tp
)
e
:
SetLabel
(
ct
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_HANDES
,
nil
,
0
,
1
-
tp
,
ct
)
end
function
c74923978
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
not
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
return
end
local
ct
=
e
g
:
GetCount
()
local
ct
=
e
:
GetLabel
()
Duel
.
DiscardHand
(
1
-
tp
,
nil
,
ct
,
ct
,
REASON_EFFECT
+
REASON_DISCARD
)
end
script/c75524092.lua
View file @
8ed0d9ea
...
...
@@ -54,13 +54,12 @@ function c75524092.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
e
:
GetHandler
():
GetEquipTarget
():
IsReason
(
REASON_BATTLE
)
end
return
true
end
function
c75524092
.
desfilter
(
c
)
return
c
~=
Duel
.
GetAttacker
()
and
c
~=
Duel
.
GetAttackTarget
()
and
c
:
IsDestructable
()
end
function
c75524092
.
desrepop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
SendtoHand
(
e
:
GetHandler
(),
nil
,
REASON_EFFECT
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c75524092
.
desfilter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
exc
=
Duel
.
GetAttacker
()
if
exc
:
IsControler
(
tp
)
then
exc
=
Duel
.
GetAttackTarget
()
end
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
Card
.
IsDestructable
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
exc
)
if
Duel
.
Destroy
(
g
,
REASON_EFFECT
)
>
0
and
Duel
.
Damage
(
1
-
tp
,
600
,
REASON_EFFECT
)
~=
0
then
if
Duel
.
GetLocationCount
(
1
-
tp
,
LOCATION_MZONE
,
tp
)
>
0
and
Duel
.
IsPlayerCanSpecialSummonMonster
(
tp
,
75524093
,
0
,
0x4011
,
2500
,
2500
,
7
,
RACE_FIEND
,
ATTRIBUTE_DARK
,
POS_FACEUP
,
1
-
tp
)
then
...
...
script/c76224717.lua
View file @
8ed0d9ea
...
...
@@ -13,6 +13,7 @@ function c76224717.initial_effect(c)
e2
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e2
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetCountLimit
(
1
)
e2
:
SetCondition
(
c76224717
.
condition
)
e2
:
SetCost
(
c76224717
.
cost
)
e2
:
SetTarget
(
c76224717
.
target1
)
...
...
@@ -27,6 +28,7 @@ function c76224717.initial_effect(c)
e3
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e3
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e3
:
SetRange
(
LOCATION_SZONE
)
e3
:
SetCountLimit
(
1
)
e3
:
SetCondition
(
c76224717
.
condition
)
e3
:
SetCost
(
c76224717
.
cost
)
e3
:
SetTarget
(
c76224717
.
target2
)
...
...
@@ -41,6 +43,7 @@ function c76224717.initial_effect(c)
e4
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e4
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e4
:
SetRange
(
LOCATION_SZONE
)
e4
:
SetCountLimit
(
1
)
e4
:
SetCondition
(
c76224717
.
condition
)
e4
:
SetCost
(
c76224717
.
cost
)
e4
:
SetTarget
(
c76224717
.
target3
)
...
...
@@ -78,13 +81,12 @@ function c76224717.clear(e,tp,eg,ep,ev,re,r,rp)
c76224717
[
0
]
=
0
c76224717
[
1
]
=
0
end
function
c76224717
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c76224717
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
c76224717
[
tp
]
>=
e
:
GetLabel
()
end
function
c76224717
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetFlagEffect
(
tp
,
76224717
)
==
0
end
if
chk
==
0
then
return
true
end
Duel
.
Hint
(
HINT_OPSELECTED
,
1
-
tp
,
e
:
GetDescription
())
Duel
.
RegisterFlagEffect
(
tp
,
76224717
,
RESET_PHASE
+
PHASE_END
,
EFFECT_FLAG_OATH
,
1
)
end
function
c76224717
.
filter1
(
c
)
return
c
:
IsFacedown
()
and
c
:
IsDestructable
()
...
...
script/c76895648.lua
View file @
8ed0d9ea
...
...
@@ -39,7 +39,7 @@ function c76895648.operation(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Draw
(
1
-
tp
,
1
,
REASON_EFFECT
)
elseif
dice
==
5
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
Card
.
IsDestructable
,
tp
,
0
,
LOCATION_
ONFIELD
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
Card
.
IsDestructable
,
tp
,
0
,
LOCATION_
MZONE
,
1
,
1
,
nil
)
Duel
.
Destroy
(
g
,
REASON_EFFECT
)
else
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_EFFECT
)
...
...
script/c77910045.lua
View file @
8ed0d9ea
...
...
@@ -14,13 +14,15 @@ function c77910045.initial_effect(c)
c
:
RegisterEffect
(
e2
)
end
function
c77910045
.
filter
(
c
,
tp
)
return
c
:
IsPreviousLocation
(
LOCATION_MZONE
)
and
c
:
GetControler
()
==
tp
and
c
:
IsType
(
TYPE_MONSTER
)
return
c
:
IsPreviousLocation
(
LOCATION_MZONE
)
and
c
:
IsControler
(
tp
)
and
c
:
IsType
(
TYPE_MONSTER
)
end
function
c77910045
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
eg
:
IsExists
(
c77910045
.
filter
,
1
,
nil
,
tp
)
then
Duel
.
Damage
(
tp
,
500
,
REASON_EFFECT
)
local
ct
=
eg
:
FilterCount
(
c77910045
.
filter
,
nil
,
tp
)
if
ct
>
0
then
Duel
.
Damage
(
tp
,
500
*
ct
,
REASON_EFFECT
)
end
if
eg
:
IsExists
(
c77910045
.
filter
,
1
,
nil
,
1
-
tp
)
then
Duel
.
Damage
(
1
-
tp
,
500
,
REASON_EFFECT
)
ct
=
eg
:
FilterCount
(
c77910045
.
filter
,
nil
,
1
-
tp
)
if
ct
>
0
then
Duel
.
Damage
(
1
-
tp
,
500
*
ct
,
REASON_EFFECT
)
end
end
script/c78663366.lua
View file @
8ed0d9ea
...
...
@@ -22,13 +22,22 @@ function c78663366.operation(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_STANDBY
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_STANDBY
)
if
Duel
.
GetCurrentPhase
()
==
PHASE_STANDBY
then
e1
:
SetLabel
(
Duel
.
GetTurnCount
())
e1
:
SetCondition
(
c78663366
.
retcon
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_STANDBY
,
2
)
else
e1
:
SetReset
(
RESET_PHASE
+
PHASE_STANDBY
)
end
e1
:
SetLabelObject
(
c
)
e1
:
SetCountLimit
(
1
)
e1
:
SetOperation
(
c78663366
.
retop
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
end
function
c78663366
.
retcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetTurnCount
()
~=
e
:
GetLabel
()
end
function
c78663366
.
retop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
e
:
GetLabelObject
()
if
Duel
.
ReturnToField
(
tc
)
and
tc
:
IsFaceup
()
then
...
...
script/c79229522.lua
View file @
8ed0d9ea
...
...
@@ -44,9 +44,9 @@ function c79229522.sprcon(e,c)
and
Duel
.
IsExistingMatchingCard
(
c79229522
.
spfilter1
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
1
,
nil
,
tp
)
end
function
c79229522
.
sprop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
792
05581
,
0
))
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
792
29522
,
0
))
local
g1
=
Duel
.
SelectMatchingCard
(
tp
,
c79229522
.
spfilter1
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
1
,
1
,
nil
,
tp
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
792
05581
,
1
))
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
792
29522
,
1
))
local
g2
=
Duel
.
SelectMatchingCard
(
tp
,
c79229522
.
spfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
10
,
g1
:
GetFirst
(),
tp
)
g1
:
Merge
(
g2
)
Duel
.
SendtoGrave
(
g1
,
REASON_COST
)
...
...
script/c80513550.lua
View file @
8ed0d9ea
...
...
@@ -15,6 +15,7 @@ function c80513550.initial_effect(c)
e2
:
SetCategory
(
CATEGORY_HANDES
+
CATEGORY_DRAW
)
e2
:
SetCode
(
EVENT_BATTLE_DAMAGE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e2
:
SetCondition
(
c80513550
.
hdcon
)
e2
:
SetTarget
(
c80513550
.
hdtg
)
e2
:
SetOperation
(
c80513550
.
hdop
)
c
:
RegisterEffect
(
e2
)
...
...
@@ -39,9 +40,12 @@ function c80513550.hspcon(e,c)
return
Duel
.
GetLocationCount
(
c
:
GetControler
(),
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
c80513550
.
hspfilter
,
c
:
GetControler
(),
LOCATION_SZONE
,
0
,
3
,
nil
)
end
function
c80513550
.
hdcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
end
function
c80513550
.
hdtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_
TOGRAVE
,
nil
,
0
,
1
-
tp
,
1
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_
HANDES
,
nil
,
0
,
1
-
tp
,
1
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DRAW
,
nil
,
0
,
tp
,
1
)
end
function
c80513550
.
hdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c80885324.lua
View file @
8ed0d9ea
...
...
@@ -4,7 +4,7 @@ function c80885324.initial_effect(c)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
80885324
,
0
))
e1
:
SetCategory
(
CATEGORY_DESTROY
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_
F
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_
O
)
e1
:
SetCode
(
EVENT_BATTLE_START
)
e1
:
SetCondition
(
c80885324
.
descon
)
e1
:
SetTarget
(
c80885324
.
destg
)
...
...
script/c84080938.lua
View file @
8ed0d9ea
...
...
@@ -16,13 +16,13 @@ function c84080938.cost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel
.
Release
(
e
:
GetHandler
(),
REASON_COST
)
end
function
c84080938
.
filter
(
c
,
tid
)
return
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
GetTurnID
()
==
tid
and
c
:
IsReason
(
REASON_BATTLE
)
and
c
:
IsAbleTo
Deck
()
return
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
GetTurnID
()
==
tid
and
c
:
IsReason
(
REASON_BATTLE
)
and
c
:
IsAbleTo
Hand
()
end
function
c84080938
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
local
tid
=
Duel
.
GetTurnCount
()
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_GRAVE
)
and
chkc
:
IsControler
(
tp
)
and
c84080938
.
filter
(
chkc
,
tid
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c84080938
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
,
tid
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
TODECK
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
RTOHAND
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c84080938
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
,
tid
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
g
,
1
,
0
,
0
)
end
...
...
script/c84080939.lua
View file @
8ed0d9ea
...
...
@@ -16,13 +16,13 @@ function c84080939.cost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel
.
Release
(
e
:
GetHandler
(),
REASON_COST
)
end
function
c84080939
.
filter
(
c
,
tid
)
return
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
GetTurnID
()
==
tid
and
c
:
IsReason
(
REASON_BATTLE
)
and
c
:
IsAbleTo
Deck
()
return
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
GetTurnID
()
==
tid
and
c
:
IsReason
(
REASON_BATTLE
)
and
c
:
IsAbleTo
Hand
()
end
function
c84080939
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
local
tid
=
Duel
.
GetTurnCount
()
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_GRAVE
)
and
chkc
:
IsControler
(
tp
)
and
c84080939
.
filter
(
chkc
,
tid
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c84080939
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
,
tid
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
TODECK
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_
RTOHAND
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c84080939
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
,
tid
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
g
,
1
,
0
,
0
)
end
...
...
script/c8487449.lua
View file @
8ed0d9ea
...
...
@@ -51,9 +51,8 @@ function c8487449.regop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
8487449
,
0
))
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
+
EFFECT_FLAG_REPEAT
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetProperty
(
EFFECT_FLAG_REPEAT
)
e1
:
SetCountLimit
(
1
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCondition
(
c8487449
.
thcon
)
...
...
script/c86170989.lua
View file @
8ed0d9ea
...
...
@@ -16,10 +16,8 @@ function c86170989.filter2(c,e,tp)
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
function
c86170989
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chk
==
0
then
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_GRAVE
)
and
chkc
:
IsControler
(
tp
)
and
c86170989
.
filter2
(
chkc
,
e
,
tp
)
end
return
e
:
GetHandler
():
IsRelateToBattle
()
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_GRAVE
)
and
chkc
:
IsControler
(
tp
)
and
c86170989
.
filter2
(
chkc
,
e
,
tp
)
end
if
chk
==
0
then
return
true
end
local
op
=
0
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
86170989
,
0
))
local
t1
=
Duel
.
IsExistingMatchingCard
(
c86170989
.
filter1
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
...
...
script/c95096437.lua
View file @
8ed0d9ea
...
...
@@ -42,7 +42,7 @@ end
function
c95096437
.
hdtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
Duel
.
SetTargetPlayer
(
tp
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_
TOGRAVE
,
nil
,
1
,
1
-
tp
,
LOCATION_HAND
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_
HANDES
,
nil
,
0
,
1
-
tp
,
2
)
end
function
c95096437
.
hdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
p
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
)
...
...
script/c95308449.lua
View file @
8ed0d9ea
...
...
@@ -3,7 +3,6 @@ function c95308449.initial_effect(c)
--Activate
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetCategory
(
CATEGORY_REMOVE
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCost
(
c95308449
.
cost
)
...
...
script/c99594764.lua
View file @
8ed0d9ea
...
...
@@ -16,7 +16,7 @@ function c99594764.thcon(e,tp,eg,ep,ev,re,r,rp)
return
eg
:
GetCount
()
==
1
and
eg
:
GetFirst
()
==
e
:
GetHandler
():
GetEquipTarget
()
end
function
c99594764
.
filter
(
c
,
race
,
att
)
return
c
:
IsRace
(
race
)
and
c
:
IsAttribute
(
att
)
and
c
:
GetLevel
()
<=
4
return
c
:
IsRace
(
race
)
and
c
:
IsAttribute
(
att
)
and
c
:
GetLevel
()
<=
4
and
c
:
IsAbleToHand
()
end
function
c99594764
.
thtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
eqc
=
e
:
GetHandler
():
GetEquipTarget
()
...
...
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