X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fbadguy%2Fdart.hpp;h=0fb6dc3ecd77df7837eb8f2363d1bbdaa0aecf2d;hb=13c84268f16872f9b442251c4175a3a1a7a7899a;hp=aaebdc26cafd214093323b207ff8dc0166616459;hpb=58eb3364f724b2100859fd39da9bba5a9a09cafc;p=supertux.git diff --git a/src/badguy/dart.hpp b/src/badguy/dart.hpp index aaebdc26c..0fb6dc3ec 100644 --- a/src/badguy/dart.hpp +++ b/src/badguy/dart.hpp @@ -1,7 +1,7 @@ // $Id$ // // Dart - Your average poison dart -// Copyright (C) 2006 Christoph Sommer +// Copyright (C) 2006 Christoph Sommer // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License @@ -30,17 +30,18 @@ class Dart : public BadGuy { public: Dart(const lisp::Lisp& reader); - Dart(float pos_x, float pos_y, Direction d, const BadGuy* parent); + Dart(const Vector& pos, Direction d, const BadGuy* parent); Dart(const Dart& dart); ~Dart(); + void initialize(); void activate(); void deactivate(); void write(lisp::Writer& writer); void active_update(float elapsed_time); - HitResponse collision_solid(GameObject& object, const CollisionHit& hit); + void collision_solid(const CollisionHit& hit); HitResponse collision_badguy(BadGuy& badguy, const CollisionHit& hit); HitResponse collision_player(Player& player, const CollisionHit& hit); @@ -49,11 +50,8 @@ public: virtual bool updatePointers(const GameObject* from_object, GameObject* to_object); protected: - bool set_direction; - Direction initial_direction; const BadGuy* parent; /**< collisions with this BadGuy will be ignored */ - SoundSource* soundSource; /**< SoundSource for ambient sound */ + std::auto_ptr sound_source; /**< SoundSource for ambient sound */ }; #endif -