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
MobiusMei
ygopro
Commits
fdb6e77c
Commit
fdb6e77c
authored
Mar 22, 2015
by
VanillaSalt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
b73f686d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
13 deletions
+10
-13
ocgcore/card.cpp
ocgcore/card.cpp
+0
-6
ocgcore/field.cpp
ocgcore/field.cpp
+8
-4
script/c42664989.lua
script/c42664989.lua
+1
-2
script/c78610936.lua
script/c78610936.lua
+1
-1
No files found.
ocgcore/card.cpp
View file @
fdb6e77c
...
@@ -884,8 +884,6 @@ void card::apply_field_effect() {
...
@@ -884,8 +884,6 @@ void card::apply_field_effect() {
if
(
it
->
second
->
in_range
(
current
.
location
,
current
.
sequence
)
||
((
it
->
second
->
range
&
LOCATION_HAND
)
if
(
it
->
second
->
in_range
(
current
.
location
,
current
.
sequence
)
||
((
it
->
second
->
range
&
LOCATION_HAND
)
&&
(
it
->
second
->
type
&
EFFECT_TYPE_TRIGGER_O
)
&&
!
(
it
->
second
->
code
&
EVENT_PHASE
)))
{
&&
(
it
->
second
->
type
&
EFFECT_TYPE_TRIGGER_O
)
&&
!
(
it
->
second
->
code
&
EVENT_PHASE
)))
{
pduel
->
game_field
->
add_effect
(
it
->
second
);
pduel
->
game_field
->
add_effect
(
it
->
second
);
if
(
it
->
second
->
code
==
EFFECT_SPSUMMON_COUNT_LIMIT
)
pduel
->
game_field
->
effects
.
spsummon_count_eff
.
insert
(
it
->
second
);
}
}
}
}
if
(
unique_code
&&
(
current
.
location
&
LOCATION_ONFIELD
))
if
(
unique_code
&&
(
current
.
location
&
LOCATION_ONFIELD
))
...
@@ -900,8 +898,6 @@ void card::cancel_field_effect() {
...
@@ -900,8 +898,6 @@ void card::cancel_field_effect() {
if
(
it
->
second
->
in_range
(
current
.
location
,
current
.
sequence
)
||
((
it
->
second
->
range
&
LOCATION_HAND
)
if
(
it
->
second
->
in_range
(
current
.
location
,
current
.
sequence
)
||
((
it
->
second
->
range
&
LOCATION_HAND
)
&&
(
it
->
second
->
type
&
EFFECT_TYPE_TRIGGER_O
)
&&
!
(
it
->
second
->
code
&
EVENT_PHASE
)))
{
&&
(
it
->
second
->
type
&
EFFECT_TYPE_TRIGGER_O
)
&&
!
(
it
->
second
->
code
&
EVENT_PHASE
)))
{
pduel
->
game_field
->
remove_effect
(
it
->
second
);
pduel
->
game_field
->
remove_effect
(
it
->
second
);
if
(
it
->
second
->
code
==
EFFECT_SPSUMMON_COUNT_LIMIT
)
pduel
->
game_field
->
effects
.
spsummon_count_eff
.
erase
(
it
->
second
);
}
}
}
}
if
(
unique_code
&&
(
current
.
location
&
LOCATION_ONFIELD
))
if
(
unique_code
&&
(
current
.
location
&
LOCATION_ONFIELD
))
...
@@ -1104,7 +1100,6 @@ int32 card::copy_effect(uint32 code, uint32 reset, uint32 count) {
...
@@ -1104,7 +1100,6 @@ int32 card::copy_effect(uint32 code, uint32 reset, uint32 count) {
read_card
(
code
,
&
cdata
);
read_card
(
code
,
&
cdata
);
if
(
cdata
.
type
&
TYPE_NORMAL
)
if
(
cdata
.
type
&
TYPE_NORMAL
)
return
-
1
;
return
-
1
;
cancel_field_effect
();
set_status
(
STATUS_COPYING_EFFECT
,
TRUE
);
set_status
(
STATUS_COPYING_EFFECT
,
TRUE
);
uint32
cr
=
pduel
->
game_field
->
core
.
copy_reset
;
uint32
cr
=
pduel
->
game_field
->
core
.
copy_reset
;
uint8
crc
=
pduel
->
game_field
->
core
.
copy_reset_count
;
uint8
crc
=
pduel
->
game_field
->
core
.
copy_reset_count
;
...
@@ -1119,7 +1114,6 @@ int32 card::copy_effect(uint32 code, uint32 reset, uint32 count) {
...
@@ -1119,7 +1114,6 @@ int32 card::copy_effect(uint32 code, uint32 reset, uint32 count) {
for
(
auto
eit
=
pduel
->
uncopy
.
begin
();
eit
!=
pduel
->
uncopy
.
end
();
++
eit
)
for
(
auto
eit
=
pduel
->
uncopy
.
begin
();
eit
!=
pduel
->
uncopy
.
end
();
++
eit
)
pduel
->
delete_effect
(
*
eit
);
pduel
->
delete_effect
(
*
eit
);
pduel
->
uncopy
.
clear
();
pduel
->
uncopy
.
clear
();
apply_field_effect
();
return
pduel
->
game_field
->
infos
.
copy_id
-
1
;
return
pduel
->
game_field
->
infos
.
copy_id
-
1
;
}
}
void
card
::
reset
(
uint32
id
,
uint32
reset_type
)
{
void
card
::
reset
(
uint32
id
,
uint32
reset_type
)
{
...
...
ocgcore/field.cpp
View file @
fdb6e77c
...
@@ -687,9 +687,11 @@ void field::add_effect(effect* peffect, uint8 owner_player) {
...
@@ -687,9 +687,11 @@ void field::add_effect(effect* peffect, uint8 owner_player) {
}
}
peffect
->
card_type
=
peffect
->
owner
->
data
.
type
;
peffect
->
card_type
=
peffect
->
owner
->
data
.
type
;
effect_container
::
iterator
it
;
effect_container
::
iterator
it
;
if
(
!
(
peffect
->
type
&
EFFECT_TYPE_ACTIONS
))
if
(
!
(
peffect
->
type
&
EFFECT_TYPE_ACTIONS
))
{
it
=
effects
.
aura_effect
.
insert
(
make_pair
(
peffect
->
code
,
peffect
));
it
=
effects
.
aura_effect
.
insert
(
make_pair
(
peffect
->
code
,
peffect
));
else
{
if
(
peffect
->
code
==
EFFECT_SPSUMMON_COUNT_LIMIT
)
effects
.
spsummon_count_eff
.
insert
(
peffect
);
}
else
{
if
(
peffect
->
type
&
EFFECT_TYPE_IGNITION
)
if
(
peffect
->
type
&
EFFECT_TYPE_IGNITION
)
it
=
effects
.
ignition_effect
.
insert
(
make_pair
(
peffect
->
code
,
peffect
));
it
=
effects
.
ignition_effect
.
insert
(
make_pair
(
peffect
->
code
,
peffect
));
else
if
(
peffect
->
type
&
EFFECT_TYPE_ACTIVATE
)
else
if
(
peffect
->
type
&
EFFECT_TYPE_ACTIVATE
)
...
@@ -722,9 +724,11 @@ void field::remove_effect(effect* peffect) {
...
@@ -722,9 +724,11 @@ void field::remove_effect(effect* peffect) {
if
(
eit
==
effects
.
indexer
.
end
())
if
(
eit
==
effects
.
indexer
.
end
())
return
;
return
;
auto
it
=
eit
->
second
;
auto
it
=
eit
->
second
;
if
(
!
(
peffect
->
type
&
EFFECT_TYPE_ACTIONS
))
if
(
!
(
peffect
->
type
&
EFFECT_TYPE_ACTIONS
))
{
effects
.
aura_effect
.
erase
(
it
);
effects
.
aura_effect
.
erase
(
it
);
else
{
if
(
peffect
->
code
==
EFFECT_SPSUMMON_COUNT_LIMIT
)
effects
.
spsummon_count_eff
.
erase
(
peffect
);
}
else
{
if
(
peffect
->
type
&
EFFECT_TYPE_IGNITION
)
if
(
peffect
->
type
&
EFFECT_TYPE_IGNITION
)
effects
.
ignition_effect
.
erase
(
it
);
effects
.
ignition_effect
.
erase
(
it
);
else
if
(
peffect
->
type
&
EFFECT_TYPE_ACTIVATE
)
else
if
(
peffect
->
type
&
EFFECT_TYPE_ACTIVATE
)
...
...
script/c42664989.lua
View file @
fdb6e77c
...
@@ -12,8 +12,7 @@ function c42664989.initial_effect(c)
...
@@ -12,8 +12,7 @@ function c42664989.initial_effect(c)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
function
c42664989
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c42664989
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
Card
.
IsAbleToRemoveAsCost
,
tp
,
LOCATION_HAND
,
0
,
1
,
e
:
GetHandler
())
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
Card
.
IsAbleToRemoveAsCost
,
tp
,
LOCATION_HAND
+
LOCATION_ONFIELD
,
0
,
1
,
e
:
GetHandler
())
end
or
Duel
.
IsExistingMatchingCard
(
Card
.
IsAbleToRemoveAsCost
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
e
:
GetHandler
())
end
local
g
=
Duel
.
GetMatchingGroup
(
Card
.
IsAbleToRemoveAsCost
,
tp
,
LOCATION_HAND
+
LOCATION_ONFIELD
,
0
,
e
:
GetHandler
())
local
g
=
Duel
.
GetMatchingGroup
(
Card
.
IsAbleToRemoveAsCost
,
tp
,
LOCATION_HAND
+
LOCATION_ONFIELD
,
0
,
e
:
GetHandler
())
Duel
.
Remove
(
g
,
POS_FACEUP
,
REASON_COST
)
Duel
.
Remove
(
g
,
POS_FACEUP
,
REASON_COST
)
end
end
...
...
script/c78610936.lua
View file @
fdb6e77c
...
@@ -29,7 +29,7 @@ function c78610936.activate(e,tp,eg,ep,ev,re,r,rp)
...
@@ -29,7 +29,7 @@ function c78610936.activate(e,tp,eg,ep,ev,re,r,rp)
local
tc
=
Duel
.
GetFirstTarget
()
local
tc
=
Duel
.
GetFirstTarget
()
if
not
tc
:
IsRelateToEffect
(
e
)
then
return
end
if
not
tc
:
IsRelateToEffect
(
e
)
then
return
end
local
mg
=
tc
:
GetOverlayGroup
()
local
mg
=
tc
:
GetOverlayGroup
()
tc
:
RemoveOverlayCard
(
tp
,
mg
:
GetCount
(),
mg
:
GetCount
()
,
REASON_EFFECT
)
Duel
.
SendtoGrave
(
mg
,
REASON_EFFECT
)
if
Duel
.
SendtoDeck
(
tc
,
nil
,
0
,
REASON_EFFECT
)
>
0
then
if
Duel
.
SendtoDeck
(
tc
,
nil
,
0
,
REASON_EFFECT
)
>
0
then
local
g
=
mg
:
Filter
(
c78610936
.
spfilter
,
nil
,
e
,
tp
)
local
g
=
mg
:
Filter
(
c78610936
.
spfilter
,
nil
,
e
,
tp
)
local
ft
=
Duel
.
GetLocationCount
(
1
-
tp
,
LOCATION_MZONE
)
local
ft
=
Duel
.
GetLocationCount
(
1
-
tp
,
LOCATION_MZONE
)
...
...
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