22 #ifndef MM1_VIEWS_ENH_INTERACTIONS_INTERACTION_H 23 #define MM1_VIEWS_ENH_INTERACTIONS_INTERACTION_H 25 #include "mm/mm1/views_enh/party_view.h" 26 #include "mm/shared/xeen/sprites.h" 31 namespace Interactions {
34 struct InteractionButton {
38 InteractionButton() {}
40 _text(text), _c(toupper(c)) {}
46 int _portraitFrameNum = 0;
52 bool _animated =
true;
80 _buttons.
push_back(InteractionButton(str, c));
87 TextAlign align = ALIGN_LEFT,
int xp = 0) {
95 TextAlign align = ALIGN_LEFT,
int xp = 0) {
116 void draw()
override;
121 bool tick()
override;
bool selectCharByDefault() const override
Definition: interaction.h:55
static String format(MSVC_PRINTF const char *fmt,...) GCC_PRINTF(1
bool msgGame(const GameMessage &msg) override
void addButton(const Common::String &str, char c)
Definition: interaction.h:79
bool msgAction(const ActionMessage &msg) override
void clear()
Definition: array.h:320
void writeLine(int lineNum, const Common::String &str, TextAlign align=ALIGN_LEFT, int xp=0)
Definition: interaction.h:86
void writeLine(int lineNum, int value, TextAlign align=ALIGN_LEFT, int xp=0)
Definition: interaction.h:94
Definition: party_view.h:32
Definition: messages.h:56
bool msgUnfocus(const UnfocusMessage &msg) override
Definition: interaction.h:33
bool msgMouseDown(const MouseDownMessage &msg) override
void writeLine(int lineNum, const Common::String &str, TextAlign align=ALIGN_LEFT, int xp=0)
Definition: messages.h:49
void push_back(const T &element)
Definition: array.h:180
Definition: messages.h:72
void clearButtons()
Definition: interaction.h:72
Definition: detection.h:27
Definition: messages.h:48
bool msgKeypress(const KeypressMessage &msg) override
Definition: messages.h:87
void addText(const Common::String &str)
virtual void viewAction()
Definition: interaction.h:62