Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
E
Entertainment Server
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
Peter Xin
Entertainment Server
Commits
ec62b3a4
Commit
ec62b3a4
authored
Jun 29, 2024
by
root
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refresh on 2024-06-29 08:12:33
parent
2b95c7d0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
239 additions
and
0 deletions
+239
-0
script/c172016310.lua
script/c172016310.lua
+134
-0
script/c172016315.lua
script/c172016315.lua
+105
-0
No files found.
script/c172016310.lua
0 → 100644
View file @
ec62b3a4
--教导的圣女 奎姆
local
s
,
id
=
GetID
()
local
o
=
1e9
function
s
.
initial_effect
(
c
)
--spsummon
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
id
,
0
))
e1
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e1
:
SetType
(
EFFECT_TYPE_IGNITION
)
e1
:
SetRange
(
LOCATION_HAND
)
e1
:
SetCondition
(
s
.
spcon
)
e1
:
SetTarget
(
s
.
sptg
)
e1
:
SetOperation
(
s
.
spop
)
c
:
RegisterEffect
(
e1
)
--to field
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
id
,
1
))
e2
:
SetCategory
(
CATEGORY_TOHAND
+
CATEGORY_SEARCH
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e2
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e2
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e2
:
SetTarget
(
s
.
settg
)
e2
:
SetOperation
(
s
.
setop
)
c
:
RegisterEffect
(
e2
)
local
e2p
=
e2
:
Clone
()
e2p
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
c
:
RegisterEffect
(
e2p
)
--gain
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_EVENT_PLAYER
)
e3
:
SetCode
(
EVENT_BE_MATERIAL
)
e3
:
SetCondition
(
s
.
mtcon
)
e3
:
SetOperation
(
s
.
mtop
)
c
:
RegisterEffect
(
e3
)
end
function
s
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
IsExistingMatchingCard
(
Card
.
IsSummonLocation
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
nil
,
LOCATION_EXTRA
)
end
function
s
.
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
s
.
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
s
.
setfilter1
(
c
)
return
c
:
IsSetCard
(
0x145
)
and
c
:
IsType
(
TYPE_SPELL
)
and
c
:
IsSSetable
()
end
function
s
.
setfilter2
(
c
)
return
c
:
IsSetCard
(
0x145
)
and
c
:
IsType
(
TYPE_TRAP
)
and
c
:
IsSSetable
()
end
function
s
.
settg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
s
.
setfilter1
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
and
Duel
.
IsExistingMatchingCard
(
s
.
setfilter2
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
end
end
function
s
.
setop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
<=
1
then
return
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SET
)
local
g1
=
Duel
.
SelectMatchingCard
(
tp
,
s
.
setfilter1
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
local
g2
=
Duel
.
SelectMatchingCard
(
tp
,
s
.
setfilter2
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
Duel
.
SSet
(
tp
,
g1
+
g2
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetCode
(
EFFECT_CANNOT_SPECIAL_SUMMON
)
e1
:
SetTargetRange
(
1
,
0
)
e1
:
SetTarget
(
s
.
splimit
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
function
s
.
splimit
(
e
,
c
)
return
c
:
IsLocation
(
LOCATION_EXTRA
)
end
function
s
.
mtcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
r
==
REASON_RITUAL
and
eg
:
IsExists
(
Card
.
IsSetCard
,
1
,
nil
,
0x145
)
and
not
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_OVERLAY
)
end
function
s
.
mtop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
g
=
eg
:
Filter
(
Card
.
IsSetCard
,
nil
,
0x145
)
local
rc
=
g
:
GetFirst
()
if
not
rc
then
return
end
local
e1
=
Effect
.
CreateEffect
(
rc
)
e1
:
SetDescription
(
aux
.
Stringid
(
id
,
2
))
e1
:
SetCategory
(
CATEGORY_DESTROY
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
EVENT_TO_GRAVE
)
e1
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCondition
(
s
.
descon
)
e1
:
SetOperation
(
s
.
desop
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
rc
:
RegisterEffect
(
e1
,
true
)
if
not
rc
:
IsType
(
TYPE_EFFECT
)
then
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetCode
(
EFFECT_ADD_TYPE
)
e3
:
SetValue
(
TYPE_EFFECT
)
e3
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
rc
:
RegisterEffect
(
e3
,
true
)
end
rc
:
RegisterFlagEffect
(
0
,
RESET_EVENT
+
RESETS_STANDARD
,
EFFECT_FLAG_CLIENT_HINT
,
1
,
0
,
aux
.
Stringid
(
id
,
3
))
end
function
s
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
eg
:
IsExists
(
Card
.
IsPreviousLocation
,
1
,
nil
,
LOCATION_EXTRA
)
--and not Duel.IsChainSolving()
end
function
s
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
HINT_CARD
,
0
,
e
:
GetHandler
():
GetCode
())
local
cg
=
eg
:
Filter
(
Card
.
IsPreviousLocation
,
nil
,
LOCATION_EXTRA
)
local
type
=
0
for
cc
in
aux
.
Next
(
cg
)
do
type
=
type
|
cc
:
GetType
()
end
type
=
type
&
(
TYPE_FUSION
+
TYPE_XYZ
+
TYPE_SYNCHRO
+
TYPE_LINK
+
TYPE_PENDULUM
)
local
dg
=
Duel
.
GetMatchingGroup
(
Card
.
IsType
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
nil
,
type
)
for
dc
in
aux
.
Next
(
dg
)
do
if
dc
:
IsCanBeDisabledByEffect
(
e
)
then
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_DISABLE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
dc
:
RegisterEffect
(
e1
)
Duel
.
NegateRelatedChain
(
dc
,
RESET_TURN_SET
)
end
end
Duel
.
AdjustInstantly
()
Duel
.
Destroy
(
dg
,
REASON_EFFECT
)
end
script/c172016315.lua
0 → 100644
View file @
ec62b3a4
--地中族邪界兽的巢穴
local
s
,
id
,
o
=
GetID
()
function
s
.
initial_effect
(
c
)
--activate
local
e0
=
Effect
.
CreateEffect
(
c
)
e0
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e0
:
SetCode
(
EVENT_FREE_CHAIN
)
c
:
RegisterEffect
(
e0
)
--reveal
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
id
,
0
))
e1
:
SetCategory
(
CATEGORY_TOHAND
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e1
:
SetRange
(
LOCATION_SZONE
)
e1
:
SetCondition
(
s
.
revcon
)
e1
:
SetTarget
(
s
.
revtg
)
e1
:
SetOperation
(
s
.
revop
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
c
:
RegisterEffect
(
e2
)
local
e3
=
e1
:
Clone
()
e3
:
SetCode
(
EVENT_FLIP_SUMMON_SUCCESS
)
c
:
RegisterEffect
(
e3
)
--attack
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetCategory
(
CATEGORY_POSITION
)
e4
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e4
:
SetCode
(
EVENT_ATTACK_ANNOUNCE
)
e4
:
SetRange
(
LOCATION_SZONE
)
e4
:
SetCondition
(
s
.
atkcon
)
e4
:
SetTarget
(
s
.
atktg
)
e4
:
SetOperation
(
s
.
atkop
)
c
:
RegisterEffect
(
e4
)
end
function
s
.
revcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
eg
:
IsExists
(
Card
.
IsSetCard
,
1
,
nil
,
0xed
)
and
ep
==
tp
end
function
s
.
revtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_DECK
,
0
)
>=
3
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
1
,
0
,
LOCATION_DECK
)
end
function
s
.
revop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
dk
=
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_DECK
,
0
)
if
dk
<
3
then
return
end
local
ct
=
3
if
dk
%
2
==
0
then
ct
=
4
end
local
st
=
(
dk
-
ct
)
/
2
local
g
=
Duel
.
GetMatchingGroup
(
s
.
revfilter
(
st
,
st
+
ct
),
tp
,
LOCATION_DECK
,
0
,
nil
)
--Duel.ConfirmCards(tp,g)
--Duel.ConfirmCards(1-tp,g)
for
c
in
aux
.
Next
(
g
)
do
Duel
.
MoveSequence
(
c
,
SEQ_DECKTOP
)
end
Duel
.
ConfirmDecktop
(
tp
,
ct
)
local
tg
=
g
:
Filter
(
Card
.
IsSetCard
,
nil
,
0xed
)
if
#
tg
>
0
then
local
tc
=
tg
:
Select
(
tp
,
1
,
1
,
nil
)
Duel
.
DisableShuffleCheck
()
Duel
.
SendtoHand
(
tc
,
tp
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
tc
)
ct
=
ct
-
1
end
Duel
.
SortDecktop
(
tp
,
tp
,
ct
)
if
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
id
,
1
),
aux
.
Stringid
(
id
,
2
))
==
1
then
for
i
=
1
,
ct
do
local
mg
=
Duel
.
GetDecktopGroup
(
tp
,
1
)
Duel
.
MoveSequence
(
mg
:
GetFirst
(),
SEQ_DECKBOTTOM
)
end
end
end
function
s
.
revfilter
(
from
,
to
)
return
function
(
c
)
local
s
=
c
:
GetSequence
()
return
s
>=
from
and
s
<
to
end
end
function
s
.
atkcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetAttacker
():
IsSetCard
(
0xed
)
or
(
Duel
.
GetAttackTarget
()
~=
nil
and
Duel
.
GetAttackTarget
():
IsSetCard
(
0xed
))
end
function
s
.
atktg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_POSITION
,
nil
,
2
,
0
,
0
)
end
function
s
.
atkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c1
=
Duel
.
GetAttacker
()
local
c2
=
Duel
.
GetAttackTarget
()
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_BATTLE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_BATTLE
)
e1
:
SetOperation
(
s
.
flipop
)
e1
:
SetDescription
(
aux
.
Stringid
(
id
,
0
))
c1
:
RegisterEffect
(
e1
:
Clone
())
if
c2
~=
nil
then
c2
:
RegisterEffect
(
e1
)
end
end
function
s
.
flipop
(
e
)
Duel
.
ChangePosition
(
e
:
GetHandler
(),
POS_FACEDOWN_DEFENSE
)
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