X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Flibr2c2%2Ftrainai.h;h=b3412c5442e18b3b7fffe4ac516d2b58b9558a2c;hb=c0e076401ee76fd9a5a96ff919a8e7b4d058c51b;hp=4f9d99cc44465e14b17d96f7eb8aacb7728be998;hpb=d3a7a9e9ad694d52ccca8b6038501772fdc1dfd5;p=r2c2.git diff --git a/source/libr2c2/trainai.h b/source/libr2c2/trainai.h index 4f9d99c..b3412c5 100644 --- a/source/libr2c2/trainai.h +++ b/source/libr2c2/trainai.h @@ -1,10 +1,3 @@ -/* $Id$ - -This file is part of R²C² -Copyright © 2011 Mikkosoft Productions, Mikko Rasa -Distributed under the GPL -*/ - #ifndef LIBR2C2_TRAINAI_H_ #define LIBR2C2_TRAINAI_H_ @@ -23,8 +16,6 @@ Base class for train AIs. AIs can help the user in various ways, ranging from automatically stopping the train at the end of allocated track to autonomously running a train. - -XXX The timestamp should be removed from tick, but Timetable depends on it */ class TrainAI { @@ -44,17 +35,14 @@ public: protected: Train &train; - std::string tag; TrainAI(Train &); public: virtual ~TrainAI(); - void set_tag(const std::string &); - const std::string &get_tag() const { return tag; } - virtual void message(const Message &) { } - virtual void tick(const Msp::Time::TimeStamp &, const Msp::Time::TimeDelta &) { } + virtual void tick(const Msp::Time::TimeDelta &) = 0; + virtual bool has_intent_to_move() const { return false; } }; } // namespace R2C2