Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
P
pre-release-database-cdb
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
Crescent/毛虫
pre-release-database-cdb
Commits
70c36cc6
Commit
70c36cc6
authored
Apr 26, 2024
by
Amiya
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新卡
parent
8a7a2177
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
88 additions
and
0 deletions
+88
-0
script/c101205067.lua
script/c101205067.lua
+88
-0
No files found.
script/c101205067.lua
0 → 100644
View file @
70c36cc6
--BBS
local
s
,
id
,
o
=
GetID
()
function
s
.
initial_effect
(
c
)
c
:
EnableCounterPermit
(
0x6c
)
c
:
SetCounterLimit
(
0x6c
,
10
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
c
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
id
,
0
))
e2
:
SetCategory
(
CATEGORY_COUNTER
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e2
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e2
:
SetCode
(
EVENT_CHAINING
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetCondition
(
s
.
ctcon
)
e2
:
SetTarget
(
s
.
cttg
)
e2
:
SetOperation
(
s
.
ctop
)
c
:
RegisterEffect
(
e2
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_FIELD
)
e3
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e3
:
SetRange
(
LOCATION_SZONE
)
e3
:
SetTargetRange
(
LOCATION_MZONE
,
0
)
e3
:
SetValue
(
s
.
val
)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetDescription
(
aux
.
Stringid
(
id
,
1
))
e4
:
SetCategory
(
CATEGORY_TOHAND
)
e4
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e4
:
SetCode
(
EVENT_CUSTOM
+
id
)
e4
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e4
:
SetRange
(
LOCATION_SZONE
)
--e4:SetCondition(s.setcon)
e4
:
SetTarget
(
s
.
settg
)
e4
:
SetOperation
(
s
.
setop
)
c
:
RegisterEffect
(
e4
)
end
function
s
.
ctcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
not
re
:
GetHandler
():
IsCode
(
id
)
end
function
s
.
cttg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
IsCanAddCounter
(
0x6c
,
1
)
end
end
function
s
.
ctop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
then
c
:
AddCounter
(
0x6c
,
1
)
if
c
:
GetCounter
(
0x6c
)
==
10
then
Duel
.
RaiseEvent
(
c
,
EVENT_CUSTOM
+
id
,
e
,
0
,
tp
,
tp
,
0
)
end
end
end
function
s
.
val
(
e
,
c
)
return
e
:
GetHandler
():
GetCounter
(
0x6c
)
*
100
end
function
s
.
filter
(
c
)
return
c
:
IsType
(
TYPE_TRAP
)
and
c
:
IsType
(
TYPE_CONTINUOUS
)
and
c
:
IsSSetable
()
and
(
c
:
GetOriginalLevel
()
>
0
or
bit
.
band
(
c
:
GetOriginalRace
(),
0x3fffffff
)
or
bit
.
band
(
c
:
GetOriginalAttribute
(),
0x7f
)
or
c
:
GetBaseAttack
()
>
0
or
c
:
GetBaseDefense
()
>
0
)
end
function
s
.
settg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
if
chk
==
0
then
return
c
:
GetCounter
(
0x6c
)
==
10
and
c
:
IsAbleToHand
()
and
Duel
.
IsExistingMatchingCard
(
s
.
filter
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
c
,
1
,
0
,
0
)
end
function
s
.
setop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
Duel
.
SendtoHand
(
c
,
nil
,
REASON_EFFECT
)
~=
0
and
c
:
IsLocation
(
LOCATION_HAND
)
then
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
<=
0
then
return
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SET
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
s
.
filter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
local
tc
=
g
:
GetFirst
()
if
tc
and
Duel
.
SSet
(
tp
,
tc
)
~=
0
then
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetDescription
(
aux
.
Stringid
(
id
,
2
))
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_TRAP_ACT_IN_SET_TURN
)
e1
:
SetProperty
(
EFFECT_FLAG_SET_AVAILABLE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
)
end
end
end
\ No newline at end of file
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