Commit a07898e5 authored by salix5's avatar salix5 Committed by GitHub

Add deck.h & remove default constructor and copy constructor from Deck (#2987)

parent eab04131
#ifndef DECK_H
#define DECK_H
#include <vector>
#include <cstdint>
#include "data_manager.h"
namespace ygo {
struct Deck {
std::vector<code_pointer> main;
std::vector<code_pointer> extra;
std::vector<code_pointer> side;
void clear() {
main.clear();
extra.clear();
side.clear();
}
};
struct DeckArray {
std::vector<uint32_t> main;
std::vector<uint32_t> extra;
std::vector<uint32_t> side;
};
}
#endif // DECK_H
......@@ -4,7 +4,7 @@
#include <unordered_map>
#include <vector>
#include <sstream>
#include "data_manager.h"
#include "deck.h"
namespace ygo {
......@@ -28,28 +28,6 @@ struct LFList {
std::wstring listName;
std::unordered_map<uint32_t, int> content;
};
struct Deck {
std::vector<code_pointer> main;
std::vector<code_pointer> extra;
std::vector<code_pointer> side;
Deck() = default;
Deck(const Deck& ndeck) {
main = ndeck.main;
extra = ndeck.extra;
side = ndeck.side;
}
void clear() {
main.clear();
extra.clear();
side.clear();
}
};
struct DeckArray {
std::vector<uint32_t> main;
std::vector<uint32_t> extra;
std::vector<uint32_t> side;
};
class DeckManager {
public:
......
......@@ -5,7 +5,7 @@
#include <set>
#include <random>
#include "config.h"
#include "deck_manager.h"
#include "deck.h"
#include "network.h"
namespace ygo {
......
#include "config.h"
#include "replay.h"
#include "myfilesystem.h"
#include "deck_manager.h"
#include "lzma/LzmaLib.h"
namespace ygo {
......
......@@ -5,7 +5,7 @@
#include <vector>
#include <string>
#include "../ocgcore/ocgapi.h"
#include "deck_manager.h"
#include "deck.h"
namespace ygo {
......
......@@ -3,7 +3,7 @@
#include <set>
#include "network.h"
#include "deck_manager.h"
#include "deck.h"
#include "replay.h"
namespace ygo {
......
......@@ -3,7 +3,7 @@
#include <set>
#include "network.h"
#include "deck_manager.h"
#include "deck.h"
#include "replay.h"
namespace ygo {
......
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