- [FIX] l'animació no funcionava be

- Versió del Update dels actors per al Editor
- [NEW] gui::TextBox
- [NEW] input::getKeyPressed()
- Acabant el editor...
This commit is contained in:
2023-10-05 18:55:51 +02:00
parent a141d11760
commit 543c6a81e3
7 changed files with 80 additions and 10 deletions

View File

@@ -545,7 +545,7 @@ namespace actor
act->anim_frame=(act->anim_frame+1)%4;
act->anim_wait_count=0;
} else {
act->anim_wait++;
act->anim_wait_count++;
}
if (act->flags & FLAG_HERO) updateUserInput(act);
@@ -560,6 +560,20 @@ namespace actor
if (update_all && next) update(next);
}
void updateEditor(actor_t *act, const bool update_all)
{
actor_t *next = act->next;
if (act->anim_wait_count==act->anim_wait) {
act->anim_frame=(act->anim_frame+1)%4;
act->anim_wait_count=0;
} else {
act->anim_wait_count++;
}
if (update_all && next) update(next);
}
void print(int x, int y, int num)
{
int digits=0;