X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fmenu%2FSelectHero.cpp;h=597faead6b2ccc7a24b6526f3ff573f3dec21430;hb=3701b454bd2c868a886ae5287d8209b714649344;hp=12690dbeabe22998d678664b359e3e4b84a52e0c;hpb=17afcc24569b38a9816f616bc025ba871ad3e48e;p=l2e.git diff --git a/src/menu/SelectHero.cpp b/src/menu/SelectHero.cpp index 12690db..597faea 100644 --- a/src/menu/SelectHero.cpp +++ b/src/menu/SelectHero.cpp @@ -1,10 +1,3 @@ -/* - * SelectHero.cpp - * - * Created on: Oct 22, 2012 - * Author: holy - */ - #include "SelectHero.h" #include "HeroStatus.h" @@ -15,11 +8,11 @@ #include "../common/GameConfig.h" #include "../common/GameState.h" #include "../common/Hero.h" -#include "../geometry/Vector.h" +#include "../math/Vector.h" #include "../graphics/Sprite.h" using app::Input; -using geometry::Vector; +using math::Vector; namespace menu { @@ -112,7 +105,7 @@ const Resources &SelectHero::Res() const { } -void SelectHero::UpdateWorld(float deltaT) { +void SelectHero::UpdateWorld(Uint32 deltaT) { } @@ -125,10 +118,11 @@ void SelectHero::Render(SDL_Surface *screen) { } void SelectHero::RenderCursor(SDL_Surface *screen) const { + const Vector offset((screen->w - partyMenu->Width()) / 2, (screen->h - partyMenu->Height()) / 2); Vector position( 0, Game().state->party[cursor]->BattleSprite()->Height()); position += partyMenu->StatusOffset(cursor); - Res().heroCursor->Draw(screen, position); + Res().heroCursor->Draw(screen, position + offset); } }