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
50b9a595
Commit
50b9a595
authored
Jul 24, 2017
by
mercury233
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
new
parent
f89d5a60
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
69 additions
and
0 deletions
+69
-0
c2414168.lua
c2414168.lua
+69
-0
No files found.
c2414168.lua
0 → 100644
View file @
50b9a595
--インタラプト・レジスタンス
function
c2414168
.
initial_effect
(
c
)
--special summon
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
2414168
,
0
))
e1
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetCode
(
EVENT_BATTLE_DAMAGE
)
e1
:
SetRange
(
LOCATION_HAND
)
e1
:
SetCondition
(
c2414168
.
spcon
)
e1
:
SetTarget
(
c2414168
.
sptg
)
e1
:
SetOperation
(
c2414168
.
spop
)
c
:
RegisterEffect
(
e1
)
--def
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
2414168
,
1
))
e2
:
SetCategory
(
CATEGORY_DEFCHANGE
)
e2
:
SetType
(
EFFECT_TYPE_TRIGGER_O
+
EFFECT_TYPE_FIELD
)
e2
:
SetCode
(
EVENT_PRE_DAMAGE_CALCULATE
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCountLimit
(
1
)
e2
:
SetCondition
(
c2414168
.
defcon
)
e2
:
SetOperation
(
c2414168
.
defop
)
c
:
RegisterEffect
(
e2
)
end
function
c2414168
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
ep
==
tp
end
function
c2414168
.
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
c2414168
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
Duel
.
SpecialSummonStep
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
then
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetValue
(
ev
)
e1
:
SetReset
(
RESET_EVENT
+
0x1ff0000
)
c
:
RegisterEffect
(
e1
)
Duel
.
SpecialSummonComplete
()
end
end
function
c2414168
.
defcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
local
d
=
a
:
GetBattleTarget
()
e
:
SetLabelObject
(
d
)
return
a
:
IsControler
(
1
-
tp
)
and
d
and
d
:
IsDefensePos
()
and
d
:
IsControler
(
tp
)
and
d
~=
e
:
GetHandler
()
end
function
c44891812
.
defop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
tc
=
e
:
GetLabelObject
()
if
tc
:
IsRelateToBattle
()
and
tc
:
IsFaceup
()
and
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
then
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e1
:
SetValue
(
c
:
GetDefense
())
e1
:
SetReset
(
RESET_PHASE
+
PHASE_DAMAGE
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_INDESTRUCTABLE_BATTLE
)
e2
:
SetValue
(
1
)
e2
:
SetReset
(
RESET_PHASE
+
PHASE_DAMAGE
)
tc
:
RegisterEffect
(
e2
)
end
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