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
|
//ArcherArmor.h
#include <string>
#include <map>
class ArcherArmor
{
private:
map <int, Armor> soldier_armor;
public:
void ArcherArmor_shop();
};
//ArcherArmor.cpp
#include "ArcherArmor.h"
void ArcherArmor::ArcherArmor_shop(){
soldier_armor = {//name, damage, price
{1, Armor("Meito Ichimonji", 4, 150, 1)},
{2, Armor("Shusui", 10, 230, 2)},
{3, Armor("Apocalypse", 16, 300, 3)},
{4, Armor("Blade of Scars", 24, 550, 4)},
{5, Armor("Ragnarok", 32, 610, 5)},
{6, Armor("Eternal Darkness", 40, 690, 6)},
{7, Armor("Masamune", 52, 750, 7)},
{8, Armor("Soul Calibur", 60, 900, 8)}
};
}
//Main.cpp
/*code left our for simplicity*/
|