Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
blob: 3a8bddf54a3ca9f164e4a6f5793f33c0d8d1ea77 (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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
/*
   base/platform.h
   This file is part of the Osirion project and is distributed under
   the terms and conditions of the GNU General Public License version 2
*/

#ifndef __INCLUDED_BASE_PLATFORM_H__
#define __INCLUDED_BASE_PLATFORM_H__

#include "base/weapon.h"

namespace game
{

/**
 * @brief a weapons platform
 * This class also serves as base class for the Station class,
 **/
class Platform : public core::Entity
{
public:
	/**
	 * @brief constructor
	 * */
	Platform();
	
	/**
	 * @brief destructor
	 * */
	virtual ~Platform();
	
	/* -- inspectors ------------------------------------------- */
	
	/**
	 * @brief the type of cannons the Platform will use
	 * */
	inline const Weapon *cannon() const
	{
		return platform_cannon;
	}
	
	/**
	 * @brief the type of turrets the Platform will use
	 * */
	inline const Weapon *turret() const
	{
		return platform_turret;
	}
	
	/* -- mutators --------------------------------------------- */
	
	/**
	 * @brief set the type of cannons the Platform will use
	 * */
	void set_cannon(const Weapon *cannon);
	
	/**
	 * @brief set the type of turrets the Platform will use
	 * */
	void set_turret(const Weapon *turret);

	/**
	 * @brief run a game frame
	 * */
	virtual void frame(const unsigned long elapsed);
	
private:
	const Weapon		*platform_cannon;
	const Weapon		*platform_turret;
};

}

#endif // __INCLUDED_BASE_SHIPDEALER_H__