summaryrefslogtreecommitdiff
path: root/src/resource.cpp
blob: 0c07be39a70730ddafa8e211fb666636a773ff9a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#include "resource.hpp"

Resource::Resource(Window m, int size)
{	
    Init(m);
    type = 2;

    rect.h = rect.w = size;
    
    L.x = rect.x;
    L.y = rect.y;

	amount = 100;
}

Resource::Resource(Window m, int size, Location z)
{
    Init(m,z);
    type = 2;
    
    rect.h = rect.w = size;
    
    L.x = rect.x;
    L.y = rect.y;

    amount = 200;
}

void Resource::eat()
{
	amount-=10;
}