Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-2pick
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
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
MyCard
ygopro-2pick
Commits
86b12c80
Commit
86b12c80
authored
Mar 16, 2013
by
argon.sun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
new
parent
59ad1a85
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
282 additions
and
4 deletions
+282
-4
ocgcore/libcard.cpp
ocgcore/libcard.cpp
+4
-1
script/c26570480.lua
script/c26570480.lua
+80
-0
script/c29267084.lua
script/c29267084.lua
+1
-1
script/c29353756.lua
script/c29353756.lua
+85
-0
script/c30585393.lua
script/c30585393.lua
+27
-0
script/c30608985.lua
script/c30608985.lua
+3
-1
script/c52575195.lua
script/c52575195.lua
+81
-0
script/c98045062.lua
script/c98045062.lua
+1
-1
No files found.
ocgcore/libcard.cpp
View file @
86b12c80
...
@@ -1724,6 +1724,9 @@ int32 scriptlib::card_add_trap_monster_attribute(lua_State *L) {
...
@@ -1724,6 +1724,9 @@ int32 scriptlib::card_add_trap_monster_attribute(lua_State *L) {
int32
level
=
lua_tointeger
(
L
,
5
);
int32
level
=
lua_tointeger
(
L
,
5
);
int32
atk
=
lua_tointeger
(
L
,
6
);
int32
atk
=
lua_tointeger
(
L
,
6
);
int32
def
=
lua_tointeger
(
L
,
7
);
int32
def
=
lua_tointeger
(
L
,
7
);
int32
is_tuner
=
FALSE
;
if
(
lua_gettop
(
L
)
>=
8
)
is_tuner
=
lua_toboolean
(
L
,
8
);
card
*
pcard
=
*
(
card
**
)
lua_touserdata
(
L
,
1
);
card
*
pcard
=
*
(
card
**
)
lua_touserdata
(
L
,
1
);
duel
*
pduel
=
pcard
->
pduel
;
duel
*
pduel
=
pcard
->
pduel
;
//type
//type
...
@@ -1733,7 +1736,7 @@ int32 scriptlib::card_add_trap_monster_attribute(lua_State *L) {
...
@@ -1733,7 +1736,7 @@ int32 scriptlib::card_add_trap_monster_attribute(lua_State *L) {
peffect
->
code
=
EFFECT_ADD_TYPE
;
peffect
->
code
=
EFFECT_ADD_TYPE
;
peffect
->
flag
=
EFFECT_FLAG_CANNOT_DISABLE
;
peffect
->
flag
=
EFFECT_FLAG_CANNOT_DISABLE
;
peffect
->
reset_flag
=
RESET_EVENT
+
0x47e0000
;
peffect
->
reset_flag
=
RESET_EVENT
+
0x47e0000
;
peffect
->
value
=
TYPE_MONSTER
|
TYPE_TRAPMONSTER
|
(
is_effect
?
TYPE_EFFECT
:
TYPE_NORMAL
);
peffect
->
value
=
TYPE_MONSTER
|
TYPE_TRAPMONSTER
|
(
is_effect
?
TYPE_EFFECT
:
TYPE_NORMAL
)
|
(
is_tuner
?
TYPE_TUNER
:
0
)
;
pcard
->
add_effect
(
peffect
);
pcard
->
add_effect
(
peffect
);
//attribute
//attribute
peffect
=
pduel
->
new_effect
();
peffect
=
pduel
->
new_effect
();
...
...
script/c26570480.lua
0 → 100644
View file @
86b12c80
--マドルチェ・ピョコレート
function
c26570480
.
initial_effect
(
c
)
--to deck
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
26570480
,
0
))
e1
:
SetCategory
(
CATEGORY_TODECK
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetCode
(
EVENT_TO_GRAVE
)
e1
:
SetCondition
(
c26570480
.
retcon
)
e1
:
SetTarget
(
c26570480
.
rettg
)
e1
:
SetOperation
(
c26570480
.
retop
)
c
:
RegisterEffect
(
e1
)
--pos
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
26570480
,
1
))
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e2
:
SetCode
(
EVENT_CHANGE_POS
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e2
:
SetCountLimit
(
1
)
e2
:
SetCondition
(
c26570480
.
poscon
)
e2
:
SetTarget
(
c26570480
.
postg
)
e2
:
SetOperation
(
c26570480
.
posop
)
c
:
RegisterEffect
(
e2
)
end
function
c26570480
.
retcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsReason
(
REASON_DESTROY
)
and
e
:
GetHandler
():
GetReasonPlayer
()
~=
tp
and
e
:
GetHandler
():
GetPreviousControler
()
==
tp
end
function
c26570480
.
rettg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TODECK
,
e
:
GetHandler
(),
1
,
0
,
0
)
end
function
c26570480
.
retop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
Duel
.
SendtoDeck
(
e
:
GetHandler
(),
nil
,
2
,
REASON_EFFECT
)
end
end
function
c26570480
.
cfilter
(
c
,
tp
)
local
np
=
c
:
GetPosition
()
local
pp
=
c
:
GetPreviousPosition
()
return
((
np
==
POS_FACEUP_DEFENCE
and
pp
==
POS_FACEUP_ATTACK
)
or
(
pp
==
POS_FACEUP_DEFENCE
and
np
==
POS_FACEUP_ATTACK
))
and
c
:
IsControler
(
tp
)
and
c
:
IsSetCard
(
0x71
)
end
function
c26570480
.
poscon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
eg
:
IsExists
(
c26570480
.
cfilter
,
1
,
nil
,
tp
)
end
function
c26570480
.
filter
(
c
)
return
not
c
:
IsPosition
(
POS_FACEUP_DEFENCE
)
end
function
c26570480
.
postg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
c26570480
.
filter
(
chkc
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c26570480
.
filter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_POSCHANGE
)
Duel
.
SelectTarget
(
tp
,
c26570480
.
filter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
nil
)
end
function
c26570480
.
posop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
not
tc
:
IsPosition
(
POS_FACEUP_DEFENCE
)
then
Duel
.
ChangePosition
(
tc
,
POS_FACEUP_DEFENCE
)
if
not
tc
:
IsSetCard
(
0x71
)
then
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_CANNOT_ATTACK
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_DISABLE
)
e2
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
tc
:
RegisterEffect
(
e2
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetCode
(
EFFECT_DISABLE_EFFECT
)
e3
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
tc
:
RegisterEffect
(
e3
)
end
end
end
script/c29267084.lua
View file @
86b12c80
...
@@ -5,7 +5,7 @@ function c29267084.initial_effect(c)
...
@@ -5,7 +5,7 @@ function c29267084.initial_effect(c)
e1
:
SetCategory
(
CATEGORY_POSITION
)
e1
:
SetCategory
(
CATEGORY_POSITION
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
+
EFFECT_FLAG_DAMAGE_STEP
)
e1
:
SetTarget
(
c29267084
.
target
)
e1
:
SetTarget
(
c29267084
.
target
)
e1
:
SetOperation
(
c29267084
.
operation
)
e1
:
SetOperation
(
c29267084
.
operation
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
...
...
script/c29353756.lua
0 → 100644
View file @
86b12c80
--ZW-荒鷲激神爪
function
c29353756
.
initial_effect
(
c
)
c
:
SetUniqueOnField
(
1
,
0
,
29353756
)
--special summon
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetRange
(
LOCATION_HAND
)
e1
:
SetCondition
(
c29353756
.
spcon
)
c
:
RegisterEffect
(
e1
)
--equip
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
29353756
,
0
))
e2
:
SetType
(
EFFECT_TYPE_IGNITION
)
e2
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e2
:
SetCategory
(
CATEGORY_EQUIP
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCondition
(
c29353756
.
eqcon
)
e2
:
SetTarget
(
c29353756
.
eqtg
)
e2
:
SetOperation
(
c29353756
.
eqop
)
c
:
RegisterEffect
(
e2
)
--negate
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetCode
(
EVENT_CHAIN_SOLVING
)
e3
:
SetRange
(
LOCATION_SZONE
)
e3
:
SetCountLimit
(
1
)
e3
:
SetCondition
(
c29353756
.
negcon
)
e3
:
SetOperation
(
c29353756
.
negop
)
c
:
RegisterEffect
(
e3
)
end
function
c29353756
.
spcon
(
e
,
c
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
return
Duel
.
GetLP
(
tp
)
<=
Duel
.
GetLP
(
1
-
tp
)
-
2000
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
end
function
c29353756
.
eqcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
CheckUniqueOnField
(
tp
)
end
function
c29353756
.
filter
(
c
)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x7f
)
end
function
c29353756
.
eqtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
IsControler
(
tp
)
and
c29353756
.
filter
(
chkc
)
end
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
>
0
and
Duel
.
IsExistingTarget
(
c29353756
.
filter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_EQUIP
)
Duel
.
SelectTarget
(
tp
,
c29353756
.
filter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
1
,
nil
)
end
function
c29353756
.
eqop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
not
c
:
IsRelateToEffect
(
e
)
then
return
end
local
tc
=
Duel
.
GetFirstTarget
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
<=
0
or
tc
:
GetControler
()
~=
tp
or
tc
:
IsFacedown
()
or
not
tc
:
IsRelateToEffect
(
e
)
or
not
c
:
CheckUniqueOnField
(
tp
)
then
Duel
.
SendtoGrave
(
c
,
REASON_EFFECT
)
return
end
Duel
.
Equip
(
tp
,
c
,
tc
,
true
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_EQUIP_LIMIT
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
e1
:
SetValue
(
c29353756
.
eqlimit
)
c
:
RegisterEffect
(
e1
)
--atkup
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_EQUIP
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetValue
(
2000
)
e2
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
c
:
RegisterEffect
(
e2
)
end
function
c29353756
.
eqlimit
(
e
,
c
)
return
c
:
IsSetCard
(
0x7f
)
end
function
c29353756
.
negcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
rp
~=
tp
and
Duel
.
GetChainInfo
(
ev
,
CHAININFO_TRIGGERING_LOCATION
)
==
LOCATION_SZONE
and
re
:
IsActiveType
(
TYPE_TRAP
)
and
Duel
.
IsChainDisablable
(
ev
)
end
function
c29353756
.
negop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
HINT_CARD
,
0
,
29353756
)
Duel
.
NegateEffect
(
ev
)
end
script/c30585393.lua
0 → 100644
View file @
86b12c80
--リボーン・パズル
function
c30585393
.
initial_effect
(
c
)
--Activate
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_DESTROYED
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetTarget
(
c30585393
.
target
)
e1
:
SetOperation
(
c30585393
.
activate
)
c
:
RegisterEffect
(
e1
)
end
function
c30585393
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
tc
=
eg
:
GetFirst
()
if
chk
==
0
then
return
eg
:
GetCount
()
==
1
and
tc
:
GetPreviousControler
()
==
tp
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
tc
:
IsLocation
(
LOCATION_GRAVE
+
LOCATION_REMOVED
)
and
tc
:
IsReason
(
REASON_EFFECT
)
and
tc
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
Duel
.
SetTargetCard
(
tc
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
tc
,
1
,
0
,
0
)
end
function
c30585393
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
then
Duel
.
SpecialSummon
(
tc
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
end
end
script/c30608985.lua
View file @
86b12c80
...
@@ -3,7 +3,6 @@ function c30608985.initial_effect(c)
...
@@ -3,7 +3,6 @@ function c30608985.initial_effect(c)
--flip
--flip
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
30608985
,
0
))
e1
:
SetDescription
(
aux
.
Stringid
(
30608985
,
0
))
e1
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_FLIP
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_FLIP
)
e1
:
SetTarget
(
c30608985
.
target
)
e1
:
SetTarget
(
c30608985
.
target
)
...
@@ -19,9 +18,12 @@ function c30608985.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -19,9 +18,12 @@ function c30608985.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingTarget
(
c30608985
.
spfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
,
e
,
tp
)
and
Duel
.
IsExistingTarget
(
c30608985
.
spfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
,
e
,
tp
)
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
30608985
,
1
))
then
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
30608985
,
1
))
then
e
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c30608985
.
spfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
,
e
,
tp
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c30608985
.
spfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
,
e
,
tp
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
g
,
g
:
GetCount
(),
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
g
,
g
:
GetCount
(),
0
,
0
)
else
e
:
SetCategory
(
0
)
end
end
end
end
function
c30608985
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c30608985
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c52575195.lua
0 → 100644
View file @
86b12c80
--ビビット騎士
function
c52575195
.
initial_effect
(
c
)
--change target
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
52575195
,
0
))
e1
:
SetCategory
(
CATEGORY_REMOVE
+
CATEGORY_SPECIAL_SUMMON
)
e1
:
SetType
(
EFFECT_TYPE_QUICK_O
)
e1
:
SetCode
(
EVENT_CHAINING
)
e1
:
SetRange
(
LOCATION_HAND
)
e1
:
SetCondition
(
c52575195
.
tgcon1
)
e1
:
SetTarget
(
c52575195
.
tgtg
)
e1
:
SetOperation
(
c52575195
.
tgop
)
c
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
52575195
,
0
))
e2
:
SetCategory
(
CATEGORY_REMOVE
+
CATEGORY_SPECIAL_SUMMON
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e2
:
SetCode
(
EVENT_ATTACK_ANNOUNCE
)
e2
:
SetRange
(
LOCATION_HAND
)
e2
:
SetCondition
(
c52575195
.
tgcon2
)
e2
:
SetTarget
(
c52575195
.
tgtg
)
e2
:
SetOperation
(
c52575195
.
tgop
)
c
:
RegisterEffect
(
e2
)
end
function
c52575195
.
tgcon1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
rp
==
tp
or
not
re
:
IsActiveType
(
TYPE_SPELL
+
TYPE_TRAP
)
or
not
re
:
IsHasProperty
(
EFFECT_FLAG_CARD_TARGET
)
then
return
false
end
local
g
=
Duel
.
GetChainInfo
(
ev
,
CHAININFO_TARGET_CARDS
)
if
not
g
or
g
:
GetCount
()
~=
1
then
return
false
end
local
tc
=
g
:
GetFirst
()
e
:
SetLabelObject
(
tc
)
return
tc
:
IsControler
(
tp
)
and
tc
:
IsLocation
(
LOCATION_MZONE
)
and
tc
:
IsFaceup
()
and
tc
:
IsAttribute
(
ATTRIBUTE_LIGHT
)
and
tc
:
IsRace
(
RACE_BEASTWARRIOR
)
end
function
c52575195
.
tgcon2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
tp
==
Duel
.
GetTurnPlayer
()
then
return
false
end
local
tc
=
Duel
.
GetAttackTarget
()
e
:
SetLabelObject
(
tc
)
return
tc
and
tc
:
IsFaceup
()
and
tc
:
IsAttribute
(
ATTRIBUTE_LIGHT
)
and
tc
:
IsRace
(
RACE_BEASTWARRIOR
)
end
function
c52575195
.
tgtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
tc
=
e
:
GetLabelObject
()
if
chk
==
0
then
return
tc
:
IsAbleToRemove
()
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>=
0
and
e
:
GetHandler
():
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
Duel
.
SetTargetCard
(
tc
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_REMOVE
,
tc
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
e
:
GetHandler
(),
1
,
0
,
0
)
end
function
c52575195
.
tgop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsControler
(
tp
)
and
Duel
.
Remove
(
tc
,
tc
:
GetPosition
(),
REASON_EFFECT
+
REASON_TEMPORARY
)
~=
0
then
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_STANDBY
)
e1
:
SetRange
(
LOCATION_REMOVED
)
e1
:
SetCountLimit
(
1
)
if
Duel
.
GetTurnPlayer
()
==
tp
then
if
Duel
.
GetCurrentPhase
()
==
PHASE_DRAW
then
e1
:
SetLabel
(
Duel
.
GetTurnCount
())
else
e1
:
SetLabel
(
Duel
.
GetTurnCount
()
+
2
)
end
else
e1
:
SetLabel
(
Duel
.
GetTurnCount
()
+
1
)
end
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
e1
:
SetCondition
(
c52575195
.
retcon
)
e1
:
SetOperation
(
c52575195
.
retop
)
tc
:
RegisterEffect
(
e1
)
if
c
:
IsRelateToEffect
(
e
)
then
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
end
end
end
function
c52575195
.
retcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetTurnCount
()
==
e
:
GetLabel
()
end
function
c52575195
.
retop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ReturnToField
(
e
:
GetHandler
())
e
:
Reset
()
end
script/c98045062.lua
View file @
86b12c80
...
@@ -6,7 +6,7 @@ function c98045062.initial_effect(c)
...
@@ -6,7 +6,7 @@ function c98045062.initial_effect(c)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetHintTiming
(
TIMING_BATTLE_PHASE
)
e1
:
SetHintTiming
(
TIMING_BATTLE_PHASE
+
TIMING_STANDBY_PHASE
)
e1
:
SetCost
(
c98045062
.
cost
)
e1
:
SetCost
(
c98045062
.
cost
)
e1
:
SetTarget
(
c98045062
.
target
)
e1
:
SetTarget
(
c98045062
.
target
)
e1
:
SetOperation
(
c98045062
.
activate
)
e1
:
SetOperation
(
c98045062
.
activate
)
...
...
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