Skip to content
Permalink
cec48399da
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
32 lines (27 sloc) 711 Bytes
#include "lootbox.h"
array<Weapon, 10> lootBoxW(){
initscr();
keypad(stdscr, TRUE);
cbreak();
noecho();
array<Weapon, 10> listEquipment;
string weaponType;
for(int i = 0; i < 10; i++){
srand (time(NULL));
int randomValue = (rand() % 2) + 1;
listEquipment[i].randomRarity();
listEquipment[i].bonusStats();
listEquipment[i].randomWeapon();
listEquipment[i].baseStats();
listEquipment[i].getStats();
weaponType = listEquipment[i].getWeaponT();
mvprintw(LINES/2 - 2,(COLS-strlen(("Weapon: " + weaponType).c_str()))/2,"%s", ("Weapon: " + weaponType).c_str());
refresh();
getch();
}
endwin();
return listEquipment;
}
int main(){
lootBoxW();
}