Commit 6809e544 authored by Chen Bill's avatar Chen Bill

add new file: card_data.h

parent e9ccdcba
......@@ -19,20 +19,6 @@ bool card_sort::operator()(void* const & p1, void* const & p2) const {
card* c2 = (card*)p2;
return c1->cardid < c2->cardid;
}
void card_data::clear() {
code = 0;
alias = 0;
setcode = 0;
type = 0;
level = 0;
attribute = 0;
race = 0;
attack = 0;
defense = 0;
lscale = 0;
rscale = 0;
link_marker = 0;
}
bool card_state::is_location(int32 loc) const {
if((loc & LOCATION_FZONE) && location == LOCATION_SZONE && sequence == 5)
return true;
......
......@@ -10,6 +10,7 @@
#include "common.h"
#include "effectset.h"
#include "card_data.h"
#include <set>
#include <map>
#include <unordered_set>
......@@ -22,23 +23,6 @@ class effect;
class group;
struct chain;
struct card_data {
uint32 code{ 0 };
uint32 alias{ 0 };
uint64 setcode{ 0 };
uint32 type{ 0 };
uint32 level{ 0 };
uint32 attribute{ 0 };
uint32 race{ 0 };
int32 attack{ 0 };
int32 defense{ 0 };
uint32 lscale{ 0 };
uint32 rscale{ 0 };
uint32 link_marker{ 0 };
void clear();
};
struct card_state {
uint32 code{ 0 };
uint32 code2{ 0 };
......
#ifndef CARD_DATA_H_
#define CARD_DATA_H_
struct card_data {
uint32 code{ 0 };
uint32 alias{ 0 };
uint64 setcode{ 0 };
uint32 type{ 0 };
uint32 level{ 0 };
uint32 attribute{ 0 };
uint32 race{ 0 };
int32 attack{ 0 };
int32 defense{ 0 };
uint32 lscale{ 0 };
uint32 rscale{ 0 };
uint32 link_marker{ 0 };
void clear() {
code = 0;
alias = 0;
setcode = 0;
type = 0;
level = 0;
attribute = 0;
race = 0;
attack = 0;
defense = 0;
lscale = 0;
rscale = 0;
link_marker = 0;
}
};
#endif /* CARD_DATA_H_ */
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