Add storage entity
This commit is contained in:
parent
b1333c74a5
commit
d00ec79847
3 changed files with 51 additions and 0 deletions
21
entities/storage_entity.cpp
Normal file
21
entities/storage_entity.cpp
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
#include "storage_entity.h"
|
||||
|
||||
|
||||
unsigned long long storage_entity::__global_id = 0;
|
||||
|
||||
storage_entity::storage_entity(unsigned int capacity) : _capacity(capacity) {
|
||||
this->_id = storage_entity::__global_id++;
|
||||
}
|
||||
|
||||
|
||||
unsigned long long storage_entity::id() {
|
||||
return this->_id;
|
||||
}
|
||||
|
||||
unsigned int storage_entity::capacity() {
|
||||
return this->_capacity;
|
||||
}
|
||||
|
||||
const QVector<cargo_entity> storage_entity::cargo() {
|
||||
return this->_cargo;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue