Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
YGOPRO-520DIY
ygopro
Commits
378da927
Commit
378da927
authored
Jun 12, 2015
by
VanillaSalt
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'DailyShna-patch-DP16'
parents
0841b765
01e4f201
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
143 additions
and
138 deletions
+143
-138
ocgcore/card.cpp
ocgcore/card.cpp
+10
-16
ocgcore/effect.cpp
ocgcore/effect.cpp
+1
-1
ocgcore/field.cpp
ocgcore/field.cpp
+2
-2
ocgcore/field.h
ocgcore/field.h
+1
-1
ocgcore/libduel.cpp
ocgcore/libduel.cpp
+8
-2
ocgcore/operations.cpp
ocgcore/operations.cpp
+2
-12
script/c10000080.lua
script/c10000080.lua
+70
-62
script/c14057297.lua
script/c14057297.lua
+23
-20
script/c25280974.lua
script/c25280974.lua
+6
-6
script/c59546797.lua
script/c59546797.lua
+15
-11
script/c97120394.lua
script/c97120394.lua
+5
-5
No files found.
ocgcore/card.cpp
View file @
378da927
...
@@ -1520,17 +1520,14 @@ void card::filter_disable_related_cards() {
...
@@ -1520,17 +1520,14 @@ void card::filter_disable_related_cards() {
}
}
int32
card
::
filter_summon_procedure
(
uint8
playerid
,
effect_set
*
peset
,
uint8
ignore_count
,
uint8
min_tribute
)
{
int32
card
::
filter_summon_procedure
(
uint8
playerid
,
effect_set
*
peset
,
uint8
ignore_count
,
uint8
min_tribute
)
{
effect_set
eset
;
effect_set
eset
;
effect
*
proc
;
filter_effect
(
EFFECT_LIMIT_SUMMON_PROC
,
&
eset
);
filter_effect
(
EFFECT_LIMIT_SUMMON_PROC
,
&
eset
);
if
(
eset
.
size
()
>
1
)
for
(
int32
i
=
0
;
i
<
eset
.
size
();
++
i
)
return
FALSE
;
if
(
eset
[
i
]
->
check_count_limit
(
playerid
)
&&
is_summonable
(
eset
[
i
],
min_tribute
)
&&
pduel
->
game_field
->
is_player_can_summon
(
eset
[
i
]
->
get_value
(
this
),
playerid
,
this
))
peset
->
add_item
(
eset
[
i
]);
if
(
eset
.
size
())
{
if
(
eset
.
size
())
{
proc
=
eset
[
0
];
if
(
peset
->
size
())
if
(
proc
->
check_count_limit
(
playerid
)
&&
is_summonable
(
proc
,
min_tribute
)
&&
pduel
->
game_field
->
is_player_can_summon
(
proc
->
get_value
(
this
),
playerid
,
this
))
{
peset
->
add_item
(
eset
[
0
]);
return
-
1
;
return
-
1
;
}
return
-
2
;
return
-
2
;
}
}
eset
.
clear
();
eset
.
clear
();
...
@@ -1563,17 +1560,14 @@ int32 card::filter_summon_procedure(uint8 playerid, effect_set* peset, uint8 ign
...
@@ -1563,17 +1560,14 @@ int32 card::filter_summon_procedure(uint8 playerid, effect_set* peset, uint8 ign
}
}
int32
card
::
filter_set_procedure
(
uint8
playerid
,
effect_set
*
peset
,
uint8
ignore_count
,
uint8
min_tribute
)
{
int32
card
::
filter_set_procedure
(
uint8
playerid
,
effect_set
*
peset
,
uint8
ignore_count
,
uint8
min_tribute
)
{
effect_set
eset
;
effect_set
eset
;
effect
*
proc
;
filter_effect
(
EFFECT_LIMIT_SET_PROC
,
&
eset
);
filter_effect
(
EFFECT_LIMIT_SET_PROC
,
&
eset
);
if
(
eset
.
size
()
>
1
)
for
(
int32
i
=
0
;
i
<
eset
.
size
();
++
i
)
return
FALSE
;
if
(
eset
[
i
]
->
check_count_limit
(
playerid
)
&&
is_summonable
(
eset
[
i
],
min_tribute
)
&&
pduel
->
game_field
->
is_player_can_mset
(
eset
[
i
]
->
get_value
(
this
),
playerid
,
this
))
peset
->
add_item
(
eset
[
i
]);
if
(
eset
.
size
())
{
if
(
eset
.
size
())
{
proc
=
eset
[
0
];
if
(
peset
->
size
())
if
(
proc
->
check_count_limit
(
playerid
)
&&
is_summonable
(
proc
,
min_tribute
)
&&
pduel
->
game_field
->
is_player_can_mset
(
proc
->
get_value
(
this
),
playerid
,
this
))
{
peset
->
add_item
(
eset
[
0
]);
return
-
1
;
return
-
1
;
}
return
-
2
;
return
-
2
;
}
}
eset
.
clear
();
eset
.
clear
();
...
...
ocgcore/effect.cpp
View file @
378da927
...
@@ -220,7 +220,7 @@ int32 effect::is_activateable(uint8 playerid, const tevent& e, int32 neglect_con
...
@@ -220,7 +220,7 @@ int32 effect::is_activateable(uint8 playerid, const tevent& e, int32 neglect_con
if
(
!
(
flag
&
EFFECT_FLAG_AVAILABLE_BD
)
&&
(
type
&
EFFECT_TYPE_FIELD
)
&&
handler
->
is_status
(
STATUS_BATTLE_DESTROYED
))
if
(
!
(
flag
&
EFFECT_FLAG_AVAILABLE_BD
)
&&
(
type
&
EFFECT_TYPE_FIELD
)
&&
handler
->
is_status
(
STATUS_BATTLE_DESTROYED
))
return
FALSE
;
return
FALSE
;
if
(((
type
&
EFFECT_TYPE_FIELD
)
||
((
type
&
EFFECT_TYPE_SINGLE
)
&&
(
flag
&
EFFECT_FLAG_SINGLE_RANGE
)))
&&
(
handler
->
current
.
location
&
LOCATION_ONFIELD
)
if
(((
type
&
EFFECT_TYPE_FIELD
)
||
((
type
&
EFFECT_TYPE_SINGLE
)
&&
(
flag
&
EFFECT_FLAG_SINGLE_RANGE
)))
&&
(
handler
->
current
.
location
&
LOCATION_ONFIELD
)
&&
(
!
handler
->
is_position
(
POS_FACEUP
)
||
!
handler
->
is_status
(
STATUS_EFFECT_ENABLED
)))
&&
!
(
flag
&
EFFECT_FLAG_SET_AVAILABLE
)
&&
(
!
handler
->
is_position
(
POS_FACEUP
)
||
!
handler
->
is_status
(
STATUS_EFFECT_ENABLED
)))
return
FALSE
;
return
FALSE
;
if
((
type
&
EFFECT_TYPE_SINGLE
)
&&
(
flag
&
EFFECT_FLAG_SINGLE_RANGE
)
&&
!
in_range
(
handler
->
current
.
location
,
handler
->
current
.
sequence
))
if
((
type
&
EFFECT_TYPE_SINGLE
)
&&
(
flag
&
EFFECT_FLAG_SINGLE_RANGE
)
&&
!
in_range
(
handler
->
current
.
location
,
handler
->
current
.
sequence
))
return
FALSE
;
return
FALSE
;
...
...
ocgcore/field.cpp
View file @
378da927
...
@@ -1189,7 +1189,7 @@ int32 field::check_release_list(uint8 playerid, int32 count, int32 use_con, int3
...
@@ -1189,7 +1189,7 @@ int32 field::check_release_list(uint8 playerid, int32 count, int32 use_con, int3
}
}
return
FALSE
;
return
FALSE
;
}
}
int32
field
::
get_summon_release_list
(
card
*
target
,
card_set
*
release_list
,
card_set
*
ex_list
,
card_set
*
ex_list_sum
,
group
*
mg
)
{
int32
field
::
get_summon_release_list
(
card
*
target
,
card_set
*
release_list
,
card_set
*
ex_list
,
card_set
*
ex_list_sum
,
group
*
mg
,
uint32
ex
)
{
uint8
p
=
target
->
current
.
controler
;
uint8
p
=
target
->
current
.
controler
;
card
*
pcard
;
card
*
pcard
;
uint32
rcount
=
0
;
uint32
rcount
=
0
;
...
@@ -1214,7 +1214,7 @@ int32 field::get_summon_release_list(card* target, card_set* release_list, card_
...
@@ -1214,7 +1214,7 @@ int32 field::get_summon_release_list(card* target, card_set* release_list, card_
continue
;
continue
;
if
(
mg
&&
!
mg
->
has_card
(
pcard
))
if
(
mg
&&
!
mg
->
has_card
(
pcard
))
continue
;
continue
;
if
(
pcard
->
is_affected_by_effect
(
EFFECT_EXTRA_RELEASE
))
{
if
(
ex
||
pcard
->
is_affected_by_effect
(
EFFECT_EXTRA_RELEASE
))
{
if
(
ex_list
)
if
(
ex_list
)
ex_list
->
insert
(
pcard
);
ex_list
->
insert
(
pcard
);
if
(
pcard
->
is_affected_by_effect
(
EFFECT_DOUBLE_TRIBUTE
,
target
))
if
(
pcard
->
is_affected_by_effect
(
EFFECT_DOUBLE_TRIBUTE
,
target
))
...
...
ocgcore/field.h
View file @
378da927
...
@@ -350,7 +350,7 @@ public:
...
@@ -350,7 +350,7 @@ public:
int32
get_release_list
(
uint8
playerid
,
card_set
*
release_list
,
card_set
*
ex_list
,
int32
use_con
,
int32
use_hand
,
int32
fun
,
int32
exarg
,
card
*
exp
);
int32
get_release_list
(
uint8
playerid
,
card_set
*
release_list
,
card_set
*
ex_list
,
int32
use_con
,
int32
use_hand
,
int32
fun
,
int32
exarg
,
card
*
exp
);
int32
check_release_list
(
uint8
playerid
,
int32
count
,
int32
use_con
,
int32
use_hand
,
int32
fun
,
int32
exarg
,
card
*
exp
);
int32
check_release_list
(
uint8
playerid
,
int32
count
,
int32
use_con
,
int32
use_hand
,
int32
fun
,
int32
exarg
,
card
*
exp
);
int32
get_summon_release_list
(
card
*
target
,
card_set
*
release_list
,
card_set
*
ex_list
,
card_set
*
ex_list_sum
,
group
*
mg
=
0
);
int32
get_summon_release_list
(
card
*
target
,
card_set
*
release_list
,
card_set
*
ex_list
,
card_set
*
ex_list_sum
,
group
*
mg
=
0
,
uint32
ex
=
0
);
int32
get_summon_count_limit
(
uint8
playerid
);
int32
get_summon_count_limit
(
uint8
playerid
);
int32
get_draw_count
(
uint8
playerid
);
int32
get_draw_count
(
uint8
playerid
);
void
get_ritual_material
(
uint8
playerid
,
effect
*
peffect
,
card_set
*
material
);
void
get_ritual_material
(
uint8
playerid
,
effect
*
peffect
,
card_set
*
material
);
...
...
ocgcore/libduel.cpp
View file @
378da927
...
@@ -1896,8 +1896,11 @@ int32 scriptlib::duel_get_tribute_count(lua_State *L) {
...
@@ -1896,8 +1896,11 @@ int32 scriptlib::duel_get_tribute_count(lua_State *L) {
check_param
(
L
,
PARAM_TYPE_GROUP
,
2
);
check_param
(
L
,
PARAM_TYPE_GROUP
,
2
);
mg
=
*
(
group
**
)
lua_touserdata
(
L
,
2
);
mg
=
*
(
group
**
)
lua_touserdata
(
L
,
2
);
}
}
uint32
ex
=
0
;
if
(
lua_gettop
(
L
)
>=
3
)
ex
=
lua_toboolean
(
L
,
3
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
lua_pushinteger
(
L
,
pduel
->
game_field
->
get_summon_release_list
(
target
,
0
,
0
,
0
,
mg
));
lua_pushinteger
(
L
,
pduel
->
game_field
->
get_summon_release_list
(
target
,
0
,
0
,
0
,
mg
,
ex
));
return
1
;
return
1
;
}
}
int32
scriptlib
::
duel_select_tribute
(
lua_State
*
L
)
{
int32
scriptlib
::
duel_select_tribute
(
lua_State
*
L
)
{
...
@@ -1915,11 +1918,14 @@ int32 scriptlib::duel_select_tribute(lua_State *L) {
...
@@ -1915,11 +1918,14 @@ int32 scriptlib::duel_select_tribute(lua_State *L) {
check_param
(
L
,
PARAM_TYPE_GROUP
,
5
);
check_param
(
L
,
PARAM_TYPE_GROUP
,
5
);
mg
=
*
(
group
**
)
lua_touserdata
(
L
,
5
);
mg
=
*
(
group
**
)
lua_touserdata
(
L
,
5
);
}
}
uint32
ex
=
0
;
if
(
lua_gettop
(
L
)
>=
6
)
ex
=
lua_toboolean
(
L
,
6
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
pduel
->
game_field
->
core
.
release_cards
.
clear
();
pduel
->
game_field
->
core
.
release_cards
.
clear
();
pduel
->
game_field
->
core
.
release_cards_ex
.
clear
();
pduel
->
game_field
->
core
.
release_cards_ex
.
clear
();
pduel
->
game_field
->
core
.
release_cards_ex_sum
.
clear
();
pduel
->
game_field
->
core
.
release_cards_ex_sum
.
clear
();
pduel
->
game_field
->
get_summon_release_list
(
target
,
&
pduel
->
game_field
->
core
.
release_cards
,
&
pduel
->
game_field
->
core
.
release_cards_ex
,
&
pduel
->
game_field
->
core
.
release_cards_ex_sum
,
mg
);
pduel
->
game_field
->
get_summon_release_list
(
target
,
&
pduel
->
game_field
->
core
.
release_cards
,
&
pduel
->
game_field
->
core
.
release_cards_ex
,
&
pduel
->
game_field
->
core
.
release_cards_ex_sum
,
mg
,
ex
);
pduel
->
game_field
->
add_process
(
PROCESSOR_SELECT_TRIBUTE_S
,
0
,
0
,
0
,
playerid
,
(
max
<<
16
)
+
min
);
pduel
->
game_field
->
add_process
(
PROCESSOR_SELECT_TRIBUTE_S
,
0
,
0
,
0
,
playerid
,
(
max
<<
16
)
+
min
);
return
lua_yield
(
L
,
0
);
return
lua_yield
(
L
,
0
);
}
}
...
...
ocgcore/operations.cpp
View file @
378da927
...
@@ -1201,14 +1201,9 @@ int32 field::summon(uint16 step, uint8 sumplayer, card * target, effect * proc,
...
@@ -1201,14 +1201,9 @@ int32 field::summon(uint16 step, uint8 sumplayer, card * target, effect * proc,
core
.
units
.
begin
()
->
step
=
3
;
core
.
units
.
begin
()
->
step
=
3
;
return
FALSE
;
return
FALSE
;
}
}
if
(
res
==
-
1
)
{
core
.
units
.
begin
()
->
peffect
=
eset
[
0
];
core
.
units
.
begin
()
->
step
=
3
;
return
FALSE
;
}
core
.
select_effects
.
clear
();
core
.
select_effects
.
clear
();
core
.
select_options
.
clear
();
core
.
select_options
.
clear
();
if
(
res
)
{
if
(
res
>
0
)
{
core
.
select_effects
.
push_back
(
0
);
core
.
select_effects
.
push_back
(
0
);
core
.
select_options
.
push_back
(
1
);
core
.
select_options
.
push_back
(
1
);
}
}
...
@@ -1694,14 +1689,9 @@ int32 field::mset(uint16 step, uint8 setplayer, card * target, effect * proc, ui
...
@@ -1694,14 +1689,9 @@ int32 field::mset(uint16 step, uint8 setplayer, card * target, effect * proc, ui
core
.
units
.
begin
()
->
step
=
3
;
core
.
units
.
begin
()
->
step
=
3
;
return
FALSE
;
return
FALSE
;
}
}
if
(
res
==
-
1
)
{
core
.
units
.
begin
()
->
peffect
=
eset
[
0
];
core
.
units
.
begin
()
->
step
=
3
;
return
FALSE
;
}
core
.
select_effects
.
clear
();
core
.
select_effects
.
clear
();
core
.
select_options
.
clear
();
core
.
select_options
.
clear
();
if
(
res
)
{
if
(
res
>
0
)
{
core
.
select_effects
.
push_back
(
0
);
core
.
select_effects
.
push_back
(
0
);
core
.
select_options
.
push_back
(
1
);
core
.
select_options
.
push_back
(
1
);
}
}
...
...
script/c10000080.lua
View file @
378da927
--ラーの翼神竜-球体
型
--ラーの翼神竜-球体
形
function
c10000080
.
initial_effect
(
c
)
function
c10000080
.
initial_effect
(
c
)
--
cannot special summon
--
summon with 3 tribute
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
10000080
,
0
))
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SPSUMMON_CONDITION
)
e1
:
SetCode
(
EFFECT_LIMIT_SUMMON_PROC
)
e1
:
SetCondition
(
c10000080
.
ttcon1
)
e1
:
SetOperation
(
c10000080
.
ttop1
)
e1
:
SetValue
(
SUMMON_TYPE_ADVANCE
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
--summon with 3 tribute
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e2
:
SetDescription
(
aux
.
Stringid
(
10000080
,
1
))
e2
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_SPSUM_PARAM
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetCode
(
EFFECT_LIMIT_SUMMON_PROC
)
e2
:
SetCode
(
EFFECT_LIMIT_SUMMON_PROC
)
e2
:
SetCondition
(
c10000080
.
ttcon
)
e2
:
SetTargetRange
(
POS_FACEUP_ATTACK
,
1
)
e2
:
SetOperation
(
c10000080
.
ttop
)
e2
:
SetCondition
(
c10000080
.
ttcon2
)
e2
:
SetOperation
(
c10000080
.
ttop2
)
e2
:
SetValue
(
SUMMON_TYPE_ADVANCE
)
e2
:
SetValue
(
SUMMON_TYPE_ADVANCE
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
local
e3
=
Effect
.
CreateEffect
(
c
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetCode
(
EFFECT_CANNOT_MSET
)
e3
:
SetCode
(
EFFECT_LIMIT_SET_PROC
)
e3
:
SetCondition
(
c10000080
.
setcon
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
--cannot special summon
local
e4
=
Effect
.
CreateEffect
(
c
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetCode
(
EFFECT_SPSUMMON_CONDITION
)
e4
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e4
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e4
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e4
:
SetOperation
(
c10000080
.
retreg
)
c
:
RegisterEffect
(
e4
)
c
:
RegisterEffect
(
e4
)
--c
annot attack
--c
ontrol return
local
e5
=
Effect
.
CreateEffect
(
c
)
local
e5
=
Effect
.
CreateEffect
(
c
)
e5
:
SetType
(
EFFECT_TYPE_SINGLE
)
e5
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e5
:
SetCode
(
EFFECT_CANNOT_ATTACK
)
e5
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e5
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e5
:
SetOperation
(
c10000080
.
retreg
)
c
:
RegisterEffect
(
e5
)
c
:
RegisterEffect
(
e5
)
--
cannot be targe
t
--
attack limi
t
local
e6
=
Effect
.
CreateEffect
(
c
)
local
e6
=
Effect
.
CreateEffect
(
c
)
e6
:
SetType
(
EFFECT_TYPE_SINGLE
)
e6
:
SetType
(
EFFECT_TYPE_SINGLE
)
e6
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e6
:
SetCode
(
EFFECT_CANNOT_ATTACK
)
e6
:
SetRange
(
LOCATION_MZONE
)
e6
:
SetCode
(
EFFECT_CANNOT_BE_BATTLE_TARGET
)
e6
:
SetValue
(
aux
.
imval1
)
c
:
RegisterEffect
(
e6
)
c
:
RegisterEffect
(
e6
)
local
e7
=
e6
:
Clone
()
--cannot be target
e7
:
SetCode
(
EFFECT_CANNOT_BE_EFFECT_TARGET
)
local
e7
=
Effect
.
CreateEffect
(
c
)
e7
:
SetValue
(
aux
.
tgoval
)
e7
:
SetType
(
EFFECT_TYPE_SINGLE
)
e7
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e7
:
SetCode
(
EFFECT_CANNOT_BE_BATTLE_TARGET
)
e7
:
SetRange
(
LOCATION_MZONE
)
e7
:
SetValue
(
aux
.
imval1
)
c
:
RegisterEffect
(
e7
)
c
:
RegisterEffect
(
e7
)
--special summon
local
e8
=
e7
:
Clone
()
local
e8
=
Effect
.
CreateEffect
(
c
)
e8
:
SetCode
(
EFFECT_CANNOT_BE_EFFECT_TARGET
)
e8
:
SetDescription
(
aux
.
Stringid
(
10000080
,
2
))
e8
:
SetValue
(
aux
.
tgoval
)
e8
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e8
:
SetType
(
EFFECT_TYPE_IGNITION
)
e8
:
SetRange
(
LOCATION_MZONE
)
e8
:
SetCost
(
c10000080
.
spcost
)
e8
:
SetTarget
(
c10000080
.
sptg
)
e8
:
SetOperation
(
c10000080
.
spop
)
c
:
RegisterEffect
(
e8
)
c
:
RegisterEffect
(
e8
)
--spsummon
local
e9
=
Effect
.
CreateEffect
(
c
)
e9
:
SetDescription
(
aux
.
Stringid
(
10000080
,
2
))
e9
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e9
:
SetType
(
EFFECT_TYPE_IGNITION
)
e9
:
SetRange
(
LOCATION_MZONE
)
e9
:
SetCost
(
c10000080
.
spcost
)
e9
:
SetTarget
(
c10000080
.
sptg
)
e9
:
SetOperation
(
c10000080
.
spop
)
c
:
RegisterEffect
(
e9
)
end
end
function
c10000080
.
ttcon
(
e
,
c
)
function
c10000080
.
ttcon1
(
e
,
c
)
if
c
==
nil
then
return
true
end
return
Duel
.
GetLocationCount
(
c
:
GetControler
(),
LOCATION_MZONE
)
>-
3
and
Duel
.
GetTributeCount
(
c
)
>=
3
end
function
c10000080
.
ttop1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
)
local
g
=
Duel
.
SelectTribute
(
tp
,
c
,
3
,
3
)
c
:
SetMaterial
(
g
)
Duel
.
Release
(
g
,
REASON_SUMMON
+
REASON_MATERIAL
)
end
function
c10000080
.
ttcon2
(
e
,
c
)
if
c
==
nil
then
return
true
end
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
local
tp
=
c
:
GetControler
()
local
g
=
Duel
.
GetFieldGroup
(
tp
,
0
,
LOCATION_MZONE
)
local
mg
=
Duel
.
GetFieldGroup
(
tp
,
0
,
LOCATION_MZONE
)
return
(
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>-
3
and
Duel
.
GetTributeCount
(
c
)
>=
3
)
return
Duel
.
GetLocationCount
(
1
-
tp
,
LOCATION_MZONE
)
>-
3
and
Duel
.
GetTributeCount
(
c
,
mg
,
true
)
>=
3
or
(
Duel
.
GetLocationCount
(
1
-
tp
,
LOCATION_MZONE
)
>-
3
and
Duel
.
IsExistingMatchingCard
(
Card
.
IsReleasable
,
c
:
GetControler
(),
0
,
LOCATION_MZONE
,
3
,
nil
))
end
end
function
c10000080
.
ttop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
)
function
c10000080
.
ttop2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
)
local
b1
=
Duel
.
GetLocationCount
(
c
:
GetControler
(),
LOCATION_MZONE
)
>-
3
and
Duel
.
GetTributeCount
(
c
)
>=
3
local
mg
=
Duel
.
GetFieldGroup
(
tp
,
0
,
LOCATION_MZONE
)
local
g
=
Duel
.
GetFieldGroup
(
c
:
GetControler
(),
0
,
LOCATION_MZONE
)
local
g
=
Duel
.
SelectTribute
(
tp
,
c
,
3
,
3
,
mg
,
true
)
local
b2
=
Duel
.
GetLocationCount
(
1
-
c
:
GetControler
(),
LOCATION_MZONE
)
>-
3
and
Duel
.
IsExistingMatchingCard
(
Card
.
IsReleasable
,
c
:
GetControler
(),
0
,
LOCATION_MZONE
,
3
,
nil
)
c
:
SetMaterial
(
g
)
local
op
=
0
Duel
.
Release
(
g
,
REASON_SUMMON
+
REASON_MATERIAL
)
if
b1
and
b2
then
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
10000080
,
0
),
aux
.
Stringid
(
10000080
,
1
))
elseif
b1
then
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
10000080
,
0
))
else
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
10000080
,
1
))
+
1
end
if
op
==
0
then
local
mg
=
Duel
.
SelectTribute
(
tp
,
c
,
3
,
3
)
c
:
SetMaterial
(
mg
)
Duel
.
Release
(
mg
,
REASON_SUMMON
+
REASON_MATERIAL
)
else
local
sg
=
Duel
.
SelectMatchingCard
(
tp
,
Card
.
IsReleasable
,
tp
,
0
,
LOCATION_MZONE
,
3
,
3
,
nil
)
c
:
SetMaterial
(
sg
)
Duel
.
Release
(
sg
,
REASON_SUMMON
+
REASON_MATERIAL
)
e
:
SetProperty
(
EFFECT_FLAG_SPSUM_PARAM
)
e
:
SetTargetRange
(
POS_FACEUP_ATTACK
,
1
)
end
end
end
function
c10000080
.
setcon
(
e
,
c
)
function
c10000080
.
setcon
(
e
,
c
)
if
not
c
then
return
true
end
if
not
c
then
return
true
end
return
false
return
false
end
end
function
c10000080
.
retreg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c10000080
.
retreg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
c
=
e
:
GetHandler
()
c
:
RegisterFlagEffect
(
10000080
,
RESET_EVENT
+
0x1fc0000
+
RESET_PHASE
+
RESET_END
,
0
,
2
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetLabel
(
Duel
.
GetTurnCount
())
e1
:
SetLabel
(
Duel
.
GetTurnCount
()
+
1
)
e1
:
SetCountLimit
(
1
)
e1
:
SetCountLimit
(
1
)
e1
:
SetCondition
(
c10000080
.
retcon
)
e1
:
SetCondition
(
c10000080
.
retcon
)
e1
:
SetOperation
(
c10000080
.
retop
)
e1
:
SetOperation
(
c10000080
.
retop
)
e1
:
SetReset
(
RESET_
EVENT
+
0x1fe0000
+
RESET_
PHASE
+
RESET_END
,
2
)
e1
:
SetReset
(
RESET_PHASE
+
RESET_END
,
2
)
e
:
GetHandler
():
RegisterEffect
(
e1
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
end
function
c10000080
.
retcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c10000080
.
retcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetTurnCount
()
~=
e
:
GetLabel
()
return
Duel
.
GetTurnCount
()
==
e
:
GetLabel
()
and
e
:
GetOwner
():
GetFlagEffect
(
10000080
)
~=
0
end
end
function
c10000080
.
retop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c10000080
.
retop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
Get
Handl
er
()
local
c
=
e
:
Get
Own
er
()
if
c
:
GetControler
()
~=
c
:
GetOwner
()
then
if
c
:
GetControler
()
~=
c
:
GetOwner
()
then
Duel
.
GetControl
(
c
,
c
:
GetOwner
())
Duel
.
GetControl
(
c
,
c
:
GetOwner
())
end
end
...
@@ -116,7 +124,7 @@ end
...
@@ -116,7 +124,7 @@ end
function
c10000080
.
sptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c10000080
.
sptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>-
1
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>-
1
and
Duel
.
IsExistingMatchingCard
(
c10000080
.
filter
,
tp
,
LOCATION_HAND
+
LOCATION_DECK
,
0
,
1
,
nil
,
e
,
tp
)
end
and
Duel
.
IsExistingMatchingCard
(
c10000080
.
filter
,
tp
,
LOCATION_HAND
+
LOCATION_DECK
,
0
,
1
,
nil
,
e
,
tp
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
nil
,
0
,
tp
,
LOCATION_HAND
+
LOCATION_DECK
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
nil
,
1
,
tp
,
LOCATION_HAND
+
LOCATION_DECK
)
end
end
function
c10000080
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c10000080
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<=
0
then
return
end
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<=
0
then
return
end
...
...
script/c14057297.lua
View file @
378da927
...
@@ -16,30 +16,33 @@ function c14057297.condition(e,tp,eg,ep,ev,re,r,rp)
...
@@ -16,30 +16,33 @@ function c14057297.condition(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c14057297
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c14057297
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsPlayerCanDraw
(
tp
,
5
)
and
Duel
.
IsPlayerCanDraw
(
1
-
tp
,
5
)
end
if
chk
==
0
then
return
Duel
.
IsPlayerCanDraw
(
tp
,
5
)
and
Duel
.
IsPlayerCanDraw
(
1
-
tp
,
5
)
end
local
g1
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_HAND
,
0
)
local
g
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_HAND
,
LOCATION_HAND
)
local
g2
=
Duel
.
GetFieldGroup
(
tp
,
0
,
LOCATION_HAND
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TODECK
,
g
,
g
:
GetCount
(),
0
,
0
)
g1
:
Merge
(
g2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TODECK
,
g1
,
g1
:
GetCount
(),
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DRAW
,
nil
,
0
,
PLAYER_ALL
,
5
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DRAW
,
nil
,
0
,
PLAYER_ALL
,
5
)
end
end
function
c14057297
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c14057297
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
ct1
=
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_HAND
,
0
)
if
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_HAND
,
LOCATION_HAND
)
==
0
then
return
end
local
ct2
=
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_HAND
)
local
p
=
tp
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TODECK
)
local
st
=
0
local
g1
=
Duel
.
SelectMatchingCard
(
tp
,
aux
.
TRUE
,
tp
,
LOCATION_HAND
,
0
,
ct1
,
ct1
,
nil
)
for
i
=
1
,
2
do
Duel
.
Hint
(
HINT_SELECTMSG
,
1
-
tp
,
HINTMSG_TODECK
)
local
sg
=
Duel
.
GetFieldGroup
(
p
,
LOCATION_HAND
,
0
)
local
g2
=
Duel
.
SelectMatchingCard
(
1
-
tp
,
aux
.
TRUE
,
tp
,
0
,
LOCATION_HAND
,
ct2
,
ct2
,
nil
)
Duel
.
SendtoDeck
(
sg
,
nil
,
0
,
REASON_EFFECT
)
g1
:
Merge
(
g2
)
local
og
=
Duel
.
GetOperatedGroup
(
)
local
count
=
Duel
.
SendtoDeck
(
g1
,
nil
,
1
,
REASON_EFFECT
)
local
ct
=
og
:
FilterCount
(
Card
.
IsLocation
,
nil
,
LOCATION_DECK
)
if
coun
t
>
0
then
if
c
t
>
0
then
Duel
.
BreakEffect
()
st
=
st
+
ct
local
lp
=
Duel
.
GetLP
(
tp
)
Duel
.
SortDecktop
(
p
,
p
,
ct
)
if
lp
<=
count
*
300
then
for
j
=
1
,
ct
do
Duel
.
SetLP
(
tp
,
0
)
local
mg
=
Duel
.
GetDecktopGroup
(
p
,
1
)
else
Duel
.
MoveSequence
(
mg
:
GetFirst
(),
1
)
Duel
.
SetLP
(
tp
,
lp
-
count
*
300
)
end
end
end
if
lp
==
0
then
return
end
p
=
1
-
p
end
local
lp
=
Duel
.
GetLP
(
tp
)
Duel
.
SetLP
(
tp
,
lp
-
st
*
300
)
if
Duel
.
GetLP
(
tp
)
>
0
then
Duel
.
BreakEffect
()
Duel
.
Draw
(
tp
,
5
,
REASON_EFFECT
)
Duel
.
Draw
(
tp
,
5
,
REASON_EFFECT
)
Duel
.
Draw
(
1
-
tp
,
5
,
REASON_EFFECT
)
Duel
.
Draw
(
1
-
tp
,
5
,
REASON_EFFECT
)
end
end
...
...
script/c25280974.lua
View file @
378da927
...
@@ -17,22 +17,22 @@ function c25280974.initial_effect(c)
...
@@ -17,22 +17,22 @@ function c25280974.initial_effect(c)
e2
:
SetProperty
(
EFFECT_FLAG_DAMAGE_STEP
+
EFFECT_FLAG_DELAY
)
e2
:
SetProperty
(
EFFECT_FLAG_DAMAGE_STEP
+
EFFECT_FLAG_DELAY
)
e2
:
SetCode
(
EVENT_TO_GRAVE
)
e2
:
SetCode
(
EVENT_TO_GRAVE
)
e2
:
SetCountLimit
(
1
,
25280974
)
e2
:
SetCountLimit
(
1
,
25280974
)
e2
:
SetCondition
(
c25280974
.
conditi
on
)
e2
:
SetCondition
(
c25280974
.
thc
on
)
e2
:
SetTarget
(
c25280974
.
t
arget
)
e2
:
SetTarget
(
c25280974
.
t
htg
)
e2
:
SetOperation
(
c25280974
.
operation
)
e2
:
SetOperation
(
c25280974
.
thop
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
function
c25280974
.
conditi
on
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c25280974
.
thc
on
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_ONFIELD
)
return
e
:
GetHandler
():
IsPreviousLocation
(
LOCATION_ONFIELD
)
end
end
function
c25280974
.
filter
(
c
)
function
c25280974
.
filter
(
c
)
return
c
:
IsType
(
TYPE_NORMAL
)
and
c
:
IsRace
(
RACE_SPELLCASTER
)
and
c
:
IsAbleToHand
()
and
not
c
:
IsHasEffect
(
EFFECT_NECRO_VALLEY
)
return
c
:
IsType
(
TYPE_NORMAL
)
and
c
:
IsRace
(
RACE_SPELLCASTER
)
and
c
:
IsAbleToHand
()
and
not
c
:
IsHasEffect
(
EFFECT_NECRO_VALLEY
)
end
end
function
c25280974
.
t
arget
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c25280974
.
t
htg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c25280974
.
filter
,
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
1
,
nil
)
end
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c25280974
.
filter
,
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
1
,
nil
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
1
,
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
1
,
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
)
end
end
function
c25280974
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c25280974
.
thop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c25280974
.
filter
,
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c25280974
.
filter
,
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
if
g
:
GetCount
()
>
0
then
...
...
script/c59546797.lua
View file @
378da927
--ジュラゲド
--ジュラゲド
function
c59546797
.
initial_effect
(
c
)
function
c59546797
.
initial_effect
(
c
)
--summon
--s
ps
ummon
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
59546797
,
0
))
e1
:
SetDescription
(
aux
.
Stringid
(
59546797
,
0
))
e1
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
+
CATEGORY_RECOVER
)
e1
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
+
CATEGORY_RECOVER
)
...
@@ -8,9 +8,9 @@ function c59546797.initial_effect(c)
...
@@ -8,9 +8,9 @@ function c59546797.initial_effect(c)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetRange
(
LOCATION_HAND
)
e1
:
SetRange
(
LOCATION_HAND
)
e1
:
SetCountLimit
(
1
,
59546797
)
e1
:
SetCountLimit
(
1
,
59546797
)
e1
:
SetCondition
(
c59546797
.
conditi
on
)
e1
:
SetCondition
(
c59546797
.
spc
on
)
e1
:
SetTarget
(
c59546797
.
target
)
e1
:
SetTarget
(
c59546797
.
sptg
)
e1
:
SetOperation
(
c59546797
.
operation
)
e1
:
SetOperation
(
c59546797
.
spop
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
--atk
--atk
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
...
@@ -19,29 +19,33 @@ function c59546797.initial_effect(c)
...
@@ -19,29 +19,33 @@ function c59546797.initial_effect(c)
e2
:
SetType
(
EFFECT_TYPE_QUICK_O
)
e2
:
SetType
(
EFFECT_TYPE_QUICK_O
)
e2
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
+
EFFECT_FLAG_DAMAGE_STEP
)
e2
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
+
EFFECT_FLAG_DAMAGE_STEP
)
e2
:
SetCode
(
EVENT_FREE_CHAIN
)
e2
:
SetCode
(
EVENT_FREE_CHAIN
)
e2
:
SetHintTiming
(
TIMING_DAMAGE_STEP
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetHintTiming
(
TIMING_DAMAGE_STEP
)
e2
:
SetCondition
(
c59546797
.
atkcon
)
e2
:
SetCost
(
c59546797
.
atkcost
)
e2
:
SetCost
(
c59546797
.
atkcost
)
e2
:
SetTarget
(
c59546797
.
atktg
)
e2
:
SetTarget
(
c59546797
.
atktg
)
e2
:
SetOperation
(
c59546797
.
atkop
)
e2
:
SetOperation
(
c59546797
.
atkop
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
function
c59546797
.
conditi
on
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c59546797
.
spc
on
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetCurrentPhase
()
==
PHASE_BATTLE
and
not
Duel
.
CheckTiming
(
TIMING_BATTLE_START
)
and
not
Duel
.
CheckTiming
(
TIMING_BATTLE_END
)
return
Duel
.
GetCurrentPhase
()
==
PHASE_BATTLE
and
not
Duel
.
CheckTiming
(
TIMING_BATTLE_START
+
TIMING_BATTLE_END
)
end
end
function
c59546797
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c59546797
.
sptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
not
e
:
GetHandler
():
IsStatus
(
STATUS_CHAINING
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
if
chk
==
0
then
return
not
e
:
GetHandler
():
IsStatus
(
STATUS_CHAINING
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
e
:
GetHandler
():
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
and
e
:
GetHandler
():
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
e
:
GetHandler
(),
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
e
:
GetHandler
(),
1
,
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_RECOVER
,
nil
,
0
,
tp
,
1000
)
end
end
function
c59546797
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c59546797
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<=
0
then
return
end
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
~=
0
then
if
c
:
IsRelateToEffect
(
e
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
~=
0
then
Duel
.
Recover
(
tp
,
1000
,
REASON_EFFECT
)
Duel
.
Recover
(
tp
,
1000
,
REASON_EFFECT
)
elseif
Duel
.
IsPlayerCanSpecialSummon
(
tp
)
then
Duel
.
SendtoGrave
(
c
,
REASON_RULE
)
end
end
end
end
function
c59546797
.
atkcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetCurrentPhase
()
~=
PHASE_DAMAGE
or
not
Duel
.
IsDamageCalculated
()
end
function
c59546797
.
atkcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c59546797
.
atkcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
e
:
GetHandler
():
IsReleasable
()
end
if
chk
==
0
then
return
e
:
GetHandler
():
IsReleasable
()
end
Duel
.
Release
(
e
:
GetHandler
(),
REASON_COST
)
Duel
.
Release
(
e
:
GetHandler
(),
REASON_COST
)
...
...
script/c97120394.lua
View file @
378da927
--封魔の矢
--封魔の矢
function
c97120394
2
.
initial_effect
(
c
)
function
c97120394
.
initial_effect
(
c
)
--Activate
--Activate
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetHintTiming
(
TIMING_BATTLE_START
,
0
)
e1
:
SetHintTiming
(
TIMING_BATTLE_START
)
e1
:
SetCondition
(
c97120394
.
condition
)
e1
:
SetCondition
(
c97120394
.
condition
)
e1
:
SetTarget
(
c97120394
.
target
)
e1
:
SetTarget
(
c97120394
.
target
)
e1
:
SetOperation
(
c97120394
.
operation
)
e1
:
SetOperation
(
c97120394
.
activate
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
function
c97120394
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c97120394
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
@@ -17,11 +17,11 @@ function c97120394.target(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -17,11 +17,11 @@ function c97120394.target(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
Duel
.
SetChainLimit
(
aux
.
FALSE
)
Duel
.
SetChainLimit
(
aux
.
FALSE
)
end
end
function
c97120394
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c97120394
.
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_FIELD
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetCode
(
EFFECT_CANNOT_ACTIVATE
)
e1
:
SetCode
(
EFFECT_CANNOT_ACTIVATE
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetTargetRange
(
1
,
1
)
e1
:
SetTargetRange
(
1
,
1
)
e1
:
SetValue
(
c97120394
.
aclimit
)
e1
:
SetValue
(
c97120394
.
aclimit
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_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