#ifndef TECH_H #define TECH_H #include #include #include #include "../umath/vec2.h" class TechBonus { public: float attack { 0 }; float defence { 0 }; int sight { 0 }; int range { 0 }; int move { 0 }; std::vector cost { 0, 0 }; std::vector cost_abs { 0, 0 }; std::vector prod { 0, 0 }; int trade; int improved_heal; int improved_convert; int req_range { 999 }; std::vector aff_id; std::vector aff_class; int aff_level; int aff_all { 0 }; TechBonus operator+(const TechBonus &rhs) { TechBonus b; b.attack = attack + rhs.attack; b.defence = defence + rhs.defence; b.sight = sight + rhs.sight; b.move = move + rhs.move; for (int i=0; i map_id; }; class Tech { public: Tech() {} std::string name; int id; int level; int req_id; std::vector cost { 0, 0 }; TechBonus bonus; vec2 spritebounds { 0, 0 }; }; #endif