Skip to content
Snippets Groups Projects
Commit 64e479ce authored by Ian Prins's avatar Ian Prins
Browse files

make goldpile subclass feature

parent ffdacddc
No related branches found
No related tags found
No related merge requests found
#include "include/goldpile.h"
#include "include/coord.h"
#include "include/feature.h"
GoldPile::GoldPile(Coord pos, int amount)
: position(pos)
: Feature('*', pos)
, amount(amount)
{}
Coord GoldPile::getPosition() {
return position;
}
{}
int GoldPile::getAmount() {
return amount;
......
#include "coord.h"
#include "feature.h"
#ifndef GOLDPILE_H
#define GOLDPILE_H
class GoldPile {
class GoldPile : public Feature {
public:
GoldPile(Coord, int);
Coord getPosition();
int getAmount();
private:
Coord position;
int amount;
};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment