Untitled
unknown
d
10 months ago
591 B
10
Indexable
module island;
static final const class Island {
static:
private:
// It is private by default, this is the little building on the island.
// The back room of the building.
Boat[] boatStock = [];
public:
// But if you go to the front desk and ask, they can get you what you need if they carry it at this facility.
Boat buyBoat() {
if (boatStock.length == 0) {
buildMoreBoats();
}
Boat thisBoat = boatStock[(boatStock.length) - 1];
boatStock.popBack();
return thisBoat;
}
private:
void buildMoreBoats() {
boatStock ~= Boat();
// etc.
}
}Editor is loading...
Leave a Comment