]> git.localhorst.tv Git - l2e.git/blobdiff - src/battle/states/PerformAttacks.cpp
added small hero tags (used in battle animation and run state)
[l2e.git] / src / battle / states / PerformAttacks.cpp
index 35253ce099c2ae6bcf1617b81145798855379ce8..5906650e0418a42949ed44bb26ffaf3e697bd821 100644 (file)
@@ -58,10 +58,10 @@ void PerformAttacks::HandleEvents(const Input &input) {
                        if (titleBarText) {
                                titleBarText = 0;
                                ++cursor;
-                               while (cursor < (int)battle->Monsters().size() && !battle->MonsterPositionOccupied(cursor)) {
+                               while (cursor < battle->MaxMonsters() && !battle->MonsterPositionOccupied(cursor)) {
                                        ++cursor;
                                }
-                               if (cursor >= (int)battle->Monsters().size()) {
+                               if (cursor >= battle->MaxMonsters()) {
                                        battle->ClearAllAttacks();
                                        ctrl->PopState();
                                }
@@ -72,7 +72,7 @@ void PerformAttacks::HandleEvents(const Input &input) {
                        if (titleBarText) {
                                titleBarText = 0;
                                ++cursor;
-                               if (cursor == (int)battle->Heroes().size()) {
+                               if (cursor == battle->NumHeroes()) {
                                        cursor = 0;
                                        monsters = true;
                                }
@@ -113,7 +113,7 @@ void PerformAttacks::Render(SDL_Surface *screen) {
        battle->RenderBackground(screen, offset);
        battle->RenderMonsters(screen, offset);
        battle->RenderHeroes(screen, offset);
-       // render small tags
+       battle->RenderSmallHeroTags(screen, offset);
        RenderTitleBar(screen, offset);
 }