There are three, so far:
Items:
sweet tooth
industrial strength starch
Knob Goblin perfume
Effects:
Sweet Tooth
Industrial Strength Starch
Knob Goblin Perfume
We convert names to the "canonical" name when storing/looking up modifiers. StringUtilities.getCanonicalName does this:
I suppose I can why we want to convert UTF characters into entities, but the lower casing is what causes the issue for the three item/effect pairs I mentioned.
I wonder what would happen if we indexed modifiers by the actual name that appears in modifiers.txt, complete with upper and lower case letters - and with HTML entities exactly as KoL itself uses them.
- would that break anything for internal uses of modifiers? I.e., do we every look them up with canonicalized names, or do we always use real item/skill/effect/etc. names?
- how about ASH programs? You can call numeric_modifier, boolean_modifier, and string_modifier with a $item, $effect, (or $skill or $familiar) and that uses the "to_string" method to get the (non-canonical) name. The thing is, you can also pass in a program-generated string.
I'm tempted to just make the change and wait for the howls of rage.
Items:
sweet tooth
industrial strength starch
Knob Goblin perfume
Effects:
Sweet Tooth
Industrial Strength Starch
Knob Goblin Perfume
We convert names to the "canonical" name when storing/looking up modifiers. StringUtilities.getCanonicalName does this:
Code:
canonicalName = StringUtilities.getEntityEncode( name ).toLowerCase();
I wonder what would happen if we indexed modifiers by the actual name that appears in modifiers.txt, complete with upper and lower case letters - and with HTML entities exactly as KoL itself uses them.
- would that break anything for internal uses of modifiers? I.e., do we every look them up with canonicalized names, or do we always use real item/skill/effect/etc. names?
- how about ASH programs? You can call numeric_modifier, boolean_modifier, and string_modifier with a $item, $effect, (or $skill or $familiar) and that uses the "to_string" method to get the (non-canonical) name. The thing is, you can also pass in a program-generated string.
I'm tempted to just make the change and wait for the howls of rage.