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

Add exit_order kwarg to get_display_exits to sort exit names #3470

Merged
merged 2 commits into from Apr 6, 2024

Conversation

chiizujin
Copy link
Contributor

Brief overview of PR changes/additions

Adds an optional exit_order kwarg to get_display_exits to allow the sorting of exits in a specified order.

Exits are specified as an iterable of str. Any exits not specified will be appended to the end in alphabetic order.

Motivation for adding to Evennia

Allow for a specific/preferred order of exit names in room descriptions rather than them appearing in creatiom order.

Copy link
Member

@Griatch Griatch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, also nice with the unittest to add further confidence 👍

@Griatch Griatch merged commit 9965ab8 into evennia:main Apr 6, 2024
8 of 10 checks passed
@chiizujin chiizujin deleted the sorted_exits branch April 7, 2024 02:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants