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

Bug: Cats do not use vertical movement texture data #11

Closed
pushfoo opened this issue Apr 26, 2022 · 6 comments
Closed

Bug: Cats do not use vertical movement texture data #11

pushfoo opened this issue Apr 26, 2022 · 6 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@pushfoo
Copy link
Member

pushfoo commented Apr 26, 2022

Describe the bug
Cats do not use the texture data for vertical movement. This data is included in their sprite sheets, but never used in-game:
image

To Reproduce
Steps to reproduce the behavior:

  1. Launch game
  2. Watch until a cat decides to move up or down

Expected behavior
Texture data for vertical movement is used when moving up or down

@pushfoo
Copy link
Member Author

pushfoo commented Apr 26, 2022

This may also extend to NPCs in general, but we do not currently have any moving NPCs other than cats.

@Cleptomania
Copy link
Member

A question that maybe makes sense for this, this is easy if it is only ever moving in one direction(left, right, up, down) but what happens when it's moving at an angle, say left and up at the same time, do we use the left facing or the up facing texture?

Obviously this could be solved by having textures for those angled directions, but those do not exist in the current spritesheet(at least for the cat specifically, but probably also for other characters). This can maybe be partially solved by switching some things to a more complete set of sprites from kenney.nl? We would definitely still have to build some logic in to handle the various directions other than left or right.

@Cleptomania Cleptomania added enhancement New feature or request good first issue Good for newcomers labels Apr 27, 2022
@pushfoo
Copy link
Member Author

pushfoo commented Apr 27, 2022

For the alignment question you brought up, I think matching the sprite to the nearest or most recent movement vector change would be fine. I think the player character behaves that way right now, but not the cats.

@pushfoo
Copy link
Member Author

pushfoo commented Apr 27, 2022

Building more refined state and animation tracking into the sprites is also worth considering. We hardcode frame numbers right now. 🙃

@bkiu
Copy link
Contributor

bkiu commented May 2, 2022

I'm working on this.

Cleptomania added a commit that referenced this issue May 2, 2022
Enabling characters to use vertical sprites for vertical movements. #11
@pushfoo
Copy link
Member Author

pushfoo commented May 10, 2022

Testing indicates that up and down data now gets used for cats and dogs. 👍

@pushfoo pushfoo closed this as completed May 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants