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
bfcf52a3
Commit
bfcf52a3
authored
Dec 29, 2019
by
DailyShana
Committed by
GitHub
Dec 29, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
apply ceil/floor when divided by 2 (#1295)
parent
b223c44b
Changes
158
Hide whitespace changes
Inline
Side-by-side
Showing
158 changed files
with
200 additions
and
200 deletions
+200
-200
c1036974.lua
c1036974.lua
+2
-2
c11264180.lua
c11264180.lua
+2
-2
c13574687.lua
c13574687.lua
+2
-2
c13611090.lua
c13611090.lua
+1
-1
c13647631.lua
c13647631.lua
+2
-2
c14258627.lua
c14258627.lua
+2
-2
c15013468.lua
c15013468.lua
+1
-1
c15552258.lua
c15552258.lua
+1
-1
c16304628.lua
c16304628.lua
+2
-2
c16625614.lua
c16625614.lua
+1
-1
c17132130.lua
c17132130.lua
+1
-1
c18271561.lua
c18271561.lua
+1
-1
c2009101.lua
c2009101.lua
+2
-2
c20281581.lua
c20281581.lua
+1
-1
c20349913.lua
c20349913.lua
+1
-1
c2137678.lua
c2137678.lua
+1
-1
c21435914.lua
c21435914.lua
+3
-3
c2148918.lua
c2148918.lua
+1
-1
c22046459.lua
c22046459.lua
+1
-1
c22359980.lua
c22359980.lua
+1
-1
c23187256.lua
c23187256.lua
+1
-1
c23770284.lua
c23770284.lua
+1
-1
c23792058.lua
c23792058.lua
+2
-2
c2396042.lua
c2396042.lua
+2
-2
c24025620.lua
c24025620.lua
+1
-1
c24673894.lua
c24673894.lua
+2
-2
c24731391.lua
c24731391.lua
+1
-1
c26211048.lua
c26211048.lua
+2
-2
c27352108.lua
c27352108.lua
+1
-1
c27548199.lua
c27548199.lua
+1
-1
c28427869.lua
c28427869.lua
+1
-1
c28429121.lua
c28429121.lua
+1
-1
c28890974.lua
c28890974.lua
+1
-1
c2948263.lua
c2948263.lua
+1
-1
c30086349.lua
c30086349.lua
+1
-1
c31444249.lua
c31444249.lua
+1
-1
c31801517.lua
c31801517.lua
+1
-1
c32446630.lua
c32446630.lua
+1
-1
c32933942.lua
c32933942.lua
+1
-1
c33460840.lua
c33460840.lua
+2
-2
c33537328.lua
c33537328.lua
+1
-1
c34016756.lua
c34016756.lua
+2
-2
c3429238.lua
c3429238.lua
+1
-1
c34487429.lua
c34487429.lua
+1
-1
c35058588.lua
c35058588.lua
+1
-1
c35268887.lua
c35268887.lua
+1
-1
c35842855.lua
c35842855.lua
+1
-1
c36076683.lua
c36076683.lua
+1
-1
c3642509.lua
c3642509.lua
+2
-2
c36956512.lua
c36956512.lua
+2
-2
c3701074.lua
c3701074.lua
+2
-2
c37057012.lua
c37057012.lua
+1
-1
c3897065.lua
c3897065.lua
+1
-1
c39299733.lua
c39299733.lua
+1
-1
c39823987.lua
c39823987.lua
+2
-2
c40473581.lua
c40473581.lua
+1
-1
c40634253.lua
c40634253.lua
+1
-1
c41546.lua
c41546.lua
+1
-1
c42421606.lua
c42421606.lua
+1
-1
c4266839.lua
c4266839.lua
+2
-2
c4290468.lua
c4290468.lua
+2
-2
c43530283.lua
c43530283.lua
+2
-2
c4446672.lua
c4446672.lua
+1
-1
c44505297.lua
c44505297.lua
+2
-2
c45313993.lua
c45313993.lua
+1
-1
c4545683.lua
c4545683.lua
+1
-1
c46195773.lua
c46195773.lua
+1
-1
c46895036.lua
c46895036.lua
+1
-1
c47737087.lua
c47737087.lua
+1
-1
c4820694.lua
c4820694.lua
+1
-1
c49202331.lua
c49202331.lua
+2
-2
c49456901.lua
c49456901.lua
+1
-1
c49678559.lua
c49678559.lua
+2
-2
c50065971.lua
c50065971.lua
+1
-1
c51402177.lua
c51402177.lua
+1
-1
c52977572.lua
c52977572.lua
+1
-1
c53025096.lua
c53025096.lua
+1
-1
c53701457.lua
c53701457.lua
+1
-1
c53950487.lua
c53950487.lua
+1
-1
c53956001.lua
c53956001.lua
+1
-1
c53981499.lua
c53981499.lua
+1
-1
c54569495.lua
c54569495.lua
+1
-1
c55713623.lua
c55713623.lua
+1
-1
c55727845.lua
c55727845.lua
+1
-1
c56339050.lua
c56339050.lua
+2
-2
c56535497.lua
c56535497.lua
+1
-1
c56574543.lua
c56574543.lua
+1
-1
c59042331.lua
c59042331.lua
+1
-1
c59642500.lua
c59642500.lua
+1
-1
c60312997.lua
c60312997.lua
+1
-1
c60953118.lua
c60953118.lua
+1
-1
c61420130.lua
c61420130.lua
+2
-2
c6142213.lua
c6142213.lua
+2
-2
c62070231.lua
c62070231.lua
+1
-1
c62325062.lua
c62325062.lua
+1
-1
c62742651.lua
c62742651.lua
+1
-1
c63364266.lua
c63364266.lua
+1
-1
c63630268.lua
c63630268.lua
+1
-1
c64145892.lua
c64145892.lua
+1
-1
c64238008.lua
c64238008.lua
+1
-1
c65472618.lua
c65472618.lua
+2
-2
c66818682.lua
c66818682.lua
+2
-2
c67508932.lua
c67508932.lua
+1
-1
c67951831.lua
c67951831.lua
+1
-1
c67959180.lua
c67959180.lua
+1
-1
c6799227.lua
c6799227.lua
+1
-1
c68540058.lua
c68540058.lua
+1
-1
c69073023.lua
c69073023.lua
+1
-1
c69931927.lua
c69931927.lua
+1
-1
c71625222.lua
c71625222.lua
+1
-1
c72083436.lua
c72083436.lua
+1
-1
c72283691.lua
c72283691.lua
+2
-2
c72896720.lua
c72896720.lua
+2
-2
c72926163.lua
c72926163.lua
+1
-1
c73048641.lua
c73048641.lua
+1
-1
c74003290.lua
c74003290.lua
+1
-1
c74069667.lua
c74069667.lua
+1
-1
c75249652.lua
c75249652.lua
+1
-1
c75253697.lua
c75253697.lua
+1
-1
c75672051.lua
c75672051.lua
+1
-1
c75902998.lua
c75902998.lua
+2
-2
c76004142.lua
c76004142.lua
+1
-1
c7700132.lua
c7700132.lua
+2
-2
c77625948.lua
c77625948.lua
+1
-1
c7845138.lua
c7845138.lua
+1
-1
c79068663.lua
c79068663.lua
+1
-1
c81332143.lua
c81332143.lua
+1
-1
c81927732.lua
c81927732.lua
+2
-2
c82458280.lua
c82458280.lua
+1
-1
c83866861.lua
c83866861.lua
+1
-1
c83965310.lua
c83965310.lua
+1
-1
c85008676.lua
c85008676.lua
+2
-2
c85121942.lua
c85121942.lua
+1
-1
c85636437.lua
c85636437.lua
+2
-2
c86915847.lua
c86915847.lua
+1
-1
c8763963.lua
c8763963.lua
+1
-1
c89448140.lua
c89448140.lua
+1
-1
c89662736.lua
c89662736.lua
+2
-2
c89743495.lua
c89743495.lua
+1
-1
c89870349.lua
c89870349.lua
+1
-1
c90020065.lua
c90020065.lua
+1
-1
c9161357.lua
c9161357.lua
+2
-2
c92246806.lua
c92246806.lua
+1
-1
c92362073.lua
c92362073.lua
+1
-1
c94156050.lua
c94156050.lua
+1
-1
c94538053.lua
c94538053.lua
+2
-2
c95026693.lua
c95026693.lua
+1
-1
c95090813.lua
c95090813.lua
+1
-1
c95448692.lua
c95448692.lua
+1
-1
c95463814.lua
c95463814.lua
+2
-2
c95685352.lua
c95685352.lua
+1
-1
c95727991.lua
c95727991.lua
+1
-1
c9603356.lua
c9603356.lua
+1
-1
c97342942.lua
c97342942.lua
+1
-1
c981540.lua
c981540.lua
+1
-1
c98637386.lua
c98637386.lua
+1
-1
c99427357.lua
c99427357.lua
+2
-2
c99795159.lua
c99795159.lua
+1
-1
No files found.
c1036974.lua
View file @
bfcf52a3
...
@@ -28,11 +28,11 @@ function c1036974.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -28,11 +28,11 @@ function c1036974.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c1036974
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c1036974
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c1036974
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c1036974
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
g
:
GetFirst
():
GetBaseAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.floor
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
)
)
end
end
function
c1036974
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c1036974
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
if
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
Duel
.
Damage
(
1
-
tp
,
tc
:
GetBaseAttack
()
/
2
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.floor
(
tc
:
GetBaseAttack
()
/
2
)
,
REASON_EFFECT
)
end
end
end
end
c11264180.lua
View file @
bfcf52a3
...
@@ -37,13 +37,13 @@ function c11264180.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -37,13 +37,13 @@ function c11264180.activate(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetValue
(
tc
:
GetDefense
()
/
2
)
e2
:
SetValue
(
math.ceil
(
tc
:
GetDefense
()
/
2
)
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
dg
=
Duel
.
SelectMatchingCard
(
tp
,
c11264180
.
dfilter
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
1
,
1
,
aux
.
ExceptThisCard
(
e
))
local
dg
=
Duel
.
SelectMatchingCard
(
tp
,
c11264180
.
dfilter
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
1
,
1
,
aux
.
ExceptThisCard
(
e
))
...
...
c13574687.lua
View file @
bfcf52a3
...
@@ -24,12 +24,12 @@ function c13574687.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -24,12 +24,12 @@ function c13574687.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c13574687
.
filter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c13574687
.
filter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
g
:
GetFirst
():
GetControler
(),
g
:
GetFirst
():
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
g
:
GetFirst
():
GetControler
(),
math.floor
(
g
:
GetFirst
():
GetAttack
()
/
2
)
)
end
end
function
c13574687
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c13574687
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
and
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
if
tc
and
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
local
dam
=
tc
:
GetAttack
()
/
2
local
dam
=
math.floor
(
tc
:
GetAttack
()
/
2
)
local
p
=
tc
:
GetControler
()
local
p
=
tc
:
GetControler
()
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
Duel
.
Damage
(
p
,
dam
,
REASON_EFFECT
)
Duel
.
Damage
(
p
,
dam
,
REASON_EFFECT
)
...
...
c13611090.lua
View file @
bfcf52a3
...
@@ -52,5 +52,5 @@ function c13611090.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -52,5 +52,5 @@ function c13611090.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
return
ep
~=
tp
end
end
function
c13611090
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c13611090
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c13647631.lua
View file @
bfcf52a3
...
@@ -48,12 +48,12 @@ function c13647631.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -48,12 +48,12 @@ function c13647631.spop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_SET_BASE_DEFENSE
)
e2
:
SetCode
(
EFFECT_SET_BASE_DEFENSE
)
e2
:
SetValue
(
def
/
2
)
e2
:
SetValue
(
math.ceil
(
def
/
2
)
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
Duel
.
SpecialSummonComplete
()
Duel
.
SpecialSummonComplete
()
end
end
...
...
c14258627.lua
View file @
bfcf52a3
...
@@ -55,10 +55,10 @@ function c14258627.adtg(e,c)
...
@@ -55,10 +55,10 @@ function c14258627.adtg(e,c)
return
c
==
e
:
GetHandler
():
GetBattleTarget
()
return
c
==
e
:
GetHandler
():
GetBattleTarget
()
end
end
function
c14258627
.
atkval
(
e
,
c
)
function
c14258627
.
atkval
(
e
,
c
)
return
c
:
GetAttack
()
/
2
return
math.ceil
(
c
:
GetAttack
()
/
2
)
end
end
function
c14258627
.
defval
(
e
,
c
)
function
c14258627
.
defval
(
e
,
c
)
return
c
:
GetDefense
()
/
2
return
math.ceil
(
c
:
GetDefense
()
/
2
)
end
end
function
c14258627
.
mtcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c14258627
.
mtcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetTurnPlayer
()
==
tp
return
Duel
.
GetTurnPlayer
()
==
tp
...
...
c15013468.lua
View file @
bfcf52a3
...
@@ -62,7 +62,7 @@ function c15013468.damcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -62,7 +62,7 @@ function c15013468.damcon(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c15013468
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c15013468
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
dam
=
e
:
GetHandler
():
GetBattleTarget
():
GetBaseAttack
()
/
2
local
dam
=
math.floor
(
e
:
GetHandler
():
GetBattleTarget
():
GetBaseAttack
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
...
...
c15552258.lua
View file @
bfcf52a3
...
@@ -29,7 +29,7 @@ function c15552258.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -29,7 +29,7 @@ function c15552258.activate(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_BATTLE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_BATTLE
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
tc
=
g
:
GetNext
()
tc
=
g
:
GetNext
()
...
...
c16304628.lua
View file @
bfcf52a3
...
@@ -41,7 +41,7 @@ function c16304628.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -41,7 +41,7 @@ function c16304628.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
then
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
then
...
@@ -49,7 +49,7 @@ function c16304628.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -49,7 +49,7 @@ function c16304628.atkop(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e2
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e2
:
SetValue
(
atk
/
2
)
e2
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
...
...
c16625614.lua
View file @
bfcf52a3
...
@@ -42,7 +42,7 @@ function c16625614.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -42,7 +42,7 @@ function c16625614.operation(e,tp,eg,ep,ev,re,r,rp)
local
coin
=
Duel
.
TossCoin
(
tp
,
1
)
local
coin
=
Duel
.
TossCoin
(
tp
,
1
)
if
coin
==
1
then
if
coin
==
1
then
if
Duel
.
NegateAttack
()
then
if
Duel
.
NegateAttack
()
then
Duel
.
Damage
(
1
-
tp
,
math.
ceil
(
tc
:
GetAttack
()
/
2
),
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.
floor
(
tc
:
GetAttack
()
/
2
),
REASON_EFFECT
)
end
end
end
end
end
end
c17132130.lua
View file @
bfcf52a3
...
@@ -97,5 +97,5 @@ function c17132130.lpc(e,tp,eg,ep,ev,re,r,rp)
...
@@ -97,5 +97,5 @@ function c17132130.lpc(e,tp,eg,ep,ev,re,r,rp)
return
tp
~=
Duel
.
GetTurnPlayer
()
return
tp
~=
Duel
.
GetTurnPlayer
()
end
end
function
c17132130
.
lpcop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c17132130
.
lpcop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
SetLP
(
1
-
tp
,
Duel
.
GetLP
(
1
-
tp
)
/
2
)
Duel
.
SetLP
(
1
-
tp
,
math.ceil
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
)
end
end
c18271561.lua
View file @
bfcf52a3
...
@@ -33,7 +33,7 @@ function c18271561.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -33,7 +33,7 @@ function c18271561.operation(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
dg
=
dg
:
Select
(
tp
,
1
,
1
,
nil
)
dg
=
dg
:
Select
(
tp
,
1
,
1
,
nil
)
end
end
local
atk
=
dg
:
GetFirst
():
GetAttack
()
/
2
local
atk
=
math.floor
(
dg
:
GetFirst
():
GetAttack
()
/
2
)
if
Duel
.
Destroy
(
dg
,
REASON_EFFECT
)
>
0
then
if
Duel
.
Destroy
(
dg
,
REASON_EFFECT
)
>
0
then
Duel
.
Damage
(
tp
,
atk
,
REASON_EFFECT
,
true
)
Duel
.
Damage
(
tp
,
atk
,
REASON_EFFECT
,
true
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
,
true
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
,
true
)
...
...
c2009101.lua
View file @
bfcf52a3
...
@@ -41,13 +41,13 @@ function c2009101.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -41,13 +41,13 @@ function c2009101.operation(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetValue
(
tc
:
GetDefense
()
/
2
)
e2
:
SetValue
(
math.ceil
(
tc
:
GetDefense
()
/
2
)
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
end
end
end
end
c20281581.lua
View file @
bfcf52a3
...
@@ -46,7 +46,7 @@ function c20281581.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -46,7 +46,7 @@ function c20281581.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
==
tp
return
ep
==
tp
end
end
function
c20281581
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c20281581
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
tp
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
tp
,
math.floor
(
ev
/
2
)
)
end
end
function
c20281581
.
filter
(
c
)
function
c20281581
.
filter
(
c
)
return
c
:
IsFacedown
()
return
c
:
IsFacedown
()
...
...
c20349913.lua
View file @
bfcf52a3
...
@@ -43,5 +43,5 @@ function c20349913.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -43,5 +43,5 @@ function c20349913.activate(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c20349913
.
damval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
function
c20349913
.
damval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
return
val
/
2
return
math.floor
(
val
/
2
)
end
end
c2137678.lua
View file @
bfcf52a3
...
@@ -38,7 +38,7 @@ function c2137678.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,7 +38,7 @@ function c2137678.operation(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
end
end
c21435914.lua
View file @
bfcf52a3
...
@@ -54,7 +54,7 @@ function c21435914.damtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -54,7 +54,7 @@ function c21435914.damtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
local
g
=
Duel
.
SelectTarget
(
tp
,
aux
.
nzatk
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
aux
.
nzatk
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
atk
=
g
:
GetFirst
():
GetAttack
()
local
atk
=
g
:
GetFirst
():
GetAttack
()
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
atk
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.ceil
(
atk
/
2
)
)
end
end
function
c21435914
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c21435914
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
...
@@ -64,8 +64,8 @@ function c21435914.damop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -64,8 +64,8 @@ function c21435914.damop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
Duel
.
Damage
(
1
-
tp
,
atk
/
2
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.ceil
(
atk
/
2
)
,
REASON_EFFECT
)
end
end
end
end
c2148918.lua
View file @
bfcf52a3
...
@@ -38,7 +38,7 @@ function c2148918.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,7 +38,7 @@ function c2148918.spop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
tc
=
g
:
GetNext
()
tc
=
g
:
GetNext
()
...
...
c22046459.lua
View file @
bfcf52a3
...
@@ -45,6 +45,6 @@ function c22046459.value(e,c)
...
@@ -45,6 +45,6 @@ function c22046459.value(e,c)
if
Duel
.
GetLP
(
p
)
<
Duel
.
GetLP
(
1
-
p
)
then
if
Duel
.
GetLP
(
p
)
<
Duel
.
GetLP
(
1
-
p
)
then
return
c
:
GetBaseAttack
()
*
2
return
c
:
GetBaseAttack
()
*
2
elseif
Duel
.
GetLP
(
p
)
>
Duel
.
GetLP
(
1
-
p
)
then
elseif
Duel
.
GetLP
(
p
)
>
Duel
.
GetLP
(
1
-
p
)
then
return
c
:
GetBaseAttack
()
/
2
return
math.ceil
(
c
:
GetBaseAttack
()
/
2
)
end
end
end
end
c22359980.lua
View file @
bfcf52a3
...
@@ -62,7 +62,7 @@ function c22359980.atktg(e,c)
...
@@ -62,7 +62,7 @@ function c22359980.atktg(e,c)
return
c
:
GetFlagEffect
(
22359980
)
~=
0
and
e
:
GetLabelObject
():
IsContains
(
c
)
return
c
:
GetFlagEffect
(
22359980
)
~=
0
and
e
:
GetLabelObject
():
IsContains
(
c
)
end
end
function
c22359980
.
atkval
(
e
,
c
)
function
c22359980
.
atkval
(
e
,
c
)
return
c
:
GetAttack
()
/
2
return
math.ceil
(
c
:
GetAttack
()
/
2
)
end
end
function
c22359980
.
mtcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c22359980
.
mtcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetTurnPlayer
()
==
tp
return
Duel
.
GetTurnPlayer
()
==
tp
...
...
c23187256.lua
View file @
bfcf52a3
...
@@ -94,7 +94,7 @@ function c23187256.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -94,7 +94,7 @@ function c23187256.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c23187256
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c23187256
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
function
c23187256
.
indfilter
(
c
)
function
c23187256
.
indfilter
(
c
)
...
...
c23770284.lua
View file @
bfcf52a3
...
@@ -49,7 +49,7 @@ function c23770284.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -49,7 +49,7 @@ function c23770284.operation(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
...
...
c23792058.lua
View file @
bfcf52a3
...
@@ -48,8 +48,8 @@ function c23792058.tdop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -48,8 +48,8 @@ function c23792058.tdop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c23792058
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c23792058
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
math.
ceil
(
ev
/
2
),
false
)
Duel
.
ChangeBattleDamage
(
ep
,
math.
floor
(
ev
/
2
),
false
)
Duel
.
ChangeBattleDamage
(
1
-
ep
,
math.
ceil
(
ev
/
2
),
false
)
Duel
.
ChangeBattleDamage
(
1
-
ep
,
math.
floor
(
ev
/
2
),
false
)
end
end
function
c23792058
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c23792058
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_PZONE
)
return
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_PZONE
)
...
...
c2396042.lua
View file @
bfcf52a3
...
@@ -22,12 +22,12 @@ function c2396042.adop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -22,12 +22,12 @@ function c2396042.adop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e1
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e1
:
SetValue
(
c
:
GetDefense
()
/
2
)
e1
:
SetValue
(
math.ceil
(
c
:
GetDefense
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
+
RESET_PHASE
+
PHASE_DAMAGE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
+
RESET_PHASE
+
PHASE_DAMAGE
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e2
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e2
:
SetValue
(
c
:
GetAttack
()
/
2
)
e2
:
SetValue
(
math.ceil
(
c
:
GetAttack
()
/
2
)
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
end
end
c24025620.lua
View file @
bfcf52a3
...
@@ -27,7 +27,7 @@ function c24025620.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -27,7 +27,7 @@ function c24025620.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
...
...
c24673894.lua
View file @
bfcf52a3
...
@@ -31,7 +31,7 @@ function c24673894.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -31,7 +31,7 @@ function c24673894.activate(e,tp,eg,ep,ev,re,r,rp)
Duel
.
BreakEffect
()
Duel
.
BreakEffect
()
local
val
=
tc
:
GetAttack
()
/
2
local
val
=
tc
:
GetAttack
()
/
2
local
op
=
Duel
.
SelectOption
(
1
-
tp
,
aux
.
Stringid
(
24673894
,
0
),
aux
.
Stringid
(
24673894
,
1
))
local
op
=
Duel
.
SelectOption
(
1
-
tp
,
aux
.
Stringid
(
24673894
,
0
),
aux
.
Stringid
(
24673894
,
1
))
if
op
==
0
then
Duel
.
Recover
(
1
-
tp
,
val
,
REASON_EFFECT
)
if
op
==
0
then
Duel
.
Recover
(
1
-
tp
,
math.ceil
(
val
)
,
REASON_EFFECT
)
else
Duel
.
Damage
(
tp
,
val
,
REASON_EFFECT
)
end
else
Duel
.
Damage
(
tp
,
math.floor
(
val
)
,
REASON_EFFECT
)
end
end
end
end
end
c24731391.lua
View file @
bfcf52a3
...
@@ -49,7 +49,7 @@ function c24731391.initial_effect(c)
...
@@ -49,7 +49,7 @@ function c24731391.initial_effect(c)
c
:
RegisterEffect
(
e5
)
c
:
RegisterEffect
(
e5
)
end
end
function
c24731391
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c24731391
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
return
dam
/
2
return
math.floor
(
dam
/
2
)
end
end
function
c24731391
.
filter
(
c
)
function
c24731391
.
filter
(
c
)
return
c
:
IsType
(
TYPE_LINK
)
return
c
:
IsType
(
TYPE_LINK
)
...
...
c26211048.lua
View file @
bfcf52a3
...
@@ -50,7 +50,7 @@ function c26211048.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -50,7 +50,7 @@ function c26211048.eqop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetValue
(
c26211048
.
eqlimit
)
e1
:
SetValue
(
c26211048
.
eqlimit
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
if
tc
:
IsFaceup
()
then
if
tc
:
IsFaceup
()
then
local
atk
=
tc
:
GetTextAttack
()
/
2
local
atk
=
math.ceil
(
tc
:
GetTextAttack
()
/
2
)
if
atk
<
0
then
atk
=
0
end
if
atk
<
0
then
atk
=
0
end
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_EQUIP
)
e2
:
SetType
(
EFFECT_TYPE_EQUIP
)
...
@@ -58,7 +58,7 @@ function c26211048.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -58,7 +58,7 @@ function c26211048.eqop(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetValue
(
atk
)
e2
:
SetValue
(
atk
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
local
def
=
tc
:
GetTextDefense
()
/
2
local
def
=
math.ceil
(
tc
:
GetTextDefense
()
/
2
)
if
def
<
0
then
def
=
0
end
if
def
<
0
then
def
=
0
end
local
e3
=
Effect
.
CreateEffect
(
c
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_EQUIP
)
e3
:
SetType
(
EFFECT_TYPE_EQUIP
)
...
...
c27352108.lua
View file @
bfcf52a3
...
@@ -54,7 +54,7 @@ function c27352108.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -54,7 +54,7 @@ function c27352108.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
==
tp
return
ep
==
tp
end
end
function
c27352108
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c27352108
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
function
c27352108
.
thcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c27352108
.
thcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
...
...
c27548199.lua
View file @
bfcf52a3
...
@@ -69,7 +69,7 @@ function c27548199.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -69,7 +69,7 @@ function c27548199.eqop(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetProperty
(
EFFECT_FLAG_OWNER_RELATE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e2
:
SetProperty
(
EFFECT_FLAG_OWNER_RELATE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetValue
(
atk
/
2
)
e2
:
SetValue
(
math.ceil
(
atk
/
2
)
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
end
end
end
end
...
...
c28427869.lua
View file @
bfcf52a3
...
@@ -49,7 +49,7 @@ function c28427869.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -49,7 +49,7 @@ function c28427869.spop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c28427869
.
halfop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c28427869
.
halfop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
tp
,
math.
ceil
(
ev
/
2
))
Duel
.
ChangeBattleDamage
(
tp
,
math.
floor
(
ev
/
2
))
end
end
function
c28427869
.
skipop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c28427869
.
skipop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
SkipPhase
(
1
-
tp
,
PHASE_BATTLE
,
RESET_PHASE
+
PHASE_BATTLE_STEP
,
1
)
Duel
.
SkipPhase
(
1
-
tp
,
PHASE_BATTLE
,
RESET_PHASE
+
PHASE_BATTLE_STEP
,
1
)
...
...
c28429121.lua
View file @
bfcf52a3
...
@@ -62,7 +62,7 @@ function c28429121.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -62,7 +62,7 @@ function c28429121.activate(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
-
RESET_TOFIELD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
-
RESET_TOFIELD
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
Duel
.
SpecialSummon
(
tc
,
SUMMON_TYPE_RITUAL
,
tp
,
tp
,
false
,
true
,
POS_FACEUP
)
Duel
.
SpecialSummon
(
tc
,
SUMMON_TYPE_RITUAL
,
tp
,
tp
,
false
,
true
,
POS_FACEUP
)
...
...
c28890974.lua
View file @
bfcf52a3
...
@@ -29,7 +29,7 @@ function c28890974.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -29,7 +29,7 @@ function c28890974.activate(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
,
true
)
tc
:
RegisterEffect
(
e1
,
true
)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
...
...
c2948263.lua
View file @
bfcf52a3
...
@@ -64,7 +64,7 @@ function c2948263.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -64,7 +64,7 @@ function c2948263.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
return
ep
~=
tp
end
end
function
c2948263
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c2948263
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
function
c2948263
.
discon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c2948263
.
discon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tgp
,
loc
=
Duel
.
GetChainInfo
(
ev
,
CHAININFO_TRIGGERING_CONTROLER
,
CHAININFO_TRIGGERING_LOCATION
)
local
tgp
,
loc
=
Duel
.
GetChainInfo
(
ev
,
CHAININFO_TRIGGERING_CONTROLER
,
CHAININFO_TRIGGERING_LOCATION
)
...
...
c30086349.lua
View file @
bfcf52a3
...
@@ -48,7 +48,7 @@ function c30086349.damop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -48,7 +48,7 @@ function c30086349.damop(e,tp,eg,ep,ev,re,r,rp)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c30086349
.
damfilter
,
tp
,
LOCATION_HAND
+
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c30086349
.
damfilter
,
tp
,
LOCATION_HAND
+
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
local
tc
=
g
:
GetFirst
()
local
tc
=
g
:
GetFirst
()
if
g
:
GetCount
()
>
0
and
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
~=
0
and
tc
:
IsLocation
(
LOCATION_GRAVE
)
then
if
g
:
GetCount
()
>
0
and
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
~=
0
and
tc
:
IsLocation
(
LOCATION_GRAVE
)
then
Duel
.
Damage
(
1
-
tp
,
math.
ceil
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
),
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.
floor
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
),
REASON_EFFECT
)
end
end
end
end
function
c30086349
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c30086349
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
c31444249.lua
View file @
bfcf52a3
...
@@ -40,7 +40,7 @@ function c31444249.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -40,7 +40,7 @@ function c31444249.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
and
ac
:
IsControler
(
tp
)
and
ac
:
IsSetCard
(
0xbb
)
and
ac
:
GetOriginalLevel
()
>=
2
and
not
ac
:
IsImmuneToEffect
(
e
)
return
ep
~=
tp
and
ac
:
IsControler
(
tp
)
and
ac
:
IsSetCard
(
0xbb
)
and
ac
:
GetOriginalLevel
()
>=
2
and
not
ac
:
IsImmuneToEffect
(
e
)
end
end
function
c31444249
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c31444249
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
function
c31444249
.
spcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c31444249
.
spcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
IsAbleToGraveAsCost
()
end
if
chk
==
0
then
return
e
:
GetHandler
():
IsAbleToGraveAsCost
()
end
...
...
c31801517.lua
View file @
bfcf52a3
...
@@ -102,5 +102,5 @@ function c31801517.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -102,5 +102,5 @@ function c31801517.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
and
not
e
:
GetHandler
():
GetOverlayGroup
():
IsExists
(
Card
.
IsCode
,
1
,
nil
,
93717133
)
return
ep
~=
tp
and
not
e
:
GetHandler
():
GetOverlayGroup
():
IsExists
(
Card
.
IsCode
,
1
,
nil
,
93717133
)
end
end
function
c31801517
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c31801517
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c32446630.lua
View file @
bfcf52a3
...
@@ -50,7 +50,7 @@ function c32446630.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -50,7 +50,7 @@ function c32446630.operation(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetValue
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
e1
:
SetValue
(
math.ceil
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
token
:
RegisterEffect
(
e1
)
token
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
local
e2
=
e1
:
Clone
()
...
...
c32933942.lua
View file @
bfcf52a3
...
@@ -42,5 +42,5 @@ function c32933942.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -42,5 +42,5 @@ function c32933942.rdcon(e,tp,eg,ep,ev,re,r,rp)
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
end
end
function
c32933942
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c32933942
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c33460840.lua
View file @
bfcf52a3
...
@@ -38,8 +38,8 @@ function c33460840.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,8 +38,8 @@ function c33460840.eqop(e,tp,eg,ep,ev,re,r,rp)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
aux
.
NecroValleyFilter
(
c33460840
.
filter
),
tp
,
LOCATION_HAND
+
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
,
c
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
aux
.
NecroValleyFilter
(
c33460840
.
filter
),
tp
,
LOCATION_HAND
+
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
,
c
)
local
tc
=
g
:
GetFirst
()
local
tc
=
g
:
GetFirst
()
if
not
(
tc
and
Duel
.
Equip
(
tp
,
tc
,
c
))
then
return
end
if
not
(
tc
and
Duel
.
Equip
(
tp
,
tc
,
c
))
then
return
end
local
atk
=
tc
:
GetTextAttack
()
/
2
local
atk
=
math.ceil
(
tc
:
GetTextAttack
()
/
2
)
local
def
=
tc
:
GetTextDefense
()
/
2
local
def
=
math.ceil
(
tc
:
GetTextDefense
()
/
2
)
if
atk
<
0
then
atk
=
0
end
if
atk
<
0
then
atk
=
0
end
if
def
<
0
then
def
=
0
end
if
def
<
0
then
def
=
0
end
--Add Equip limit
--Add Equip limit
...
...
c33537328.lua
View file @
bfcf52a3
...
@@ -41,7 +41,7 @@ function c33537328.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -41,7 +41,7 @@ function c33537328.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
if
Duel
.
SelectEffectYesNo
(
tp
,
c
,
96
)
then
if
Duel
.
SelectEffectYesNo
(
tp
,
c
,
96
)
then
local
g
=
Duel
.
SelectReleaseGroup
(
tp
,
Card
.
IsReleasableByEffect
,
1
,
1
,
c
)
local
g
=
Duel
.
SelectReleaseGroup
(
tp
,
Card
.
IsReleasableByEffect
,
1
,
1
,
c
)
Duel
.
Release
(
g
,
REASON_EFFECT
)
Duel
.
Release
(
g
,
REASON_EFFECT
)
Duel
.
SetLP
(
1
-
tp
,
Duel
.
GetLP
(
1
-
tp
)
/
2
)
Duel
.
SetLP
(
1
-
tp
,
math.ceil
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
)
return
true
return
true
else
return
false
end
else
return
false
end
end
end
c34016756.lua
View file @
bfcf52a3
...
@@ -30,13 +30,13 @@ function c34016756.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -30,13 +30,13 @@ function c34016756.activate(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
if
hc
:
RegisterEffect
(
e1
)
then
if
hc
:
RegisterEffect
(
e1
)
then
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e2
:
SetValue
(
atk
/
2
)
e2
:
SetValue
(
math.ceil
(
atk
/
2
)
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
end
end
end
end
...
...
c3429238.lua
View file @
bfcf52a3
...
@@ -52,7 +52,7 @@ function c3429238.datop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -52,7 +52,7 @@ function c3429238.datop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
c
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
c
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
...
...
c34487429.lua
View file @
bfcf52a3
...
@@ -132,7 +132,7 @@ function c34487429.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -132,7 +132,7 @@ function c34487429.rdcon(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c34487429
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c34487429
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
Duel
.
SelectEffectYesNo
(
tp
,
e
:
GetHandler
())
then
if
Duel
.
SelectEffectYesNo
(
tp
,
e
:
GetHandler
())
then
Duel
.
ChangeBattleDamage
(
tp
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
tp
,
math.floor
(
ev
/
2
)
)
e
:
GetHandler
():
RegisterFlagEffect
(
34487429
,
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
,
0
,
1
)
e
:
GetHandler
():
RegisterFlagEffect
(
34487429
,
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
,
0
,
1
)
end
end
end
end
c35058588.lua
View file @
bfcf52a3
...
@@ -51,7 +51,7 @@ function c35058588.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -51,7 +51,7 @@ function c35058588.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e2
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e2
:
SetValue
(
hc
:
GetAttack
()
/
2
)
e2
:
SetValue
(
math.ceil
(
hc
:
GetAttack
()
/
2
)
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
hc
:
RegisterEffect
(
e2
)
hc
:
RegisterEffect
(
e2
)
end
end
...
...
c35268887.lua
View file @
bfcf52a3
...
@@ -52,7 +52,7 @@ function c35268887.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -52,7 +52,7 @@ function c35268887.activate(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c35268887
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c35268887
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_EFFECT
)
~=
0
then
if
bit
.
band
(
r
,
REASON_EFFECT
)
~=
0
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
function
c35268887
.
tokentg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c35268887
.
tokentg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
...
...
c35842855.lua
View file @
bfcf52a3
...
@@ -50,7 +50,7 @@ end
...
@@ -50,7 +50,7 @@ end
function
c35842855
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c35842855
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
==
1
then
if
tc
:
IsRelateToEffect
(
e
)
and
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
==
1
then
local
atk
=
tc
:
GetTextAttack
()
/
2
local
atk
=
math.floor
(
tc
:
GetTextAttack
()
/
2
)
if
atk
>
0
then
if
atk
>
0
then
Duel
.
Damage
(
tp
,
atk
,
REASON_EFFECT
,
true
)
Duel
.
Damage
(
tp
,
atk
,
REASON_EFFECT
,
true
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
,
true
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
,
true
)
...
...
c36076683.lua
View file @
bfcf52a3
...
@@ -48,6 +48,6 @@ function c36076683.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -48,6 +48,6 @@ function c36076683.atkop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c36076683
.
damval
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c36076683
.
damval
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
and
rc
==
e
:
GetHandler
()
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
and
rc
==
e
:
GetHandler
()
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
c3642509.lua
View file @
bfcf52a3
...
@@ -34,13 +34,13 @@ function c3642509.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -34,13 +34,13 @@ function c3642509.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetValue
(
def
/
2
)
e2
:
SetValue
(
math.ceil
(
def
/
2
)
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
tc
=
tg
:
GetNext
()
tc
=
tg
:
GetNext
()
...
...
c36956512.lua
View file @
bfcf52a3
...
@@ -77,13 +77,13 @@ function c36956512.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -77,13 +77,13 @@ function c36956512.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetValue
(
def
/
2
)
e2
:
SetValue
(
math.ceil
(
def
/
2
)
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
tc
=
tg
:
GetNext
()
tc
=
tg
:
GetNext
()
...
...
c3701074.lua
View file @
bfcf52a3
...
@@ -36,7 +36,7 @@ function c3701074.recop1(e,tp,eg,ep,ev,re,r,rp)
...
@@ -36,7 +36,7 @@ function c3701074.recop1(e,tp,eg,ep,ev,re,r,rp)
if
not
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
return
end
if
not
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
return
end
local
tc
=
eg
:
GetFirst
()
local
tc
=
eg
:
GetFirst
()
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
local
rec
=
tc
:
GetAttack
()
/
2
local
rec
=
math.ceil
(
tc
:
GetAttack
()
/
2
)
Duel
.
Recover
(
1
-
tp
,
rec
,
REASON_EFFECT
)
Duel
.
Recover
(
1
-
tp
,
rec
,
REASON_EFFECT
)
end
end
end
end
...
@@ -57,6 +57,6 @@ function c3701074.recop2(e,tp,eg,ep,ev,re,r,rp)
...
@@ -57,6 +57,6 @@ function c3701074.recop2(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TARGET
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TARGET
)
g
=
g
:
Select
(
tp
,
1
,
1
,
nil
)
g
=
g
:
Select
(
tp
,
1
,
1
,
nil
)
end
end
Duel
.
Recover
(
1
-
tp
,
g
:
GetFirst
():
GetAttack
()
/
2
,
REASON_EFFECT
)
Duel
.
Recover
(
1
-
tp
,
math.ceil
(
g
:
GetFirst
():
GetAttack
()
/
2
)
,
REASON_EFFECT
)
end
end
end
end
c37057012.lua
View file @
bfcf52a3
...
@@ -18,5 +18,5 @@ function c37057012.atkcon(e)
...
@@ -18,5 +18,5 @@ function c37057012.atkcon(e)
and
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
and
Duel
.
GetAttackTarget
()
~=
nil
and
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
and
Duel
.
GetAttackTarget
()
~=
nil
end
end
function
c37057012
.
atkval
(
e
,
c
)
function
c37057012
.
atkval
(
e
,
c
)
return
Duel
.
GetAttackTarget
():
GetAttack
()
/
2
return
math.ceil
(
Duel
.
GetAttackTarget
():
GetAttack
()
/
2
)
end
end
c3897065.lua
View file @
bfcf52a3
...
@@ -80,6 +80,6 @@ function c3897065.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -80,6 +80,6 @@ function c3897065.atkop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_DAMAGE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_DAMAGE
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
c39299733.lua
View file @
bfcf52a3
...
@@ -93,7 +93,7 @@ function c39299733.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -93,7 +93,7 @@ function c39299733.rdcon(e,tp,eg,ep,ev,re,r,rp)
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
end
end
function
c39299733
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c39299733
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
function
c39299733
.
eqlimit
(
e
,
c
)
function
c39299733
.
eqlimit
(
e
,
c
)
return
c
:
IsRace
(
RACE_FAIRY
)
or
e
:
GetHandler
():
GetEquipTarget
()
==
c
return
c
:
IsRace
(
RACE_FAIRY
)
or
e
:
GetHandler
():
GetEquipTarget
()
==
c
...
...
c39823987.lua
View file @
bfcf52a3
...
@@ -30,13 +30,13 @@ function c39823987.destg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -30,13 +30,13 @@ function c39823987.destg(e,tp,eg,ep,ev,re,r,rp,chk)
local
tc
=
e
:
GetHandler
():
GetReasonCard
()
local
tc
=
e
:
GetHandler
():
GetReasonCard
()
if
tc
:
IsRelateToBattle
()
then
if
tc
:
IsRelateToBattle
()
then
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
tc
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
tc
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
tc
:
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.floor
(
tc
:
GetAttack
()
/
2
)
)
end
end
end
end
function
c39823987
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c39823987
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
e
:
GetHandler
():
GetReasonCard
()
local
tc
=
e
:
GetHandler
():
GetReasonCard
()
if
not
tc
:
IsRelateToBattle
()
then
return
end
if
not
tc
:
IsRelateToBattle
()
then
return
end
local
atk
=
tc
:
GetAttack
()
/
2
local
atk
=
math.floor
(
tc
:
GetAttack
()
/
2
)
if
atk
<
0
then
atk
=
0
end
if
atk
<
0
then
atk
=
0
end
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
...
...
c40473581.lua
View file @
bfcf52a3
...
@@ -23,5 +23,5 @@ function c40473581.dcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -23,5 +23,5 @@ function c40473581.dcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
and
(
c
==
Duel
.
GetAttacker
()
or
c
==
Duel
.
GetAttackTarget
())
return
ep
~=
tp
and
(
c
==
Duel
.
GetAttacker
()
or
c
==
Duel
.
GetAttackTarget
())
end
end
function
c40473581
.
dop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c40473581
.
dop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c40634253.lua
View file @
bfcf52a3
...
@@ -80,6 +80,6 @@ function c40634253.damop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -80,6 +80,6 @@ function c40634253.damop(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TARGET
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TARGET
)
g
=
g
:
Select
(
tp
,
1
,
1
,
nil
)
g
=
g
:
Select
(
tp
,
1
,
1
,
nil
)
end
end
Duel
.
Damage
(
1
-
tp
,
math.
ceil
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
),
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.
floor
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
),
REASON_EFFECT
)
end
end
end
end
c41546.lua
View file @
bfcf52a3
...
@@ -89,6 +89,6 @@ function c41546.desop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -89,6 +89,6 @@ function c41546.desop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c41546
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c41546
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
return
math.
ceil
(
dam
/
2
)
return
math.
floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
c42421606.lua
View file @
bfcf52a3
...
@@ -32,7 +32,7 @@ end
...
@@ -32,7 +32,7 @@ end
function
c42421606
.
efop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c42421606
.
efop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
dc
=
Duel
.
TossDice
(
tp
,
1
)
local
dc
=
Duel
.
TossDice
(
tp
,
1
)
if
dc
==
1
then
if
dc
==
1
then
Duel
.
SetLP
(
tp
,
Duel
.
GetLP
(
tp
)
/
2
)
Duel
.
SetLP
(
tp
,
math.ceil
(
Duel
.
GetLP
(
tp
)
/
2
)
)
elseif
dc
==
2
then
elseif
dc
==
2
then
Duel
.
Draw
(
tp
,
1
,
REASON_EFFECT
)
Duel
.
Draw
(
tp
,
1
,
REASON_EFFECT
)
elseif
dc
==
3
then
elseif
dc
==
3
then
...
...
c4266839.lua
View file @
bfcf52a3
...
@@ -52,7 +52,7 @@ end
...
@@ -52,7 +52,7 @@ end
function
c4266839
.
retg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c4266839
.
retg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
ec
=
e
:
GetHandler
():
GetEquipTarget
()
local
ec
=
e
:
GetHandler
():
GetEquipTarget
()
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
ec
:
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
math.ceil
(
ec
:
GetAttack
()
/
2
)
)
end
end
function
c4266839
.
reop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c4266839
.
reop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
...
@@ -60,6 +60,6 @@ function c4266839.reop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -60,6 +60,6 @@ function c4266839.reop(e,tp,eg,ep,ev,re,r,rp)
local
ec
=
c
:
GetEquipTarget
()
local
ec
=
c
:
GetEquipTarget
()
if
ec
then
if
ec
then
local
atk
=
ec
:
GetAttack
()
local
atk
=
ec
:
GetAttack
()
Duel
.
Recover
(
tp
,
atk
/
2
,
REASON_EFFECT
)
Duel
.
Recover
(
tp
,
math.ceil
(
atk
/
2
)
,
REASON_EFFECT
)
end
end
end
end
c4290468.lua
View file @
bfcf52a3
...
@@ -49,7 +49,7 @@ function c4290468.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -49,7 +49,7 @@ function c4290468.atkop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
function
c4290468
.
dacon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c4290468
.
dacon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
@@ -70,7 +70,7 @@ function c4290468.daop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -70,7 +70,7 @@ function c4290468.daop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
c
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
c
:
GetAttack
()
/
2
)
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
...
...
c43530283.lua
View file @
bfcf52a3
...
@@ -36,13 +36,13 @@ function c43530283.atkval(e,c)
...
@@ -36,13 +36,13 @@ function c43530283.atkval(e,c)
if
c
:
GetFlagEffect
(
43530283
)
==
0
then
if
c
:
GetFlagEffect
(
43530283
)
==
0
then
return
c
:
GetBaseAttack
()
*
2
return
c
:
GetBaseAttack
()
*
2
else
else
return
c
:
GetBaseAttack
()
/
2
return
math.ceil
(
c
:
GetBaseAttack
()
/
2
)
end
end
end
end
function
c43530283
.
defval
(
e
,
c
)
function
c43530283
.
defval
(
e
,
c
)
if
c
:
GetFlagEffect
(
43530283
)
==
0
then
if
c
:
GetFlagEffect
(
43530283
)
==
0
then
return
c
:
GetBaseDefense
()
*
2
return
c
:
GetBaseDefense
()
*
2
else
else
return
c
:
GetBaseDefense
()
/
2
return
math.ceil
(
c
:
GetBaseDefense
()
/
2
)
end
end
end
end
c4446672.lua
View file @
bfcf52a3
...
@@ -25,7 +25,7 @@ function c4446672.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -25,7 +25,7 @@ function c4446672.activate(e,tp,eg,ep,ev,re,r,rp)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
then
if
tc
:
IsRelateToEffect
(
e
)
then
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
>
0
then
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
>
0
then
Duel
.
Damage
(
1
-
tp
,
tc
:
GetBaseAttack
()
/
2
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.floor
(
tc
:
GetBaseAttack
()
/
2
)
,
REASON_EFFECT
)
end
end
end
end
end
end
c44505297.lua
View file @
bfcf52a3
...
@@ -54,7 +54,7 @@ function c44505297.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -54,7 +54,7 @@ function c44505297.eqop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetValue
(
c44505297
.
eqlimit
)
e1
:
SetValue
(
c44505297
.
eqlimit
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
atk
=
tc
:
GetTextAttack
()
/
2
local
atk
=
math.ceil
(
tc
:
GetTextAttack
()
/
2
)
if
atk
<
0
then
atk
=
0
end
if
atk
<
0
then
atk
=
0
end
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_EQUIP
)
e2
:
SetType
(
EFFECT_TYPE_EQUIP
)
...
@@ -62,7 +62,7 @@ function c44505297.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -62,7 +62,7 @@ function c44505297.eqop(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetValue
(
atk
)
e2
:
SetValue
(
atk
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
local
def
=
tc
:
GetTextDefense
()
/
2
local
def
=
math.ceil
(
tc
:
GetTextDefense
()
/
2
)
if
def
<
0
then
def
=
0
end
if
def
<
0
then
def
=
0
end
local
e3
=
Effect
.
CreateEffect
(
c
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_EQUIP
)
e3
:
SetType
(
EFFECT_TYPE_EQUIP
)
...
...
c45313993.lua
View file @
bfcf52a3
...
@@ -29,7 +29,7 @@ function c45313993.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -29,7 +29,7 @@ function c45313993.spop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
c
:
RegisterEffect
(
e1
,
true
)
c
:
RegisterEffect
(
e1
,
true
)
Duel
.
SpecialSummonComplete
()
Duel
.
SpecialSummonComplete
()
...
...
c4545683.lua
View file @
bfcf52a3
...
@@ -72,7 +72,7 @@ function c4545683.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -72,7 +72,7 @@ function c4545683.spop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c4545683
.
val
(
e
,
c
)
function
c4545683
.
val
(
e
,
c
)
return
Duel
.
GetLP
(
c
:
GetControler
())
/
2
return
math.ceil
(
Duel
.
GetLP
(
c
:
GetControler
())
/
2
)
end
end
function
c4545683
.
eqfilter
(
c
)
function
c4545683
.
eqfilter
(
c
)
return
c
:
IsFaceup
()
and
c
:
IsType
(
TYPE_SYNCHRO
)
and
c
:
IsAbleToChangeControler
()
return
c
:
IsFaceup
()
and
c
:
IsType
(
TYPE_SYNCHRO
)
and
c
:
IsAbleToChangeControler
()
...
...
c46195773.lua
View file @
bfcf52a3
...
@@ -41,7 +41,7 @@ function c46195773.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -41,7 +41,7 @@ function c46195773.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
d
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
d
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_DAMAGE
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_DAMAGE
)
d
:
RegisterEffect
(
e1
)
d
:
RegisterEffect
(
e1
)
end
end
...
...
c46895036.lua
View file @
bfcf52a3
...
@@ -63,7 +63,7 @@ function c46895036.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -63,7 +63,7 @@ function c46895036.operation(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
end
end
...
...
c47737087.lua
View file @
bfcf52a3
...
@@ -46,5 +46,5 @@ function c47737087.atkcon(e)
...
@@ -46,5 +46,5 @@ function c47737087.atkcon(e)
return
c
:
IsDefensePos
()
and
c
==
Duel
.
GetAttacker
()
and
Duel
.
GetAttackTarget
()
==
nil
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
==
1
return
c
:
IsDefensePos
()
and
c
==
Duel
.
GetAttacker
()
and
Duel
.
GetAttackTarget
()
==
nil
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
==
1
end
end
function
c47737087
.
atkval
(
e
,
c
)
function
c47737087
.
atkval
(
e
,
c
)
return
c
:
GetAttack
()
/
2
return
math.ceil
(
c
:
GetAttack
()
/
2
)
end
end
c4820694.lua
View file @
bfcf52a3
...
@@ -52,7 +52,7 @@ function c4820694.lpop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -52,7 +52,7 @@ function c4820694.lpop(e,tp,eg,ep,ev,re,r,rp)
local
og2
=
tc2
:
GetOverlayGroup
()
local
og2
=
tc2
:
GetOverlayGroup
()
og1
:
Merge
(
og2
)
og1
:
Merge
(
og2
)
if
Duel
.
SendtoGrave
(
og1
,
REASON_EFFECT
)
<
og1
:
GetCount
()
then
return
end
if
Duel
.
SendtoGrave
(
og1
,
REASON_EFFECT
)
<
og1
:
GetCount
()
then
return
end
Duel
.
SetLP
(
1
-
tp
,
Duel
.
GetLP
(
1
-
tp
)
/
2
)
Duel
.
SetLP
(
1
-
tp
,
math.ceil
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
)
end
end
end
end
function
c4820694
.
tgfilter
(
c
)
function
c4820694
.
tgfilter
(
c
)
...
...
c49202331.lua
View file @
bfcf52a3
...
@@ -29,7 +29,7 @@ function c49202331.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -29,7 +29,7 @@ function c49202331.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
bc
=
e
:
GetHandler
():
GetBattleTarget
()
local
bc
=
e
:
GetHandler
():
GetBattleTarget
()
Duel
.
SetTargetCard
(
bc
)
Duel
.
SetTargetCard
(
bc
)
local
dam
=
bc
:
GetAttack
()
/
2
local
dam
=
math.floor
(
bc
:
GetAttack
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
...
@@ -39,7 +39,7 @@ function c49202331.damop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -39,7 +39,7 @@ function c49202331.damop(e,tp,eg,ep,ev,re,r,rp)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
then
if
tc
:
IsRelateToEffect
(
e
)
then
local
p
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
)
local
p
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
)
local
dam
=
tc
:
GetAttack
()
/
2
local
dam
=
math.floor
(
tc
:
GetAttack
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
Damage
(
p
,
dam
,
REASON_EFFECT
)
Duel
.
Damage
(
p
,
dam
,
REASON_EFFECT
)
end
end
...
...
c49456901.lua
View file @
bfcf52a3
...
@@ -64,6 +64,6 @@ function c49456901.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -64,6 +64,6 @@ function c49456901.operation(e,tp,eg,ep,ev,re,r,rp)
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
49456901
,
2
))
then
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
49456901
,
2
))
then
local
g
=
Duel
.
GetFieldGroup
(
1
-
tp
,
LOCATION_HAND
,
0
):
RandomSelect
(
1
-
tp
,
1
)
local
g
=
Duel
.
GetFieldGroup
(
1
-
tp
,
LOCATION_HAND
,
0
):
RandomSelect
(
1
-
tp
,
1
)
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
Duel
.
SetLP
(
1
-
tp
,
Duel
.
GetLP
(
1
-
tp
)
/
2
)
Duel
.
SetLP
(
1
-
tp
,
math.ceil
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
)
end
end
end
end
c49678559.lua
View file @
bfcf52a3
...
@@ -46,7 +46,7 @@ function c49678559.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -46,7 +46,7 @@ function c49678559.operation(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
...
@@ -80,6 +80,6 @@ function c49678559.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -80,6 +80,6 @@ function c49678559.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function
c49678559
.
damval
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c49678559
.
damval
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
c50065971.lua
View file @
bfcf52a3
...
@@ -48,7 +48,7 @@ function c50065971.dirop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -48,7 +48,7 @@ function c50065971.dirop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_BASE_DEFENSE
)
e1
:
SetCode
(
EFFECT_SET_BASE_DEFENSE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
c
:
GetBaseDefense
()
/
2
)
e1
:
SetValue
(
math.ceil
(
c
:
GetBaseDefense
()
/
2
)
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
--
--
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
...
...
c51402177.lua
View file @
bfcf52a3
...
@@ -62,7 +62,7 @@ function c51402177.damcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -62,7 +62,7 @@ function c51402177.damcon(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c51402177
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c51402177
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
dam
=
e
:
GetHandler
():
GetBattleTarget
():
GetBaseDefense
()
/
2
local
dam
=
math.floor
(
e
:
GetHandler
():
GetBattleTarget
():
GetBaseDefense
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
...
...
c52977572.lua
View file @
bfcf52a3
...
@@ -62,5 +62,5 @@ function c52977572.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -62,5 +62,5 @@ function c52977572.rdcon(e,tp,eg,ep,ev,re,r,rp)
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
end
end
function
c52977572
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c52977572
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c53025096.lua
View file @
bfcf52a3
...
@@ -19,7 +19,7 @@ function c53025096.damcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -19,7 +19,7 @@ function c53025096.damcon(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c53025096
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c53025096
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
dam
=
e
:
GetHandler
():
GetBattleTarget
():
GetAttack
()
/
2
local
dam
=
math.floor
(
e
:
GetHandler
():
GetBattleTarget
():
GetAttack
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
...
...
c53701457.lua
View file @
bfcf52a3
...
@@ -38,7 +38,7 @@ function c53701457.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,7 +38,7 @@ function c53701457.rdcon(e,tp,eg,ep,ev,re,r,rp)
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
end
end
function
c53701457
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c53701457
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
function
c53701457
.
damcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c53701457
.
damcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
ep
~=
tp
return
ep
~=
tp
...
...
c53950487.lua
View file @
bfcf52a3
...
@@ -42,7 +42,7 @@ function c53950487.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -42,7 +42,7 @@ function c53950487.atkop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_DAMAGE_CAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_DAMAGE_CAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
end
end
...
...
c53956001.lua
View file @
bfcf52a3
...
@@ -42,7 +42,7 @@ end
...
@@ -42,7 +42,7 @@ end
function
c53956001
.
daop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c53956001
.
daop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
local
atk
=
math.
floor
(
tc
:
GetAttack
()
/
2
)
local
atk
=
math.
ceil
(
tc
:
GetAttack
()
/
2
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_DIRECT_ATTACK
)
e1
:
SetCode
(
EFFECT_DIRECT_ATTACK
)
...
...
c53981499.lua
View file @
bfcf52a3
...
@@ -24,7 +24,7 @@ function c53981499.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -24,7 +24,7 @@ function c53981499.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
local
bc
=
c
:
GetBattleTarget
()
local
bc
=
c
:
GetBattleTarget
()
local
dam
=
bc
:
GetAttack
()
/
2
local
dam
=
math.floor
(
bc
:
GetAttack
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
...
...
c54569495.lua
View file @
bfcf52a3
...
@@ -56,7 +56,7 @@ function c54569495.spop(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -56,7 +56,7 @@ function c54569495.spop(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
end
end
function
c54569495
.
damop2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c54569495
.
damop2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
tp
,
math.
ceil
(
ev
/
2
))
Duel
.
ChangeBattleDamage
(
tp
,
math.
floor
(
ev
/
2
))
end
end
function
c54569495
.
damcon1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c54569495
.
damcon1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
local
a
=
Duel
.
GetAttacker
()
...
...
c55713623.lua
View file @
bfcf52a3
...
@@ -28,7 +28,7 @@ function c55713623.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -28,7 +28,7 @@ function c55713623.activate(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
tc
:
GetBaseAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetBaseAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
end
end
c55727845.lua
View file @
bfcf52a3
...
@@ -29,7 +29,7 @@ function c55727845.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -29,7 +29,7 @@ function c55727845.atkop(e,tp,eg,ep,ev,re,r,rp)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
and
not
tc
:
IsImmuneToEffect
(
e
)
then
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
and
not
tc
:
IsImmuneToEffect
(
e
)
then
local
atk
=
tc
:
GetAttack
()
/
2
local
atk
=
math.ceil
(
tc
:
GetAttack
()
/
2
)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
...
...
c56339050.lua
View file @
bfcf52a3
...
@@ -31,7 +31,7 @@ function c56339050.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -31,7 +31,7 @@ function c56339050.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if
chkc
then
return
chkc
==
tc
end
if
chkc
then
return
chkc
==
tc
end
if
chk
==
0
then
return
tc
:
IsOnField
()
and
tc
:
IsCanBeEffectTarget
(
e
)
end
if
chk
==
0
then
return
tc
:
IsOnField
()
and
tc
:
IsCanBeEffectTarget
(
e
)
end
Duel
.
SetTargetCard
(
tc
)
Duel
.
SetTargetCard
(
tc
)
local
dam
=
tc
:
GetAttack
()
/
2
local
dam
=
math.floor
(
tc
:
GetAttack
()
/
2
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
tc
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
tc
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
dam
)
...
@@ -39,7 +39,7 @@ end
...
@@ -39,7 +39,7 @@ end
function
c56339050
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c56339050
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
and
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
and
tc
:
IsAttackable
()
then
if
tc
and
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
and
tc
:
IsAttackable
()
then
local
atk
=
tc
:
GetAttack
()
/
2
local
atk
=
math.floor
(
tc
:
GetAttack
()
/
2
)
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
end
end
...
...
c56535497.lua
View file @
bfcf52a3
...
@@ -66,7 +66,7 @@ function c56535497.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -66,7 +66,7 @@ function c56535497.operation(e,tp,eg,ep,ev,re,r,rp)
local
tc2
=
g
:
GetFirst
()
local
tc2
=
g
:
GetFirst
()
if
tc1
==
tc2
then
tc2
=
g
:
GetNext
()
end
if
tc1
==
tc2
then
tc2
=
g
:
GetNext
()
end
if
tc1
:
IsFaceup
()
and
tc1
:
IsRelateToEffect
(
e
)
and
tc2
:
IsFaceup
()
and
tc2
:
IsRelateToEffect
(
e
)
then
if
tc1
:
IsFaceup
()
and
tc1
:
IsRelateToEffect
(
e
)
and
tc2
:
IsFaceup
()
and
tc2
:
IsRelateToEffect
(
e
)
then
local
atk
=
tc1
:
GetAttack
()
/
2
local
atk
=
math.ceil
(
tc1
:
GetAttack
()
/
2
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
...
...
c56574543.lua
View file @
bfcf52a3
...
@@ -48,5 +48,5 @@ function c56574543.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -48,5 +48,5 @@ function c56574543.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
return
ep
~=
tp
end
end
function
c56574543
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c56574543
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c59042331.lua
View file @
bfcf52a3
...
@@ -34,7 +34,7 @@ function c59042331.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -34,7 +34,7 @@ function c59042331.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e2
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e2
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e2
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
end
end
...
...
c59642500.lua
View file @
bfcf52a3
...
@@ -36,7 +36,7 @@ function c59642500.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -36,7 +36,7 @@ function c59642500.rdcon(e,tp,eg,ep,ev,re,r,rp)
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
end
end
function
c59642500
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c59642500
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
function
c59642500
.
thcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c59642500
.
thcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
...
...
c60312997.lua
View file @
bfcf52a3
...
@@ -44,7 +44,7 @@ function c60312997.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -44,7 +44,7 @@ function c60312997.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c60312997
.
damval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
function
c60312997
.
damval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
if
r
==
REASON_BATTLE
then
if
r
==
REASON_BATTLE
then
return
val
/
2
return
math.floor
(
val
/
2
)
else
return
val
end
else
return
val
end
end
end
function
c60312997
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c60312997
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
c60953118.lua
View file @
bfcf52a3
...
@@ -82,7 +82,7 @@ function c60953118.rdcon2(e)
...
@@ -82,7 +82,7 @@ function c60953118.rdcon2(e)
end
end
function
c60953118
.
rdval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
function
c60953118
.
rdval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
return
val
/
2
return
math.floor
(
val
/
2
)
else
else
return
val
return
val
end
end
...
...
c61420130.lua
View file @
bfcf52a3
...
@@ -38,13 +38,13 @@ function c61420130.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,13 +38,13 @@ function c61420130.activate(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e2
:
SetValue
(
tc
:
GetDefense
()
/
2
)
e2
:
SetValue
(
math.ceil
(
tc
:
GetDefense
()
/
2
)
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
end
end
end
end
...
...
c6142213.lua
View file @
bfcf52a3
...
@@ -23,14 +23,14 @@ function c6142213.condition(e,tp,eg,ep,ev,re,r,rp)
...
@@ -23,14 +23,14 @@ function c6142213.condition(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c6142213
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c6142213
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
dam
=
Duel
.
GetAttackTarget
():
GetAttack
()
/
2
local
dam
=
math.floor
(
Duel
.
GetAttackTarget
():
GetAttack
()
/
2
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
0
,
0
,
1
-
tp
,
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
0
,
0
,
1
-
tp
,
dam
)
end
end
function
c6142213
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c6142213
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
p
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
)
local
p
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
)
Duel
.
Damage
(
p
,
Duel
.
GetAttackTarget
():
GetAttack
()
/
2
,
REASON_EFFECT
)
Duel
.
Damage
(
p
,
math.floor
(
Duel
.
GetAttackTarget
():
GetAttack
()
/
2
)
,
REASON_EFFECT
)
end
end
function
c6142213
.
indcon
(
e
)
function
c6142213
.
indcon
(
e
)
return
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
return
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
...
...
c62070231.lua
View file @
bfcf52a3
...
@@ -38,7 +38,7 @@ function c62070231.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,7 +38,7 @@ function c62070231.operation(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
if
Duel
.
GetTurnPlayer
()
~=
tp
then
if
Duel
.
GetTurnPlayer
()
~=
tp
then
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
,
2
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
,
2
)
else
else
...
...
c62325062.lua
View file @
bfcf52a3
...
@@ -39,5 +39,5 @@ function c62325062.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -39,5 +39,5 @@ function c62325062.activate(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c62325062
.
atkval
(
e
,
c
)
function
c62325062
.
atkval
(
e
,
c
)
return
c
:
GetBaseAttack
()
/
2
return
math.ceil
(
c
:
GetBaseAttack
()
/
2
)
end
end
c62742651.lua
View file @
bfcf52a3
...
@@ -34,7 +34,7 @@ end
...
@@ -34,7 +34,7 @@ end
function
c62742651
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c62742651
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
bc
=
e
:
GetHandler
():
GetBattleTarget
()
local
bc
=
e
:
GetHandler
():
GetBattleTarget
()
local
dam
=
bc
:
GetAttack
()
/
2
local
dam
=
math.floor
(
bc
:
GetAttack
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
tp
,
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
tp
,
dam
)
...
...
c63364266.lua
View file @
bfcf52a3
...
@@ -44,7 +44,7 @@ function c63364266.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -44,7 +44,7 @@ function c63364266.spop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
,
true
)
tc
:
RegisterEffect
(
e1
,
true
)
Duel
.
SpecialSummonComplete
()
Duel
.
SpecialSummonComplete
()
...
...
c63630268.lua
View file @
bfcf52a3
...
@@ -36,5 +36,5 @@ function c63630268.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -36,5 +36,5 @@ function c63630268.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c63630268
.
damval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
function
c63630268
.
damval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
return
val
/
2
return
math.floor
(
val
/
2
)
end
end
c64145892.lua
View file @
bfcf52a3
...
@@ -12,5 +12,5 @@ function c64145892.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -12,5 +12,5 @@ function c64145892.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
==
tp
return
ep
==
tp
end
end
function
c64145892
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c64145892
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c64238008.lua
View file @
bfcf52a3
...
@@ -19,7 +19,7 @@ function c64238008.cost(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -19,7 +19,7 @@ function c64238008.cost(e,tp,eg,ep,ev,re,r,rp,chk)
e
:
SetLabel
(
1
)
e
:
SetLabel
(
1
)
if
chk
==
0
then
return
Duel
.
GetCustomActivityCount
(
64238008
,
tp
,
ACTIVITY_CHAIN
)
==
0
and
Duel
.
CheckReleaseGroup
(
tp
,
nil
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
GetCustomActivityCount
(
64238008
,
tp
,
ACTIVITY_CHAIN
)
==
0
and
Duel
.
CheckReleaseGroup
(
tp
,
nil
,
1
,
nil
)
end
local
g
=
Duel
.
SelectReleaseGroup
(
tp
,
nil
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectReleaseGroup
(
tp
,
nil
,
1
,
1
,
nil
)
local
atk
=
g
:
GetFirst
():
GetTextAttack
()
/
2
local
atk
=
math.floor
(
g
:
GetFirst
():
GetTextAttack
()
/
2
)
if
atk
<
0
then
atk
=
0
end
if
atk
<
0
then
atk
=
0
end
e
:
SetLabel
(
atk
)
e
:
SetLabel
(
atk
)
Duel
.
Release
(
g
,
REASON_COST
)
Duel
.
Release
(
g
,
REASON_COST
)
...
...
c65472618.lua
View file @
bfcf52a3
...
@@ -42,12 +42,12 @@ function c65472618.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -42,12 +42,12 @@ function c65472618.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
bc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
bc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
bc
:
RegisterEffect
(
e1
)
bc
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetCode
(
EFFECT_SET_DEFENSE_FINAL
)
e2
:
SetValue
(
bc
:
GetDefense
()
/
2
)
e2
:
SetValue
(
math.ceil
(
bc
:
GetDefense
()
/
2
)
)
bc
:
RegisterEffect
(
e2
)
bc
:
RegisterEffect
(
e2
)
end
end
end
end
...
...
c66818682.lua
View file @
bfcf52a3
...
@@ -28,12 +28,12 @@ function c66818682.rectg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -28,12 +28,12 @@ function c66818682.rectg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
tc
=
Duel
.
GetAttacker
()
local
tc
=
Duel
.
GetAttacker
()
tc
:
CreateEffectRelation
(
e
)
tc
:
CreateEffectRelation
(
e
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
tc
:
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
end
end
function
c66818682
.
recop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c66818682
.
recop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetAttacker
()
local
tc
=
Duel
.
GetAttacker
()
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
Duel
.
Recover
(
tp
,
tc
:
GetAttack
()
/
2
,
REASON_EFFECT
)
Duel
.
Recover
(
tp
,
math.ceil
(
tc
:
GetAttack
()
/
2
)
,
REASON_EFFECT
)
end
end
end
end
function
c66818682
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c66818682
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
c67508932.lua
View file @
bfcf52a3
...
@@ -82,7 +82,7 @@ function c67508932.rmop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -82,7 +82,7 @@ function c67508932.rmop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c67508932
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c67508932
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
return
math.
ceil
(
dam
/
2
)
return
math.
floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
function
c67508932
.
spfilter
(
c
,
e
,
tp
)
function
c67508932
.
spfilter
(
c
,
e
,
tp
)
...
...
c67951831.lua
View file @
bfcf52a3
...
@@ -24,7 +24,7 @@ function c67951831.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -24,7 +24,7 @@ function c67951831.activate(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
...
...
c67959180.lua
View file @
bfcf52a3
...
@@ -27,7 +27,7 @@ function c67959180.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -27,7 +27,7 @@ function c67959180.operation(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
+
RESET_PHASE
+
PHASE_END
)
if
opt
==
coin
then
if
opt
==
coin
then
e1
:
SetValue
(
c
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
c
:
GetAttack
()
/
2
)
)
else
else
e1
:
SetValue
(
c
:
GetAttack
()
*
2
)
e1
:
SetValue
(
c
:
GetAttack
()
*
2
)
end
end
...
...
c6799227.lua
View file @
bfcf52a3
...
@@ -29,7 +29,7 @@ function c6799227.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -29,7 +29,7 @@ function c6799227.activate(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
end
end
c68540058.lua
View file @
bfcf52a3
...
@@ -94,5 +94,5 @@ function c68540058.atkcon(e)
...
@@ -94,5 +94,5 @@ function c68540058.atkcon(e)
and
Duel
.
GetAttacker
()
==
e
:
GetHandler
():
GetEquipTarget
()
and
Duel
.
GetAttackTarget
()
and
Duel
.
GetAttacker
()
==
e
:
GetHandler
():
GetEquipTarget
()
and
Duel
.
GetAttackTarget
()
end
end
function
c68540058
.
atkval
(
e
,
c
)
function
c68540058
.
atkval
(
e
,
c
)
return
Duel
.
GetAttackTarget
():
GetAttack
()
/
2
return
math.ceil
(
Duel
.
GetAttackTarget
():
GetAttack
()
/
2
)
end
end
c69073023.lua
View file @
bfcf52a3
...
@@ -74,5 +74,5 @@ function c69073023.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -74,5 +74,5 @@ function c69073023.spop(e,tp,eg,ep,ev,re,r,rp)
Duel
.
RegisterEffect
(
e1
,
tp
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
end
function
c69073023
.
damval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
function
c69073023
.
damval
(
e
,
re
,
val
,
r
,
rp
,
rc
)
return
val
/
2
return
math.floor
(
val
/
2
)
end
end
c69931927.lua
View file @
bfcf52a3
...
@@ -57,7 +57,7 @@ function c69931927.damcost(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -57,7 +57,7 @@ function c69931927.damcost(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function
c69931927
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c69931927
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
dam
=
e
:
GetHandler
():
GetDefense
()
/
2
local
dam
=
math.floor
(
e
:
GetHandler
():
GetDefense
()
/
2
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
dam
)
...
...
c71625222.lua
View file @
bfcf52a3
...
@@ -37,7 +37,7 @@ function c71625222.desop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -37,7 +37,7 @@ function c71625222.desop(e,tp,eg,ep,ev,re,r,rp)
sum
=
sum
+
math.max
(
c
:
GetAttack
(),
0
)
sum
=
sum
+
math.max
(
c
:
GetAttack
(),
0
)
end
end
if
sum
>
0
then
if
sum
>
0
then
Duel
.
Damage
(
tp
,
sum
/
2
,
REASON_EFFECT
)
Duel
.
Damage
(
tp
,
math.floor
(
sum
/
2
)
,
REASON_EFFECT
)
end
end
end
end
end
end
c72083436.lua
View file @
bfcf52a3
...
@@ -58,5 +58,5 @@ function c72083436.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -58,5 +58,5 @@ function c72083436.rdcon(e,tp,eg,ep,ev,re,r,rp)
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
c
:
GetFlagEffect
(
72083436
)
>
0
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
c
:
GetFlagEffect
(
72083436
)
>
0
end
end
function
c72083436
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c72083436
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c72283691.lua
View file @
bfcf52a3
...
@@ -87,12 +87,12 @@ function c72283691.atktg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -87,12 +87,12 @@ function c72283691.atktg(e,tp,eg,ep,ev,re,r,rp,chk)
local
tc
=
Duel
.
GetAttacker
()
local
tc
=
Duel
.
GetAttacker
()
Duel
.
SetTargetCard
(
tc
)
Duel
.
SetTargetCard
(
tc
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
tc
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
tc
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
tc
:
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.floor
(
tc
:
GetAttack
()
/
2
)
)
end
end
function
c72283691
.
atkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c72283691
.
atkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
not
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
return
end
if
not
e
:
GetHandler
():
IsRelateToEffect
(
e
)
then
return
end
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
local
atk
=
math.
ceil
(
tc
:
GetAttack
()
/
2
)
local
atk
=
math.
floor
(
tc
:
GetAttack
()
/
2
)
if
tc
:
IsRelateToEffect
(
e
)
and
not
tc
:
IsStatus
(
STATUS_ATTACK_CANCELED
)
and
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
if
tc
:
IsRelateToEffect
(
e
)
and
not
tc
:
IsStatus
(
STATUS_ATTACK_CANCELED
)
and
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
end
end
...
...
c72896720.lua
View file @
bfcf52a3
...
@@ -38,7 +38,7 @@ function c72896720.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -38,7 +38,7 @@ function c72896720.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local
atk
=
0
local
atk
=
0
if
d
:
IsFaceup
()
then
atk
=
d
:
GetAttack
()
end
if
d
:
IsFaceup
()
then
atk
=
d
:
GetAttack
()
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
atk
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.floor
(
atk
/
2
)
)
end
end
function
c72896720
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c72896720
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
...
@@ -46,6 +46,6 @@ function c72896720.desop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -46,6 +46,6 @@ function c72896720.desop(e,tp,eg,ep,ev,re,r,rp)
local
atk
=
0
local
atk
=
0
if
tc
:
IsFaceup
()
then
atk
=
tc
:
GetAttack
()
end
if
tc
:
IsFaceup
()
then
atk
=
tc
:
GetAttack
()
end
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
==
0
then
return
end
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
==
0
then
return
end
Duel
.
Damage
(
1
-
tp
,
atk
/
2
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.floor
(
atk
/
2
)
,
REASON_EFFECT
)
end
end
end
end
c72926163.lua
View file @
bfcf52a3
...
@@ -43,7 +43,7 @@ function c72926163.valcheck(e,c)
...
@@ -43,7 +43,7 @@ function c72926163.valcheck(e,c)
local
tc
=
g
:
GetFirst
()
local
tc
=
g
:
GetFirst
()
if
tc
:
IsCode
(
89943723
)
or
tc
:
CheckFusionSubstitute
(
c
)
then
tc
=
g
:
GetNext
()
end
if
tc
:
IsCode
(
89943723
)
or
tc
:
CheckFusionSubstitute
(
c
)
then
tc
=
g
:
GetNext
()
end
if
not
tc
:
IsCode
(
89943723
)
then
if
not
tc
:
IsCode
(
89943723
)
then
atk
=
tc
:
GetTextAttack
()
/
2
atk
=
math.ceil
(
tc
:
GetTextAttack
()
/
2
)
end
end
e
:
SetLabel
(
atk
)
e
:
SetLabel
(
atk
)
end
end
...
...
c73048641.lua
View file @
bfcf52a3
...
@@ -29,7 +29,7 @@ function c73048641.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -29,7 +29,7 @@ function c73048641.activate(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
...
...
c74003290.lua
View file @
bfcf52a3
...
@@ -53,7 +53,7 @@ function c74003290.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -53,7 +53,7 @@ function c74003290.activate(e,tp,eg,ep,ev,re,r,rp)
Duel
.
AdjustInstantly
(
tc
)
Duel
.
AdjustInstantly
(
tc
)
local
e3
=
e1
:
Clone
()
local
e3
=
e1
:
Clone
()
e3
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e3
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e3
:
SetValue
(
tc
:
GetBaseAttack
()
/
2
)
e3
:
SetValue
(
math.ceil
(
tc
:
GetBaseAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e3
)
tc
:
RegisterEffect
(
e3
)
end
end
end
end
...
...
c74069667.lua
View file @
bfcf52a3
...
@@ -75,7 +75,7 @@ function c74069667.spop1(e,tp,eg,ep,ev,re,r,rp)
...
@@ -75,7 +75,7 @@ function c74069667.spop1(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c74069667
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c74069667
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
function
c74069667
.
spfilter2
(
c
,
e
,
tp
)
function
c74069667
.
spfilter2
(
c
,
e
,
tp
)
...
...
c75249652.lua
View file @
bfcf52a3
...
@@ -34,7 +34,7 @@ function c75249652.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -34,7 +34,7 @@ function c75249652.activate(e,tp,eg,ep,ev,re,r,rp)
if
tatk
>
0
then
atk
=
atk
+
tatk
end
if
tatk
>
0
then
atk
=
atk
+
tatk
end
tc
=
dg
:
GetNext
()
tc
=
dg
:
GetNext
()
end
end
local
dam
=
Duel
.
Damage
(
tp
,
atk
/
2
,
REASON_EFFECT
)
local
dam
=
Duel
.
Damage
(
tp
,
math.floor
(
atk
/
2
)
,
REASON_EFFECT
)
if
Duel
.
GetLP
(
tp
)
>
0
and
dam
>
0
then
if
Duel
.
GetLP
(
tp
)
>
0
and
dam
>
0
then
Duel
.
BreakEffect
()
Duel
.
BreakEffect
()
Duel
.
Damage
(
1
-
tp
,
dam
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
dam
,
REASON_EFFECT
)
...
...
c75253697.lua
View file @
bfcf52a3
...
@@ -52,6 +52,6 @@ function c75253697.desop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -52,6 +52,6 @@ function c75253697.desop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c75253697
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c75253697
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
c75672051.lua
View file @
bfcf52a3
...
@@ -38,7 +38,7 @@ function c75672051.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,7 +38,7 @@ function c75672051.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
math.
floor
(
tc
:
GetAttack
()
/
2
))
e1
:
SetValue
(
math.
ceil
(
tc
:
GetAttack
()
/
2
))
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
Duel
.
BreakEffect
()
Duel
.
BreakEffect
()
...
...
c75902998.lua
View file @
bfcf52a3
...
@@ -17,14 +17,14 @@ end
...
@@ -17,14 +17,14 @@ end
function
c75902998
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c75902998
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
at
=
Duel
.
GetAttacker
()
local
at
=
Duel
.
GetAttacker
()
if
chk
==
0
then
return
at
:
IsRelateToBattle
()
end
if
chk
==
0
then
return
at
:
IsRelateToBattle
()
end
local
dam
=
math.max
(
at
:
GetBaseAttack
()
/
2
,
0
)
local
dam
=
math.max
(
math.floor
(
at
:
GetBaseAttack
()
/
2
)
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
at
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
at
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
dam
)
end
end
function
c75902998
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c75902998
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
at
=
Duel
.
GetAttacker
()
local
at
=
Duel
.
GetAttacker
()
if
at
:
IsRelateToBattle
()
and
Duel
.
Destroy
(
at
,
REASON_EFFECT
)
~=
0
then
if
at
:
IsRelateToBattle
()
and
Duel
.
Destroy
(
at
,
REASON_EFFECT
)
~=
0
then
local
atk
=
at
:
GetBaseAttack
()
/
2
local
atk
=
math.floor
(
at
:
GetBaseAttack
()
/
2
)
if
atk
>
0
then
if
atk
>
0
then
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
end
end
...
...
c76004142.lua
View file @
bfcf52a3
...
@@ -35,7 +35,7 @@ end
...
@@ -35,7 +35,7 @@ end
function
c76004142
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c76004142
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
then
local
atk
=
tc
:
GetAttack
()
/
2
local
atk
=
math.floor
(
tc
:
GetAttack
()
/
2
)
local
val
=
Duel
.
Damage
(
tp
,
atk
,
REASON_EFFECT
)
local
val
=
Duel
.
Damage
(
tp
,
atk
,
REASON_EFFECT
)
if
val
>
0
and
Duel
.
GetLP
(
tp
)
>
0
then
if
val
>
0
and
Duel
.
GetLP
(
tp
)
>
0
then
Duel
.
BreakEffect
()
Duel
.
BreakEffect
()
...
...
c7700132.lua
View file @
bfcf52a3
...
@@ -13,8 +13,8 @@ function c7700132.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -13,8 +13,8 @@ function c7700132.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
if
Duel
.
GetCurrentPhase
()
==
PHASE_DAMAGE
and
e
:
GetHandler
()
==
Duel
.
GetAttackTarget
()
then
if
Duel
.
GetCurrentPhase
()
==
PHASE_DAMAGE
and
e
:
GetHandler
()
==
Duel
.
GetAttackTarget
()
then
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
Duel
.
GetAttacker
():
GetAttack
()
/
2
)
Duel
.
SetTargetParam
(
math.floor
(
Duel
.
GetAttacker
():
GetAttack
()
/
2
)
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
Duel
.
GetAttacker
():
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.floor
(
Duel
.
GetAttacker
():
GetAttack
()
/
2
)
)
end
end
end
end
function
c7700132
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c7700132
.
damop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
c77625948.lua
View file @
bfcf52a3
...
@@ -79,5 +79,5 @@ function c77625948.atkcon(e)
...
@@ -79,5 +79,5 @@ function c77625948.atkcon(e)
and
e
:
GetHandler
():
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
==
1
and
e
:
GetHandler
():
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
==
1
end
end
function
c77625948
.
atkval
(
e
,
c
)
function
c77625948
.
atkval
(
e
,
c
)
return
c
:
GetAttack
()
/
2
return
math.ceil
(
c
:
GetAttack
()
/
2
)
end
end
c7845138.lua
View file @
bfcf52a3
...
@@ -31,7 +31,7 @@ function c7845138.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -31,7 +31,7 @@ function c7845138.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
e1
:
SetValue
(
math.ceil
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
...
...
c79068663.lua
View file @
bfcf52a3
...
@@ -57,7 +57,7 @@ function c79068663.damop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -57,7 +57,7 @@ function c79068663.damop(e,tp,eg,ep,ev,re,r,rp)
local
des
=
eg
:
GetFirst
()
local
des
=
eg
:
GetFirst
()
local
p
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
)
local
p
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PLAYER
)
if
des
:
IsRelateToEffect
(
e
)
then
if
des
:
IsRelateToEffect
(
e
)
then
local
dam
=
des
:
GetAttack
()
/
2
local
dam
=
math.floor
(
des
:
GetAttack
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
Damage
(
p
,
dam
,
REASON_EFFECT
)
Duel
.
Damage
(
p
,
dam
,
REASON_EFFECT
)
end
end
...
...
c81332143.lua
View file @
bfcf52a3
...
@@ -22,7 +22,7 @@ function c81332143.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -22,7 +22,7 @@ function c81332143.activate(e,tp,eg,ep,ev,re,r,rp)
opt
=
Duel
.
SelectOption
(
1
-
tp
,
aux
.
Stringid
(
81332143
,
0
))
opt
=
Duel
.
SelectOption
(
1
-
tp
,
aux
.
Stringid
(
81332143
,
0
))
end
end
if
opt
==
0
then
if
opt
==
0
then
local
lp
=
(
Duel
.
GetLP
(
tp
)
+
Duel
.
GetLP
(
1
-
tp
))
/
2
local
lp
=
math.ceil
((
Duel
.
GetLP
(
tp
)
+
Duel
.
GetLP
(
1
-
tp
))
/
2
)
Duel
.
SetLP
(
tp
,
lp
)
Duel
.
SetLP
(
tp
,
lp
)
Duel
.
SetLP
(
1
-
tp
,
lp
)
Duel
.
SetLP
(
1
-
tp
,
lp
)
end
end
...
...
c81927732.lua
View file @
bfcf52a3
...
@@ -82,12 +82,12 @@ function c81927732.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -82,12 +82,12 @@ function c81927732.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
g
=
Duel
.
SelectTarget
(
tp
,
aux
.
TRUE
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
aux
.
TRUE
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
g
:
GetFirst
():
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.floor
(
g
:
GetFirst
():
GetAttack
()
/
2
)
)
end
end
function
c81927732
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c81927732
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
then
if
tc
:
IsRelateToEffect
(
e
)
then
local
dam
=
tc
:
GetAttack
()
/
2
local
dam
=
math.floor
(
tc
:
GetAttack
()
/
2
)
if
dam
<
0
or
tc
:
IsFacedown
()
then
dam
=
0
end
if
dam
<
0
or
tc
:
IsFacedown
()
then
dam
=
0
end
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
Duel
.
Damage
(
1
-
tp
,
dam
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
dam
,
REASON_EFFECT
)
...
...
c82458280.lua
View file @
bfcf52a3
...
@@ -45,7 +45,7 @@ function c82458280.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -45,7 +45,7 @@ function c82458280.operation(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e2
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e2
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e2
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
...
...
c83866861.lua
View file @
bfcf52a3
...
@@ -62,7 +62,7 @@ function c83866861.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -62,7 +62,7 @@ function c83866861.spop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
,
true
)
tc
:
RegisterEffect
(
e1
,
true
)
Duel
.
SpecialSummonComplete
()
Duel
.
SpecialSummonComplete
()
...
...
c83965310.lua
View file @
bfcf52a3
...
@@ -89,7 +89,7 @@ function c83965310.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -89,7 +89,7 @@ function c83965310.eqop(e,tp,eg,ep,ev,re,r,rp)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
then
if
tc
:
IsRelateToEffect
(
e
)
then
if
c
:
IsFaceup
()
and
c
:
IsRelateToEffect
(
e
)
then
if
c
:
IsFaceup
()
and
c
:
IsRelateToEffect
(
e
)
then
local
atk
=
tc
:
GetTextAttack
()
/
2
local
atk
=
math.ceil
(
tc
:
GetTextAttack
()
/
2
)
if
tc
:
IsFacedown
()
then
atk
=
0
end
if
tc
:
IsFacedown
()
then
atk
=
0
end
if
atk
<
0
then
atk
=
0
end
if
atk
<
0
then
atk
=
0
end
if
not
Duel
.
Equip
(
tp
,
tc
,
c
,
false
)
then
return
end
if
not
Duel
.
Equip
(
tp
,
tc
,
c
,
false
)
then
return
end
...
...
c85008676.lua
View file @
bfcf52a3
...
@@ -50,7 +50,7 @@ function c85008676.damop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -50,7 +50,7 @@ function c85008676.damop(e,tp,eg,ep,ev,re,r,rp)
Duel
.
RegisterEffect
(
e1
,
tp
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
end
function
c85008676
.
halfop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c85008676
.
halfop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
tp
,
math.
ceil
(
ev
/
2
))
Duel
.
ChangeBattleDamage
(
tp
,
math.
floor
(
ev
/
2
))
end
end
function
c85008676
.
damcon2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c85008676
.
damcon2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
ep
~=
tp
and
aux
.
damcon1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
ep
~=
tp
and
aux
.
damcon1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
@@ -71,7 +71,7 @@ function c85008676.damval2(e,re,val,r,rp,rc)
...
@@ -71,7 +71,7 @@ function c85008676.damval2(e,re,val,r,rp,rc)
local
cc
=
Duel
.
GetCurrentChain
()
local
cc
=
Duel
.
GetCurrentChain
()
if
cc
==
0
or
bit
.
band
(
r
,
REASON_EFFECT
)
==
0
then
return
end
if
cc
==
0
or
bit
.
band
(
r
,
REASON_EFFECT
)
==
0
then
return
end
local
cid
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_CHAIN_ID
)
local
cid
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_CHAIN_ID
)
return
cid
==
e
:
GetLabel
()
and
math.
ceil
(
val
/
2
)
or
val
return
cid
==
e
:
GetLabel
()
and
math.
floor
(
val
/
2
)
or
val
end
end
function
c85008676
.
thcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c85008676
.
thcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_ONFIELD
)
return
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_ONFIELD
)
...
...
c85121942.lua
View file @
bfcf52a3
...
@@ -38,7 +38,7 @@ function c85121942.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -38,7 +38,7 @@ function c85121942.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
local
bc
=
c
:
GetBattleTarget
()
local
bc
=
c
:
GetBattleTarget
()
local
dam
=
bc
:
GetTextAttack
()
/
2
local
dam
=
math.floor
(
bc
:
GetTextAttack
()
/
2
)
if
dam
<
0
then
dam
=
0
end
if
dam
<
0
then
dam
=
0
end
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetPlayer
(
1
-
tp
)
Duel
.
SetTargetParam
(
dam
)
Duel
.
SetTargetParam
(
dam
)
...
...
c85636437.lua
View file @
bfcf52a3
...
@@ -22,12 +22,12 @@ function c85636437.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -22,12 +22,12 @@ function c85636437.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c85636437
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c85636437
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c85636437
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c85636437
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.
ceil
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
))
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.
floor
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
))
end
end
function
c85636437
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c85636437
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
if
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
Duel
.
Damage
(
1
-
tp
,
math.
ceil
(
tc
:
GetBaseAttack
()
/
2
),
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.
floor
(
tc
:
GetBaseAttack
()
/
2
),
REASON_EFFECT
)
end
end
if
not
e
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
)
then
return
end
if
not
e
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
)
then
return
end
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
...
...
c86915847.lua
View file @
bfcf52a3
...
@@ -25,7 +25,7 @@ function c86915847.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -25,7 +25,7 @@ function c86915847.operation(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
end
end
c8763963.lua
View file @
bfcf52a3
...
@@ -51,7 +51,7 @@ function c8763963.dcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -51,7 +51,7 @@ function c8763963.dcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
and
(
c
==
Duel
.
GetAttacker
()
or
c
==
Duel
.
GetAttackTarget
())
return
ep
~=
tp
and
(
c
==
Duel
.
GetAttacker
()
or
c
==
Duel
.
GetAttackTarget
())
end
end
function
c8763963
.
dop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c8763963
.
dop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
function
c8763963
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c8763963
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
...
...
c89448140.lua
View file @
bfcf52a3
...
@@ -33,7 +33,7 @@ function c89448140.condition(e)
...
@@ -33,7 +33,7 @@ function c89448140.condition(e)
return
Duel
.
IsExistingMatchingCard
(
c89448140
.
cfilter
,
e
:
GetHandlerPlayer
(),
LOCATION_MZONE
,
0
,
1
,
nil
)
return
Duel
.
IsExistingMatchingCard
(
c89448140
.
cfilter
,
e
:
GetHandlerPlayer
(),
LOCATION_MZONE
,
0
,
1
,
nil
)
end
end
function
c89448140
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c89448140
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
return
math.
ceil
(
dam
/
2
)
return
math.
floor
(
dam
/
2
)
end
end
function
c89448140
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c89448140
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_ONFIELD
)
return
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_ONFIELD
)
...
...
c89662736.lua
View file @
bfcf52a3
...
@@ -24,12 +24,12 @@ function c89662736.nacost(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -24,12 +24,12 @@ function c89662736.nacost(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function
c89662736
.
natg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c89662736
.
natg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetAttacker
():
IsOnField
()
end
if
chk
==
0
then
return
Duel
.
GetAttacker
():
IsOnField
()
end
local
dam
=
Duel
.
GetAttacker
():
GetAttack
()
/
2
local
dam
=
math.floor
(
Duel
.
GetAttacker
():
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
dam
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
dam
)
end
end
function
c89662736
.
naop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c89662736
.
naop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
local
a
=
Duel
.
GetAttacker
()
if
Duel
.
NegateAttack
()
then
if
Duel
.
NegateAttack
()
then
Duel
.
Damage
(
1
-
tp
,
a
:
GetAttack
()
/
2
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.floor
(
a
:
GetAttack
()
/
2
)
,
REASON_EFFECT
)
end
end
end
end
c89743495.lua
View file @
bfcf52a3
...
@@ -66,7 +66,7 @@ function c89743495.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -66,7 +66,7 @@ function c89743495.atkop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
atk
/
2
)
e1
:
SetValue
(
math.ceil
(
atk
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
end
end
c89870349.lua
View file @
bfcf52a3
...
@@ -43,7 +43,7 @@ function c89870349.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -43,7 +43,7 @@ function c89870349.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
...
...
c90020065.lua
View file @
bfcf52a3
...
@@ -39,7 +39,7 @@ function c90020065.destg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -39,7 +39,7 @@ function c90020065.destg(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function
c90020065
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c90020065
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
g
=
Duel
.
GetMatchingGroup
(
aux
.
TRUE
,
tp
,
LOCATION_MZONE
,
0
,
nil
)
local
g
=
Duel
.
GetMatchingGroup
(
aux
.
TRUE
,
tp
,
LOCATION_MZONE
,
0
,
nil
)
local
dam
=
g
:
GetSum
(
Card
.
GetAttack
)
/
2
local
dam
=
math.floor
(
g
:
GetSum
(
Card
.
GetAttack
)
/
2
)
Duel
.
Destroy
(
g
,
REASON_EFFECT
)
Duel
.
Destroy
(
g
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
dam
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
dam
,
REASON_EFFECT
)
end
end
c9161357.lua
View file @
bfcf52a3
...
@@ -55,7 +55,7 @@ function c9161357.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -55,7 +55,7 @@ function c9161357.eqop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e1
:
SetValue
(
c9161357
.
eqlimit
)
e1
:
SetValue
(
c9161357
.
eqlimit
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
local
atk
=
tc
:
GetBaseAttack
()
/
2
local
atk
=
math.ceil
(
tc
:
GetBaseAttack
()
/
2
)
if
atk
>
0
then
if
atk
>
0
then
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_EQUIP
)
e2
:
SetType
(
EFFECT_TYPE_EQUIP
)
...
@@ -86,5 +86,5 @@ function c9161357.lpcost(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -86,5 +86,5 @@ function c9161357.lpcost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel
.
RegisterEffect
(
e1
,
tp
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
end
function
c9161357
.
lpop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c9161357
.
lpop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
SetLP
(
1
-
tp
,
Duel
.
GetLP
(
1
-
tp
)
/
2
)
Duel
.
SetLP
(
1
-
tp
,
math.ceil
(
Duel
.
GetLP
(
1
-
tp
)
/
2
)
)
end
end
c92246806.lua
View file @
bfcf52a3
...
@@ -50,7 +50,7 @@ function c92246806.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -50,7 +50,7 @@ function c92246806.rdcon(e,tp,eg,ep,ev,re,r,rp)
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
and
c
:
GetEffectCount
(
EFFECT_DIRECT_ATTACK
)
<
2
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_MZONE
)
>
0
end
end
function
c92246806
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c92246806
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
function
c92246806
.
regop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c92246806
.
regop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
...
...
c92362073.lua
View file @
bfcf52a3
...
@@ -69,7 +69,7 @@ function c92362073.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -69,7 +69,7 @@ function c92362073.atkop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c92362073
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c92362073
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
if
bit
.
band
(
r
,
REASON_BATTLE
)
~=
0
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
function
c92362073
.
tpcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c92362073
.
tpcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
c94156050.lua
View file @
bfcf52a3
...
@@ -25,7 +25,7 @@ function c94156050.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -25,7 +25,7 @@ function c94156050.operation(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetCode
(
EFFECT_SET_ATTACK_FINAL
)
e1
:
SetValue
(
tc
:
GetAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
tc
=
g
:
GetNext
()
tc
=
g
:
GetNext
()
...
...
c94538053.lua
View file @
bfcf52a3
...
@@ -33,12 +33,12 @@ function c94538053.atkop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -33,12 +33,12 @@ function c94538053.atkop(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetValue
(
c
:
GetBaseAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
c
:
GetBaseAttack
()
/
2
)
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
+
RESET_PHASE
+
PHASE_STANDBY
+
RESET_SELF_TURN
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_DISABLE
+
RESET_PHASE
+
PHASE_STANDBY
+
RESET_SELF_TURN
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_SET_BASE_DEFENSE
)
e2
:
SetCode
(
EFFECT_SET_BASE_DEFENSE
)
e2
:
SetValue
(
c
:
GetBaseDefense
()
/
2
)
e2
:
SetValue
(
math.ceil
(
c
:
GetBaseDefense
()
/
2
)
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
local
e3
=
e1
:
Clone
()
local
e3
=
e1
:
Clone
()
e3
:
SetCode
(
EFFECT_CHANGE_LEVEL
)
e3
:
SetCode
(
EFFECT_CHANGE_LEVEL
)
...
...
c95026693.lua
View file @
bfcf52a3
...
@@ -35,7 +35,7 @@ function c95026693.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -35,7 +35,7 @@ function c95026693.activate(e,tp,eg,ep,ev,re,r,rp)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c95026693
.
filter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c95026693
.
filter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
if
g
:
GetCount
()
>
0
then
Duel
.
Remove
(
g
,
POS_FACEUP
,
REASON_EFFECT
)
Duel
.
Remove
(
g
,
POS_FACEUP
,
REASON_EFFECT
)
local
dam
=
g
:
GetFirst
():
GetAttack
()
/
2
local
dam
=
math.floor
(
g
:
GetFirst
():
GetAttack
()
/
2
)
Duel
.
Damage
(
1
-
tp
,
dam
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
dam
,
REASON_EFFECT
)
end
end
end
end
c95090813.lua
View file @
bfcf52a3
...
@@ -93,7 +93,7 @@ function c95090813.eqop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -93,7 +93,7 @@ function c95090813.eqop(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e2
:
SetProperty
(
EFFECT_FLAG_IGNORE_IMMUNE
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
)
e2
:
SetValue
(
atk
/
2
)
e2
:
SetValue
(
math.ceil
(
atk
/
2
)
)
tc
:
RegisterEffect
(
e2
)
tc
:
RegisterEffect
(
e2
)
local
e3
=
Effect
.
CreateEffect
(
c
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_EQUIP
)
e3
:
SetType
(
EFFECT_TYPE_EQUIP
)
...
...
c95448692.lua
View file @
bfcf52a3
...
@@ -45,6 +45,6 @@ function c95448692.activate2(e,tp,eg,ep,ev,re,r,rp)
...
@@ -45,6 +45,6 @@ function c95448692.activate2(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c95448692
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c95448692
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
c95448692
[
e
:
GetOwnerPlayer
()]
==
1
or
bit
.
band
(
r
,
REASON_EFFECT
)
~=
0
then
if
c95448692
[
e
:
GetOwnerPlayer
()]
==
1
or
bit
.
band
(
r
,
REASON_EFFECT
)
~=
0
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
end
end
c95463814.lua
View file @
bfcf52a3
...
@@ -28,12 +28,12 @@ function c95463814.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -28,12 +28,12 @@ function c95463814.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c95463814
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c95463814
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_FACEUP
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c95463814
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c95463814
.
filter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.
ceil
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
))
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DAMAGE
,
nil
,
0
,
1
-
tp
,
math.
floor
(
g
:
GetFirst
():
GetBaseAttack
()
/
2
))
end
end
function
c95463814
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c95463814
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
if
tc
:
IsFaceup
()
and
tc
:
IsRelateToEffect
(
e
)
then
Duel
.
Damage
(
1
-
tp
,
math.
ceil
(
tc
:
GetBaseAttack
()
/
2
),
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
math.
floor
(
tc
:
GetBaseAttack
()
/
2
),
REASON_EFFECT
)
end
end
end
end
function
c95463814
.
cfilter
(
c
,
tp
)
function
c95463814
.
cfilter
(
c
,
tp
)
...
...
c95685352.lua
View file @
bfcf52a3
...
@@ -54,7 +54,7 @@ function c95685352.atkop1(e,tp,eg,ep,ev,re,r,rp)
...
@@ -54,7 +54,7 @@ function c95685352.atkop1(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetCode
(
EFFECT_SET_BASE_ATTACK
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetValue
(
tc
:
GetBaseAttack
()
/
2
)
e1
:
SetValue
(
math.ceil
(
tc
:
GetBaseAttack
()
/
2
)
)
tc
:
RegisterEffect
(
e1
)
tc
:
RegisterEffect
(
e1
)
end
end
end
end
...
...
c95727991.lua
View file @
bfcf52a3
...
@@ -16,7 +16,7 @@ end
...
@@ -16,7 +16,7 @@ end
function
c95727991
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c95727991
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
CheckReleaseGroup
(
tp
,
nil
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
CheckReleaseGroup
(
tp
,
nil
,
1
,
nil
)
end
local
sg
=
Duel
.
SelectReleaseGroup
(
tp
,
nil
,
1
,
1
,
nil
)
local
sg
=
Duel
.
SelectReleaseGroup
(
tp
,
nil
,
1
,
1
,
nil
)
e
:
SetLabel
(
sg
:
GetFirst
():
GetAttack
()
/
2
)
e
:
SetLabel
(
math.floor
(
sg
:
GetFirst
():
GetAttack
()
/
2
)
)
Duel
.
Release
(
sg
,
REASON_COST
)
Duel
.
Release
(
sg
,
REASON_COST
)
end
end
function
c95727991
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c95727991
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
...
...
c9603356.lua
View file @
bfcf52a3
...
@@ -52,5 +52,5 @@ function c9603356.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -52,5 +52,5 @@ function c9603356.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
and
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
return
ep
~=
tp
and
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
end
end
function
c9603356
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c9603356
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c97342942.lua
View file @
bfcf52a3
...
@@ -34,7 +34,7 @@ function c97342942.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -34,7 +34,7 @@ function c97342942.operation(e,tp,eg,ep,ev,re,r,rp)
if
not
c
:
IsRelateToEffect
(
e
)
then
return
end
if
not
c
:
IsRelateToEffect
(
e
)
then
return
end
local
rg
=
Duel
.
SelectReleaseGroup
(
tp
,
c97342942
.
rfilter
,
1
,
1
,
e
:
GetHandler
(),
e
)
local
rg
=
Duel
.
SelectReleaseGroup
(
tp
,
c97342942
.
rfilter
,
1
,
1
,
e
:
GetHandler
(),
e
)
if
Duel
.
Release
(
rg
,
REASON_EFFECT
)
>
0
then
if
Duel
.
Release
(
rg
,
REASON_EFFECT
)
>
0
then
local
atk
=
rg
:
GetFirst
():
GetBaseAttack
()
/
2
local
atk
=
math.floor
(
rg
:
GetFirst
():
GetBaseAttack
()
/
2
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
end
end
end
end
c981540.lua
View file @
bfcf52a3
...
@@ -38,5 +38,5 @@ function c981540.rdcon(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,5 +38,5 @@ function c981540.rdcon(e,tp,eg,ep,ev,re,r,rp)
return
ep
==
e
:
GetOwnerPlayer
()
return
ep
==
e
:
GetOwnerPlayer
()
end
end
function
c981540
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c981540
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c98637386.lua
View file @
bfcf52a3
...
@@ -38,5 +38,5 @@ function c98637386.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,5 +38,5 @@ function c98637386.spop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c98637386
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c98637386
.
rdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
ChangeBattleDamage
(
ep
,
ev
/
2
)
Duel
.
ChangeBattleDamage
(
ep
,
math.floor
(
ev
/
2
)
)
end
end
c99427357.lua
View file @
bfcf52a3
...
@@ -41,12 +41,12 @@ function c99427357.rectg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...
@@ -41,12 +41,12 @@ function c99427357.rectg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c99427357
.
recfilter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
c99427357
.
recfilter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TARGET
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TARGET
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c99427357
.
recfilter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectTarget
(
tp
,
c99427357
.
recfilter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
1
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
g
:
GetFirst
():
GetAttack
()
/
2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
math.ceil
(
g
:
GetFirst
():
GetAttack
()
/
2
)
)
end
end
function
c99427357
.
recop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c99427357
.
recop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
and
tc
:
GetAttack
()
>
0
then
if
tc
:
IsRelateToEffect
(
e
)
and
tc
:
IsFaceup
()
and
tc
:
GetAttack
()
>
0
then
Duel
.
Recover
(
tp
,
tc
:
GetAttack
()
/
2
,
REASON_EFFECT
)
Duel
.
Recover
(
tp
,
math.ceil
(
tc
:
GetAttack
()
/
2
)
,
REASON_EFFECT
)
end
end
end
end
function
c99427357
.
negcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c99427357
.
negcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
c99795159.lua
View file @
bfcf52a3
...
@@ -36,6 +36,6 @@ function c99795159.dirtg(e,c)
...
@@ -36,6 +36,6 @@ function c99795159.dirtg(e,c)
end
end
function
c99795159
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
function
c99795159
.
val
(
e
,
re
,
dam
,
r
,
rp
,
rc
)
if
bit
.
band
(
r
,
REASON_EFFECT
)
~=
0
or
(
rc
and
not
rc
:
IsSetCard
(
0x8d
))
then
if
bit
.
band
(
r
,
REASON_EFFECT
)
~=
0
or
(
rc
and
not
rc
:
IsSetCard
(
0x8d
))
then
return
dam
/
2
return
math.floor
(
dam
/
2
)
else
return
dam
end
else
return
dam
end
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