Open
Conversation
* Add the static pointer path for Nights's LogicMgr. * Set the `None` `PowerupType` enum to 0, so that the rest of the enum uses a known base number to increment from. * Add the Electrobolt and the weird AI Player powerup to the `PowerupType` enum. * Make `PowerupType` an `enum class` for now, until we get sick of `enum class`es. * Add `CharacterId` enum, which might actually be better off in another class, if appropriate. * Add `PlayerId` enum. I assume mod devs will just use int literals for player numbers, but having the enum type makes it easy to interpret the LogicMgr struct members. * Replace `struct LogicMgr_` with `struct LogicMgr_Deluxe101_` and `struct LogicMgr_Nights10_`. * In the `State` enum, rename `CharacterDialog` to `CharacterSelect` so it is more intuitive that the state is the character selection dialog.
* Run the exception handler for all exceptions when the example mod fails to run. * Change `LogicMgr::AddStandardText()` string arg to a `const` so it can use rvalue strings. * Move the LogicMgr structures inside of the `LogicMgr` class so they can access its internals.
* Note: Nights 1.01 is the version that EA/Origin distributes. Steam distributes version 1.00.
# Conflicts: # src/haggle/callbacks/callbacks.cpp
I didn't find an easy way to access the static LogicMgr pointer from another library (mod). Probably missing a DLL export for it, but I figured the simplest way is to add a getter function for it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I only have the struct detailed for the EA release of Peggle Nights (v1.01). I started looking into the struct for the Steam release, and it's only slightly different (I think four members were added in v1.01 somewhere).