-
Notifications
You must be signed in to change notification settings - Fork 1
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
add resourcepack linting and cleanup .ajmodel
export files
#62
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- converted file dimensions to be square (2 140x140 frames animated = 140x280)
…textures instead of `projectile-star.png` sprite file
… to fix mipmap warning in console - warning: `Texture animated_java:item/attacks/homing-vine-blinking-lane with size 1x1 limits mip level from 4 to 0`
…ipmap warning in console
- `yarn start lint.resourcepack`
- if a texture isn't (e.g. its width is 1 pixel), we get a warning in the Minecraft game output (log) - e.g. `Texture animated_java:item/black with size 1x1 limits mip level from 4 to 0`
- resize 1x1, 1x2 etc images to be 16x16, 16x32 etc
- had to also update model's UV mapping
TheAfroOfDoom
changed the title
add resourcepack linting for texture dimensions and cleanup
add resourcepack linting and cleanup Jan 8, 2024
.ajmodel
export files.ajmodel
export files
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
When working on #8, we realized that an update to either Blockbench or Animated Java caused diffs in AJ's exported files. This PR runs the exporter again manually on each
.ajmodel
file to ensure cleaner diffs once #8 is complete.During this process, we decided to also cleanup all the warnings that appear in the Minecraft log upon resourcepack reload (
F3 + T
). In particular, we were getting warnings relating to the miplevel (Wikipedia, Minecraft-specific context) being dropped from 4 to 0 due to our textures' dimensions not being divisible by 16.custom linting rules
This PR also adds the infrastructure to support custom linting rules we can run on the datapack/resourcepack files. We added a workflow so that they also run in GitHub Actions.
We add a linting rule that checks every texture file in the
resourcepacks
directory (.png
files) and ensures that their width/heights are divisible by 16.These custom linting rules can be ran with
yarn start lint.resourcepack
.Test plan
models whose textures were modified were re-tested in game to ensure they still functioned/animated/remained the same visually
Reproducing in-game
N/A -- map behavior/visuals should remain unchanged
Preview
Supplemental changes
warning.png
file deleting upon AJ export: a274d2c