Runtime flags: New bit-fields for storing various interpreter states#491
Runtime flags: New bit-fields for storing various interpreter states#491florianessl wants to merge 5 commits intoEasyRPG:masterfrom
Conversation
…ify which enum names are considered to be "scoped" ('class' enums in C++)
…preter related SaveState structures (SaveEventExecState, SaveEventExecFrame & SaveMapEventBase)
…e corresponding enumeration
…n created by EasyRPGs new "CloneMapEvent" command
|
I think this issue is pretty critical, so I just pushed an additional new field here to address it before 0.8.1 is released: There's currently no way of determining if an event has been inserted dynamically via the new "CloneMapEvent" command. I'm currently trying to achieve in-game changing of the game's language without having to re-enter maps & this new command would make it impossible to implement this in a reliable way... |
Ideas from the chat to prevent issues with "index adjust" because ShowMessage can be longer or shorter: Original command (3 line message box) Case 1: Translation is shorter Case 2: Translation is longer (Problem): Case 2: Translation is longer (Solution): In the called event: |
|
@florianessl the flags can be actually encoded using our This way you can do both I will do directly the same for The flag stuff we have in lcf is not usable for what you want to do with it. But I'm working on a patch so the flags can be added at all locations you propose. |
All the mappings for "maniac_event_info" were already documented here: |
|
Ah okay so they aren't really bitfields but a mix of both. Not suitable for our flag code |
|
Thanks I picked the suggested chunks and implemented the runtime_flags in terms of the "Flags" class we already have. Closing this in favour of #492 |
I suggest adding some general-purpose UInt32 fields for following data structures:
This PR adds a new field 0xC8 "easyrpg_runtime_flags" to these 3 structures and also includes some suggested bitmask values for "SaveEventExecState" based on some requirements for @Ghabry's suggested rework of the "SetInterpreterFlag" command -> EasyRPG/Player#3123