Commit 1d3b7ecb authored by DailyShana's avatar DailyShana Committed by mercury233

transfer STATUS_PROC_COMPLETE to client (#194)

parent 3737bd18
...@@ -188,16 +188,14 @@ uint32 card::get_infos(byte* buf, int32 query_flag, int32 use_cache) { ...@@ -188,16 +188,14 @@ uint32 card::get_infos(byte* buf, int32 query_flag, int32 use_cache) {
} }
if(query_flag & QUERY_OWNER) if(query_flag & QUERY_OWNER)
*p++ = owner; *p++ = owner;
if(query_flag & QUERY_IS_DISABLED) { if(query_flag & QUERY_STATUS) {
tdata = (status & (STATUS_DISABLED | STATUS_FORBIDDEN)) ? 1 : 0; tdata = status & (STATUS_DISABLED | STATUS_FORBIDDEN | STATUS_PROC_COMPLETE);
if(!use_cache || (tdata != q_cache.is_disabled)) { if(!use_cache || (tdata != q_cache.status)) {
q_cache.is_disabled = tdata; q_cache.status = tdata;
*p++ = tdata; *p++ = tdata;
} else } else
query_flag &= ~QUERY_IS_DISABLED; query_flag &= ~QUERY_STATUS;
} }
if(query_flag & QUERY_IS_PUBLIC)
*p++ = is_position(POS_FACEUP) ? 1 : 0;
if(!use_cache) { if(!use_cache) {
if(query_flag & QUERY_LSCALE) q_cache.lscale = *p++ = get_lscale(); if(query_flag & QUERY_LSCALE) q_cache.lscale = *p++ = get_lscale();
if(query_flag & QUERY_RSCALE) q_cache.rscale = *p++ = get_rscale(); if(query_flag & QUERY_RSCALE) q_cache.rscale = *p++ = get_rscale();
......
...@@ -80,8 +80,7 @@ struct query_cache { ...@@ -80,8 +80,7 @@ struct query_cache {
int32 base_attack; int32 base_attack;
int32 base_defense; int32 base_defense;
uint32 reason; uint32 reason;
int32 is_public; int32 status;
int32 is_disabled;
uint32 lscale; uint32 lscale;
uint32 rscale; uint32 rscale;
uint32 link_marker; uint32 link_marker;
...@@ -361,38 +360,6 @@ public: ...@@ -361,38 +360,6 @@ public:
#define SUMMON_TYPE_XYZ 0x49000000 #define SUMMON_TYPE_XYZ 0x49000000
#define SUMMON_TYPE_PENDULUM 0x4a000000 #define SUMMON_TYPE_PENDULUM 0x4a000000
#define SUMMON_TYPE_LINK 0x4c000000 #define SUMMON_TYPE_LINK 0x4c000000
//Status
#define STATUS_DISABLED 0x0001 //
#define STATUS_TO_ENABLE 0x0002 //
#define STATUS_TO_DISABLE 0x0004 //
#define STATUS_PROC_COMPLETE 0x0008 //
#define STATUS_SET_TURN 0x0010 //
#define STATUS_NO_LEVEL 0x0020 //
#define STATUS_BATTLE_RESULT 0x0040 //
#define STATUS_SPSUMMON_STEP 0x0080 //
#define STATUS_FORM_CHANGED 0x0100 //
#define STATUS_SUMMONING 0x0200 //
#define STATUS_EFFECT_ENABLED 0x0400 //
#define STATUS_SUMMON_TURN 0x0800 //
#define STATUS_DESTROY_CONFIRMED 0x1000 //
#define STATUS_LEAVE_CONFIRMED 0x2000 //
#define STATUS_BATTLE_DESTROYED 0x4000 //
#define STATUS_COPYING_EFFECT 0x8000 //
#define STATUS_CHAINING 0x10000 //
#define STATUS_SUMMON_DISABLED 0x20000 //
#define STATUS_ACTIVATE_DISABLED 0x40000 //
#define STATUS_EFFECT_REPLACED 0x80000
#define STATUS_FUTURE_FUSION 0x100000
#define STATUS_ATTACK_CANCELED 0x200000
#define STATUS_INITIALIZING 0x400000
//#define STATUS_ACTIVATED 0x800000
#define STATUS_JUST_POS 0x1000000
#define STATUS_CONTINUOUS_POS 0x2000000
#define STATUS_FORBIDDEN 0x4000000
#define STATUS_ACT_FROM_HAND 0x8000000
#define STATUS_OPPO_BATTLE 0x10000000
#define STATUS_FLIP_SUMMON_TURN 0x20000000
#define STATUS_SPSUMMON_TURN 0x40000000
//Counter //Counter
#define COUNTER_WITHOUT_PERMIT 0x1000 #define COUNTER_WITHOUT_PERMIT 0x1000
#define COUNTER_NEED_ENABLE 0x2000 #define COUNTER_NEED_ENABLE 0x2000
......
...@@ -160,6 +160,39 @@ struct card_sort { ...@@ -160,6 +160,39 @@ struct card_sort {
//#define REASON_REVEAL 0x8000000 // //#define REASON_REVEAL 0x8000000 //
#define REASON_LINK 0x10000000 // #define REASON_LINK 0x10000000 //
//Status
#define STATUS_DISABLED 0x0001 //
#define STATUS_TO_ENABLE 0x0002 //
#define STATUS_TO_DISABLE 0x0004 //
#define STATUS_PROC_COMPLETE 0x0008 //
#define STATUS_SET_TURN 0x0010 //
#define STATUS_NO_LEVEL 0x0020 //
#define STATUS_BATTLE_RESULT 0x0040 //
#define STATUS_SPSUMMON_STEP 0x0080 //
#define STATUS_FORM_CHANGED 0x0100 //
#define STATUS_SUMMONING 0x0200 //
#define STATUS_EFFECT_ENABLED 0x0400 //
#define STATUS_SUMMON_TURN 0x0800 //
#define STATUS_DESTROY_CONFIRMED 0x1000 //
#define STATUS_LEAVE_CONFIRMED 0x2000 //
#define STATUS_BATTLE_DESTROYED 0x4000 //
#define STATUS_COPYING_EFFECT 0x8000 //
#define STATUS_CHAINING 0x10000 //
#define STATUS_SUMMON_DISABLED 0x20000 //
#define STATUS_ACTIVATE_DISABLED 0x40000 //
#define STATUS_EFFECT_REPLACED 0x80000
#define STATUS_FUTURE_FUSION 0x100000
#define STATUS_ATTACK_CANCELED 0x200000
#define STATUS_INITIALIZING 0x400000
//#define STATUS_ACTIVATED 0x800000
#define STATUS_JUST_POS 0x1000000
#define STATUS_CONTINUOUS_POS 0x2000000
#define STATUS_FORBIDDEN 0x4000000
#define STATUS_ACT_FROM_HAND 0x8000000
#define STATUS_OPPO_BATTLE 0x10000000
#define STATUS_FLIP_SUMMON_TURN 0x20000000
#define STATUS_SPSUMMON_TURN 0x40000000
//Query list //Query list
#define QUERY_CODE 0x1 #define QUERY_CODE 0x1
#define QUERY_POSITION 0x2 #define QUERY_POSITION 0x2
...@@ -180,8 +213,7 @@ struct card_sort { ...@@ -180,8 +213,7 @@ struct card_sort {
#define QUERY_OVERLAY_CARD 0x10000 #define QUERY_OVERLAY_CARD 0x10000
#define QUERY_COUNTERS 0x20000 #define QUERY_COUNTERS 0x20000
#define QUERY_OWNER 0x40000 #define QUERY_OWNER 0x40000
#define QUERY_IS_DISABLED 0x80000 #define QUERY_STATUS 0x80000
#define QUERY_IS_PUBLIC 0x100000
#define QUERY_LSCALE 0x200000 #define QUERY_LSCALE 0x200000
#define QUERY_RSCALE 0x400000 #define QUERY_RSCALE 0x400000
#define QUERY_LINK 0x800000 #define QUERY_LINK 0x800000
......
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