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
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
Commits
f3c38954
Commit
f3c38954
authored
Jul 21, 2014
by
VanillaSalt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
a699b7e0
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
35 additions
and
21 deletions
+35
-21
gframe/drawing.cpp
gframe/drawing.cpp
+8
-8
ocgcore/interpreter.cpp
ocgcore/interpreter.cpp
+1
-0
ocgcore/libcard.cpp
ocgcore/libcard.cpp
+10
-0
ocgcore/processor.cpp
ocgcore/processor.cpp
+3
-3
ocgcore/scriptlib.h
ocgcore/scriptlib.h
+1
-0
script/c16037007.lua
script/c16037007.lua
+1
-0
script/c82962242.lua
script/c82962242.lua
+1
-1
script/c8522996.lua
script/c8522996.lua
+1
-0
script/c9287078.lua
script/c9287078.lua
+9
-9
No files found.
gframe/drawing.cpp
View file @
f3c38954
...
...
@@ -398,23 +398,23 @@ void Game::DrawMisc() {
}
pcard
=
dField
.
szone
[
0
][
6
];
if
(
pcard
)
{
adFont
->
draw
(
pcard
->
lscstring
,
recti
(
386
,
398
,
398
,
418
),
0xff000000
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
lscstring
,
recti
(
387
,
399
,
399
,
419
),
0xffffffff
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
lscstring
,
recti
(
426
,
394
,
438
,
414
),
0xff000000
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
lscstring
,
recti
(
427
,
395
,
439
,
415
),
0xffffffff
,
true
,
false
,
0
);
}
pcard
=
dField
.
szone
[
0
][
7
];
if
(
pcard
)
{
adFont
->
draw
(
pcard
->
rscstring
,
recti
(
880
,
39
8
,
912
,
418
),
0xff000000
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
rscstring
,
recti
(
881
,
39
9
,
913
,
419
),
0xffffffff
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
rscstring
,
recti
(
880
,
39
4
,
912
,
414
),
0xff000000
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
rscstring
,
recti
(
881
,
39
5
,
913
,
415
),
0xffffffff
,
true
,
false
,
0
);
}
pcard
=
dField
.
szone
[
1
][
6
];
if
(
pcard
)
{
adFont
->
draw
(
pcard
->
lscstring
,
recti
(
83
4
,
245
,
866
,
265
),
0xff000000
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
lscstring
,
recti
(
8
35
,
246
,
867
,
266
),
0xffffffff
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
lscstring
,
recti
(
83
9
,
245
,
871
,
265
),
0xff000000
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
lscstring
,
recti
(
8
40
,
246
,
872
,
266
),
0xffffffff
,
true
,
false
,
0
);
}
pcard
=
dField
.
szone
[
1
][
7
];
if
(
pcard
)
{
adFont
->
draw
(
pcard
->
rscstring
,
recti
(
4
28
,
245
,
460
,
265
),
0xff000000
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
rscstring
,
recti
(
4
29
,
246
,
461
,
266
),
0xffffffff
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
rscstring
,
recti
(
4
63
,
245
,
495
,
265
),
0xff000000
,
true
,
false
,
0
);
adFont
->
draw
(
pcard
->
rscstring
,
recti
(
4
64
,
246
,
496
,
266
),
0xffffffff
,
true
,
false
,
0
);
}
if
(
dField
.
extra
[
0
].
size
())
{
numFont
->
draw
(
dataManager
.
GetNumString
(
dField
.
extra
[
0
].
size
()),
recti
(
330
,
562
,
381
,
552
),
0xff000000
,
true
,
false
,
0
);
...
...
ocgcore/interpreter.cpp
View file @
f3c38954
...
...
@@ -26,6 +26,7 @@ static const struct luaL_Reg cardlib[] = {
{
"GetSynchroLevel"
,
scriptlib
::
card_get_synchro_level
},
{
"GetRitualLevel"
,
scriptlib
::
card_get_ritual_level
},
{
"GetOriginalLevel"
,
scriptlib
::
card_get_origin_level
},
{
"GetOriginalRank"
,
scriptlib
::
card_get_origin_rank
},
{
"IsXyzLevel"
,
scriptlib
::
card_is_xyz_level
},
{
"GetLeftScale"
,
scriptlib
::
card_get_lscale
},
{
"GetRightScale"
,
scriptlib
::
card_get_rscale
},
...
...
ocgcore/libcard.cpp
View file @
f3c38954
...
...
@@ -101,6 +101,16 @@ int32 scriptlib::card_get_origin_level(lua_State *L) {
lua_pushinteger
(
L
,
pcard
->
data
.
level
);
return
1
;
}
int32
scriptlib
::
card_get_origin_rank
(
lua_State
*
L
)
{
check_param_count
(
L
,
1
);
check_param
(
L
,
PARAM_TYPE_CARD
,
1
);
card
*
pcard
=
*
(
card
**
)
lua_touserdata
(
L
,
1
);
if
(
!
(
pcard
->
data
.
type
&
TYPE_XYZ
))
lua_pushinteger
(
L
,
0
);
else
lua_pushinteger
(
L
,
pcard
->
data
.
level
);
return
1
;
}
int32
scriptlib
::
card_is_xyz_level
(
lua_State
*
L
)
{
check_param_count
(
L
,
3
);
check_param
(
L
,
PARAM_TYPE_CARD
,
1
);
...
...
ocgcore/processor.cpp
View file @
f3c38954
...
...
@@ -1837,9 +1837,9 @@ int32 field::process_point_event(int16 step, int32 special, int32 skip_new) {
uint8
tp
=
clit
->
triggering_player
;
core
.
select_effects
.
clear
();
core
.
select_options
.
clear
();
core
.
select_effects
.
push_back
((
effect
*
)
0
);
uintptr_t
index
=
0
;
core
.
select_effects
.
push_back
((
effect
*
)
index
);
core
.
select_options
.
push_back
(
peffect
->
description
);
int32
index
=
0
;
while
(
++
clit
!=
core
.
new_ochain_s
.
end
())
{
++
index
;
peffect
=
clit
->
triggering_effect
;
...
...
@@ -1971,7 +1971,7 @@ int32 field::process_point_event(int16 step, int32 special, int32 skip_new) {
return
TRUE
;
}
case
20
:
{
int32
index
=
(
int32
)
core
.
select_effects
[
returns
.
ivalue
[
0
]];
uintptr_t
index
=
(
uintptr_t
)
core
.
select_effects
[
returns
.
ivalue
[
0
]];
auto
clit
=
core
.
new_ochain_s
.
begin
();
std
::
advance
(
clit
,
index
);
effect
*
peffect
=
clit
->
triggering_effect
;
...
...
ocgcore/scriptlib.h
View file @
f3c38954
...
...
@@ -28,6 +28,7 @@ public:
static
int32
card_get_synchro_level
(
lua_State
*
L
);
static
int32
card_get_ritual_level
(
lua_State
*
L
);
static
int32
card_get_origin_level
(
lua_State
*
L
);
static
int32
card_get_origin_rank
(
lua_State
*
L
);
static
int32
card_is_xyz_level
(
lua_State
*
L
);
static
int32
card_get_lscale
(
lua_State
*
L
);
static
int32
card_get_rscale
(
lua_State
*
L
);
...
...
script/c16037007.lua
View file @
f3c38954
...
...
@@ -39,6 +39,7 @@ function c16037007.disop(e,tp,eg,ep,ev,re,r,rp)
if
Duel
.
NegateActivation
(
ev
)
and
re
:
GetHandler
():
IsRelateToEffect
(
re
)
and
Duel
.
Destroy
(
eg
,
REASON_EFFECT
)
>
0
then
if
Duel
.
IsExistingMatchingCard
(
Card
.
IsDestructable
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
1
,
nil
)
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
16037007
,
1
))
then
Duel
.
BreakEffect
()
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
Card
.
IsDestructable
,
tp
,
LOCATION_ONFIELD
,
LOCATION_ONFIELD
,
1
,
1
,
nil
)
Duel
.
HintSelection
(
g
)
...
...
script/c82962242.lua
View file @
f3c38954
...
...
@@ -46,7 +46,7 @@ function c82962242.cfilter(c,tp)
return
c
:
IsFaceup
()
and
c
:
IsSetCard
(
0x8e
)
and
c
:
IsControler
(
tp
)
end
function
c82962242
.
eqcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
eg
:
IsContains
(
e
:
GetHandler
())
or
eg
:
IsExists
(
c82962242
.
cfilter
,
1
,
nil
,
tp
)
return
not
eg
:
IsContains
(
e
:
GetHandler
())
and
eg
:
IsExists
(
c82962242
.
cfilter
,
1
,
nil
,
tp
)
end
function
c82962242
.
eqfilter
(
c
,
atk
)
return
c
:
IsFaceup
()
and
c
:
GetAttack
()
>
atk
and
c
:
IsAbleToChangeControler
()
...
...
script/c8522996.lua
View file @
f3c38954
...
...
@@ -13,6 +13,7 @@ function c8522996.initial_effect(c)
e2
:
SetDescription
(
aux
.
Stringid
(
8522996
,
1
))
e2
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e2
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e2
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e2
:
SetCondition
(
c8522996
.
con
)
e2
:
SetCost
(
c8522996
.
cost
)
e2
:
SetTarget
(
c8522996
.
tg
)
...
...
script/c9287078.lua
View file @
f3c38954
...
...
@@ -13,21 +13,21 @@ function c9287078.initial_effect(c)
e2
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
c
:
RegisterEffect
(
e2
)
end
function
c9287078
.
filter
(
c
)
function
c9287078
.
filter1
(
c
,
e
,
tp
)
return
c
:
GetSummonPlayer
()
==
1
-
tp
and
c
:
IsCanBeEffectTarget
(
e
)
and
Duel
.
IsExistingTarget
(
c9287078
.
filter2
,
tp
,
LOCATION_MZONE
,
0
,
1
,
c
)
end
function
c9287078
.
filter2
(
c
)
return
c
:
IsFaceup
()
and
c
:
IsRace
(
RACE_SPELLCASTER
)
end
function
c9287078
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chkc
then
return
false
end
if
chk
==
0
then
local
ec
=
eg
:
GetFirst
()
return
eg
:
GetCount
()
==
1
and
ec
:
GetSummonPlayer
()
==
1
-
tp
and
ec
:
IsCanBeEffectTarget
(
e
)
and
Duel
.
IsExistingTarget
(
c9287078
.
filter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
ec
)
end
if
chk
==
0
then
return
eg
:
IsExists
(
c9287078
.
filter1
,
1
,
nil
,
e
,
tp
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TOGRAVE
)
local
g1
=
eg
:
Select
(
tp
,
1
,
1
,
nil
)
local
g1
=
eg
:
FilterSelect
(
tp
,
c9287078
.
filter1
,
1
,
1
,
nil
,
e
,
tp
)
Duel
.
SetTargetCard
(
g1
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TOGRAVE
)
local
g2
=
Duel
.
SelectTarget
(
tp
,
c9287078
.
filter
,
tp
,
LOCATION_MZONE
,
0
,
1
,
1
,
g1
:
GetFirst
())
local
g2
=
Duel
.
SelectTarget
(
tp
,
c9287078
.
filter
2
,
tp
,
LOCATION_MZONE
,
0
,
1
,
1
,
g1
:
GetFirst
())
g1
:
Merge
(
g2
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOGRAVE
,
g1
,
2
,
0
,
0
)
end
...
...
@@ -37,7 +37,7 @@ function c9287078.spfilter(c,e,tp)
end
function
c9287078
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_CARDS
):
Filter
(
Card
.
IsRelateToEffect
,
nil
,
e
)
if
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
==
2
and
g
:
IsExists
(
Card
.
IsLocation
,
2
,
nil
,
LOCATION_GRAVE
)
then
if
g
:
GetCount
()
==
2
and
Duel
.
SendtoGrave
(
g
,
REASON_EFFECT
)
==
2
and
g
:
IsExists
(
Card
.
IsLocation
,
2
,
nil
,
LOCATION_GRAVE
)
then
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<=
0
then
return
end
local
sg
=
Duel
.
GetMatchingGroup
(
c9287078
.
spfilter
,
tp
,
LOCATION_DECK
+
LOCATION_GRAVE
,
0
,
nil
,
e
,
tp
)
if
sg
:
GetCount
()
>
0
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
9287078
,
0
))
then
...
...
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