19#ifndef HEADER_CHECK_CANNON_HPP
20#define HEADER_CHECK_CANNON_HPP
22#include "animations/animation_base.hpp"
23#include "tracks/check_line.hpp"
24#include "utils/cpp2011.hpp"
36 class SPDynamicDrawCall;
55#if defined(DEBUG) && !defined(SERVER_ONLY)
61 std::shared_ptr<SP::SPDynamicDrawCall> m_debug_target_dy_dc;
64 std::set<Flyable*> m_all_flyables;
70 virtual void trigger(
unsigned int kart_index) OVERRIDE {}
74 virtual void update(
float dt) OVERRIDE;
76 virtual bool triggeringCheckline() const OVERRIDE {
return false; }
90 const Vec3& getTargetRight()
const {
return m_target_right; }
Implements a simple checkline that will cause a kart or flyable to be shot to a specified point.
Definition: check_cannon.hpp:46
virtual void update(float dt) OVERRIDE
Overriden to also check all flyables registered with the cannon.
Definition: check_cannon.cpp:129
virtual ~CheckCannon()
Destructor, frees the curve data (which the cannon animation objects only have a read-only copy of).
Definition: check_cannon.cpp:98
Ipo * m_curve
Stores the cannon curve data.
Definition: check_cannon.hpp:53
Vec3 m_target_left
The target point the kart will fly to.
Definition: check_cannon.hpp:49
virtual void changeDebugColor(bool is_active) OVERRIDE
Changes the colour of a check cannon depending on state.
Definition: check_cannon.cpp:111
void removeFlyable(Flyable *flyable)
Removes a flyable from the tests if it crosses a checkline.
Definition: check_cannon.hpp:86
virtual void trigger(unsigned int kart_index) OVERRIDE
Is called when this check structure is triggered.
Definition: check_cannon.hpp:70
virtual CheckStructure * clone() OVERRIDE
Clone to child process for server usage (atm no sound or scripting).
Definition: check_cannon.cpp:178
void addFlyable(Flyable *flyable)
Adds a flyable to be tested for crossing a cannon checkline.
Definition: check_cannon.hpp:81
Implements a simple checkline.
Definition: check_line.hpp:50
Controls all checks structures of a track.
Definition: check_manager.hpp:40
Virtual base class for a check structure.
Definition: check_structure.hpp:52
Definition: flyable.hpp:50
A class to manage a single blender IPO curve.
Definition: ipo.hpp:38
This class is used for debugging.
Definition: show_curve.hpp:46
A wrapper around bullets btVector3 to include conventient conversion functions (e....
Definition: vec3.hpp:35
utility class used to parse XML files
Definition: xml_node.hpp:48