Add code to register objects to the collider.

The character and the platforms can register now, but
collision is not triggered for some reason.
This commit is contained in:
King_DuckZ 2014-08-01 00:50:49 +02:00
parent 42fb50e93e
commit cdd37fead7
13 changed files with 133 additions and 10 deletions

View file

@ -20,6 +20,7 @@
#include "character.hpp"
#include "sdlmain.hpp"
#include "texture.hpp"
#include "collider.hpp"
#include <cassert>
namespace cloonel {
@ -52,6 +53,12 @@ namespace cloonel {
Character::~Character() noexcept {
}
///-------------------------------------------------------------------------
///-------------------------------------------------------------------------
void Character::RegisterForCollision (ColliderRegisterFunc parRegisterCollision) {
parRegisterCollision(&m_bottomBar);
}
///-------------------------------------------------------------------------
///-------------------------------------------------------------------------
void Character::Prepare() {