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

make extensions case insensitive for type guessing and texture reloading #676

Draft
wants to merge 2 commits into
base: dev
Choose a base branch
from

Conversation

microlith57
Copy link
Member

do not merge until asset reloading is properly tested

currently, files such as image.PNG are not recognised as PNG images, whereas image.png are.
this PR makes the type guesser and texture reloader case insensitive for extensions, so those files would both be recognised as PNGs.

@microlith57
Copy link
Member Author

aparently OrdinalIgnoreCase is better than InvariantCultureIgnoreCase; i'll change that

@@ -709,25 +709,33 @@ public static class Content {
public static void Add(string path, ModAsset metadata)
=> TryAdd(path, metadata);

private static readonly string[] METADATA_YAML_NAMES = {
Copy link
Member

Choose a reason for hiding this comment

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

metadata.yaml and multimetadata.yaml are no longer supported, I just forgot to remove them from the type guesser apparently

@maddie480 maddie480 added the dormant This PR is really old, do we really need it? label Apr 29, 2024
@microlith57 microlith57 self-assigned this Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dormant This PR is really old, do we really need it?
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants