Open
Conversation
Contributor
Author
|
This will also need some changes after next vanilla merge, to replace |
Owner
|
On the 8.0-savebreaking branch soon there is an "unused" bitfield in struct rm that is intended to have bits allocated away from it for new purposes such as this. |
136c455 to
5602add
Compare
Contributor
Author
|
Rebased onto 8.0-savebreaking |
Contributor
Author
|
(poorly, apparently...) |
5602add to
6cd879f
Compare
7513983 to
5394e89
Compare
Add the function, make it work (once a bit is defined to be used with it), make it accessible from level files.
...instead of a level-wide ceiling/no-ceiling, when appropriate.
This is arguably a better approach than the previous one, in that it allows for rock traps to generate randomly indoors (or under some other kind of ceiling) even on levels that are flagged 'outdoors'. However, it's a bit wasteful since any outdoors level without 'indoor' areas will spend a bunch of cycles trying to place the trap before finally giving up. Maybe not that big a deal in the big picture though.
Instead of checking for any adjacent ceiling, require ceiling directly above the hero or monster reading the scroll. This avoids the need for more complicated feedback (e.g. "the ceiling rumbles nearby" or similar when there's no ceiling directly above you), and I think it probably makes sense anyway... This also allows us to drop the boolean param from ceiling_exists.
Storing it in 'flags' was causing it to be overwritten when a door or other furniture was added to a square. It should be consistent even when furniture, etc, changes.
aosdict pointed out there's no definitive indication that it's a courtyard, and players who consider the possibility of a courtyard may waste scrolls of earth standing in it, which would be frustrating.
I wouldn't include this in the actual release/master branch, since it sloppily relies on overwriting the color and piggybacking off the inverse video effect of object piles, but it's useful for testing purposes. If this were to be a permanent addition to the game I'd add some new flag like MG_CEILING that could be used for this purpose, but I doubt it's worth it. I'm including it in this branch just so that others can use it for testing if desired, because it's convenient.
Contributor
Author
|
Rebased onto master, so the coordxy stuff should be taken care of. Could probably take a look at it properly now and potentially adopt it (optionally after dropping the wizceiling option and squashing everything). |
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.
Opening this PR just to document the ceiling stuff I did a while ago. Needs
an extra field in struct rm so not for immediate use.