Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ritual Circles Work #72128

Merged
merged 2 commits into from
Mar 3, 2024
Merged

Conversation

LetterShapedGlyphs
Copy link
Contributor

@LetterShapedGlyphs LetterShapedGlyphs commented Mar 3, 2024

Summary

Features "Ritual Circles satisfy spell component requirements"

Purpose of change

Ritual circles were neat but spellcasting didn't recognize anything that wasn't in your personal inventory, including the furniture pseudoitem generated by a ritual circle. This also solves #63888

Describe the solution

The window to display available spell components was using the default crafting inventory with its range of 6. Then, when determining whether or not you could cast the spell it was trying to use a radius of 0 which was bugged with clearpath=true and so was ignoring any items in your tile. The spell window now correctly also uses radius 0, and actually makes the items on your tile available to be consumed.

Describe alternatives you've considered

Using a radius of 1 to allow for other furniture involved in ritual casting.
Some other workaround to make rituals work.

Testing

Compiled, testing casting spells without components, spells with components in inventory, spells with components at the character's feet, and spells with components adjacent.

Additional context

There was a comment about making a const cast of the caster to maybe not write to cache? Except the code which was populating the window was making use of the exact same function without doing the cast so I don't think it was doing anything. Can easily be restored if I was mistaken.

LetterShapedGlyphs and others added 2 commits March 2, 2024 18:38
Uses components and qualities at your location to cast spells
@github-actions github-actions bot added [C++] Changes (can be) made in C++. Previously named `Code` <Enhancement / Feature> New features, or enhancements on existing labels Mar 3, 2024
@github-actions github-actions bot requested a review from KorGgenT March 3, 2024 03:31
@github-actions github-actions bot added json-styled JSON lint passed, label assigned by github actions astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Mar 3, 2024
@Maleclypse Maleclypse merged commit 3257bc0 into CleverRaven:master Mar 3, 2024
22 of 27 checks passed
@Maleclypse
Copy link
Member

Thank you for doing this!

@Standing-Storm
Copy link
Contributor

Seconding the thank you! This is going to make #71012 a lot more user-friendly once I finish it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions [C++] Changes (can be) made in C++. Previously named `Code` <Enhancement / Feature> New features, or enhancements on existing json-styled JSON lint passed, label assigned by github actions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants