Skip to content

Conversation

@jetrotal
Copy link
Contributor

@jetrotal jetrotal commented Dec 12, 2025

in maniacs this is a thing:
image

To support it, this PR Introduces the ResolveEventCommand method to process Maniac Patch @cmd (Call Command) event commands, resolving them into their actual form. Refactors interpreter logic to use this method where event commands are accessed, ensuring correct handling of Maniac Patch commands and improving compatibility. Updates function signatures and documentation accordingly.

Test map (dog npc):
Map0003.zip

@jetrotal jetrotal force-pushed the maniacs/callcmd_handler branch from d54ce7d to 35bc22c Compare December 12, 2025 09:46
@Ghabry
Copy link
Member

Ghabry commented Dec 12, 2025

Your screenshot is misleading. The code in Map0003 is different to it.

Also a typical problem with these AI generated commit messages: They explain "what" they did but not "why" they did it.


So here is the why explanation:

grafik

Commands like ShowMessage read the event commands right after to locate stuff such as ShowMessage_2 (line continuation) or ShowChoice.

What is new: The "right after" scan also supports now CallCommand lines for on-the-fly generation of e.g. continuations. To implement this, the parsing logic from CallCommand had to be extracted into a new method ResolveEventCommand which is now used everywhere where these continuation scans happen.

@jetrotal
Copy link
Contributor Author

Sorry I edited the map but forgot to save before zipping.

Correct map:
Map0003.zip

Yeah, I also forgot to explain why those changes happened. The idea, as you said, is to properly support parent/sibling commands both as its typical command or as a call command.

Introduces the ResolveEventCommand method to process Maniac Patch @cmd (Call Command) event commands, resolving them into their actual form. Refactors interpreter logic to use this method where event commands are accessed, ensuring correct handling of Maniac Patch commands and improving compatibility. Updates function signatures and documentation accordingly.
@jetrotal jetrotal force-pushed the maniacs/callcmd_handler branch from 35bc22c to ded0719 Compare December 12, 2025 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants