Commit graph

359 commits

Author SHA1 Message Date
Nathan Lovato
0dfc7a7ca1
Merge pull request #163 from GDquest/features/hookable-enemies
First rough pass at enemy as hookable
2019-09-24 18:07:20 +02:00
Francois Belair
fcf909fcba Recommended coding style fixes. 2019-09-24 08:52:04 -04:00
Francois Belair
e1712731ba Fixed die state not receiving last_checkpoint outside of debug commands.
Sequestered the hop on enemy logic into Player so the enemy entity does not control the player. Added stunned state for enemy for the knockback effect.
2019-09-23 15:38:37 -04:00
Nathan Lovato
113f83e358 Make the player stop and hop upon reaching a hooked enemy 2019-09-21 10:25:38 +02:00
Francois Belair
8223a8c1fa Enemy damaged by hook instead of bounce. Player velocity boosted instead of just a jump impulse, if it exists. 2019-09-20 15:52:58 -04:00
Francois Belair
72ef29770f Player.gd now has a get_collider method for ducktyping when accessing its body in signals.
Basic enemy that patrols side to side - can be hooked onto and bounced off of without any modification to player.
2019-09-19 14:39:34 -04:00
Francois Belair
0e873f37c0 First enemy using steering and state machine (#161)
* Added a basic enemy that charges towards the player. Uses state machine decision making, and steering behaviors.

* Added a basic enemy that charges towards the player. Uses state machine decision making, and steering behaviors.

Cleaned up code and fit guidelines.

* Update code style

Use var name: Type = value instead of casting the variable with as
Use onready vars to cache node dependencies
Use the player node (KinematicBody2D) as a target instead of getting its
collision shape (we should never get a child of a node from another scene
directly)
Remove wrapper method to change state: we already have
_state_machine.transition_to, it doesn't add much to me to wrap it under a _change_state method
2019-09-17 12:18:09 +02:00
Nathan Lovato
0a3c2b34fc Change restart input action 2019-09-07 14:34:57 +02:00
Nathan Lovato
8ef30f68dc Update the game concept 2019-09-07 11:13:59 +02:00
Nathan Lovato
fb5b1f5996 Close #134: Add time limit and gradual slow down after a power jump 2019-09-07 10:32:14 +02:00
Nathan Lovato
5362968598 Fix broken transition from the hook Aim to Fire state 2019-09-07 10:14:23 +02:00
Nathan Lovato
42bb4cbecd Close #159: Remove aim logic in the Fire state
Now the Fire state doesn't depend on the Aim state anymore so I removed
the parenting
2019-09-07 10:05:02 +02:00
Nathan Lovato
f54fb0eee2 Update default acceleration, set LedgeWallDetector active 2019-08-25 16:19:11 +02:00
Nathan Lovato
e5fbf57b03 Let the player throw the hook even when there is no target in range
This is merely visual for now. Also, the arrow doesn't collide with walls or the
floor: it goes through.
2019-08-25 16:17:05 +02:00
Nathan Lovato
d09ccabd04 Change type of the variable to State 2019-08-25 16:05:01 +02:00
Nathan Lovato
b608fcb45e Fix unknown move identifier 2019-08-25 16:04:44 +02:00
Nathan Lovato
c1a3af6082 Fix #155 Add Wall -> ledge state transition to avoid jitter 2019-08-23 11:36:28 +02:00
Nathan Lovato
af3e4bb83b Fix shadow jitter under Robi 2019-08-21 17:23:37 +02:00
Nathan Lovato
8ae2a95e30 Fix bug with floor not detected in ledge state 2019-08-21 17:22:36 +02:00
Nathan Lovato
418eae6a18 Simplify hook fire code 2019-08-20 15:50:04 +02:00
Nathan Lovato
08eec07a30 Remove superfluous condition in SnapDetector 2019-08-20 15:48:39 +02:00
Nathan Lovato
1fbbd0ad2b Clean up SnapDetector 2019-08-20 11:13:35 +02:00
Nathan Lovato
9f4579e225 Fix #158: Add a transition from Hook -> Run state 2019-08-14 10:22:05 +02:00
Nathan Lovato
1d5f921cf4 Update environment art, fix some artifacts 2019-08-14 10:21:23 +02:00
Nathan Lovato
8c4220245a Add a shadow that scales under the player
The distance to the floor is a bit messed up right now, the shadow ends up
moving vertically on the ground.
2019-08-14 10:07:50 +02:00
Nathan Lovato
097950a071
Merge pull request #157 from razcore-art/feature-state_parent
Replace get_parent() calls with _parent var
2019-08-14 09:51:53 +02:00
Răzvan C. Rădulescu
c31e970772 Replace get_parent() calls with _parent var 2019-08-14 10:33:46 +03:00
Nathan Lovato
c696824583 Improve formatting in Steering.gd 2019-08-13 16:30:18 +02:00
Nathan Lovato
1d0c826ef8 simplify air state code 2019-08-13 14:45:03 +02:00
Nathan Lovato
718a6e00d5 Update State and StateMachine docstrings, simplify code
is_composite was set on _init() so get_child_count() != 0 would always be false.
The only place we used that variable was in an assert that would always pass.
2019-08-11 22:28:35 +02:00
Nathan Lovato
7197cff0a5 Simplify hook drawing code, remove obsolete conditional
Remove TargetCircle, make arrow sprite always visible
2019-08-10 14:00:15 +02:00
Nathan Lovato
2fc15f04dd Remove unused sprint input action 2019-08-10 10:22:31 +02:00
Nathan Lovato
34b54a95a9 Hook tweaks and fixes, add docstrings, remove superfluous script
Remove Raycast2D script, add docstrings
2019-08-10 10:15:14 +02:00
Nathan Lovato
d0b68a2b06 Simplify Hook.gd 2019-08-10 09:10:23 +02:00
Nathan Lovato
da975c84d9 Add Hook node icon 2019-08-09 18:35:04 +02:00
Nathan Lovato
e76573518c Add R2/RT button to hook 2019-08-09 10:53:13 +02:00
Nathan Lovato
c4d9ea1f8f Wall state: add back lost unhandled_input function during merge 2019-08-09 08:28:29 +02:00
Nathan Lovato
9ce1fb6427 Merge branch 'master' of github.com:GDquest/godot-metroidvania-2d 2019-08-08 17:42:08 +02:00
Nathan Lovato
768c57cb73 Fix wall state continuing after sliding off a wall
Refactored the LedgeDetector, now called LedgeWallDetector, as it's used to
detect both ledges and walls
2019-08-08 17:38:00 +02:00
Nathan Lovato
5d335581d6 Move DrawingUtils to Autoload folder 2019-08-08 17:37:21 +02:00
Nathan Lovato
9ff09ff15a
Merge pull request #154 from razcore-art/fix-state_signals
Get states to manage their own signal connections in enter/exit
2019-08-08 15:56:59 +02:00
Nathan Lovato
3ee46095fd Update icon 2019-08-08 15:53:07 +02:00
Nathan Lovato
60f2b2afc9 Rename, remove, and reorganize assets 2019-08-08 15:27:28 +02:00
Nathan Lovato
9c684ede37 Remove unused Events signals 2019-08-08 15:23:47 +02:00
Răzvan C. Rădulescu
164f0f590f Get states to manage their own signal connections in enter/exit 2019-08-08 16:21:56 +03:00
Nathan Lovato
87037136d2 Fix #150: increase Air max speed based on the previous state's velocity 2019-08-08 12:26:35 +02:00
Henrique Campos
0a0950d829 Fix PassThrough not working (#147)
* Fix PassThrough not working

* Move PassThrough logic to Move

Also Remove PassThrough.gd from the project.
2019-08-08 11:48:29 +02:00
Nathan Lovato
8423575c7a Move StateMachine to the Main folder 2019-08-07 19:38:01 +02:00
Nathan Lovato
685f2dda83
Merge pull request #149 from razcore-art/feature_backtracking
Add ability to travel through portals from level to level
2019-08-07 15:49:02 +02:00
Nathan Lovato
ebcf566ab3 Close #148: Remove unused camera anchor detector dependency on Player
All the other onready var are in use
2019-08-07 14:36:27 +02:00