Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-2pick
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-2pick
Commits
8ee9467d
Commit
8ee9467d
authored
Nov 23, 2012
by
VanillaSalt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
suggest
parent
b50bc708
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
34 additions
and
30 deletions
+34
-30
ocgcore/card.cpp
ocgcore/card.cpp
+4
-2
ocgcore/operations.cpp
ocgcore/operations.cpp
+26
-0
script/c18988391.lua
script/c18988391.lua
+4
-28
No files found.
ocgcore/card.cpp
View file @
8ee9467d
...
@@ -1509,8 +1509,10 @@ int32 card::get_summon_tribute_count() {
...
@@ -1509,8 +1509,10 @@ int32 card::get_summon_tribute_count() {
min
=
max
=
2
;
min
=
max
=
2
;
effect_set
eset
;
effect_set
eset
;
filter_effect
(
EFFECT_DECREASE_TRIBUTE
,
&
eset
);
filter_effect
(
EFFECT_DECREASE_TRIBUTE
,
&
eset
);
if
(
eset
.
count
)
{
for
(
int32
i
=
0
;
i
<
eset
.
count
;
++
i
)
{
int32
dec
=
eset
.
get_last
()
->
get_value
(
this
);
if
((
eset
[
i
]
->
flag
&
EFFECT_FLAG_COUNT_LIMIT
)
&&
(
eset
[
i
]
->
reset_count
&
0xf00
)
==
0
)
continue
;
int32
dec
=
eset
[
i
]
->
get_value
(
this
);
min
-=
dec
&
0xffff
;
min
-=
dec
&
0xffff
;
max
-=
dec
>>
16
;
max
-=
dec
>>
16
;
}
}
...
...
ocgcore/operations.cpp
View file @
8ee9467d
...
@@ -1185,6 +1185,32 @@ int32 field::summon(uint16 step, uint8 sumplayer, card * target, effect * proc,
...
@@ -1185,6 +1185,32 @@ int32 field::summon(uint16 step, uint8 sumplayer, card * target, effect * proc,
return
FALSE
;
return
FALSE
;
}
}
case
3
:
{
case
3
:
{
int32
min
=
0
;
int32
level
=
target
->
get_level
();
if
(
level
<
5
)
min
=
0
;
else
if
(
level
<
7
)
min
=
1
;
else
min
=
2
;
min
-=
returns
.
bvalue
[
0
];
effect_set
eset
;
target
->
filter_effect
(
EFFECT_DECREASE_TRIBUTE
,
&
eset
);
for
(
int32
i
=
0
;
i
<
eset
.
count
;
++
i
)
{
if
(
!
(
eset
[
i
]
->
flag
&
EFFECT_FLAG_COUNT_LIMIT
))
{
int32
dec
=
eset
[
i
]
->
get_value
(
target
);
min
-=
dec
&
0xffff
;
}
}
for
(
int32
i
=
0
;
i
<
eset
.
count
;
++
i
)
{
if
(
min
<=
0
)
break
;
if
((
eset
[
i
]
->
flag
&
EFFECT_FLAG_COUNT_LIMIT
)
&&
(
eset
[
i
]
->
reset_count
&
0xf00
)
>
0
)
{
int32
dec
=
eset
[
i
]
->
get_value
(
target
);
min
-=
dec
&
0xffff
;
eset
[
i
]
->
dec_count
();
}
}
if
(
returns
.
bvalue
[
0
])
{
if
(
returns
.
bvalue
[
0
])
{
card_set
tributes
;
card_set
tributes
;
for
(
int32
i
=
0
;
i
<
returns
.
bvalue
[
0
];
++
i
)
{
for
(
int32
i
=
0
;
i
<
returns
.
bvalue
[
0
];
++
i
)
{
...
...
script/c18988391.lua
View file @
8ee9467d
--アマリリース
--アマリリース
function
c18988391
.
initial_effect
(
c
)
function
c18988391
.
initial_effect
(
c
)
--
--
decrease tribute
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
18988391
,
0
))
e1
:
SetDescription
(
aux
.
Stringid
(
18988391
,
0
))
e1
:
SetType
(
EFFECT_TYPE_IGNITION
)
e1
:
SetType
(
EFFECT_TYPE_IGNITION
)
...
@@ -18,34 +18,10 @@ function c18988391.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -18,34 +18,10 @@ function c18988391.operation(e,tp,eg,ep,ev,re,r,rp)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetDescription
(
aux
.
Stringid
(
18988391
,
1
))
e1
:
SetDescription
(
aux
.
Stringid
(
18988391
,
1
))
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_DECREASE_TRIBUTE
)
e1
:
SetTargetRange
(
LOCATION_HAND
,
0
)
e1
:
SetTargetRange
(
LOCATION_HAND
,
0
)
e1
:
SetCode
(
EFFECT_SUMMON_PROC
)
e1
:
SetCountLimit
(
1
)
e1
:
SetCondition
(
c18988391
.
sumcon
)
e1
:
SetValue
(
0x1
)
e1
:
SetTarget
(
c18988391
.
efftg
)
e1
:
SetOperation
(
c18988391
.
sumop
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
Duel
.
RegisterEffect
(
e1
,
tp
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
end
function
c18988391
.
efftg
(
e
,
c
)
local
mi
,
ma
=
c
:
GetTributeRequirement
()
return
mi
>
0
end
function
c18988391
.
sumcon
(
e
,
c
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
local
mi
,
ma
=
c
:
GetTributeRequirement
()
local
ft
=
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
return
(
mi
==
1
and
ft
>
0
and
Duel
.
IsPlayerCanSummon
(
tp
,
SUMMON_TYPE_NORMAL
,
c
))
or
(
ma
==
2
and
ft
>-
1
and
Duel
.
IsPlayerCanSummon
(
tp
,
SUMMON_TYPE_ADVANCE
,
c
)
and
Duel
.
GetTributeCount
(
c
)
>=
1
)
end
function
c18988391
.
sumop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
)
local
mi
,
ma
=
c
:
GetTributeRequirement
()
local
ft
=
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
if
ft
>
0
and
(
ma
==
1
or
(
mi
==
1
and
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
18988391
,
2
))))
then
else
local
g
=
Duel
.
SelectTribute
(
tp
,
c
,
1
,
1
)
c
:
SetMaterial
(
g
)
Duel
.
Release
(
g
,
REASON_SUMMON
+
REASON_MATERIAL
)
end
e
:
Reset
()
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