HeadBall  1.0
A game
Uphill.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #include "Game.hpp"
4 
5 namespace HeadBall {
9  class UpHill {
10  public:
17  UpHill (GameDataRef data, WorldRef world);
18 
24  void init (sf::Vector2i position );
25 
31  sf::RectangleShape shape ( );
32 
33  private:
36 
37  sf::RectangleShape _shape;
38 
39 
40  b2BodyDef _bodyDef;
41  b2Body* _body;
42  b2PolygonShape _polyShape;
43  b2FixtureDef _fixture;
44  };
45 }
The Uphill part of the game field, below the goal post and above the ground.
Definition: Uphill.hpp:9
WorldRef _world
The Shared Pointer of Box2D World.
Definition: Uphill.hpp:35
GameDataRef _data
The Shared Pointer of the game data.
Definition: Uphill.hpp:34
void init(sf::Vector2i position)
Initiate the Up Hill ubject.
Definition: Uphill.cpp:8
b2BodyDef _bodyDef
The Definition of Box2D body.
Definition: Uphill.hpp:40
UpHill(GameDataRef data, WorldRef world)
Construct a new Up Hill object.
Definition: Uphill.cpp:6
b2PolygonShape _polyShape
The polygon shape for fixture definition.
Definition: Uphill.hpp:42
b2Body * _body
The Box2D body of uphill.
Definition: Uphill.hpp:41
b2FixtureDef _fixture
The fixture of uphill for defining its properties.
Definition: Uphill.hpp:43
sf::RectangleShape _shape
The SFML shape of the uphill.
Definition: Uphill.hpp:37
sf::RectangleShape shape()
Return the shape of Up Hill object.
Definition: Uphill.cpp:25
Custom namespace used throughout the project.
Definition: AboutState.cpp:6
std::shared_ptr< b2World > WorldRef
The Shared Pointer that points to the Box2D world.
Definition: Game.hpp:51
std::shared_ptr< GameData > GameDataRef
The Shared Pointer of GameData Struct.
Definition: Game.hpp:39