Commit 7f7ad8a5 authored by Milwaukee Davis's avatar Milwaukee Davis
Browse files

Upload Inventory class implementation

parent cc608f83
//filename: Inventory.cpp
//Contains the implementation of the more complicated functions from the item class, which represents the items the player is carrying in the form of several dynamic arrays.
#include <iostream> //for output
#include <vector>
#include "Item.h"
#include "Inventory.h"
using namespace std;
//Constructs a new Item class.
Inventory::Inventory(){
equipped = 0;
}
//outputs the inventory array
void Inventory::listInventory(){
for(int i = 0; i < inventory.size(); i++){
cout << inventory.at(i).getName() << ": Fight: " << inventory.at(i).getFight() << " Talk: " << inventory.at(i).getTalk() << endl;
}
}
\ No newline at end of file
Supports Markdown
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