Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-scripts
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-scripts
Commits
85d164cc
Commit
85d164cc
authored
Feb 01, 2016
by
salix5
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
https://github.com/Fluorohydride/ygopro-scripts/pull/246
parent
af8a4f4c
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
70 additions
and
44 deletions
+70
-44
c3167573.lua
c3167573.lua
+20
-11
c31829185.lua
c31829185.lua
+19
-17
c3758046.lua
c3758046.lua
+9
-4
c56585883.lua
c56585883.lua
+3
-1
c63767246.lua
c63767246.lua
+1
-1
c74845897.lua
c74845897.lua
+9
-4
c95291684.lua
c95291684.lua
+9
-6
No files found.
c3167573.lua
View file @
85d164cc
...
...
@@ -11,6 +11,16 @@ function c3167573.initial_effect(c)
e1
:
SetTarget
(
c3167573
.
sptg
)
e1
:
SetOperation
(
c3167573
.
spop
)
c
:
RegisterEffect
(
e1
)
--destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e2
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCountLimit
(
1
)
e2
:
SetCondition
(
c3167573
.
descon
)
e2
:
SetOperation
(
c3167573
.
desop
)
c
:
RegisterEffect
(
e2
)
e1
:
SetLabelObject
(
e2
)
end
function
c3167573
.
cfilter
(
c
,
tp
)
return
c
:
IsControler
(
1
-
tp
)
and
c
:
IsPreviousLocation
(
LOCATION_DECK
)
and
not
c
:
IsReason
(
REASON_DRAW
)
...
...
@@ -27,21 +37,20 @@ end
function
c3167573
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
~=
0
then
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
+
RESET_SELF_TURN
)
e1
:
SetCountLimit
(
1
)
e1
:
SetCondition
(
c3167573
.
descon
)
e1
:
SetOperation
(
c3167573
.
desop
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e
:
GetLabelObject
()
if
Duel
.
GetTurnPlayer
()
==
tp
then
c
:
RegisterFlagEffect
(
3167573
,
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
+
RESET_SELF_TURN
,
0
,
2
)
e2
:
SetLabel
(
Duel
.
GetTurnCount
()
+
2
)
else
c
:
RegisterFlagEffect
(
3167573
,
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
+
RESET_SELF_TURN
,
0
,
1
)
e2
:
SetLabel
(
Duel
.
GetTurnCount
()
+
1
)
end
end
end
function
c3167573
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetTurnPlayer
()
==
tp
return
e
:
GetHandler
():
GetFlagEffect
(
31829185
)
>
0
and
Duel
.
GetTurnCount
()
==
e
:
GetLabel
()
end
function
c3167573
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
e
:
SetLabel
(
0
)
Duel
.
Destroy
(
e
:
GetHandler
(),
REASON_EFFECT
)
end
c31829185.lua
View file @
85d164cc
...
...
@@ -10,12 +10,24 @@ function c31829185.initial_effect(c)
e1
:
SetCondition
(
c31829185
.
spcon
)
e1
:
SetOperation
(
c31829185
.
spop
)
c
:
RegisterEffect
(
e1
)
--
destroy
--
reg
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e2
:
SetCode
(
EVENT_TO_GRAVE
)
e2
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e2
:
SetOperation
(
c31829185
.
tgop
)
c
:
RegisterEffect
(
e2
)
--equip
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e3
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e3
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e3
:
SetRange
(
LOCATION_GRAVE
)
e3
:
SetCountLimit
(
1
)
e3
:
SetCondition
(
c31829185
.
eqcon
)
e3
:
SetTarget
(
c31829185
.
eqtg
)
e3
:
SetOperation
(
c31829185
.
eqop
)
c
:
RegisterEffect
(
e3
)
end
function
c31829185
.
spfilter
(
c
)
return
c
:
IsRace
(
RACE_FIEND
)
and
c
:
IsAbleToRemoveAsCost
()
...
...
@@ -35,27 +47,17 @@ function c31829185.tgop(e,tp,eg,ep,ev,re,r,rp)
local
c
=
e
:
GetHandler
()
if
c
:
GetPreviousControler
()
==
tp
and
c
:
IsPreviousLocation
(
LOCATION_MZONE
)
and
rp
~=
tp
and
bit
.
band
(
r
,
REASON_DESTROY
)
~=
0
then
--equip action
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e1
:
SetRange
(
LOCATION_GRAVE
)
e1
:
SetCountLimit
(
1
)
e1
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetTarget
(
c31829185
.
eqtg
)
e1
:
SetOperation
(
c31829185
.
eqop
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterFlagEffect
(
31829185
,
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
,
0
,
1
)
end
end
function
c31829185
.
filter
(
c
)
return
c
:
IsFaceup
()
and
c
:
IsControlerCanBeChanged
()
function
c31829185
.
eqcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
GetFlagEffect
(
31829185
)
>
0
end
function
c31829185
.
eqtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
IsControler
(
1
-
tp
)
and
c
31829185
.
filter
(
chkc
)
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_MZONE
)
and
chkc
:
IsControler
(
1
-
tp
)
and
c
hkc
:
IsFaceup
(
)
end
if
chk
==
0
then
return
true
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_CONTROL
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c31829185
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
Card
.
IsFaceup
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_CONTROL
,
g
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_EQUIP
,
e
:
GetHandler
(),
1
,
0
,
0
)
end
...
...
@@ -73,7 +75,7 @@ function c31829185.eqop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_EQUIP_LIMIT
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetReset
(
RESET_EVENT
+
0x1f
e
0000
)
e1
:
SetReset
(
RESET_EVENT
+
0x1f
f
0000
)
e1
:
SetValue
(
c31829185
.
eqlimit
)
c
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
...
...
c3758046.lua
View file @
85d164cc
...
...
@@ -49,10 +49,15 @@ function c3758046.filter(c,e,tp,id)
end
function
c3758046
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
ft
=
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
if
ft
<=
0
then
return
end
local
tg
=
Duel
.
SelectMatchingCard
(
tp
,
c3758046
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
,
e
,
tp
,
Duel
.
GetTurnCount
())
if
ft
<=
0
or
(
Duel
.
IsPlayerAffectedByEffect
(
tp
,
59822133
)
and
tg
:
GetCount
()
>
1
and
ft
>
1
)
then
return
end
local
g
=
nil
if
tg
:
Getcount
()
>
ft
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c3758046
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
ft
,
ft
,
nil
,
e
,
tp
,
Duel
.
GetTurnCount
())
if
Duel
.
IsPlayerAffectedByEffect
(
tp
,
59822133
)
and
g
:
GetCount
()
>
1
then
return
end
g
=
tg
:
Select
(
tp
,
ft
,
ft
,
nil
)
else
g
=
tg
:
Clone
()
end
if
g
:
GetCount
()
>
0
then
Duel
.
SpecialSummon
(
g
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
...
...
c56585883.lua
View file @
85d164cc
...
...
@@ -19,12 +19,14 @@ function c56585883.initial_effect(c)
e2
:
SetTarget
(
c56585883
.
target
)
e2
:
SetOperation
(
c56585883
.
operation
)
c
:
RegisterEffect
(
e2
)
--
to grave
--
reg
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetCode
(
EVENT_TO_GRAVE
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e3
:
SetOperation
(
c56585883
.
regop
)
c
:
RegisterEffect
(
e3
)
--search
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetDescription
(
aux
.
Stringid
(
56585883
,
1
))
e4
:
SetCategory
(
CATEGORY_TOHAND
+
CATEGORY_SEARCH
)
...
...
c63767246.lua
View file @
85d164cc
...
...
@@ -51,7 +51,7 @@ function c63767246.disop(e,tp,eg,ep,ev,re,r,rp)
Duel
.
NegateEffect
(
ev
)
local
c
=
e
:
GetHandler
()
local
rc
=
re
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
rc
:
IsRelateToEffect
(
re
)
then
if
c
:
IsRelateToEffect
(
e
)
and
rc
:
IsRelateToEffect
(
re
)
and
c
:
IsType
(
TYPE_XYZ
)
then
rc
:
CancelToGrave
()
Duel
.
Overlay
(
c
,
Group
.
FromCards
(
rc
))
end
...
...
c74845897.lua
View file @
85d164cc
...
...
@@ -19,10 +19,15 @@ function c74845897.tg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function
c74845897
.
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
ft
=
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
if
ft
<=
0
then
return
end
if
Duel
.
IsPlayerAffectedByEffect
(
tp
,
59822133
)
then
ft
=
1
end
local
tg
=
Duel
.
GetMatchingGroup
(
tp
,
c74845897
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
,
e
,
tp
)
if
ft
<=
0
or
(
Duel
.
IsPlayerAffectedByEffect
(
tp
,
59822133
)
and
tg
:
GetCount
()
>
1
and
ft
>
1
)
then
return
end
local
g
=
nil
if
tg
:
Getcount
()
>
ft
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c74845897
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
ft
,
ft
,
nil
,
e
,
tp
)
g
=
tg
:
Select
(
tp
,
ft
,
ft
,
nil
)
else
g
=
tg
:
Clone
()
end
if
g
:
GetCount
()
>
0
then
local
fid
=
e
:
GetHandler
():
GetFieldID
()
local
tc
=
g
:
GetFirst
()
...
...
c95291684.lua
View file @
85d164cc
...
...
@@ -23,10 +23,11 @@ function c95291684.initial_effect(c)
c
:
RegisterEffect
(
e2
)
--cannot normal summon
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetCode
(
E
VENT_SPSUMMON_SUCCESS
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetCode
(
E
FFECT_SPSUMMON_COST
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e3
:
SetOperation
(
c95291684
.
lmop
)
e3
:
SetCost
(
c95291684
.
spcost
)
e3
:
SetOperation
(
c95291684
.
spcop
)
c
:
RegisterEffect
(
e3
)
end
function
c95291684
.
cfilter
(
c
)
...
...
@@ -35,8 +36,7 @@ end
function
c95291684
.
sprcon
(
e
,
c
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
return
Duel
.
GetActivityCount
(
tp
,
ACTIVITY_NORMALSUMMON
)
==
0
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
c95291684
.
cfilter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
)
return
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
c95291684
.
cfilter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
)
end
function
c95291684
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
GetSummonType
()
==
SUMMON_TYPE_SPECIAL
+
1
...
...
@@ -67,7 +67,10 @@ function c95291684.spop(e,tp,eg,ep,ev,re,r,rp)
tc
:
RegisterEffect
(
e2
,
true
)
end
end
function
c95291684
.
lmop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c95291684
.
spcost
(
e
,
c
,
tp
)
return
Duel
.
GetActivityCount
(
tp
,
ACTIVITY_NORMALSUMMON
)
==
0
end
function
c95291684
.
spcop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
...
...
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