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

[Done] WallMech enemy #252

Merged
merged 6 commits into from Apr 14, 2022
Merged

[Done] WallMech enemy #252

merged 6 commits into from Apr 14, 2022

Conversation

godofgrunts
Copy link
Contributor

Working on #219 with @Charbomber as the designer.

Here is a gif of the current implementation

output

Currently the WallMech AI acts in the following manner:

  • Has a move_direction and shoot_direction which are exported vars.
  • Will continue on its path until it hits a collide-able object, then reverse direction
    • Currently will bounce off the player as well, will fix later
  • When WallMech is ready to attack (3 seconds after it begins moving) it will:
    1. Stop moving for 1 second
    2. Fire
    3. Cooldown for 1 second
    4. Begin moving again

I didn't see any particular art work or sound effects for WallMech's bullets so I reused the Bub enemy's asset. That can easily be changed.

TODO:

  • WallMech doesn't have health
  • Nothing related to WallMech's death is handled
  • Stop WallMech from bouncing off player (needs testing, but I think I just need to remove the player mask)

@github-actions
Copy link

🎉 You can test out this change! ✨👉 https://pr-252--little-mario.netlify.app 👈✨

@godofgrunts
Copy link
Contributor Author

An interesting "problem" has come up. I think most of the world is set to layer 1 which is labeled as "player". Turning that off causes WallMech to go through the world...

I think I might, as a temporary fix, makes a special exception for the player, but I think the baseblock needs to be changed. Might make another commit for that.

@github-actions
Copy link

🎉 You can test out this change! ✨👉 https://pr-252--little-mario.netlify.app 👈✨

@github-actions
Copy link

🎉 You can test out this change! ✨👉 https://pr-252--little-mario.netlify.app 👈✨

@godofgrunts
Copy link
Contributor Author

Added a "flashing" animation (modulates the alpha channel on the sprite) to indicate the enemy has been hit. Enemy needs to be hit 3 times before dying. Not sure if @Charbomber wants a death animation yet.

output1

@github-actions
Copy link

🎉 You can test out this change! ✨👉 https://pr-252--little-mario.netlify.app 👈✨

1 similar comment
@github-actions
Copy link

🎉 You can test out this change! ✨👉 https://pr-252--little-mario.netlify.app 👈✨

@godofgrunts godofgrunts marked this pull request as ready for review April 14, 2022 18:04
@godofgrunts
Copy link
Contributor Author

godofgrunts commented Apr 14, 2022

I've confirmed with @Charbomber that the enemy acts as desired and is ready for merging.

This closes #219

@godofgrunts godofgrunts changed the title WIP WallMech enemy [Done] WallMech enemy Apr 14, 2022
scenes/enemies/Enemy.tscn Outdated Show resolved Hide resolved
@github-actions
Copy link

🎉 You can test out this change! ✨👉 https://pr-252--little-mario.netlify.app 👈✨

@paulloz paulloz merged commit c50557a into a-little-org-called-mario:main Apr 14, 2022
@godofgrunts godofgrunts deleted the wall-mech branch April 15, 2022 00:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants