26 lines
731 B
C
26 lines
731 B
C
/**
|
|
* Copyright (c) 2025 Dominic Masters
|
|
*
|
|
* This software is released under the MIT License.
|
|
* https://opensource.org/licenses/MIT
|
|
*/
|
|
|
|
#include "event.h"
|
|
#include "ui/uitextbox.h"
|
|
#include "assert/assert.h"
|
|
|
|
void eventTextStart(const eventitem_t *item) {
|
|
assertNotNull(item, "Event item cannot be NULL");
|
|
assertTrue(item->type == EVENT_TYPE_TEXT, "Event item must be of type TEXT");
|
|
assertNotNull(item->text, "Event item must have at least one text");
|
|
uiTextboxSetText(item->text);
|
|
}
|
|
|
|
void eventTextUpdate(const eventitem_t *item) {
|
|
assertNotNull(item, "Event item cannot be NULL");
|
|
assertTrue(item->type == EVENT_TYPE_TEXT, "Event item must be of type TEXT");
|
|
|
|
if(!UI_TEXTBOX.visible) {
|
|
eventNext();
|
|
}
|
|
} |