Simulant  21.12-574
A portable game engine for Windows, OSX, Linux, Dreamcast, and PSP
airplane.h
1 #pragma once
2 
3 #include "../behaviour.h"
4 #include "../../event_listener.h"
5 
6 namespace smlt {
7 namespace behaviours {
8 
9 class Airplane:
10  public BehaviourWithInput,
11  public RefCounted<Airplane> {
12 
13 public:
14  Airplane(Window* window);
15 
16  void set_turn_speed(float x) { turn_speed_ = x; }
17 
18  void fixed_update(float step);
19 
20  const char* name() const { return "Airplane"; }
21 
22 private:
23  void on_behaviour_added(Organism *controllable);
24 
25  Window* window_;
26 
27  float turn_speed_ = 10.0f;
28  float throttle_speed_ = 200.0f;
29  float throttle_ = 0.0f;
30 };
31 
32 
33 }
34 }
smlt::Organism
Definition: behaviour.h:132
smlt::RefCounted
Definition: managed.h:65
smlt
Definition: animation.cpp:25
smlt::Window
Definition: window.h:65
smlt::behaviours::Airplane
Definition: airplane.h:11
smlt::BehaviourWithInput
Definition: behaviour.h:100