blob: 5e793c4314c5bbc93d7d74655a1daa925a242dde (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
#pragma once
#include "common.h"
namespace aoc2015 {
struct spell;
struct wizard {
int points = 0;
int armor = 0;
int mana = 0;
wizard* wp = nullptr;
spell* spells[5] = {nullptr, nullptr, nullptr, nullptr, nullptr};
wizard () {}
wizard(wizard& w) {
points = w.points;
armor = w.armor;
mana = w.mana;
wp = w.wp;
for (int i = 0; i < 5; i++) {
spells[i] = w.spells[i];
}
}
};
struct spell {
const char * name;
int costs;
int turns;
int damage;
int heals;
int payback;
int protect;
int tick;
};
std::pair<int, int> day22(wizard me, wizard boss);
} // namespace aoc2015
|