]> Dogcows Code - chaz/yoink/blobdiff - src/GameLayer.cc
preliminary cleanup of character class
[chaz/yoink] / src / GameLayer.cc
index 33710696107bd5f0f8b4c91ef0867384e34c5b6e..2035248115869afdb4a42cb16647be34f29014d0 100644 (file)
@@ -48,7 +48,7 @@ GameLayer::GameLayer() :
        music.stream();
 
        heroine = Heroine::alloc();
-       heroine->getAnimation().startSequence("FlyDiagonallyUp");
+       heroine->animation.startSequence("FlyDiagonallyUp");
 
        Mf::Scalar a[6] = {0.0, 1.5, -0.5, 3.0, -2.0, 1.0};
        interp.init(a, 2.0, Mf::Interpolator::OSCILLATE);
@@ -107,7 +107,7 @@ bool GameLayer::handleEvent(const Mf::Event& event)
                case SDL_KEYDOWN:
                        if (event.key.keysym.sym == SDLK_SPACE)
                        {
-                               heroine->getAnimation().startSequence("Flattened");
+                               heroine->animation.startSequence("Flattened");
                                Mf::logInfo("thump!");
                                punchSound.play();
                                return true;
@@ -124,8 +124,7 @@ bool GameLayer::handleEvent(const Mf::Event& event)
                        }
 
                case SDL_KEYUP:
-                       heroine->handleEvent(event);
-                       break;
+                       return heroine->handleEvent(event);
 
                case SDL_MOUSEMOTION:
                case SDL_MOUSEBUTTONDOWN:
This page took 0.018079 seconds and 4 git commands to generate.