X-Git-Url: https://git.dogcows.com/gitweb?p=chaz%2Fyoink;a=blobdiff_plain;f=src%2FGameLayer.hh;h=73b6a23e6a141ec2315cb9f5f2a5f34e91e90dc8;hp=f966c7092ca3703affa4dee90dc60172815a75dd;hb=b357615aba1dbde81e3c6999366604e6001010a7;hpb=2d77fb5fb3480f522658f30af6addd5146530517 diff --git a/src/GameLayer.hh b/src/GameLayer.hh index f966c70..73b6a23 100644 --- a/src/GameLayer.hh +++ b/src/GameLayer.hh @@ -51,6 +51,7 @@ #include #include #include +#include #include "Character.hh" #include "Heroine.hh" @@ -79,9 +80,7 @@ public: struct State { - // the script object must be mutable because some script functions must be - // called during draw - mutable Mf::Script script; + Mf::Script script; std::vector sceneList; HeroineP heroine; @@ -97,19 +96,23 @@ private: void loadSceneLoader(); void advanceScene(); - Mf::Scalar getZCoord(const Mf::Vector2& position) const; + void thinkTimer(); void setProjection(); void setProjection(Mf::Scalar width, Mf::Scalar height); - State mState; - Mf::Sound mMusic; - Mf::Sound mPunchSound; + State mState; + Mf::Timer mThinkTimer; - Mf::Ray<2> mRay; - Mf::Line<2> mLine; - Mf::Plane mPlane; + Mf::SoundStream mMusic; + Mf::Sound mPunchSound; + + Mf::Ray<2> mRay; + Mf::Line<2> mLine; Mf::Sphere<2> mSphere; + + Mf::Timer mRayTimer; + void rayTimer(); };