Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
no81cards
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
Huangnan
no81cards
Commits
1745db5f
Commit
1745db5f
authored
Jul 05, 2023
by
Nemo Ma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
4a47186c
Changes
9
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
167 additions
and
146 deletions
+167
-146
expansions/script/c10100000.lua
expansions/script/c10100000.lua
+11
-11
expansions/script/c10174034.lua
expansions/script/c10174034.lua
+17
-17
expansions/script/c11451780.lua
expansions/script/c11451780.lua
+1
-1
expansions/script/c130006034.lua
expansions/script/c130006034.lua
+31
-24
expansions/script/c130006035.lua
expansions/script/c130006035.lua
+30
-26
expansions/script/c130006036.lua
expansions/script/c130006036.lua
+38
-34
expansions/script/c130006037.lua
expansions/script/c130006037.lua
+35
-30
expansions/script/c130006038.lua
expansions/script/c130006038.lua
+3
-3
expansions/script/c9910731.lua
expansions/script/c9910731.lua
+1
-0
No files found.
expansions/script/c10100000.lua
View file @
1745db5f
...
...
@@ -7261,5 +7261,5 @@ s.record_previous_inside_series()
s
.
previous_xyz_material_record
()
s
.
record_official_filter
()
s
.
add_current_effect_check
()
s.add_type_normal_spell_or_trap_scl()
--
s.add_type_normal_spell_or_trap_scl()
Scl
.
RaiseGlobalSetEvent
()
\ No newline at end of file
expansions/script/c10174034.lua
View file @
1745db5f
--能量体
if
not
pcall
(
function
()
require
(
"expansions/script/c10199990"
)
end
)
then
require
(
"script/c10199990"
)
end
local
m
=
10174034
local
cm
=
_G
[
"c"
..
m
]
function
cm
.
initial_effect
(
c
)
local
e1
=
rsef
.
SV_UPDATE
(
c
,
"atk"
,
cm
.
val
)
local
e2
=
rsef
.
I
(
c
,{
m
,
0
},
1
,
"des"
,
"tg"
,
LOCATION_MZONE
,
cm
.
con
(
2000
),
rscost
.
cost
(
Card
.
IsDiscardable
,
"dish"
,
LOCATION_HAND
),
rstg
.
target
(
aux
.
TRUE
,
"des"
,
0
,
LOCATION_ONFIELD
),
cm
.
desop
)
local
e3
=
rsef
.
SV_IMMUNE_EFFECT
(
c
,
cm
.
imval
,
cm
.
con
(
4000
))
--rescripted 20230705
if
not
pcall
(
function
()
require
(
"expansions/script/c10100000"
)
end
)
then
require
(
"script/c10100000"
)
end
local
s
,
id
=
GetID
()
function
s
.
initial_effect
(
c
)
local
e1
=
Scl
.
CreateSingleBuffEffect
(
c
,
"+ATK"
,
s
.
val
,
"MonsterZone"
)
local
e2
=
Scl
.
CreateIgnitionEffect
(
c
,
"Destroy"
,
1
,
"Destroy"
,
"Target"
,
"MonsterZone"
,
s
.
descon
,
{
"PlayerCost"
,
"Discard"
,
1
},
{
"Target"
,
"Destroy"
,
aux
.
TRUE
,
0
,
"OnField"
},
s
.
desop
)
local
e4
=
Scl
.
CreateSingleBuffEffect
(
c
,
"UnaffectedByOpponentsActivatedEffects"
,
1
,
"MonsterZone"
,
s
.
uecon
)
end
function
cm
.
val
(
e
,
c
)
return
Duel
.
GetFieldGroupCount
(
c
:
GetControler
(),
0
,
LOCATION_
MZONE
)
*
1000
function
s
.
val
(
e
,
c
)
return
Duel
.
GetFieldGroupCount
(
c
:
GetControler
(),
0
,
LOCATION_
ONFIELD
)
*
1000
end
function
cm
.
con
(
atk
)
return
function
(
e
)
return
e
:
GetHandler
():
IsAttackAbove
(
atk
)
end
function
s
.
descon
(
e
,
tp
)
return
e
:
GetHandler
():
IsAttackAbove
(
2000
)
end
function
cm
.
desop
(
e
,
tp
)
local
tc
=
rscf
.
GetTargetCard
()
function
s
.
desop
(
e
,
tp
)
local
_
,
tc
=
Scl
.
GetTargetsReleate2Chain
()
if
tc
then
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
end
end
function
cm
.
imval
(
e
,
re
)
return
re
:
GetOwnerPlayer
()
~=
e
:
GetOwnerPlayer
()
and
re
:
IsActivated
(
)
function
s
.
uecon
(
e
,
tp
)
return
e
:
GetHandler
():
IsAttackAbove
(
4000
)
end
\ No newline at end of file
expansions/script/c11451780.lua
View file @
1745db5f
...
...
@@ -226,8 +226,8 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local
tc
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
filter2
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
,
tp
):
GetFirst
()
if
tc
then
Duel
.
MoveToField
(
tc
,
tp
,
tp
,
LOCATION_SZONE
,
POS_FACEUP
,
true
)
te
:
UseCountLimit
(
tp
,
1
,
true
)
local
te
=
tc
:
GetActivateEffect
()
te
:
UseCountLimit
(
tp
,
1
,
true
)
local
tep
=
tc
:
GetControler
()
local
cost
=
te
:
GetCost
()
if
cost
then
cost
(
te
,
tep
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
1
)
end
...
...
expansions/script/c130006034.lua
View file @
1745db5f
...
...
@@ -3,7 +3,10 @@ if not pcall(function() require("expansions/script/c130001000") end) then requir
local
s
,
id
=
Scl
.
SetID
(
130006034
,
"LordOfChain"
)
function
s
.
initial_effect
(
c
)
local
e1
=
Scl
.
CreateSingleBuffEffect
(
c
,
"Reveal"
,
1
,
"Hand"
)
local
e2
=
Scl
.
CreateQuickMandatoryEffect
(
c
,
"ActivateEffect"
,
nil
,
nil
,
nil
,
nil
,
"Hand,MonsterZone"
,
nil
,
nil
,
s
.
mixtg
)
local
e2
=
Scl
.
CreateQuickMandatoryEffect
(
c
,
"ActivateEffect"
,
nil
,
nil
,
nil
,
nil
,
"Hand,MonsterZone"
,
nil
,
nil
,
s
.
mixtg
,
s
.
mixop
)
if
not
s
.
chain_id_scl
then
s
.
chain_id_scl
=
{}
end
end
function
s
.
get_count
(
zone
)
local
ct
=
Duel
.
GetFieldGroupCount
(
0
,
zone
,
0
)
-
Duel
.
GetFieldGroupCount
(
0
,
0
,
zone
)
...
...
@@ -11,13 +14,15 @@ function s.get_count(zone)
end
function
s
.
mixtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
local
cct
=
Duel
.
GetCurrentChain
()
local
b1
=
(
c
:
IsOnField
()
or
c
:
IsPublic
())
and
c
:
GetFlagEffect
(
id
)
<
s
.
get_count
(
LOCATION_ONFIELD
)
local
b2
=
c
:
IsLocation
(
LOCATION_HAND
)
and
c
:
GetFlagEffect
(
id
+
100
)
==
0
and
Duel
.
GetCurrentChain
()
>
2
local
b2
=
c
:
IsLocation
(
LOCATION_HAND
)
and
c
:
GetFlagEffect
(
id
+
100
)
==
0
and
cct
>
1
if
chk
==
0
then
return
b1
or
b2
end
local
op
=
b1
and
1
or
2
if
b1
and
b2
then
op
=
Scl
.
SelectOption
(
tp
,
true
,
"Damage"
,
true
,
{
id
,
0
})
end
--local op = b1 and 1 or 2
--if b1 and b2 then
--op = Scl.SelectOption(tp, true, "Damage", true, {id, 0})
--end
local
op
=
b2
and
2
or
1
if
op
==
1
then
e
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e
:
SetCategory
(
CATEGORY_DAMAGE
)
...
...
@@ -25,7 +30,6 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
100
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
100
)
Duel
.
ChangeChainOperation
(
0
,
s
.
op1
)
else
e
:
SetProperty
(
0
)
c
:
RegisterFlagEffect
(
id
+
100
,
RESET_CHAIN
,
0
,
1
)
...
...
@@ -41,18 +45,20 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
end
e
:
SetCategory
(
ctgy
)
Duel
.
ChangeChainOperation
(
0
,
s
.
op2
)
end
s
.
chain_id_scl
[
cct
]
=
op
end
function
s
.
op1
(
e
,
tp
)
function
s
.
mixop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
cct
=
Duel
.
GetCurrentChain
()
local
op
=
s
.
chain_id_scl
[
cct
]
if
op
==
1
then
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
Duel
.
Damage
(
p
,
d
,
REASON_EFFECT
)
end
function
s
.
op2
(
e
,
tp
)
else
local
c
=
e
:
GetHandler
()
local
cct
=
Duel
.
GetCurrentChain
()
if
cct
>=
3
then
if
c
:
IsRelateToChain
(
0
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
and
if
c
:
IsRelateToChain
(
0
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
>
0
then
Scl
.
SelectAndOperateCards
(
"Send2GY"
,
tp
,
Card
.
IsAbleToGrave
,
tp
,
"OnField"
,
"OnField"
,
1
,
1
,
nil
)()
end
...
...
@@ -63,6 +69,7 @@ function s.op2(e,tp)
if
cct
>=
7
then
local
e1
=
Scl
.
CreateFieldTriggerContinousEffect
({
c
,
tp
},
"AfterEffectResolving"
,
nil
,
nil
,
nil
,
nil
,
s
.
tgcon
,
s
.
tgop
,
RESET_EP_SCL
)
end
end
end
function
s
.
spfilter
(
c
,
e
,
tp
)
return
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Scl
.
IsSeries
(
c
,
"LordOfChain"
)
...
...
expansions/script/c130006035.lua
View file @
1745db5f
...
...
@@ -3,7 +3,10 @@ if not pcall(function() require("expansions/script/c130001000") end) then requir
local
s
,
id
=
Scl
.
SetID
(
130006035
,
"LordOfChain"
)
function
s
.
initial_effect
(
c
)
local
e1
=
Scl
.
CreateSingleBuffEffect
(
c
,
"Reveal"
,
1
,
"Hand"
)
local
e2
=
Scl
.
CreateQuickMandatoryEffect
(
c
,
"ActivateEffect"
,
nil
,
nil
,
nil
,
nil
,
"Hand,MonsterZone"
,
nil
,
nil
,
s
.
mixtg
)
local
e2
=
Scl
.
CreateQuickMandatoryEffect
(
c
,
"ActivateEffect"
,
nil
,
nil
,
nil
,
nil
,
"Hand,MonsterZone"
,
nil
,
nil
,
s
.
mixtg
,
s
.
mixop
)
if
not
s
.
chain_id_scl
then
s
.
chain_id_scl
=
{}
end
end
function
s
.
get_count
(
zone
)
local
ct
=
Duel
.
GetFieldGroupCount
(
0
,
zone
,
0
)
-
Duel
.
GetFieldGroupCount
(
0
,
0
,
zone
)
...
...
@@ -11,13 +14,15 @@ function s.get_count(zone)
end
function
s
.
mixtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
local
cct
=
Duel
.
GetCurrentChain
()
local
b1
=
(
c
:
IsOnField
()
or
c
:
IsPublic
())
and
c
:
GetFlagEffect
(
id
)
<
s
.
get_count
(
LOCATION_HAND
)
local
b2
=
c
:
IsLocation
(
LOCATION_HAND
)
and
c
:
GetFlagEffect
(
id
+
100
)
==
0
and
Duel
.
GetCurrentChain
()
>
2
local
b2
=
c
:
IsLocation
(
LOCATION_HAND
)
and
c
:
GetFlagEffect
(
id
+
100
)
==
0
and
cct
>
1
if
chk
==
0
then
return
b1
or
b2
end
local
op
=
b1
and
1
or
2
if
b1
and
b2
then
op
=
Scl
.
SelectOption
(
tp
,
true
,
"GainLP"
,
true
,
{
id
,
0
})
end
--local op = b1 and 1 or 2
--if b1 and b2 then
--op = Scl.SelectOption(tp, true, "Damage", true, {id, 0})
--end
local
op
=
b2
and
2
or
1
if
op
==
1
then
e
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e
:
SetCategory
(
CATEGORY_RECOVER
)
...
...
@@ -25,11 +30,9 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
Duel
.
SetTargetPlayer
(
tp
)
Duel
.
SetTargetParam
(
100
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
100
)
Duel
.
ChangeChainOperation
(
0
,
s
.
op1
)
else
e
:
SetProperty
(
0
)
c
:
RegisterFlagEffect
(
id
+
100
,
RESET_CHAIN
,
0
,
1
)
local
cct
=
Duel
.
GetCurrentChain
()
local
ctgy
=
0
if
cct
>=
3
then
ctgy
=
ctgy
+
CATEGORY_SPECIAL_SUMMON
+
CATEGORY_HANDES
...
...
@@ -41,16 +44,16 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
ctgy
=
ctgy
+
CATEGORY_DRAW
end
e
:
SetCategory
(
ctgy
)
Duel
.
ChangeChainOperation
(
0
,
s
.
op2
)
end
e
:
SetLabel
(
op
)
s
.
chain_id_scl
[
cct
]
=
op
end
function
s
.
op1
(
e
,
tp
)
function
s
.
mixop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
cct
=
Duel
.
GetCurrentChain
()
local
op
=
s
.
chain_id_scl
[
cct
]
if
op
==
1
then
local
p
,
d
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
,
CHAININFO_TARGET_PARAM
)
Duel
.
Recover
(
p
,
d
,
REASON_EFFECT
)
end
function
s
.
op2
(
e
,
tp
)
local
cct
=
Duel
.
GetCurrentChain
()
else
local
c
=
e
:
GetHandler
()
if
cct
>=
3
then
if
c
:
IsRelateToChain
(
0
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
and
...
...
@@ -64,6 +67,7 @@ function s.op2(e,tp)
if
cct
>=
9
then
local
e1
=
Scl
.
CreateFieldTriggerContinousEffect
({
c
,
tp
},
"AfterEffectResolving"
,
nil
,
nil
,
nil
,
nil
,
s
.
drcon
,
s
.
drop
,
RESET_EP_SCL
)
end
end
end
function
s
.
thfilter
(
c
,
e
,
tp
)
return
c
:
IsAbleToHand
()
and
Scl
.
IsSeries
(
c
,
"LordOfChain"
)
...
...
expansions/script/c130006036.lua
View file @
1745db5f
...
...
@@ -3,7 +3,10 @@ if not pcall(function() require("expansions/script/c130001000") end) then requir
local
s
,
id
=
Scl
.
SetID
(
130006036
,
"LordOfChain"
)
function
s
.
initial_effect
(
c
)
local
e1
=
Scl
.
CreateSingleBuffEffect
(
c
,
"Reveal"
,
1
,
"Hand"
)
local
e2
=
Scl
.
CreateQuickMandatoryEffect
(
c
,
"ActivateEffect"
,
nil
,
nil
,
nil
,
nil
,
"Hand,MonsterZone"
,
nil
,
nil
,
s
.
mixtg
)
local
e2
=
Scl
.
CreateQuickMandatoryEffect
(
c
,
"ActivateEffect"
,
nil
,
nil
,
nil
,
nil
,
"Hand,MonsterZone"
,
nil
,
nil
,
s
.
mixtg
,
s
.
mixop
)
if
not
s
.
chain_id_scl
then
s
.
chain_id_scl
=
{}
end
end
function
s
.
get_count
(
zone
)
local
ct
=
Duel
.
GetFieldGroupCount
(
0
,
zone
,
0
)
-
Duel
.
GetFieldGroupCount
(
0
,
0
,
zone
)
...
...
@@ -11,22 +14,22 @@ function s.get_count(zone)
end
function
s
.
mixtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
local
cct
=
Duel
.
GetCurrentChain
()
local
b1
=
(
c
:
IsOnField
()
or
c
:
IsPublic
())
and
c
:
GetFlagEffect
(
id
)
<
s
.
get_count
(
LOCATION_DECK
)
local
b2
=
c
:
IsLocation
(
LOCATION_HAND
)
and
c
:
GetFlagEffect
(
id
+
100
)
==
0
and
Duel
.
GetCurrentChain
()
>
2
local
b2
=
c
:
IsLocation
(
LOCATION_HAND
)
and
c
:
GetFlagEffect
(
id
+
100
)
==
0
and
cct
>
1
if
chk
==
0
then
return
b1
or
b2
end
local
op
=
b1
and
1
or
2
if
b1
and
b2
then
op
=
Scl
.
SelectOption
(
tp
,
true
,
"ChangeDEF"
,
true
,
{
id
,
0
})
end
--local op = b1 and 1 or 2
--if b1 and b2 then
--op = Scl.SelectOption(tp, true, "Damage", true, {id, 0})
--end
local
op
=
b2
and
2
or
1
if
op
==
1
then
e
:
SetProperty
(
0
)
e
:
SetCategory
(
CATEGORY_DEFCHANGE
)
c
:
RegisterFlagEffect
(
id
,
RESET_CHAIN
,
0
,
1
)
Duel
.
ChangeChainOperation
(
0
,
s
.
op1
)
else
e
:
SetProperty
(
0
)
c
:
RegisterFlagEffect
(
id
+
100
,
RESET_CHAIN
,
0
,
1
)
local
cct
=
Duel
.
GetCurrentChain
()
local
ctgy
=
0
if
cct
>=
3
then
ctgy
=
ctgy
+
CATEGORY_SPECIAL_SUMMON
+
CATEGORY_REMOVE
...
...
@@ -38,19 +41,19 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
ctgy
=
ctgy
+
CATEGORY_DISABLE
end
e
:
SetCategory
(
ctgy
)
Duel
.
ChangeChainOperation
(
0
,
s
.
op2
)
end
e
:
SetLabel
(
op
)
s
.
chain_id_scl
[
cct
]
=
op
end
function
s
.
op1
(
e
,
tp
)
function
s
.
mixop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
cct
=
Duel
.
GetCurrentChain
()
local
op
=
s
.
chain_id_scl
[
cct
]
if
op
==
1
then
local
g
=
Duel
.
GetMatchingGroup
(
Card
.
IsFaceup
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
)
for
tc
in
aux
.
Next
(
g
)
do
Scl
.
AddSingleBuff
({
e
:
GetHandler
(),
tc
},
"+DEF"
,
-
300
)
end
end
function
s
.
op2
(
e
,
tp
)
else
local
c
=
e
:
GetHandler
()
local
cct
=
Duel
.
GetCurrentChain
()
if
cct
>=
3
then
if
c
:
IsRelateToChain
(
0
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
>
0
then
...
...
@@ -64,7 +67,7 @@ function s.op2(e,tp)
local
f
=
function
(
tc
)
return
tc
:
IsFaceup
()
and
tc
:
IsDefense
(
0
)
end
local
g
=
Duel
.
GetMatchingGroup
(
f
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
)
local
g
=
Duel
.
GetMatchingGroup
(
f
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
)
if
#
g
>
0
then
Duel
.
SendtoHand
(
g
,
nil
,
REASON_EFFECT
)
end
...
...
@@ -72,6 +75,7 @@ function s.op2(e,tp)
if
cct
>=
11
then
local
e1
=
Scl
.
CreateFieldTriggerContinousEffect
({
c
,
tp
},
"BeforeEffectResolving"
,
nil
,
nil
,
nil
,
nil
,
s
.
discon
,
s
.
disop
,
RESET_EP_SCL
)
end
end
end
function
s
.
discon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
)
return
ev
>=
2
and
ep
~=
tp
...
...
expansions/script/c130006037.lua
View file @
1745db5f
...
...
@@ -3,7 +3,10 @@ if not pcall(function() require("expansions/script/c130001000") end) then requir
local
s
,
id
=
Scl
.
SetID
(
130006037
,
"LordOfChain"
)
function
s
.
initial_effect
(
c
)
local
e1
=
Scl
.
CreateSingleBuffEffect
(
c
,
"Reveal"
,
1
,
"Hand"
)
local
e2
=
Scl
.
CreateQuickMandatoryEffect
(
c
,
"ActivateEffect"
,
nil
,
nil
,
nil
,
nil
,
"Hand,MonsterZone"
,
nil
,
nil
,
s
.
mixtg
)
local
e2
=
Scl
.
CreateQuickMandatoryEffect
(
c
,
"ActivateEffect"
,
nil
,
nil
,
nil
,
nil
,
"Hand,MonsterZone"
,
nil
,
nil
,
s
.
mixtg
,
s
.
mixop
)
if
not
s
.
chain_id_scl
then
s
.
chain_id_scl
=
{}
end
end
function
s
.
get_count
(
zone
)
local
ct
=
Duel
.
GetFieldGroupCount
(
0
,
zone
,
0
)
-
Duel
.
GetFieldGroupCount
(
0
,
0
,
zone
)
...
...
@@ -11,21 +14,21 @@ function s.get_count(zone)
end
function
s
.
mixtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
local
cct
=
Duel
.
GetCurrentChain
()
local
b1
=
(
c
:
IsOnField
()
or
c
:
IsPublic
())
and
c
:
GetFlagEffect
(
id
)
<
s
.
get_count
(
LOCATION_GRAVE
)
local
b2
=
c
:
IsLocation
(
LOCATION_HAND
)
and
c
:
GetFlagEffect
(
id
+
100
)
==
0
and
Duel
.
GetCurrentChain
()
>
2
local
b2
=
c
:
IsLocation
(
LOCATION_HAND
)
and
c
:
GetFlagEffect
(
id
+
100
)
==
0
and
cct
>
1
if
chk
==
0
then
return
b1
or
b2
end
local
op
=
b1
and
1
or
2
if
b1
and
b2
then
op
=
Scl
.
SelectOption
(
tp
,
true
,
"ChangeATK"
,
true
,
{
id
,
0
})
end
--local op = b1 and 1 or 2
--if b1 and b2 then
--op = Scl.SelectOption(tp, true, "Damage", true, {id, 0})
--end
local
op
=
b2
and
2
or
1
if
op
==
1
then
e
:
SetProperty
(
0
)
e
:
SetCategory
(
CATEGORY_ATKCHANGE
)
c
:
RegisterFlagEffect
(
id
,
RESET_CHAIN
,
0
,
1
)
Duel
.
ChangeChainOperation
(
0
,
s
.
op1
)
else
c
:
RegisterFlagEffect
(
id
+
100
,
RESET_CHAIN
,
0
,
1
)
local
cct
=
Duel
.
GetCurrentChain
()
local
ctgy
=
0
if
cct
>=
3
then
ctgy
=
ctgy
+
CATEGORY_SPECIAL_SUMMON
+
CATEGORY_REMOVE
+
CATEGORY_GRAVE_ACTION
...
...
@@ -37,18 +40,19 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
ctgy
=
ctgy
+
CATEGORY_DISABLE
end
e
:
SetCategory
(
ctgy
)
Duel
.
ChangeChainOperation
(
0
,
s
.
op2
)
end
s
.
chain_id_scl
[
cct
]
=
op
end
function
s
.
op1
(
e
,
tp
)
function
s
.
mixop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
cct
=
Duel
.
GetCurrentChain
()
local
op
=
s
.
chain_id_scl
[
cct
]
if
op
==
1
then
local
g
=
Duel
.
GetMatchingGroup
(
Card
.
IsFaceup
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
)
for
tc
in
aux
.
Next
(
g
)
do
Scl
.
AddSingleBuff
({
e
:
GetHandler
(),
tc
},
"+ATK"
,
400
)
end
end
function
s
.
op2
(
e
,
tp
)
else
local
c
=
e
:
GetHandler
()
local
cct
=
Duel
.
GetCurrentChain
()
if
cct
>=
3
then
if
c
:
IsRelateToChain
(
0
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
>
0
then
...
...
@@ -65,4 +69,5 @@ function s.op2(e,tp)
local
e1
=
Scl
.
CreateFieldBuffEffect
({
c
,
tp
},
"NegateEffect"
,
1
,
f
,
{
"OnField"
,
"OnField"
},
nil
,
nil
,
RESET_EP_SCL
)
local
e2
=
Scl
.
CreateFieldBuffEffect
({
c
,
tp
},
"=Name"
,
32274490
,
f
,
{
"OnField"
,
"OnField"
},
nil
,
nil
,
RESET_EP_SCL
)
end
end
end
\ No newline at end of file
expansions/script/c130006038.lua
View file @
1745db5f
...
...
@@ -3,8 +3,8 @@ if not pcall(function() require("expansions/script/c130001000") end) then requir
local
s
,
id
=
Scl
.
SetID
(
130006038
,
"LordOfChain"
)
function
s
.
initial_effect
(
c
)
local
e1
=
Scl
.
CreateActivateEffect
(
c
,
"FreeChain"
,
nil
,
nil
,
"Send2GY,Draw"
,
"!NegateEffect,!NegateActivation"
,
s
.
con
,
nil
,
{
{
"~Target"
,
"Send2GY"
,
Card
.
IsAbleToGrave
,
0
,
"OnField"
,
s
.
ct
},
{
"PlayerTarget"
,
"Draw"
,
s
.
ct
}
},
s
.
op
)
{
{
"~Target"
,
"Send2GY"
,
Card
.
IsAbleToGrave
,
0
,
"OnField"
,
s
.
ct
},
{
"PlayerTarget"
,
"Draw"
,
s
.
ct
}
},
s
.
op
)
local
e2
=
Scl
.
CreateQuickOptionalEffect
(
c
,
"ActivateEffect"
,
"ShuffleIn2Deck"
,
{
1
,
id
,
"Chain"
},
"ShuffleIn2Deck,AddFromDeck2Hand"
,
nil
,
"Hand"
,
s
.
scon
,
nil
,
s
.
stg
,
s
.
sop
)
end
function
s
.
ct
(
e
,
tp
)
...
...
@@ -12,7 +12,7 @@ function s.ct(e,tp)
return
#
g
>
0
and
1
or
0
end
function
s
.
con
(
e
,
tp
)
return
Duel
.
CheckPhaseActivity
()
return
Duel
.
GetCurrentPhase
()
==
PHASE_MAIN1
and
not
Duel
.
CheckPhaseActivity
()
end
function
s
.
op
(
e
,
tp
)
local
g
=
Scl
.
GetMatchingGroup
(
Card
.
IsPublic
,
tp
,
"Hand"
,
0
,
nil
)
...
...
expansions/script/c9910731.lua
View file @
1745db5f
...
...
@@ -60,6 +60,7 @@ function c9910731.conop(e,tp,eg,ep,ev,re,r,rp)
if
sg
:
IsExists
(
Card
.
IsLocation
,
1
,
nil
,
LOCATION_HAND
)
then
Duel
.
ShuffleHand
(
1
-
tp
)
end
local
c
=
e
:
GetHandler
()
for
tc
in
aux
.
Next
(
sg
)
do
tc
:
RegisterFlagEffect
(
9910731
,
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
,
EFFECT_FLAG_CLIENT_HINT
,
2
,
0
,
aux
.
Stringid
(
9910731
,
5
))
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_DISABLE
)
...
...
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