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
Nemo Ma
no81cards
Commits
32609f29
Commit
32609f29
authored
Jun 30, 2022
by
Nemo Ma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
179c6249
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
52 additions
and
49 deletions
+52
-49
expansions/script/c25000104.lua
expansions/script/c25000104.lua
+51
-48
expansions/script/c33200529.lua
expansions/script/c33200529.lua
+1
-1
No files found.
expansions/script/c25000104.lua
View file @
32609f29
...
...
@@ -21,7 +21,10 @@ function cm.checkop(e,tp,eg,ep,ev,re,r,rp)
Duel
.
RegisterFlagEffect
(
ep
,
m
,
0
,
0
,
1
)
end
function
cm
.
con
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetFlagEffect
(
tp
,
m
)
==
0
if
Duel
.
GetFlagEffect
(
tp
,
m
)
>
0
then
e
:
Reset
()
return
false
else
return
true
end
end
function
cm
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
...
...
@@ -30,28 +33,22 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetCondition
(
cm
.
con
)
e1
:
SetOperation
(
cm
.
tkop
)
Duel
.
RegisterEffect
(
e1
,
tp
)
if
Duel
.
GetFlagEffect
(
0
,
m
+
20000
)
>
0
then
return
end
Duel
.
RegisterFlagEffect
(
0
,
m
+
20000
,
0
,
0
,
0
)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetType
(
EFFECT_TYPE_FIELD
)
e2
:
SetCode
(
EFFECT_SUMMON_COST
)
e2
:
SetTargetRange
(
0xff
,
0xff
)
e2
:
SetOperation
(
cm
.
costop
)
Duel
.
RegisterEffect
(
e2
,
tp
)
end
function
cm
.
costop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
RegisterFlagEffect
(
0
,
m
+
10000
,
RESET_CHAIN
,
0
,
0
)
end
function
cm
.
tkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
Duel
.
GetMatchingGroupCount
(
function
(
c
)
return
c
:
IsFaceup
()
and
c
:
IsCode
(
m
+
1
)
end
,
tp
,
LOCATION_MZONE
,
0
,
nil
)
>
0
or
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<=
0
or
not
Duel
.
IsPlayerCanSpecialSummonMonster
(
tp
,
m
+
1
,
0
,
TYPES_TOKEN_MONSTER
,
0
,
0
,
10
,
RACE_FAIRY
,
ATTRIBUTE_LIGHT
)
then
return
end
local
token
=
Duel
.
CreateToken
(
tp
,
m
+
1
)
Duel
.
SpecialSummon
(
token
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
EVENT_ADJUST
)
e1
:
SetLabelObject
(
token
)
e1
:
SetCondition
(
cm
.
con
)
e1
:
SetOperation
(
cm
.
effop
)
Duel
.
RegisterEffect
(
e1
,
tp
)
Duel
.
Readjust
()
end
function
cm
.
effop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
e
:
GetLabelObject
()
if
not
tc
or
not
tc
:
IsLocation
(
LOCATION_ONFIELD
)
then
e
:
Reset
()
return
end
if
tc
:
GetFlagEffect
(
m
)
>
0
then
return
end
tc
:
RegisterFlagEffect
(
m
,
RESET_EVENT
+
RESETS_STANDARD
+
RESET_OVERLAY
,
0
,
1
)
if
Duel
.
GetMatchingGroupCount
(
function
(
c
)
return
c
:
IsFaceup
()
and
c
:
IsCode
(
m
+
1
)
end
,
tp
,
LOCATION_MZONE
,
0
,
nil
)
>
0
or
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<=
0
or
not
Duel
.
IsPlayerCanSpecialSummonMonster
(
tp
,
m
+
1
,
0
,
TYPES_TOKEN_MONSTER
,
0
,
0
,
10
,
RACE_FAIRY
,
ATTRIBUTE_LIGHT
)
or
Duel
.
GetFlagEffect
(
0
,
m
+
10000
)
>
0
then
return
end
local
tc
=
Duel
.
CreateToken
(
tp
,
m
+
1
)
Duel
.
SpecialSummon
(
tc
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
local
c
=
e
:
GetHandler
()
local
e0
=
Effect
.
CreateEffect
(
c
)
e0
:
SetType
(
EFFECT_TYPE_FIELD
)
...
...
@@ -60,55 +57,62 @@ function cm.effop(e,tp,eg,ep,ev,re,r,rp)
e0
:
SetLabelObject
(
tc
)
e0
:
SetTargetRange
(
1
,
0
)
e0
:
SetCondition
(
cm
.
econ
)
cm
.
R
Effect
(
e0
,
tp
)
Duel
.
Register
Effect
(
e0
,
tp
)
local
e1
=
e0
:
Clone
()
e1
:
SetCode
(
EFFECT_REFLECT_DAMAGE
)
e1
:
SetValue
(
function
(
e
,
re
,
ev
,
r
,
rp
,
rc
)
return
bit
.
band
(
r
,
REASON_EFFECT
)
~=
0
end
)
cm
.
R
Effect
(
e1
,
tp
)
Duel
.
Register
Effect
(
e1
,
tp
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e2
:
SetCode
(
EVENT_CHAINING
)
e2
:
SetLabelObject
(
tc
)
e2
:
SetCondition
(
cm
.
econ
)
e2
:
SetOperation
(
cm
.
ceoperation
)
cm
.
R
Effect
(
e2
,
tp
)
Duel
.
Register
Effect
(
e2
,
tp
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetCode
(
EVENT_FREE_CHAIN
)
e3
:
SetCountLimit
(
1
)
e3
:
SetLabelObject
(
tc
)
e3
:
SetCondition
(
cm
.
econ2
)
e3
:
SetOperation
(
cm
.
tgop
)
cm
.
R
Effect
(
e3
,
tp
)
Duel
.
Register
Effect
(
e3
,
tp
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_FIELD
)
e4
:
SetCode
(
EFFECT_SET_ATTACK
_FINAL
)
e4
:
SetCode
(
EFFECT_SET_ATTACK
)
e4
:
SetTargetRange
(
LOCATION_MZONE
,
0
)
e4
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e4
:
SetLabelObject
(
tc
)
e4
:
SetCondition
(
cm
.
atkcon
)
e4
:
SetTarget
(
function
(
e
,
c
)
return
c
==
e
:
GetLabelObject
()
end
)
e4
:
SetValue
(
cm
.
atkval
)
cm
.
R
Effect
(
e4
,
tp
)
Duel
.
Register
Effect
(
e4
,
tp
)
local
e5
=
e4
:
Clone
()
e5
:
SetCode
(
EFFECT_SET_DEFENSE
_FINAL
)
e5
:
SetCode
(
EFFECT_SET_DEFENSE
)
e5
:
SetValue
(
cm
.
defval
)
cm
.
REffect
(
e5
,
tp
)
Duel
.
RegisterEffect
(
e5
,
tp
)
local
e6
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e6
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e6
:
SetCode
(
EVENT_LEAVE_FIELD_P
)
e6
:
SetLabelObject
(
tc
)
e6
:
SetOperation
(
cm
.
rstop1
)
Duel
.
RegisterEffect
(
e6
,
tp
)
local
e7
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e7
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e7
:
SetCode
(
EVENT_CUSTOM
+
m
)
e7
:
SetLabelObject
(
e3
)
e7
:
SetOperation
(
cm
.
rstop2
)
Duel
.
RegisterEffect
(
e7
,
tp
)
end
function
cm
.
econ
(
e
)
local
tc
=
e
:
GetLabelObject
()
if
not
tc
or
tc
:
GetFlagEffect
(
m
)
==
0
then
if
not
tc
or
Duel
.
GetFlagEffect
(
e
:
GetHandlerPlayer
(),
m
)
>
0
then
e
:
Reset
()
return
false
else
return
true
end
end
function
cm
.
econ2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
e
:
GetLabelObject
()
local
ph
=
Duel
.
GetCurrentPhase
()
if
not
tc
or
tc
:
GetFlagEffect
(
m
)
==
0
then
e
:
Reset
()
return
false
else
return
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
(
ph
==
PHASE_MAIN1
or
ph
==
PHASE_MAIN2
)
and
Duel
.
GetCurrentChain
()
==
0
and
Duel
.
GetTurnPlayer
()
==
tp
end
return
Duel
.
GetFlagEffect
(
tp
,
m
)
==
0
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
(
ph
==
PHASE_MAIN1
or
ph
==
PHASE_MAIN2
)
and
Duel
.
GetCurrentChain
()
==
0
and
Duel
.
GetTurnPlayer
()
==
tp
end
function
cm
.
ceoperation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
rp
==
tp
or
not
re
:
IsActiveType
(
TYPE_MONSTER
)
then
return
end
...
...
@@ -128,7 +132,7 @@ end
function
cm
.
atkcon
(
e
)
local
tc
=
e
:
GetLabelObject
()
local
ph
=
Duel
.
GetCurrentPhase
()
if
not
tc
or
tc
:
GetFlagEffect
(
m
)
==
0
then
if
not
tc
or
Duel
.
GetFlagEffect
(
e
:
GetHandlerPlayer
(),
m
)
>
0
then
e
:
Reset
()
return
false
else
return
(
ph
==
PHASE_DAMAGE
or
ph
==
PHASE_DAMAGE_CAL
)
and
tc
:
GetBattleTarget
()
end
...
...
@@ -136,6 +140,7 @@ end
function
cm
.
atkval
(
e
,
c
)
local
tc
=
e
:
GetLabelObject
()
local
bc
=
tc
:
GetBattleTarget
()
if
not
bc
then
return
false
end
local
atk
=
bc
:
GetAttack
()
+
100
if
bc
:
IsFacedown
()
then
atk
=
100
end
return
atk
...
...
@@ -143,21 +148,19 @@ end
function
cm
.
defval
(
e
,
c
)
local
tc
=
e
:
GetLabelObject
()
local
bc
=
tc
:
GetBattleTarget
()
if
not
bc
then
return
false
end
local
def
=
bc
:
GetDefense
()
+
100
if
bc
:
IsFacedown
()
then
def
=
100
end
return
def
end
function
cm
.
REffect
(
e
,
tp
)
Duel
.
RegisterEffect
(
e
,
tp
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
EVENT_ADJUST
)
e1
:
SetLabelObject
(
e
)
e1
:
SetOperation
(
cm
.
rstop
)
Duel
.
RegisterEffect
(
e1
,
tp
)
function
cm
.
rstop1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
e
:
GetLabelObject
()
if
not
eg
:
IsContains
(
tc
)
then
return
end
Duel
.
RaiseEvent
(
eg
,
EVENT_CUSTOM
+
m
,
re
,
r
,
rp
,
ep
,
ev
)
e
:
Reset
()
end
function
cm
.
rstop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
Duel
.
GetFlagEffect
(
tp
,
m
)
==
0
then
return
end
if
e
:
GetLabelObject
()
then
e
:
GetLabelObject
()
:
Reset
()
end
function
cm
.
rstop
2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
re
=
e
:
GetLabelObject
()
if
re
then
re
:
Reset
()
end
e
:
Reset
()
end
expansions/script/c33200529.lua
View file @
32609f29
...
...
@@ -56,6 +56,6 @@ function c33200529.tzop(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e2
:
SetCode
(
33200505
)
e2
:
SetTargetRange
(
1
,
0
)
e
:
SetReset
(
RESET_EVENT
+
RESET_CHAIN
)
e
2
:
SetReset
(
RESET_EVENT
+
RESET_CHAIN
)
Duel
.
RegisterEffect
(
e2
,
tp
)
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