Commit 3c1db2fc authored by lllyasviel's avatar lllyasviel Committed by GitHub

Merge pull request #77 from nekrozar/patch-2

add race Cybers
parents df28a5b8 0dd1db53
......@@ -231,7 +231,7 @@ public:
void set_material(card_set* materials);
void add_card_target(card* pcard);
void cancel_card_target(card* pcard);
void filter_effect(int32 code, effect_set* eset, uint8 sort = TRUE);
void filter_single_effect(int32 code, effect_set* eset, uint8 sort = TRUE);
void filter_single_continuous_effect(int32 code, effect_set* eset, uint8 sort = TRUE);
......@@ -247,7 +247,7 @@ public:
int32 fusion_check(group* fusion_m, card* cg, uint32 chkf);
void fusion_select(uint8 playerid, group* fusion_m, card* cg, uint32 chkf);
int32 check_fusion_substitute(card* fcard);
int32 check_unique_code(card* pcard);
void get_unique_target(card_set* cset, int32 controler);
int32 is_summonable_card();
......@@ -376,7 +376,8 @@ public:
#define RACE_PSYCHO 0x100000 //
#define RACE_DEVINE 0x200000 //
#define RACE_CREATORGOD 0x400000 //
#define RACE_PHANTOMDRAGON 0x800000 //
#define RACE_WYRM 0x800000 //
#define RACE_CYBERS 0x1000000 //
//Reason
#define REASON_DESTROY 0x1 //
#define REASON_RELEASE 0x2 //
......
......@@ -390,8 +390,8 @@ int32 field::select_place(uint16 step, uint8 playerid, uint32 flag, uint8 count)
p = returns.bvalue[pt];
l = returns.bvalue[pt + 1];
s = returns.bvalue[pt + 2];
if((p != 0 && p != 1)
|| ((l != LOCATION_MZONE) && (l != LOCATION_SZONE))
if((p != 0 && p != 1)
|| ((l != LOCATION_MZONE) && (l != LOCATION_SZONE))
|| ((0x1u << s) & (flag >> (((p == playerid) ? 0 : 16) + ((l == LOCATION_MZONE) ? 0 : 8))))) {
pduel->write_buffer8(MSG_RETRY);
return FALSE;
......@@ -715,7 +715,7 @@ int32 field::sort_card(int16 step, uint8 playerid, uint8 is_chain) {
int32 field::announce_race(int16 step, uint8 playerid, int32 count, int32 available) {
if(step == 0) {
int32 scount = 0;
for(int32 ft = 0x1; ft != 0x1000000; ft <<= 1) {
for(int32 ft = 0x1; ft != 0x2000000; ft <<= 1) {
if(ft & available)
scount++;
}
......@@ -731,7 +731,7 @@ int32 field::announce_race(int16 step, uint8 playerid, int32 count, int32 availa
} else {
int32 rc = returns.ivalue[0];
int32 sel = 0;
for(int32 ft = 0x1; ft != 0x1000000; ft <<= 1) {
for(int32 ft = 0x1; ft != 0x2000000; ft <<= 1) {
if(!(ft & rc)) continue;
if(!(ft & available)) {
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