From 4af63a0b060feec64dd54a4d6e3860ccff3a3beb Mon Sep 17 00:00:00 2001 From: Griatch Date: Sat, 15 Feb 2025 17:36:25 +0100 Subject: [PATCH] Better explain on utlity tutorial use of `ABILITY_REVERSE_MAP`. Resolve #3680 --- .../Beginner-Tutorial/Part3/Beginner-Tutorial-Utilities.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/source/Howtos/Beginner-Tutorial/Part3/Beginner-Tutorial-Utilities.md b/docs/source/Howtos/Beginner-Tutorial/Part3/Beginner-Tutorial-Utilities.md index 9da8752e07..d493ce0db2 100644 --- a/docs/source/Howtos/Beginner-Tutorial/Part3/Beginner-Tutorial-Utilities.md +++ b/docs/source/Howtos/Beginner-Tutorial/Part3/Beginner-Tutorial-Utilities.md @@ -135,9 +135,9 @@ ABILITY_REVERSE_MAP = { Above, the `Ability` class holds some basic properties of a character sheet. -The `ABILITY_REVERSE_MAP` is a convenient map to go the other way — if in some command we were to enter the string 'cha', we could use this mapping to directly convert your input to the correct `Ability`. For example: +The `ABILITY_REVERSE_MAP` is a convenient map to convert a string to an Enum. The most common use of this would be in a Command; the Player don't know anything about Enums, they can only send strings. So we'd only get the string "cha". Using this `ABILITY_REVERSE_MAP` we can conveniently convert this input to an `Ability.CHA` Enum you can then pass around in code - ability = ABILITY_REVERSE_MAP.get(your_input) + ability = ABILITY_REVERSE_MAP.get(user_input) ## Utility Module