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
355231c8
Commit
355231c8
authored
Sep 19, 2015
by
VanillaSalt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
0e32cdfd
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
10 deletions
+17
-10
ocgcore/card.cpp
ocgcore/card.cpp
+10
-6
script/c37745740.lua
script/c37745740.lua
+2
-0
script/c63323539.lua
script/c63323539.lua
+2
-1
script/c81907872.lua
script/c81907872.lua
+3
-3
No files found.
ocgcore/card.cpp
View file @
355231c8
...
...
@@ -448,20 +448,20 @@ void card::calc_attack_defence(int32 *patk, int32 *pdef) {
uint32
base_atk
=
get_base_attack
();
uint32
base_def
=
get_base_defence
();
temp
.
base_attack
=
base_atk
;
temp
.
attack
=
base_atk
;
temp
.
base_defence
=
base_def
;
temp
.
defence
=
base_def
;
int32
up_atk
=
0
,
upc_atk
=
0
;
int32
up_def
=
0
,
upc_def
=
0
;
effect_set
eset
;
filter_effect
(
EFFECT_SWAP_AD
,
&
eset
,
FALSE
);
int32
swap
=
eset
.
size
();
if
(
swap
||
patk
)
{
temp
.
attack
=
base_atk
;
filter_effect
(
EFFECT_UPDATE_ATTACK
,
&
eset
,
FALSE
);
filter_effect
(
EFFECT_SET_ATTACK
,
&
eset
,
FALSE
);
filter_effect
(
EFFECT_SET_ATTACK_FINAL
,
&
eset
,
FALSE
);
}
if
(
swap
||
pdef
)
{
temp
.
defence
=
base_def
;
filter_effect
(
EFFECT_UPDATE_DEFENCE
,
&
eset
,
FALSE
);
filter_effect
(
EFFECT_SET_DEFENCE
,
&
eset
,
FALSE
);
filter_effect
(
EFFECT_SET_DEFENCE_FINAL
,
&
eset
,
FALSE
);
...
...
@@ -527,11 +527,15 @@ void card::calc_attack_defence(int32 *patk, int32 *pdef) {
break
;
}
if
(
!
rev
)
{
temp
.
attack
=
base_atk
+
up_atk
+
upc_atk
;
temp
.
defence
=
base_def
+
up_def
+
upc_def
;
if
(
temp
.
attack
!=
-
1
)
temp
.
attack
=
base_atk
+
up_atk
+
upc_atk
;
if
(
temp
.
defence
!=
-
1
)
temp
.
defence
=
base_def
+
up_def
+
upc_def
;
}
else
{
temp
.
attack
=
base_atk
-
up_atk
-
upc_atk
;
temp
.
defence
=
base_def
-
up_def
-
upc_def
;
if
(
temp
.
attack
!=
-
1
)
temp
.
attack
=
base_atk
-
up_atk
-
upc_atk
;
if
(
temp
.
defence
!=
-
1
)
temp
.
defence
=
base_def
-
up_def
-
upc_def
;
}
}
if
(
swap_final
)
{
...
...
script/c37745740.lua
View file @
355231c8
...
...
@@ -27,6 +27,7 @@ function c37745740.initial_effect(c)
end
function
c37745740
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
CheckReleaseGroup
(
tp
,
Card
.
IsSetCard
,
1
,
nil
,
0x9f
)
end
Duel
.
Hint
(
HINT_OPSELECTED
,
1
-
tp
,
e
:
GetDescription
())
local
g
=
Duel
.
SelectReleaseGroup
(
tp
,
Card
.
IsSetCard
,
1
,
1
,
nil
,
0x9f
)
e
:
SetLabel
(
g
:
GetFirst
():
GetLevel
()
*
100
)
Duel
.
Release
(
g
,
REASON_COST
)
...
...
@@ -43,6 +44,7 @@ function c37745740.operation(e,tp,eg,ep,ev,re,r,rp)
end
function
c37745740
.
thcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
CheckReleaseGroup
(
tp
,
Card
.
IsSetCard
,
1
,
nil
,
0x9f
)
end
Duel
.
Hint
(
HINT_OPSELECTED
,
1
-
tp
,
e
:
GetDescription
())
local
g
=
Duel
.
SelectReleaseGroup
(
tp
,
Card
.
IsSetCard
,
1
,
1
,
nil
,
0x9f
)
e
:
SetLabelObject
(
g
:
GetFirst
())
Duel
.
Release
(
g
,
REASON_COST
)
...
...
script/c63323539.lua
View file @
355231c8
...
...
@@ -23,9 +23,10 @@ function c63323539.operation(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_DESTROY
)
local
g
=
eg
:
FilterSelect
(
tp
,
c63323539
.
filter
,
1
,
1
,
nil
,
e
,
tp
)
local
tc
=
g
:
GetFirst
()
if
not
tc
then
return
end
local
atk
=
tc
:
GetAttack
()
if
atk
<
0
or
tc
:
IsFacedown
()
then
atk
=
0
end
if
tc
and
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
if
Duel
.
Destroy
(
tc
,
REASON_EFFECT
)
~=
0
then
Duel
.
Damage
(
1
-
tp
,
atk
,
REASON_EFFECT
)
end
end
script/c81907872.lua
View file @
355231c8
...
...
@@ -47,11 +47,11 @@ function c81907872.posop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c81907872
.
cfilter1
(
c
,
tp
)
return
c
:
IsControler
(
tp
)
and
c
:
GetPreviousControler
()
==
tp
and
c
:
IsReason
(
REASON_DESTROY
+
REASON_EFFECT
)
and
c
:
IsSetCard
(
0x8d
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
not
c
:
IsPreviousLocation
(
LOCATION_SZONE
)
return
c
:
IsControler
(
tp
)
and
c
:
GetPreviousControler
()
==
tp
and
c
:
IsReason
(
REASON_DESTROY
)
and
c
:
IsReason
(
REASON_EFFECT
)
and
c
:
IsSetCard
(
0x8d
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
not
c
:
IsPreviousLocation
(
LOCATION_SZONE
)
end
function
c81907872
.
cfilter2
(
c
)
return
c
:
IsReason
(
REASON_BATTLE
)
and
c
:
IsStatus
(
STATUS_OPPO_BATTLE
)
and
c
==
Duel
.
GetAttackTarget
()
return
c
:
IsReason
(
REASON_BATTLE
)
and
c
:
IsStatus
(
STATUS_OPPO_BATTLE
)
and
c
==
Duel
.
GetAttackTarget
()
end
function
c81907872
.
spcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
(
rp
~=
tp
and
eg
:
IsExists
(
c81907872
.
cfilter1
,
1
,
nil
,
tp
))
or
eg
:
IsExists
(
c81907872
.
cfilter2
,
1
,
nil
)
...
...
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