Feature Move latte locations to separate data file (or add ASH functions for ingredients)

Saklad5

Member
I recently realized that you can access builtin data files like “modifiers.txt” using file_to_map. With that in mind, I think it would be very helpful for LatteRequest.java to be reworked such that the map of latte ingredients is stored as a separate data file, rather than being hard-coded. It is incredibly tedious for everyone to handle latte ingredients independently, and this has the benefit of being maintained should any changes be made in the future.

For instance, one of the ingredients still hasn’t been found, and it is reasonable to assume it will be eventually. It’s also not improbable that ingredients will be added in the future, as some IotMs like this get minor content updates.

If this is infeasible for some reason (I’m not very well-versed in KoLmafia’s design, which is why I’m not making a patch for this), then at least make it possible to access the data through functions or proxy record fields.
 

Saklad5

Member
Making this accessible to everyone would also mean that the ingredient names (already used for the latteUnlocks property) are standardized across scripts. Scripts like Ezandora’s relay override have to include their own ingredient lists, and they often diverge in that regard.
 

AlbinoRhino

Active member
I made this a while back but you're welcome to it:

it fits this records structure
Code:
record lattinf {
		string lattbonus;
		string mafiaproptext;
		string lattloc;
	};
	lattinf[int] latte_unlocks;
 

Attachments

  • latteData.txt
    2.7 KB · Views: 21
Top