]> git.localhorst.tv Git - l2e.git/blob - src/battle/PartyLayout.h
use sdl utility functions for debug drawing
[l2e.git] / src / battle / PartyLayout.h
1 /*
2  * PartyLayout.h
3  *
4  *  Created on: Aug 5, 2012
5  *      Author: holy
6  */
7
8 #ifndef BATTLE_PARTYLAYOUT_H_
9 #define BATTLE_PARTYLAYOUT_H_
10
11 #include "../geometry/Vector.h"
12
13 #include <cassert>
14 #include <vector>
15 #include <SDL.h>
16
17 namespace battle {
18
19 class PartyLayout {
20
21 public:
22         PartyLayout() : positions(0), numPositions(0) { }
23
24 public:
25         std::vector<geometry::Vector<int> >::size_type NumPositions() const { return numPositions; }
26         void CalculatePositions(int width, int height, std::vector<geometry::Vector<int> > &dest) const;
27         geometry::Vector<int> CalculatePosition(int index, int width, int height) const;
28
29 public:
30         void SetPositions(const geometry::Vector<int> *p, int num) {
31                 positions = p;
32                 numPositions = num;
33         }
34
35         static void CreateTypeDescription();
36         static void Construct(void *);
37
38 private:
39         const geometry::Vector<int> *positions;
40         int numPositions;
41
42 };
43
44 }
45
46 #endif /* BATTLE_PARTYLAYOUT_H_ */