-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAdult.h
42 lines (36 loc) · 1.31 KB
/
Adult.h
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
33
34
35
36
37
38
39
40
41
42
// Adult.h: interface for the CAdult class.
//
//////////////////////////////////////////////////////////////////////
// For some reason the guard in Adult.h AFX_ADULT_H__8C6C41B6_7899_11D2_8D9A_0020AF233A70__INCLUDED_
// was conflicting on some Linux machines so let's get rid of it
#pragma once
#include "Bee.h"
#include "Mite.h"
class CAdult : public CBee
{
private:
float m_Lifespan;
float m_CurrentAge;
CMite m_Mites;
double m_Virgins;
double m_ForageInc;
public:
CAdult();
CAdult(int Num);
CAdult(CAdult* oldAdult);
void SetLifespan(int span) { m_Lifespan = (float)span; }
void SetCurrentAge(float age) { m_CurrentAge = age; }
void IncCurrentAge(float ageIncrement) { m_CurrentAge += ageIncrement; }
void SetPropVirgins(double prop) { m_Virgins = prop; }
double GetPropVirgins() { return m_Virgins; }
void IncrementAge(float increment) { m_CurrentAge += increment; }
float GetCurrentAge() { return m_CurrentAge; }
int GetLifespan() { return int(m_Lifespan); }
void SetForageInc(double Inc) { m_ForageInc = Inc; }
double GetForageInc() { return m_ForageInc; }
void Serialize(CArchive& ar);
virtual ~CAdult();
CAdult& operator=(const CAdult& theAdult);
void SetMites(CMite theMites) { m_Mites = theMites; }
CMite GetMites() { return m_Mites; }
};