Skip to content
This repository has been archived by the owner on Mar 28, 2023. It is now read-only.

Custom bg names #120

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open

Custom bg names #120

wants to merge 6 commits into from

Conversation

stonedDiscord
Copy link
Member

it is configurable

@stonedDiscord
Copy link
Member Author

to elaborate

this let's you configure if users can set whatever they want as backgrounds or only bgd from the background list, per area

@stonedDiscord stonedDiscord requested a review from oldmud0 May 11, 2021 21:00
Comment on lines +761 to 764
item['background'], item['bglock'], item['custom_bg_allowed'],
item['evidence_mod'], item['locking_allowed'],
item['iniswap_allowed'],
item['showname_changes_allowed'],
Copy link
Member

Choose a reason for hiding this comment

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

Actually now that this was changed, I think you can actually get away with doing

self.Area(self.cur_id, self.server, **item)

and then the default parameters set in item just above become redundant.

@@ -410,8 +412,7 @@ def change_background(self, bg: str):
Raises:
AreaError: if `bg` is not in background list
"""

if bg.lower() not in (name.lower()
if self.custom_bg == False or bg.lower() not in (name.lower()
Copy link
Member

Choose a reason for hiding this comment

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

Will always say "invalid background name" if custom backgrounds is set to false.

Suggested change
if self.custom_bg == False or bg.lower() not in (name.lower()
if not self.custom_bg and bg.lower() not in (name.lower()

Crystalwarrior referenced this pull request in Crystalwarrior/KFO-Server Feb 11, 2022
* Basic processing

* Basic functionality

* Add /charlog

* Add character showname checking logic

* Add character details to client info

* Bump up version

* Make commands support char showname+Standardize /whois identifier type lookup priority
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants