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
035ce707
Commit
035ce707
authored
Sep 01, 2017
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
updig
parent
15c84ead
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
409 additions
and
2 deletions
+409
-2
.gitignore
.gitignore
+1
-0
expansions/script/c100220001.lua
expansions/script/c100220001.lua
+38
-0
expansions/script/c100230009.lua
expansions/script/c100230009.lua
+71
-0
expansions/script/c100230010.lua
expansions/script/c100230010.lua
+48
-0
expansions/script/c100305025.lua
expansions/script/c100305025.lua
+1
-0
expansions/script/c101003027.lua
expansions/script/c101003027.lua
+2
-2
expansions/script/c101003032.lua
expansions/script/c101003032.lua
+74
-0
expansions/script/c101003074.lua
expansions/script/c101003074.lua
+89
-0
expansions/script/c15327215.lua
expansions/script/c15327215.lua
+85
-0
No files found.
.gitignore
View file @
035ce707
...
@@ -4,6 +4,7 @@
...
@@ -4,6 +4,7 @@
/build
/build
/event
/event
/lua
/lua
/script
/sqlite3
/sqlite3
/replay
/replay
/deck
/deck
...
...
expansions/script/c100220001.lua
0 → 100644
View file @
035ce707
--コード・トーカー
--Code Talker
--Scripted by Eerie Code
function
c100220001
.
initial_effect
(
c
)
--link summon
aux
.
AddLinkProcedure
(
c
,
aux
.
FilterBoolFunction
(
Card
.
IsLinkType
,
TYPE_EFFECT
),
2
,
2
)
c
:
EnableReviveLimit
()
--atk
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetValue
(
c100220001
.
atkval
)
c
:
RegisterEffect
(
e1
)
--indes
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCode
(
EFFECT_INDESTRUCTABLE_BATTLE
)
e2
:
SetCondition
(
c100220001
.
incon
)
e2
:
SetValue
(
1
)
c
:
RegisterEffect
(
e2
)
local
e3
=
e2
:
Clone
()
e3
:
SetCode
(
EFFECT_INDESTRUCTABLE_EFFECT
)
e3
:
SetValue
(
c100220001
.
inval
)
c
:
RegisterEffect
(
e3
)
end
function
c100220001
.
atkval
(
e
,
c
)
return
c
:
GetLinkedGroupCount
()
*
500
end
function
c100220001
.
incon
(
e
)
return
e
:
GetHandler
():
GetLinkedGroupCount
()
>
0
end
function
c100220001
.
inval
(
e
,
re
,
r
,
rp
)
return
rp
~=
e
:
GetHandlerPlayer
()
end
expansions/script/c100230009.lua
0 → 100644
View file @
035ce707
--武力の軍奏
--Tin Musical Battlemech
--Script by nekrozar
function
c100230009
.
initial_effect
(
c
)
--synchro summon
aux
.
AddSynchroProcedure
(
c
,
nil
,
aux
.
NonTuner
(
nil
),
1
)
c
:
EnableReviveLimit
()
--special summon
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
100230009
,
0
))
e1
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
+
EFFECT_FLAG_DELAY
)
e1
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e1
:
SetCountLimit
(
1
,
100230009
)
e1
:
SetCondition
(
c100230009
.
spcon
)
e1
:
SetTarget
(
c100230009
.
sptg
)
e1
:
SetOperation
(
c100230009
.
spop
)
c
:
RegisterEffect
(
e1
)
--add tuner
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e2
:
SetCode
(
EVENT_BE_MATERIAL
)
e2
:
SetCondition
(
c100230009
.
tncon
)
e2
:
SetOperation
(
c100230009
.
tnop
)
c
:
RegisterEffect
(
e2
)
end
function
c100230009
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
end
function
c100230009
.
spfilter
(
c
,
e
,
tp
)
return
c
:
IsType
(
TYPE_TUNER
)
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
,
POS_FACEUP_DEFENSE
)
end
function
c100230009
.
sptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_GRAVE
)
and
chkc
:
IsControler
(
tp
)
and
c100230009
.
spfilter
(
chkc
,
e
,
tp
)
end
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingTarget
(
c100230009
.
spfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
,
e
,
tp
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c100230009
.
spfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
,
e
,
tp
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
g
,
1
,
0
,
0
)
end
function
c100230009
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
Duel
.
SpecialSummonStep
(
tc
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP_DEFENSE
)
then
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_DISABLE
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_DISABLE_EFFECT
)
e2
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
tc
:
RegisterEffect
(
e2
)
end
Duel
.
SpecialSummonComplete
()
end
function
c100230009
.
tncon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
r
==
REASON_SYNCHRO
end
function
c100230009
.
tnop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
rc
=
c
:
GetReasonCard
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_ADD_TYPE
)
e1
:
SetValue
(
TYPE_TUNER
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
)
rc
:
RegisterEffect
(
e1
)
end
expansions/script/c100230010.lua
0 → 100644
View file @
035ce707
--キキナガシ風鳥
--Disdainful Bird of Paradise
--Script by nekrozar
function
c100230010
.
initial_effect
(
c
)
--xyz summon
aux
.
AddXyzProcedure
(
c
,
nil
,
1
,
2
)
c
:
EnableReviveLimit
()
--immune
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_IMMUNE_EFFECT
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetValue
(
c100230010
.
efilter
)
c
:
RegisterEffect
(
e1
)
--indes
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
100230010
,
0
))
e2
:
SetType
(
EFFECT_TYPE_QUICK_O
)
e2
:
SetCode
(
EVENT_FREE_CHAIN
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCountLimit
(
1
)
e2
:
SetCost
(
c100230010
.
indcost
)
e2
:
SetOperation
(
c100230010
.
indop
)
c
:
RegisterEffect
(
e2
)
end
function
c100230010
.
efilter
(
e
,
te
)
return
te
:
GetOwner
()
~=
e
:
GetOwner
()
end
function
c100230010
.
indcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
CheckRemoveOverlayCard
(
tp
,
2
,
REASON_COST
)
end
e
:
GetHandler
():
RemoveOverlayCard
(
tp
,
2
,
2
,
REASON_COST
)
end
function
c100230010
.
indop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
then
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetCode
(
EFFECT_INDESTRUCTABLE_BATTLE
)
e1
:
SetValue
(
1
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_AVOID_BATTLE_DAMAGE
)
c
:
RegisterEffect
(
e2
)
end
end
expansions/script/c100305025.lua
View file @
035ce707
...
@@ -69,6 +69,7 @@ function c100305025.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -69,6 +69,7 @@ function c100305025.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TODECK
,
tg
,
tg
:
GetCount
(),
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TODECK
,
tg
,
tg
:
GetCount
(),
0
,
0
)
end
end
function
c100305025
.
tdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c100305025
.
tdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
not
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
return
end
local
tg
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_CARDS
):
Filter
(
Card
.
IsRelateToEffect
,
nil
,
e
)
local
tg
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_CARDS
):
Filter
(
Card
.
IsRelateToEffect
,
nil
,
e
)
if
tg
:
GetCount
()
==
0
then
return
end
if
tg
:
GetCount
()
==
0
then
return
end
local
ct
=
Duel
.
SendtoDeck
(
tg
,
nil
,
0
,
REASON_EFFECT
)
local
ct
=
Duel
.
SendtoDeck
(
tg
,
nil
,
0
,
REASON_EFFECT
)
...
...
expansions/script/c101003027.lua
View file @
035ce707
...
@@ -80,7 +80,7 @@ function c101003027.thop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -80,7 +80,7 @@ function c101003027.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c101003027
.
acop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c101003027
.
acop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
re
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
)
and
re
:
IsActiveType
(
TYPE_SPELL
)
and
e
:
GetHandler
():
GetFlagEffect
(
1
)
>
0
then
if
re
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
)
and
re
:
IsActiveType
(
TYPE_SPELL
)
and
e
:
GetHandler
():
GetFlagEffect
(
1
)
>
0
then
e
:
GetHandler
():
AddCounter
(
0x1
,
1
)
e
:
GetHandler
():
AddCounter
(
0x1
,
2
)
end
end
end
end
function
c101003027
.
incon
(
e
)
function
c101003027
.
incon
(
e
)
...
@@ -110,7 +110,7 @@ function c101003027.rmop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -110,7 +110,7 @@ function c101003027.rmop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetValue
(
atk
)
e1
:
SetValue
(
atk
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
+
RESET_OPPO_TURN
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
end
end
expansions/script/c101003032.lua
0 → 100644
View file @
035ce707
--魅幽鳥
--Mikuratori
--Script by nekrozar
function
c101003032
.
initial_effect
(
c
)
--atkup
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCondition
(
c101003032
.
atkcon
)
e1
:
SetValue
(
1000
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_UPDATE_DEFENSE
)
c
:
RegisterEffect
(
e2
)
--extra attack
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e3
:
SetCode
(
EFFECT_EXTRA_ATTACK_MONSTER
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCondition
(
c101003032
.
eacon
)
e3
:
SetValue
(
1
)
c
:
RegisterEffect
(
e3
)
--cannot target
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetCode
(
EFFECT_CANNOT_BE_EFFECT_TARGET
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCondition
(
c101003032
.
indcon
)
e4
:
SetValue
(
aux
.
tgoval
)
c
:
RegisterEffect
(
e4
)
--indes
local
e5
=
Effect
.
CreateEffect
(
c
)
e5
:
SetType
(
EFFECT_TYPE_SINGLE
)
e5
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e5
:
SetCode
(
EFFECT_INDESTRUCTABLE_EFFECT
)
e5
:
SetRange
(
LOCATION_MZONE
)
e5
:
SetCondition
(
c101003032
.
indcon
)
e5
:
SetValue
(
c101003032
.
indval
)
c
:
RegisterEffect
(
e5
)
--cannot activate
local
e6
=
Effect
.
CreateEffect
(
c
)
e6
:
SetType
(
EFFECT_TYPE_FIELD
)
e6
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e6
:
SetCode
(
EFFECT_CANNOT_ACTIVATE
)
e6
:
SetRange
(
LOCATION_MZONE
)
e6
:
SetTargetRange
(
1
,
1
)
e6
:
SetCondition
(
c101003032
.
actcon
)
e6
:
SetValue
(
c101003032
.
aclimit
)
c
:
RegisterEffect
(
e6
)
end
function
c101003032
.
atkcon
(
e
)
return
e
:
GetHandler
():
GetSequence
()
==
0
end
function
c101003032
.
eacon
(
e
)
return
e
:
GetHandler
():
GetSequence
()
==
4
end
function
c101003032
.
indcon
(
e
)
return
e
:
GetHandler
():
GetSequence
()
==
2
end
function
c101003032
.
indval
(
e
,
re
,
tp
)
return
tp
~=
e
:
GetHandlerPlayer
()
end
function
c101003032
.
actcon
(
e
)
local
c
=
e
:
GetHandler
()
return
c
:
GetSequence
()
==
1
or
c
:
GetSequence
()
==
3
end
function
c101003032
.
aclimit
(
e
,
re
,
tp
)
local
tc
=
re
:
GetHandler
()
return
tc
:
IsLocation
(
LOCATION_MZONE
)
and
re
:
IsActiveType
(
TYPE_MONSTER
)
and
e
:
GetHandler
():
GetColumnGroup
():
IsContains
(
tc
)
and
not
tc
:
IsImmuneToEffect
(
e
)
end
expansions/script/c101003074.lua
0 → 100644
View file @
035ce707
--ゴーストリック・リフォーム
--Ghostrick Reform
--Script by nekrozar
function
c101003074
.
initial_effect
(
c
)
--Activate
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetCategory
(
CATEGORY_TOHAND
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetTarget
(
c101003074
.
target
)
e1
:
SetOperation
(
c101003074
.
activate
)
c
:
RegisterEffect
(
e1
)
--special summon
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
101003074
,
0
))
e2
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e2
:
SetType
(
EFFECT_TYPE_QUICK_O
)
e2
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e2
:
SetCode
(
EVENT_FREE_CHAIN
)
e2
:
SetRange
(
LOCATION_GRAVE
)
e2
:
SetCountLimit
(
1
,
101003074
)
e2
:
SetCost
(
aux
.
bfgcost
)
e2
:
SetTarget
(
c101003074
.
sptg
)
e2
:
SetOperation
(
c101003074
.
spop
)
c
:
RegisterEffect
(
e2
)
end
function
c101003074
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
local
tc
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_SZONE
,
5
)
if
chkc
then
return
false
end
if
chk
==
0
then
return
tc
and
tc
:
IsFaceup
()
and
tc
:
IsSetCard
(
0x8d
)
and
tc
:
IsAbleToHand
()
and
tc
:
IsCanBeEffectTarget
(
e
)
end
Duel
.
SetTargetCard
(
tc
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
tc
,
1
,
0
,
0
)
end
function
c101003074
.
actfilter
(
c
,
tp
)
return
c
:
IsType
(
TYPE_FIELD
)
and
c
:
GetActivateEffect
():
IsActivatable
(
tp
)
end
function
c101003074
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
Duel
.
SendtoHand
(
tc
,
nil
,
REASON_EFFECT
)
~=
0
and
tc
:
IsLocation
(
LOCATION_HAND
)
then
local
g
=
Duel
.
GetMatchingGroup
(
c101003074
.
actfilter
,
tp
,
LOCATION_HAND
+
LOCATION_DECK
,
0
,
nil
,
tp
)
if
g
:
GetCount
()
>
0
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
101003074
,
1
))
then
Duel
.
BreakEffect
()
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TOFIELD
)
local
sg
=
g
:
Select
(
tp
,
1
,
1
,
nil
)
local
sc
=
sg
:
GetFirst
()
Duel
.
MoveToField
(
sc
,
tp
,
tp
,
LOCATION_SZONE
,
POS_FACEUP
,
true
)
local
te
=
sc
:
GetActivateEffect
()
local
tep
=
sc
:
GetControler
()
local
cost
=
te
:
GetCost
()
if
cost
then
cost
(
te
,
tep
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
1
)
end
Duel
.
RaiseEvent
(
sc
,
4179255
,
te
,
0
,
tp
,
tp
,
Duel
.
GetCurrentChain
())
end
end
end
function
c101003074
.
filter1
(
c
,
e
,
tp
)
return
c
:
IsFaceup
()
and
c
:
IsType
(
TYPE_XYZ
)
and
c
:
IsSetCard
(
0x8d
)
and
Duel
.
IsExistingMatchingCard
(
c101003074
.
filter2
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
nil
,
e
,
tp
,
c
,
c
:
GetCode
())
and
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
c
)
>
0
end
function
c101003074
.
filter2
(
c
,
e
,
tp
,
mc
,
code
)
return
c
:
IsType
(
TYPE_XYZ
)
and
c
:
IsSetCard
(
0x8d
)
and
not
c
:
IsCode
(
code
)
and
mc
:
IsCanBeXyzMaterial
(
c
)
and
c
:
IsCanBeSpecialSummoned
(
e
,
SUMMON_TYPE_XYZ
,
tp
,
false
,
false
)
end
function
c101003074
.
sptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsControler
(
tp
)
and
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
c101003074
.
filter1
(
chkc
,
e
,
tp
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c101003074
.
filter1
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
,
e
,
tp
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TARGET
)
Duel
.
SelectTarget
(
tp
,
c101003074
.
filter1
,
tp
,
LOCATION_MZONE
,
0
,
1
,
1
,
nil
,
e
,
tp
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
nil
,
1
,
tp
,
LOCATION_EXTRA
)
end
function
c101003074
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
if
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
tc
)
<=
0
then
return
end
if
tc
:
IsFacedown
()
or
not
tc
:
IsRelateToEffect
(
e
)
or
tc
:
IsControler
(
1
-
tp
)
or
tc
:
IsImmuneToEffect
(
e
)
then
return
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c101003074
.
filter2
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
1
,
nil
,
e
,
tp
,
tc
,
tc
:
GetCode
())
local
sc
=
g
:
GetFirst
()
if
sc
then
local
mg
=
tc
:
GetOverlayGroup
()
if
mg
:
GetCount
()
~=
0
then
Duel
.
Overlay
(
sc
,
mg
)
end
sc
:
SetMaterial
(
Group
.
FromCards
(
tc
))
Duel
.
Overlay
(
sc
,
Group
.
FromCards
(
tc
))
Duel
.
SpecialSummon
(
sc
,
SUMMON_TYPE_XYZ
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
sc
:
CompleteProcedure
()
end
end
expansions/script/c15327215.lua
0 → 100644
View file @
035ce707
--六武衆の真影
--Legendary Shadow of the Six Samurai
--Script by nekrozar
function
c15327215
.
initial_effect
(
c
)
--special summon
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
15327215
,
0
))
e1
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e1
:
SetRange
(
LOCATION_HAND
)
e1
:
SetCountLimit
(
1
,
15327215
)
e1
:
SetCondition
(
c15327215
.
spcon
)
e1
:
SetTarget
(
c15327215
.
sptg
)
e1
:
SetOperation
(
c15327215
.
spop
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
c
:
RegisterEffect
(
e2
)
--
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetDescription
(
aux
.
Stringid
(
15327215
,
1
))
e3
:
SetType
(
EFFECT_TYPE_IGNITION
)
e3
:
SetCountLimit
(
1
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCost
(
c15327215
.
cost
)
e3
:
SetOperation
(
c15327215
.
operation
)
c
:
RegisterEffect
(
e3
)
end
function
c15327215
.
cfilter
(
c
,
tp
)
return
c
:
IsFaceup
()
and
c
:
GetSummonPlayer
()
==
tp
and
c
:
IsSetCard
(
0x103d
)
end
function
c15327215
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
eg
:
IsExists
(
c15327215
.
cfilter
,
1
,
nil
,
tp
)
end
function
c15327215
.
sptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
e
:
GetHandler
():
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
e
:
GetHandler
(),
1
,
0
,
0
)
end
function
c15327215
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
then
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
end
end
function
c15327215
.
filter
(
c
,
mc
)
return
c
:
IsLevelBelow
(
4
)
and
c
:
IsSetCard
(
0x3d
)
and
c
:
IsAbleToRemoveAsCost
()
and
not
(
c
:
GetLevel
()
==
mc
:
GetLevel
()
and
c
:
IsAttribute
(
mc
:
GetAttribute
())
and
c
:
GetAttack
()
==
mc
:
GetAttack
()
and
c
:
GetDefense
()
==
mc
:
GetDefense
())
end
function
c15327215
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c15327215
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
,
e
:
GetHandler
())
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_REMOVE
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c15327215
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
,
e
:
GetHandler
())
Duel
.
Remove
(
g
,
POS_FACEUP
,
REASON_COST
)
e
:
SetLabelObject
(
g
:
GetFirst
())
end
function
c15327215
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
tc
=
e
:
GetLabelObject
()
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
then
local
lv
=
tc
:
GetLevel
()
local
att
=
tc
:
GetAttribute
()
local
atk
=
tc
:
GetAttack
()
local
def
=
tc
:
GetDefense
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_CHANGE_LEVEL_FINAL
)
e1
:
SetValue
(
lv
)
e1
:
SetReset
(
RESET_EVENT
+
0x1ff0000
+
RESET_PHASE
+
PHASE_END
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_CHANGE_ATTRIBUTE
)
e2
:
SetValue
(
att
)
c
:
RegisterEffect
(
e2
)
local
e3
=
e1
:
Clone
()
e3
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e3
:
SetValue
(
atk
)
c
:
RegisterEffect
(
e3
)
local
e4
=
e1
:
Clone
()
e4
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e4
:
SetValue
(
def
)
c
:
RegisterEffect
(
e4
)
end
end
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