Commit ea275fa6 authored by salix5's avatar salix5

change returns.svalue to uint16

parent a0e388c2
......@@ -161,7 +161,7 @@ constexpr int SIZE_IVALUE = SIZE_RETURN_VALUE / 4;
constexpr int SIZE_LVALUE = SIZE_RETURN_VALUE / 8;
union return_value {
int8 bvalue[SIZE_RETURN_VALUE];
int16 svalue[SIZE_SVALUE];
uint16 svalue[SIZE_SVALUE];
int32 ivalue[SIZE_IVALUE];
int64 lvalue[SIZE_LVALUE];
};
......
......@@ -710,7 +710,7 @@ int32 field::remove_counter(uint16 step, uint32 reason, card* pcard, uint8 rplay
core.select_effects.clear();
if((pcard && pcard->get_counter(countertype) >= count) || (!pcard && get_field_counter(rplayer, s, o, countertype))) {
core.select_options.push_back(10);
core.select_effects.push_back(0);
core.select_effects.push_back(nullptr);
}
auto pr = effects.continuous_effect.equal_range(EFFECT_RCOUNTER_REPLACE + countertype);
tevent e;
......@@ -733,7 +733,7 @@ int32 field::remove_counter(uint16 step, uint32 reason, card* pcard, uint8 rplay
return TRUE;
if(core.select_options.size() == 1)
returns.ivalue[0] = 0;
else if(core.select_effects[0] == 0 && core.select_effects.size() == 2)
else if(core.select_effects[0] == nullptr && core.select_effects.size() == 2)
add_process(PROCESSOR_SELECT_EFFECTYN, 0, 0, (group*)core.select_effects[1]->handler, rplayer, 220);
else
add_process(PROCESSOR_SELECT_OPTION, 0, 0, 0, rplayer, 0);
......
......@@ -606,7 +606,7 @@ int32 field::select_counter(uint16 step, uint8 playerid, uint16 countertype, uin
}
return FALSE;
} else {
uint16 ct = 0;
int32 ct = 0;
for(int32 i = 0; i < (int32)core.select_cards.size(); ++i) {
if(core.select_cards[i]->get_counter(countertype) < returns.svalue[i]) {
pduel->write_buffer8(MSG_RETRY);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment