Commit b719d306 authored by Chen Bill's avatar Chen Bill Committed by GitHub

zero initialize (#2534)

* DeckBuilder zero initialize

* DeckManager zero initialize
parent 10a27acf
...@@ -41,49 +41,49 @@ public: ...@@ -41,49 +41,49 @@ public:
void pop_side(int seq); void pop_side(int seq);
bool check_limit(code_pointer pointer); bool check_limit(code_pointer pointer);
long long filter_effect; long long filter_effect{};
unsigned int filter_type; unsigned int filter_type{};
unsigned int filter_type2; unsigned int filter_type2{};
unsigned int filter_attrib; unsigned int filter_attrib{};
unsigned int filter_race; unsigned int filter_race{};
unsigned int filter_atktype; unsigned int filter_atktype{};
int filter_atk; int filter_atk{};
unsigned int filter_deftype; unsigned int filter_deftype{};
int filter_def; int filter_def{};
unsigned int filter_lvtype; unsigned int filter_lvtype{};
unsigned int filter_lv; unsigned int filter_lv{};
unsigned int filter_scltype; unsigned int filter_scltype{};
unsigned int filter_scl; unsigned int filter_scl{};
unsigned int filter_marks; unsigned int filter_marks{};
int filter_lm; int filter_lm{};
position2di mouse_pos; position2di mouse_pos;
int hovered_code; int hovered_code{};
int hovered_pos; int hovered_pos{};
int hovered_seq; int hovered_seq{ -1 };
int is_lastcard; int is_lastcard{};
int click_pos; int click_pos{};
bool is_draging; bool is_draging{};
bool is_starting_dragging; bool is_starting_dragging{};
int dragx; int dragx{};
int dragy; int dragy{};
int bigcard_code; int bigcard_code{};
float bigcard_zoom; float bigcard_zoom{};
size_t pre_mainc; size_t pre_mainc{};
size_t pre_extrac; size_t pre_extrac{};
size_t pre_sidec; size_t pre_sidec{};
code_pointer draging_pointer; code_pointer draging_pointer;
int prev_category; int prev_category{};
int prev_deck; int prev_deck{};
s32 prev_operation; s32 prev_operation{};
int prev_sel; int prev_sel{ -1 };
bool is_modified; bool is_modified{};
bool readonly; bool readonly{};
bool showing_pack; bool showing_pack{};
mt19937 rnd; mt19937 rnd;
const std::unordered_map<int, int>* filterList; const std::unordered_map<int, int>* filterList;
std::vector<code_pointer> results; std::vector<code_pointer> results;
wchar_t result_string[8]; wchar_t result_string[8]{};
std::vector<std::wstring> expansionPacks; std::vector<std::wstring> expansionPacks;
}; };
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
namespace ygo { namespace ygo {
char DeckManager::deckBuffer[0x10000]; char DeckManager::deckBuffer[0x10000]{};
DeckManager deckManager; DeckManager deckManager;
void DeckManager::LoadLFListSingle(const char* path) { void DeckManager::LoadLFListSingle(const char* path) {
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
namespace ygo { namespace ygo {
struct LFList { struct LFList {
unsigned int hash; unsigned int hash{};
std::wstring listName; std::wstring listName;
std::unordered_map<int, int> content; std::unordered_map<int, int> content;
}; };
......
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