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

Movement Animations #27

Closed
2 tasks done
benisrael29 opened this issue Sep 1, 2021 · 0 comments
Closed
2 tasks done

Movement Animations #27

benisrael29 opened this issue Sep 1, 2021 · 0 comments

Comments

@benisrael29
Copy link
Contributor

benisrael29 commented Sep 1, 2021

Task: Add movement animations for both NPC's and the player character.

Feature:

  • Implement a PlayerAnimationController which configures animations to be played when the player changes direction.

  • Configure KeyboardPlayerInputComponent to throw entity events when keyboard input is received.

  • Tigger events only in KeyboardPlayerInputComponent.KeyUp to avoid triggering animations every update() cycle.

  • Implement PhysicsComponent.MovementEvents() to be called in PhysicsComponent.update() and throw movement events for the NPC entity.

  • Use private int lastDirection and private int currentDirection to track changes in direction of the NPC. lastDirection is to be update via PhysicsComponent.MovementEvents() where as currentDirection is update every cycle by a call to KeyboardPlayerInputComponent.getCurrentDirectionCode().

  • Implement player animations

  • Implement NPC animations

Dependencies

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants