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
nanahira
ygopro
Commits
d847a4e5
Commit
d847a4e5
authored
Jul 18, 2012
by
argon.sun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
4946107b
Changes
50
Hide whitespace changes
Inline
Side-by-side
Showing
50 changed files
with
266 additions
and
96 deletions
+266
-96
gframe/data_manager.cpp
gframe/data_manager.cpp
+3
-2
gframe/duelclient.cpp
gframe/duelclient.cpp
+8
-4
gframe/replay_mode.cpp
gframe/replay_mode.cpp
+1
-1
gframe/single_mode.cpp
gframe/single_mode.cpp
+1
-0
gframe/tag_duel.cpp
gframe/tag_duel.cpp
+30
-15
ocgcore/libduel.cpp
ocgcore/libduel.cpp
+2
-0
ocgcore/playerop.cpp
ocgcore/playerop.cpp
+11
-0
script/c10875327.lua
script/c10875327.lua
+2
-0
script/c10979723.lua
script/c10979723.lua
+2
-0
script/c12600382.lua
script/c12600382.lua
+3
-1
script/c13474291.lua
script/c13474291.lua
+2
-0
script/c15187079.lua
script/c15187079.lua
+2
-0
script/c16008155.lua
script/c16008155.lua
+2
-0
script/c16886617.lua
script/c16886617.lua
+2
-0
script/c1710476.lua
script/c1710476.lua
+2
-0
script/c18631392.lua
script/c18631392.lua
+1
-0
script/c19312169.lua
script/c19312169.lua
+2
-0
script/c1953925.lua
script/c1953925.lua
+1
-1
script/c23205979.lua
script/c23205979.lua
+2
-0
script/c2333365.lua
script/c2333365.lua
+2
-0
script/c24857466.lua
script/c24857466.lua
+36
-46
script/c33537328.lua
script/c33537328.lua
+2
-0
script/c35781051.lua
script/c35781051.lua
+17
-11
script/c36521459.lua
script/c36521459.lua
+2
-0
script/c37115575.lua
script/c37115575.lua
+2
-0
script/c39168895.lua
script/c39168895.lua
+2
-0
script/c41181774.lua
script/c41181774.lua
+2
-0
script/c41420027.lua
script/c41420027.lua
+2
-6
script/c45358284.lua
script/c45358284.lua
+2
-0
script/c46263076.lua
script/c46263076.lua
+2
-0
script/c48357738.lua
script/c48357738.lua
+2
-0
script/c55343236.lua
script/c55343236.lua
+2
-0
script/c55982698.lua
script/c55982698.lua
+2
-0
script/c57319935.lua
script/c57319935.lua
+69
-0
script/c59258334.lua
script/c59258334.lua
+2
-0
script/c598988.lua
script/c598988.lua
+2
-0
script/c60627999.lua
script/c60627999.lua
+2
-0
script/c61314842.lua
script/c61314842.lua
+3
-1
script/c69931927.lua
script/c69931927.lua
+2
-0
script/c71983925.lua
script/c71983925.lua
+2
-0
script/c72926163.lua
script/c72926163.lua
+6
-2
script/c79798060.lua
script/c79798060.lua
+2
-0
script/c85684223.lua
script/c85684223.lua
+2
-0
script/c89194033.lua
script/c89194033.lua
+2
-0
script/c91107093.lua
script/c91107093.lua
+2
-0
script/c91895091.lua
script/c91895091.lua
+4
-4
script/c94081496.lua
script/c94081496.lua
+1
-1
script/c9433350.lua
script/c9433350.lua
+2
-0
script/utility.lua
script/utility.lua
+6
-0
system.conf
system.conf
+1
-1
No files found.
gframe/data_manager.cpp
View file @
d847a4e5
...
...
@@ -2,7 +2,7 @@
#include <stdio.h>
namespace
ygo
{
const
wchar_t
*
DataManager
::
unknown_string
=
L"???"
;
wchar_t
DataManager
::
strBuffer
[
2048
];
DataManager
dataManager
;
...
...
@@ -233,7 +233,8 @@ const wchar_t* DataManager::FormatType(int type) {
return
tpBuffer
;
}
int
DataManager
::
CardReader
(
int
code
,
void
*
pData
)
{
dataManager
.
GetData
(
code
,
(
CardData
*
)
pData
);
if
(
!
dataManager
.
GetData
(
code
,
(
CardData
*
)
pData
))
memset
(
pData
,
0
,
sizeof
(
CardData
));
return
0
;
}
...
...
gframe/duelclient.cpp
View file @
d847a4e5
...
...
@@ -1470,7 +1470,7 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
mainGame
->
lstLog
->
addItem
(
textBuffer
);
mainGame
->
logParam
.
push_back
(
code
);
if
(
l
&
0x41
)
{
if
(
count
<=
3
)
{
if
(
count
==
1
)
{
float
shift
=
-
0.15
f
;
if
(
c
==
0
&&
l
==
0x40
)
shift
=
0.15
f
;
pcard
->
dPos
=
irr
::
core
::
vector3df
(
shift
,
0
,
0
);
...
...
@@ -1482,8 +1482,10 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
mainGame
->
WaitFrameSignal
(
45
);
mainGame
->
dField
.
MoveCard
(
pcard
,
5
);
mainGame
->
WaitFrameSignal
(
5
);
}
else
panel_confirm
.
push_back
(
pcard
);
}
else
{
if
(
!
mainGame
->
dInfo
.
isReplay
)
panel_confirm
.
push_back
(
pcard
);
}
}
else
field_confirm
.
push_back
(
pcard
);
}
...
...
@@ -1523,6 +1525,8 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
std
::
sort
(
panel_confirm
.
begin
(),
panel_confirm
.
end
(),
ClientCard
::
client_card_sort
);
mainGame
->
gMutex
.
Lock
();
mainGame
->
dField
.
selectable_cards
=
panel_confirm
;
myswprintf
(
textBuffer
,
dataManager
.
GetSysString
(
208
),
panel_confirm
.
size
());
mainGame
->
wCardSelect
->
setText
(
textBuffer
);
mainGame
->
dField
.
ShowSelectCard
(
true
);
mainGame
->
gMutex
.
Unlock
();
mainGame
->
actionSignal
.
Reset
();
...
...
@@ -1564,7 +1568,7 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
int
player
=
mainGame
->
LocalPlayer
(
BufferIO
::
ReadInt8
(
pbuf
));
int
count
=
BufferIO
::
ReadInt8
(
pbuf
);
mainGame
->
WaitFrameSignal
(
5
);
if
(
player
==
1
&&
!
mainGame
->
dInfo
.
isReplay
)
{
if
(
player
==
1
&&
!
mainGame
->
dInfo
.
isReplay
&&
!
mainGame
->
dInfo
.
isSingleMode
)
{
bool
flip
=
false
;
for
(
auto
cit
=
mainGame
->
dField
.
hand
[
player
].
begin
();
cit
!=
mainGame
->
dField
.
hand
[
player
].
end
();
++
cit
)
if
((
*
cit
)
->
code
)
{
...
...
gframe/replay_mode.cpp
View file @
d847a4e5
...
...
@@ -301,7 +301,7 @@ bool ReplayMode::ReplayAnalyze(char* msg, unsigned int len) {
player
=
BufferIO
::
ReadInt8
(
pbuf
);
count
=
BufferIO
::
ReadInt8
(
pbuf
);
pbuf
+=
count
*
7
;
pauseable
=
false
;
DuelClient
::
ClientAnalyze
(
offset
,
pbuf
-
offset
)
;
break
;
}
case
MSG_SHUFFLE_DECK
:
{
...
...
gframe/single_mode.cpp
View file @
d847a4e5
...
...
@@ -277,6 +277,7 @@ bool SingleMode::SinglePlayAnalyze(char* msg, unsigned int len) {
player
=
BufferIO
::
ReadInt8
(
pbuf
);
count
=
BufferIO
::
ReadInt8
(
pbuf
);
pbuf
+=
count
*
7
;
DuelClient
::
ClientAnalyze
(
offset
,
pbuf
-
offset
);
break
;
}
case
MSG_SHUFFLE_DECK
:
{
...
...
gframe/tag_duel.cpp
View file @
d847a4e5
...
...
@@ -1425,7 +1425,9 @@ void TagDuel::RefreshMzone(int player, int flag, int use_cache) {
BufferIO
::
WriteInt8
(
qbuf
,
player
);
BufferIO
::
WriteInt8
(
qbuf
,
LOCATION_MZONE
);
int
len
=
query_field_card
(
pduel
,
player
,
LOCATION_MZONE
,
flag
,
(
unsigned
char
*
)
qbuf
,
use_cache
);
NetServer
::
SendBufferToPlayer
(
cur_player
[
player
],
STOC_GAME_MSG
,
query_buffer
,
len
+
3
);
int
pid
=
(
player
==
0
)
?
0
:
2
;
NetServer
::
SendBufferToPlayer
(
players
[
pid
],
STOC_GAME_MSG
,
query_buffer
,
len
+
3
);
NetServer
::
ReSendToPlayer
(
players
[
pid
+
1
]);
for
(
int
i
=
0
;
i
<
5
;
++
i
)
{
int
clen
=
BufferIO
::
ReadInt32
(
qbuf
);
if
(
clen
==
4
)
...
...
@@ -1434,9 +1436,9 @@ void TagDuel::RefreshMzone(int player, int flag, int use_cache) {
memset
(
qbuf
,
0
,
clen
-
4
);
qbuf
+=
clen
-
4
;
}
for
(
int
i
=
0
;
i
<
4
;
++
i
)
if
(
players
[
i
]
!=
cur_player
[
player
])
NetServer
::
SendBufferToPlayer
(
players
[
i
],
STOC_GAME_MSG
,
query_buffer
,
len
+
3
);
pid
=
2
-
pid
;
NetServer
::
SendBufferToPlayer
(
players
[
pid
],
STOC_GAME_MSG
,
query_buffer
,
len
+
3
);
NetServer
::
ReSendToPlayer
(
players
[
pid
+
1
]
);
for
(
auto
pit
=
observers
.
begin
();
pit
!=
observers
.
end
();
++
pit
)
NetServer
::
ReSendToPlayer
(
*
pit
);
}
...
...
@@ -1447,7 +1449,9 @@ void TagDuel::RefreshSzone(int player, int flag, int use_cache) {
BufferIO
::
WriteInt8
(
qbuf
,
player
);
BufferIO
::
WriteInt8
(
qbuf
,
LOCATION_SZONE
);
int
len
=
query_field_card
(
pduel
,
player
,
LOCATION_SZONE
,
flag
,
(
unsigned
char
*
)
qbuf
,
use_cache
);
NetServer
::
SendBufferToPlayer
(
cur_player
[
player
],
STOC_GAME_MSG
,
query_buffer
,
len
+
3
);
int
pid
=
(
player
==
0
)
?
0
:
2
;
NetServer
::
SendBufferToPlayer
(
players
[
pid
],
STOC_GAME_MSG
,
query_buffer
,
len
+
3
);
NetServer
::
ReSendToPlayer
(
players
[
pid
+
1
]);
for
(
int
i
=
0
;
i
<
6
;
++
i
)
{
int
clen
=
BufferIO
::
ReadInt32
(
qbuf
);
if
(
clen
==
4
)
...
...
@@ -1456,9 +1460,9 @@ void TagDuel::RefreshSzone(int player, int flag, int use_cache) {
memset
(
qbuf
,
0
,
clen
-
4
);
qbuf
+=
clen
-
4
;
}
for
(
int
i
=
0
;
i
<
4
;
++
i
)
if
(
players
[
i
]
!=
cur_player
[
player
])
NetServer
::
SendBufferToPlayer
(
players
[
i
],
STOC_GAME_MSG
,
query_buffer
,
len
+
3
);
pid
=
2
-
pid
;
NetServer
::
SendBufferToPlayer
(
players
[
pid
],
STOC_GAME_MSG
,
query_buffer
,
len
+
3
);
NetServer
::
ReSendToPlayer
(
players
[
pid
+
1
]
);
for
(
auto
pit
=
observers
.
begin
();
pit
!=
observers
.
end
();
++
pit
)
NetServer
::
ReSendToPlayer
(
*
pit
);
}
...
...
@@ -1518,13 +1522,24 @@ void TagDuel::RefreshSingle(int player, int location, int sequence, int flag) {
int
len
=
query_card
(
pduel
,
player
,
location
,
sequence
,
flag
,
(
unsigned
char
*
)
qbuf
,
0
);
if
(
location
==
LOCATION_REMOVED
&&
(
qbuf
[
15
]
&
POS_FACEDOWN
))
return
;
NetServer
::
SendBufferToPlayer
(
cur_player
[
player
],
STOC_GAME_MSG
,
query_buffer
,
len
+
4
);
if
((
location
&
0x90
)
||
((
location
&
0x2c
)
&&
(
qbuf
[
15
]
&
POS_FACEUP
)))
{
for
(
int
i
=
0
;
i
<
4
;
++
i
)
if
(
players
[
i
]
!=
cur_player
[
player
])
NetServer
::
ReSendToPlayer
(
players
[
i
]);
for
(
auto
pit
=
observers
.
begin
();
pit
!=
observers
.
end
();
++
pit
)
NetServer
::
ReSendToPlayer
(
*
pit
);
if
(
location
&
LOCATION_ONFIELD
)
{
int
pid
=
(
player
==
0
)
?
0
:
2
;
NetServer
::
SendBufferToPlayer
(
players
[
pid
],
STOC_GAME_MSG
,
query_buffer
,
len
+
4
);
NetServer
::
ReSendToPlayer
(
players
[
pid
+
1
]);
if
(
qbuf
[
15
]
&
POS_FACEUP
)
{
pid
=
2
-
pid
;
NetServer
::
SendBufferToPlayer
(
players
[
pid
],
STOC_GAME_MSG
,
query_buffer
,
len
+
4
);
NetServer
::
ReSendToPlayer
(
players
[
pid
+
1
]);
}
}
else
{
NetServer
::
SendBufferToPlayer
(
cur_player
[
player
],
STOC_GAME_MSG
,
query_buffer
,
len
+
4
);
if
(
location
&
0x90
)
{
for
(
int
i
=
0
;
i
<
4
;
++
i
)
if
(
players
[
i
]
!=
cur_player
[
player
])
NetServer
::
ReSendToPlayer
(
players
[
i
]);
for
(
auto
pit
=
observers
.
begin
();
pit
!=
observers
.
end
();
++
pit
)
NetServer
::
ReSendToPlayer
(
*
pit
);
}
}
}
int
TagDuel
::
MessageHandler
(
long
fduel
,
int
type
)
{
...
...
ocgcore/libduel.cpp
View file @
d847a4e5
...
...
@@ -928,6 +928,8 @@ int32 scriptlib::duel_pay_lp_cost(lua_State *L) {
if
(
playerid
!=
0
&&
playerid
!=
1
)
return
0
;
uint32
cost
=
lua_tointeger
(
L
,
2
);
if
(
cost
==
0
)
return
0
;
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
pduel
->
game_field
->
add_process
(
PROCESSOR_PAY_LPCOST
,
0
,
0
,
0
,
playerid
,
cost
);
return
lua_yield
(
L
,
0
);
...
...
ocgcore/playerop.cpp
View file @
d847a4e5
...
...
@@ -387,6 +387,17 @@ int32 field::select_position(uint16 step, uint8 playerid, uint32 code, uint8 pos
returns
.
ivalue
[
0
]
=
positions
;
return
TRUE
;
}
if
((
playerid
==
1
)
&&
(
core
.
duel_options
&
DUEL_SIMPLE_AI
))
{
if
(
positions
&
0x4
)
returns
.
ivalue
[
0
]
=
0x4
;
else
if
(
positions
&
0x1
)
returns
.
ivalue
[
0
]
=
0x1
;
else
if
(
positions
&
0x8
)
returns
.
ivalue
[
0
]
=
0x8
;
else
returns
.
ivalue
[
0
]
=
0x2
;
return
TRUE
;
}
pduel
->
write_buffer8
(
MSG_SELECT_POSITION
);
pduel
->
write_buffer8
(
playerid
);
pduel
->
write_buffer32
(
code
);
...
...
script/c10875327.lua
View file @
d847a4e5
...
...
@@ -17,6 +17,8 @@ function c10875327.initial_effect(c)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCode
(
EFFECT_SELF_DESTROY
)
e4
:
SetCondition
(
c10875327
.
sdcon
)
c
:
RegisterEffect
(
e4
)
...
...
script/c10979723.lua
View file @
d847a4e5
...
...
@@ -34,6 +34,8 @@ function c10979723.initial_effect(c)
c
:
RegisterEffect
(
e5
)
local
e6
=
Effect
.
CreateEffect
(
c
)
e6
:
SetType
(
EFFECT_TYPE_SINGLE
)
e6
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e6
:
SetRange
(
LOCATION_MZONE
)
e6
:
SetCode
(
EFFECT_SELF_DESTROY
)
e6
:
SetCondition
(
c10979723
.
descon
)
c
:
RegisterEffect
(
e6
)
...
...
script/c12600382.lua
View file @
d847a4e5
--エクゾディア·ネクロス
function
c12600382
.
initial_effect
(
c
)
c
:
EnableReviveLimit
()
--cannot destroy
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
...
...
@@ -36,10 +37,11 @@ function c12600382.initial_effect(c)
--selfdes
local
e5
=
Effect
.
CreateEffect
(
c
)
e5
:
SetType
(
EFFECT_TYPE_SINGLE
)
e5
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e5
:
SetRange
(
LOCATION_MZONE
)
e5
:
SetCode
(
EFFECT_SELF_DESTROY
)
e5
:
SetCondition
(
c12600382
.
descondition
)
c
:
RegisterEffect
(
e5
)
c
:
EnableReviveLimit
()
end
function
c12600382
.
efdes
(
e
,
re
)
return
not
re
:
GetHandler
():
IsType
(
TYPE_MONSTER
)
...
...
script/c13474291.lua
View file @
d847a4e5
...
...
@@ -10,6 +10,8 @@ function c13474291.initial_effect(c)
--selfdes
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCode
(
EFFECT_SELF_DESTROY
)
e2
:
SetCondition
(
c13474291
.
sdcon
)
c
:
RegisterEffect
(
e2
)
...
...
script/c15187079.lua
View file @
d847a4e5
...
...
@@ -17,6 +17,8 @@ function c15187079.initial_effect(c)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCode
(
EFFECT_SELF_DESTROY
)
e4
:
SetCondition
(
c15187079
.
sdcon
)
c
:
RegisterEffect
(
e4
)
...
...
script/c16008155.lua
View file @
d847a4e5
...
...
@@ -3,6 +3,8 @@ function c16008155.initial_effect(c)
--self destroy
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCode
(
EFFECT_SELF_DESTROY
)
e1
:
SetCondition
(
c16008155
.
sdcon
)
c
:
RegisterEffect
(
e1
)
...
...
script/c16886617.lua
View file @
d847a4e5
...
...
@@ -24,6 +24,8 @@ function c16886617.initial_effect(c)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCode
(
EFFECT_SELF_DESTROY
)
e4
:
SetCondition
(
c16886617
.
sdcon
)
c
:
RegisterEffect
(
e4
)
...
...
script/c1710476.lua
View file @
d847a4e5
...
...
@@ -36,6 +36,8 @@ function c1710476.initial_effect(c)
--selfdes
local
e7
=
Effect
.
CreateEffect
(
c
)
e7
:
SetType
(
EFFECT_TYPE_SINGLE
)
e7
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e7
:
SetRange
(
LOCATION_MZONE
)
e7
:
SetCode
(
EFFECT_SELF_DESTROY
)
e7
:
SetCondition
(
c1710476
.
descon
)
c
:
RegisterEffect
(
e7
)
...
...
script/c18631392.lua
View file @
d847a4e5
...
...
@@ -79,6 +79,7 @@ function c18631392.retop(code1,code2,code3)
if
c
:
IsRelateToEffect
(
e
)
then
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_COPY_INHERIT
)
e1
:
SetCode
(
EFFECT_SET_ATTACK
)
e1
:
SetValue
(
hg
:
GetCount
()
*
1000
)
e1
:
SetReset
(
RESET_EVENT
+
0x1ff0000
)
...
...
script/c19312169.lua
View file @
d847a4e5
...
...
@@ -9,6 +9,8 @@ function c19312169.initial_effect(c)
--destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetCode
(
EFFECT_SELF_DESTROY
)
e2
:
SetCondition
(
c19312169
.
descon
)
c
:
RegisterEffect
(
e2
)
...
...
script/c1953925.lua
View file @
d847a4e5
...
...
@@ -37,7 +37,7 @@ function c1953925.initial_effect(c)
c
:
RegisterEffect
(
e5
)
end
function
c1953925
.
distg
(
e
,
c
)
if
not
c
:
IsType
(
TYPE_TRAP
)
and
c
:
GetCardTargetCount
()
==
0
then
return
false
end
if
not
c
:
IsType
(
TYPE_TRAP
)
or
c
:
GetCardTargetCount
()
==
0
then
return
false
end
return
c
:
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
c1953925
.
disop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c23205979.lua
View file @
d847a4e5
...
...
@@ -19,6 +19,8 @@ function c23205979.initial_effect(c)
--self des
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCode
(
EFFECT_SELF_DESTROY
)
e3
:
SetCondition
(
c23205979
.
sdcon
)
c
:
RegisterEffect
(
e3
)
...
...
script/c2333365.lua
View file @
d847a4e5
...
...
@@ -3,6 +3,8 @@ function c2333365.initial_effect(c)
--self destroy
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCode
(
EFFECT_SELF_DESTROY
)
e1
:
SetCondition
(
c2333365
.
descon
)
c
:
RegisterEffect
(
e1
)
...
...
script/c24857466.lua
View file @
d847a4e5
--冥王竜ヴァンダルギオン
function
c24857466
.
initial_effect
(
c
)
--counter
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
EVENT_CHAINING
)
e1
:
SetRange
(
LOCATION_HAND
)
e1
:
SetOperation
(
c24857466
.
chop1
)
c
:
RegisterEffect
(
e1
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e2
:
SetCode
(
EVENT_CHAIN_NEGATED
)
e2
:
SetRange
(
LOCATION_HAND
)
e2
:
SetOperation
(
c24857466
.
chop
2
)
e2
:
SetOperation
(
c24857466
.
chop
)
c
:
RegisterEffect
(
e2
)
e1
:
SetLabelObject
(
e2
)
--special summon
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetDescription
(
aux
.
Stringid
(
24857466
,
0
))
...
...
@@ -22,10 +14,9 @@ function c24857466.initial_effect(c)
e3
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e3
:
SetCode
(
EVENT_CHAIN_END
)
e3
:
SetRange
(
LOCATION_HAND
)
e3
:
SetCondition
(
c24857466
.
sumcon
)
e3
:
SetTarget
(
c24857466
.
sumtg
)
e3
:
SetOperation
(
c24857466
.
sumop
)
e3
:
SetLabelObject
(
e2
)
e3
:
SetCondition
(
c24857466
.
hspcon
)
e3
:
SetTarget
(
c24857466
.
hsptg
)
e3
:
SetOperation
(
c24857466
.
hspop
)
c
:
RegisterEffect
(
e3
)
--spell:damage
local
e4
=
Effect
.
CreateEffect
(
c
)
...
...
@@ -33,11 +24,10 @@ function c24857466.initial_effect(c)
e4
:
SetCategory
(
CATEGORY_DAMAGE
)
e4
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e4
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e4
:
SetCode
(
24857466
)
e4
:
SetCondition
(
c24857466
.
damcon
)
e4
:
SetTarget
(
c24857466
.
damtg
)
e4
:
SetOperation
(
c24857466
.
damop
)
e4
:
SetLabelObject
(
e3
)
c
:
RegisterEffect
(
e4
)
--trap:Destroy
local
e5
=
Effect
.
CreateEffect
(
c
)
...
...
@@ -45,11 +35,10 @@ function c24857466.initial_effect(c)
e5
:
SetCategory
(
CATEGORY_DESTROY
)
e5
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e5
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e5
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e5
:
SetCode
(
24857466
)
e5
:
SetCondition
(
c24857466
.
descon
)
e5
:
SetTarget
(
c24857466
.
destg
)
e5
:
SetOperation
(
c24857466
.
desop
)
e5
:
SetLabelObject
(
e3
)
c
:
RegisterEffect
(
e5
)
--monster:spsummon
local
e6
=
Effect
.
CreateEffect
(
c
)
...
...
@@ -57,53 +46,56 @@ function c24857466.initial_effect(c)
e6
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e6
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e6
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
e6
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e6
:
SetCode
(
24857466
)
e6
:
SetCondition
(
c24857466
.
spcon
)
e6
:
SetTarget
(
c24857466
.
sptg
)
e6
:
SetOperation
(
c24857466
.
spop
)
e6
:
SetLabelObject
(
e3
)
c
:
RegisterEffect
(
e6
)
end
function
c24857466
.
chop1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
e
:
GetLabelObject
():
SetLabel
(
0
)
e
:
GetLabelObject
():
SetLabelObject
(
nil
)
end
function
c24857466
.
chop2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c24857466
.
chop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
rp
==
tp
then
return
end
local
de
,
dp
=
Duel
.
GetChainInfo
(
ev
,
CHAININFO_DISABLE_REASON
,
CHAININFO_DISABLE_PLAYER
)
if
de
and
dp
==
tp
and
de
:
GetHandler
():
IsType
(
TYPE_COUNTER
)
then
local
flag
=
e
:
GetLabel
()
if
de
~=
e
:
GetLabelObject
()
then
local
ty
=
re
:
GetActiveType
()
local
flag
=
c
:
GetFlagEffectLabel
(
24857466
)
if
not
flag
then
c
:
RegisterFlagEffect
(
24857466
,
RESET_EVENT
+
0x1fe0000
,
0
,
0
,
ty
)
e
:
SetLabelObject
(
de
)
elseif
de
~=
e
:
GetLabelObject
()
then
e
:
SetLabelObject
(
de
)
flag
=
0
c
:
SetFlagEffectLabel
(
24857466
,
ty
)
else
c
:
SetFlagEffectLabel
(
24857466
,
bit
.
bor
(
flag
,
ty
))
end
local
ty
=
re
:
GetActiveType
()
if
bit
.
band
(
ty
,
TYPE_SPELL
)
~=
0
then
flag
=
bit
.
bor
(
flag
,
0x1
)
elseif
bit
.
band
(
ty
,
TYPE_TRAP
)
~=
0
then
flag
=
bit
.
bor
(
flag
,
0x2
)
else
flag
=
bit
.
bor
(
flag
,
0x4
)
end
e
:
SetLabel
(
flag
)
end
end
function
c24857466
.
sumcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetLabelObject
():
GetLabel
()
~=
0
end
function
c24857466
.
sumtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c24857466
.
hspcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
label
=
c
:
GetFlagEffectLabel
(
24857466
)
if
label
~=
nil
then
c
:
ResetFlagEffect
(
24857466
)
e
:
SetLabel
(
label
)
return
true
else
return
false
end
end
function
c24857466
.
hsptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
e
:
GetHandler
():
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
Duel
.
ConfirmCards
(
1
-
tp
,
e
:
GetHandler
())
Duel
.
ShuffleHand
(
tp
)
e
:
SetLabel
(
e
:
GetLabelObject
()
:
GetLabel
())
Duel
.
SetTargetParam
(
e
:
GetLabel
())
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
e
:
GetHandler
(),
1
,
0
,
0
)
end
function
c24857466
.
sum
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c24857466
.
hsp
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
then
Duel
.
SpecialSummon
(
c
,
1
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
if
c
:
IsRelateToEffect
(
e
)
and
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
>
0
then
local
tpe
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_PARAM
)
Duel
.
RaiseSingleEvent
(
c
,
24857466
,
e
,
0
,
0
,
tp
,
tpe
)
end
end
function
c24857466
.
damcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
GetSummonType
()
==
SUMMON_TYPE_SPECIAL
+
1
and
bit
.
band
(
e
:
GetLabelObject
():
GetLabel
(),
0x1
)
~=
0
return
bit
.
band
(
ev
,
TYPE_SPELL
)
~=
0
end
function
c24857466
.
damtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
...
...
@@ -116,8 +108,7 @@ function c24857466.damop(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Damage
(
p
,
d
,
REASON_EFFECT
)
end
function
c24857466
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
GetSummonType
()
==
SUMMON_TYPE_SPECIAL
+
1
and
bit
.
band
(
e
:
GetLabelObject
():
GetLabel
(),
0x2
)
~=
0
return
bit
.
band
(
ev
,
TYPE_TRAP
)
~=
0
end
function
c24857466
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsControler
(
1
-
tp
)
and
chkc
:
IsOnField
()
and
chkc
:
IsDestructable
()
end
...
...
@@ -133,8 +124,7 @@ function c24857466.desop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c24857466
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
GetSummonType
()
==
SUMMON_TYPE_SPECIAL
+
1
and
bit
.
band
(
e
:
GetLabelObject
():
GetLabel
(),
0x4
)
~=
0
return
bit
.
band
(
ev
,
TYPE_MONSTER
)
~=
0
end
function
c24857466
.
spfilter
(
c
,
e
,
tp
)
return
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
...
...
script/c33537328.lua
View file @
d847a4e5
...
...
@@ -17,6 +17,8 @@ function c33537328.initial_effect(c)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCode
(
EFFECT_SELF_DESTROY
)
e4
:
SetCondition
(
c33537328
.
sdcon
)
c
:
RegisterEffect
(
e4
)
...
...
script/c35781051.lua
View file @
d847a4e5
...
...
@@ -42,18 +42,24 @@ function c35781051.arcanareg(c,coin)
e1
:
SetOperation
(
c35781051
.
spop
)
e1
:
SetReset
(
RESET_EVENT
+
0x1ff0000
)
c
:
RegisterEffect
(
e1
)
--
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
35781051
,
2
))
e2
:
SetCategory
(
CATEGORY_TOGRAVE
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e2
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCondition
(
c35781051
.
tgcon
)
e2
:
SetTarget
(
c35781051
.
tgtg
)
e2
:
SetOperation
(
c35781051
.
tgop
)
e2
:
SetReset
(
RESET_EVENT
+
0x1ff0000
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EVENT_MSET
)
c
:
RegisterEffect
(
e2
)
--
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetDescription
(
aux
.
Stringid
(
35781051
,
2
))
e3
:
SetCategory
(
CATEGORY_TOGRAVE
)
e3
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e3
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCondition
(
c35781051
.
tgcon
)
e3
:
SetTarget
(
c35781051
.
tgtg
)
e3
:
SetOperation
(
c35781051
.
tgop
)
e3
:
SetReset
(
RESET_EVENT
+
0x1ff0000
)
c
:
RegisterEffect
(
e3
)
local
e4
=
e3
:
Clone
()
e4
:
SetCode
(
EVENT_MSET
)
c
:
RegisterEffect
(
e4
)
c
:
RegisterFlagEffect
(
36690018
,
RESET_EVENT
+
0x1ff0000
,
EFFECT_FLAG_CLIENT_HINT
,
1
,
coin
,
63
-
coin
)
end
function
c35781051
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
...
script/c36521459.lua
View file @
d847a4e5
...
...
@@ -36,6 +36,8 @@ function c36521459.initial_effect(c)
--selfdes
local
e7
=
Effect
.
CreateEffect
(
c
)
e7
:
SetType
(
EFFECT_TYPE_SINGLE
)
e7
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e7
:
SetRange
(
LOCATION_MZONE
)
e7
:
SetCode
(
EFFECT_SELF_DESTROY
)
e7
:
SetCondition
(
c36521459
.
descon
)
c
:
RegisterEffect
(
e7
)
...
...
script/c37115575.lua
View file @
d847a4e5
...
...
@@ -40,6 +40,8 @@ function c37115575.initial_effect(c)
--selfdes
local
e7
=
Effect
.
CreateEffect
(
c
)
e7
:
SetType
(
EFFECT_TYPE_SINGLE
)
e7
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e7
:
SetRange
(
LOCATION_MZONE
)
e7
:
SetCode
(
EFFECT_SELF_DESTROY
)
e7
:
SetCondition
(
c37115575
.
descon
)
c
:
RegisterEffect
(
e7
)
...
...
script/c39168895.lua
View file @
d847a4e5
...
...
@@ -16,6 +16,8 @@ function c39168895.initial_effect(c)
--destroy
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCode
(
EFFECT_SELF_DESTROY
)
e3
:
SetCondition
(
c39168895
.
descon
)
c
:
RegisterEffect
(
e3
)
...
...
script/c41181774.lua
View file @
d847a4e5
...
...
@@ -17,6 +17,8 @@ function c41181774.initial_effect(c)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCode
(
EFFECT_SELF_DESTROY
)
e4
:
SetCondition
(
c41181774
.
sdcon
)
c
:
RegisterEffect
(
e4
)
...
...
script/c41420027.lua
View file @
d847a4e5
...
...
@@ -32,9 +32,7 @@ function c41420027.condition1(e,tp,eg,ep,ev,re,r,rp)
end
function
c41420027
.
cost1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
local
lp
=
Duel
.
GetLP
(
tp
)
local
costlp
=
math.floor
((
lp
+
1
)
/
2
)
Duel
.
PayLPCost
(
tp
,
costlp
)
Duel
.
PayLPCost
(
tp
,
Duel
.
GetLP
(
tp
)
/
2
)
end
function
c41420027
.
target1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
...
...
@@ -50,9 +48,7 @@ function c41420027.condition2(e,tp,eg,ep,ev,re,r,rp)
end
function
c41420027
.
cost2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
local
lp
=
Duel
.
GetLP
(
tp
)
local
costlp
=
math.floor
((
lp
+
1
)
/
2
)
Duel
.
PayLPCost
(
tp
,
costlp
)
Duel
.
PayLPCost
(
tp
,
Duel
.
GetLP
(
tp
)
/
2
)
end
function
c41420027
.
target2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
...
...
script/c45358284.lua
View file @
d847a4e5
...
...
@@ -20,6 +20,8 @@ function c45358284.initial_effect(c)
--destroy
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCode
(
EFFECT_SELF_DESTROY
)
e3
:
SetCondition
(
c45358284
.
descon
)
c
:
RegisterEffect
(
e3
)
...
...
script/c46263076.lua
View file @
d847a4e5
...
...
@@ -17,6 +17,8 @@ function c46263076.initial_effect(c)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCode
(
EFFECT_SELF_DESTROY
)
e4
:
SetCondition
(
c46263076
.
sdcon
)
c
:
RegisterEffect
(
e4
)
...
...
script/c48357738.lua
View file @
d847a4e5
...
...
@@ -18,6 +18,8 @@ function c48357738.initial_effect(c)
--des
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e3
:
SetRange
(
LOCATION_SZONE
)
e3
:
SetCode
(
EFFECT_SELF_DESTROY
)
e3
:
SetCondition
(
c48357738
.
descon
)
c
:
RegisterEffect
(
e3
)
...
...
script/c55343236.lua
View file @
d847a4e5
...
...
@@ -36,6 +36,8 @@ function c55343236.initial_effect(c)
--selfdes
local
e7
=
Effect
.
CreateEffect
(
c
)
e7
:
SetType
(
EFFECT_TYPE_SINGLE
)
e7
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e7
:
SetRange
(
LOCATION_MZONE
)
e7
:
SetCode
(
EFFECT_SELF_DESTROY
)
e7
:
SetCondition
(
c55343236
.
descon
)
c
:
RegisterEffect
(
e7
)
...
...
script/c55982698.lua
View file @
d847a4e5
...
...
@@ -13,6 +13,8 @@ function c55982698.initial_effect(c)
--self destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCode
(
EFFECT_SELF_DESTROY
)
e2
:
SetCondition
(
c55982698
.
sdcon
)
c
:
RegisterEffect
(
e2
)
...
...
script/c57319935.lua
0 → 100644
View file @
d847a4e5
--エクシーズ熱戦!!
function
c57319935
.
initial_effect
(
c
)
--Activate
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetCategory
(
CATEGORY_DAMAGE
)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_BATTLE_DESTROYED
)
e1
:
SetCondition
(
c57319935
.
condition
)
e1
:
SetCost
(
c57319935
.
cost
)
e1
:
SetTarget
(
c57319935
.
target
)
e1
:
SetOperation
(
c57319935
.
activate
)
c
:
RegisterEffect
(
e1
)
end
function
c57319935
.
cfilter
(
c
,
tp
)
return
c
:
IsType
(
TYPE_XYZ
)
and
c
:
GetPreviousControler
()
==
tp
end
function
c57319935
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tc
=
eg
:
GetFirst
()
if
c57319935
.
cfilter
(
tc
,
tp
)
then
e
:
SetLabel
(
tc
:
GetRank
())
return
true
end
tc
=
eg
:
GetNext
()
if
tc
and
c57319935
.
cfilter
(
tc
,
tp
)
then
e
:
SetLabel
(
tc
:
GetRank
())
return
true
end
return
false
end
function
c57319935
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
CheckLPCost
(
tp
,
1000
)
end
Duel
.
PayLPCost
(
tp
,
1000
)
end
function
c57319935
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
Card
.
IsRankBelow
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
nil
,
e
:
GetLabel
())
and
Duel
.
GetFieldGroupCount
(
tp
,
0
,
LOCATION_EXTRA
)
>
0
end
end
function
c57319935
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
57319935
,
0
))
local
tc1
=
Duel
.
SelectMatchingCard
(
tp
,
Card
.
IsRankBelow
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
1
,
nil
,
e
:
GetLabel
()):
GetFirst
()
Duel
.
Hint
(
HINT_SELECTMSG
,
1
-
tp
,
aux
.
Stringid
(
57319935
,
0
))
local
tc2
=
Duel
.
SelectMatchingCard
(
1
-
tp
,
Card
.
IsRankBelow
,
1
-
tp
,
LOCATION_EXTRA
,
0
,
1
,
1
,
nil
,
e
:
GetLabel
()):
GetFirst
()
if
tc1
and
tc2
then
Duel
.
ConfirmCards
(
1
-
tp
,
tc1
)
Duel
.
ConfirmCards
(
tp
,
tc2
)
local
atk1
=
tc1
:
GetAttack
()
local
atk2
=
tc2
:
GetAttack
()
if
atk1
>
atk2
then
Duel
.
Damage
(
1
-
tp
,
atk1
-
atk2
,
REASON_EFFECT
)
elseif
atk1
<
atk2
then
Duel
.
Damage
(
tp
,
atk2
-
atk1
,
REASON_EFFECT
)
end
elseif
tc1
then
Duel
.
ConfirmCards
(
1
-
tp
,
tc1
)
local
g
=
Duel
.
GetFieldGroup
(
1
-
tp
,
LOCATION_EXTRA
,
0
)
Duel
.
ConfirmCards
(
tp
,
g
)
Duel
.
Damage
(
1
-
tp
,
tc1
:
GetAttack
(),
REASON_EFFECT
)
elseif
tc2
then
Duel
.
ConfirmCards
(
tp
,
tc2
)
local
g
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_EXTRA
,
0
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
Duel
.
Damage
(
tp
,
tc2
:
GetAttack
(),
REASON_EFFECT
)
else
local
g1
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_EXTRA
,
0
)
local
g2
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_EXTRA
,
0
)
Duel
.
ConfirmCards
(
tp
,
g2
)
Duel
.
ConfirmCards
(
1
-
tp
,
g1
)
end
end
script/c59258334.lua
View file @
d847a4e5
...
...
@@ -12,6 +12,8 @@ function c59258334.initial_effect(c)
--destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetCode
(
EFFECT_SELF_DESTROY
)
e2
:
SetCondition
(
c59258334
.
descon
)
c
:
RegisterEffect
(
e2
)
...
...
script/c598988.lua
View file @
d847a4e5
...
...
@@ -36,6 +36,8 @@ function c598988.initial_effect(c)
--selfdes
local
e7
=
Effect
.
CreateEffect
(
c
)
e7
:
SetType
(
EFFECT_TYPE_SINGLE
)
e7
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e7
:
SetRange
(
LOCATION_MZONE
)
e7
:
SetCode
(
EFFECT_SELF_DESTROY
)
e7
:
SetCondition
(
c598988
.
descon
)
c
:
RegisterEffect
(
e7
)
...
...
script/c60627999.lua
View file @
d847a4e5
...
...
@@ -10,6 +10,8 @@ function c60627999.initial_effect(c)
--destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetCode
(
EFFECT_SELF_DESTROY
)
e2
:
SetCondition
(
c60627999
.
descon
)
c
:
RegisterEffect
(
e2
)
...
...
script/c61314842.lua
View file @
d847a4e5
...
...
@@ -14,12 +14,14 @@ function c61314842.filter(c,e,tp)
return
c
:
IsSetCard
(
0x76
)
and
c
:
IsCanBeEffectTarget
(
e
)
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
function
c61314842
.
xyzfilter
(
c
,
mg
)
if
c
.
xyz_count
~=
2
then
return
false
end
return
c
:
IsXyzSummonable
(
mg
)
end
function
c61314842
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
false
end
local
mg
=
Duel
.
GetMatchingGroup
(
c61314842
.
filter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
,
e
,
tp
)
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
1
and
mg
:
GetCount
()
>
1
end
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
1
and
mg
:
GetCount
()
>
1
and
Duel
.
IsExistingMatchingCard
(
c61314842
.
xyzfilter
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
nil
,
mg
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
local
g
=
mg
:
Select
(
tp
,
2
,
2
,
nil
)
Duel
.
SetTargetCard
(
g
)
...
...
script/c69931927.lua
View file @
d847a4e5
...
...
@@ -17,6 +17,8 @@ function c69931927.initial_effect(c)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCode
(
EFFECT_SELF_DESTROY
)
e4
:
SetCondition
(
c69931927
.
sdcon
)
c
:
RegisterEffect
(
e4
)
...
...
script/c71983925.lua
View file @
d847a4e5
...
...
@@ -9,6 +9,8 @@ function c71983925.initial_effect(c)
--destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e2
:
SetRange
(
LOCATION_SZONE
)
e2
:
SetCode
(
EFFECT_SELF_DESTROY
)
e2
:
SetCondition
(
c71983925
.
descon
)
c
:
RegisterEffect
(
e2
)
...
...
script/c72926163.lua
View file @
d847a4e5
...
...
@@ -14,7 +14,8 @@ function c72926163.initial_effect(c)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e3
:
SetOperation
(
c72926163
.
sucop
)
e3
:
SetCondition
(
c72926163
.
atkcon
)
e3
:
SetOperation
(
c72926163
.
atkop
)
c
:
RegisterEffect
(
e3
)
--multiatk
local
e4
=
Effect
.
CreateEffect
(
c
)
...
...
@@ -33,7 +34,10 @@ c72926163.material={89943723}
function
c72926163
.
splimit
(
e
,
se
,
sp
,
st
)
return
bit
.
band
(
st
,
SUMMON_TYPE_FUSION
)
==
SUMMON_TYPE_FUSION
end
function
c72926163
.
sucop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c72926163
.
atkcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
bit
.
band
(
e
:
GetHandler
():
GetSummonType
(),
SUMMON_TYPE_FUSION
)
==
SUMMON_TYPE_FUSION
end
function
c72926163
.
atkop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
g
=
c
:
GetMaterial
()
local
tc
=
g
:
GetFirst
()
...
...
script/c79798060.lua
View file @
d847a4e5
...
...
@@ -17,6 +17,8 @@ function c79798060.initial_effect(c)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCode
(
EFFECT_SELF_DESTROY
)
e4
:
SetCondition
(
c79798060
.
sdcon
)
c
:
RegisterEffect
(
e4
)
...
...
script/c85684223.lua
View file @
d847a4e5
...
...
@@ -22,6 +22,8 @@ function c85684223.initial_effect(c)
--self des
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCode
(
EFFECT_SELF_DESTROY
)
e3
:
SetCondition
(
c85684223
.
sdcon
)
c
:
RegisterEffect
(
e3
)
...
...
script/c89194033.lua
View file @
d847a4e5
...
...
@@ -3,6 +3,8 @@ function c89194033.initial_effect(c)
--selfdestroy
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCode
(
EFFECT_SELF_DESTROY
)
e1
:
SetCondition
(
c89194033
.
descon
)
c
:
RegisterEffect
(
e1
)
...
...
script/c91107093.lua
View file @
d847a4e5
...
...
@@ -17,6 +17,8 @@ function c91107093.initial_effect(c)
--self destroy
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCode
(
EFFECT_SELF_DESTROY
)
e3
:
SetCondition
(
c91107093
.
descon
)
c
:
RegisterEffect
(
e3
)
...
...
script/c91895091.lua
View file @
d847a4e5
...
...
@@ -3,7 +3,7 @@ function c91895091.initial_effect(c)
--xyz summon
aux
.
AddXyzProcedure
(
c
,
c91895091
.
xyzfilter
,
2
)
c
:
EnableReviveLimit
()
--a
ddown
--a
ctlimit
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
91895091
,
0
))
e1
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
)
...
...
@@ -34,10 +34,10 @@ function c91895091.cost(e,tp,eg,ep,ev,re,r,rp,chk)
e
:
GetHandler
():
RemoveOverlayCard
(
tp
,
1
,
1
,
REASON_COST
)
end
function
c91895091
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_SZONE
)
and
chkc
:
IsFacedown
()
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
Card
.
IsFacedown
,
tp
,
LOCATION_SZONE
,
LOCATION_SZONE
,
1
,
nil
)
end
if
chkc
then
return
chkc
:
IsLocation
(
LOCATION_SZONE
)
and
chkc
:
Is
Controler
(
1
-
tp
)
and
chkc
:
Is
Facedown
()
end
if
chk
==
0
then
return
Duel
.
IsExistingTarget
(
Card
.
IsFacedown
,
tp
,
0
,
LOCATION_SZONE
,
1
,
nil
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
91895091
,
2
))
Duel
.
SelectTarget
(
tp
,
Card
.
IsFacedown
,
tp
,
LOCATION_SZONE
,
LOCATION_SZONE
,
1
,
1
,
nil
)
Duel
.
SelectTarget
(
tp
,
Card
.
IsFacedown
,
tp
,
0
,
LOCATION_SZONE
,
1
,
1
,
nil
)
end
function
c91895091
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
...
...
script/c94081496.lua
View file @
d847a4e5
...
...
@@ -21,7 +21,7 @@ function c94081496.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local
tc
=
eg
:
GetFirst
()
if
chkc
then
return
chkc
==
tc
end
if
chk
==
0
then
return
eg
:
GetCount
()
==
1
and
tc
:
IsFaceup
()
and
tc
:
IsType
(
TYPE_SYNCHRO
)
and
tc
:
IsOnField
()
and
tc
:
IsCanBeEffectTarget
(
e
)
and
tc
:
IsDestructable
()
end
and
tc
:
IsC
ontroler
(
1
-
tp
)
and
tc
:
IsC
anBeEffectTarget
(
e
)
and
tc
:
IsDestructable
()
end
Duel
.
SetTargetCard
(
eg
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
tc
,
1
,
0
,
0
)
end
...
...
script/c9433350.lua
View file @
d847a4e5
...
...
@@ -36,6 +36,8 @@ function c9433350.initial_effect(c)
--selfdes
local
e7
=
Effect
.
CreateEffect
(
c
)
e7
:
SetType
(
EFFECT_TYPE_SINGLE
)
e7
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e7
:
SetRange
(
LOCATION_MZONE
)
e7
:
SetCode
(
EFFECT_SELF_DESTROY
)
e7
:
SetCondition
(
c9433350
.
descon
)
c
:
RegisterEffect
(
e7
)
...
...
script/utility.lua
View file @
d847a4e5
...
...
@@ -158,6 +158,12 @@ function Auxiliary.AddSynchroProcedure2(c,f1,f2)
c
:
RegisterEffect
(
e1
)
end
function
Auxiliary
.
AddXyzProcedure
(
c
,
f
,
ct
,
alterf
,
desc
)
if
c
.
xyz_filter
==
nil
then
local
code
=
c
:
GetOriginalCode
()
local
mt
=
_G
[
"c"
..
code
]
mt
.
xyz_filter
=
f
mt
.
xyz_count
=
ct
end
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
...
...
system.conf
View file @
d847a4e5
#config file
#nickname & gamename should be less than 20 characters
use_d3d
=
1
use_d3d
=
0
antialias
=
2
errorlog
=
1
nickname
=
Player
...
...
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