Week 33: Bouncy movement and reversible navigation

An animated GIF of a recording from Momma Duck showing three ducklings bouncing along behind momma duck.

tl;dr: Last week, I added support for making any navigation bouncy, for ensuring navigation is reversible, and for crawling on ceilings.

What happened last week?


  • I added support for making any navigation be bouncy.
    • Similarly, I added support for specifying that any navigation should either start or end with a jump.
    • Implement ends_with_a_jump for all Behaviors.
  • I added support for configuring whether a Behavior can navigate paths that they cannot return from.
  • I started adding support for characters crawling on ceilings.

Laundry list

  • Add support for being able to get back to where you started.
    • Add support for tracking reachable and reversibly-reachable surfaces.
    • Add a utility for calculating the squared distance between two AABBs.
    • Add support for Behavior.can_leave_start_surface and Behavior.only_navigates_reversible_paths.
  • Add support for extra jumps in navigations.
    • Implement JumpBackAndForthBehavior.
    • Add support for starts_with_a_jump in RunAwayBehavior.
    • Add support for starts_with_a_jump for all Behaviors.
    • Implement CollideBehavior.ends_with_a_jump.
    • Fix navigation-state logic to not immediately skip a jump edge if it ends on the same surface it starts from.
    • Add support for making any navigation be bouncy.
    • Remove JumpBackAndForthBehavior.
      • Fix ends-with-jump to include an intra-surface-edge after the new jump edge.
      • Update path distance and duration after inserting extra jumps at start or end.
  • Miscellaneous
    • Wrap lines that exceed 80 columns.
    • Disable path-pulse when "active trajectory" is disabled.
    • Disable origin annotation when destination annotation is disabled.
    • Update nav trajectory annotations to use the per-player colors rather than global framework colors.
    • Group character Godot-inspector property rows for colors and exclamation-mark parameters.
    • Add another character-log-event type for collisions.
    • Add an editor-inspector checkbox for quickly toggling some common player logs.
    • Move surface_parser and graph_parser references into the level class.
    • Use a new MovementParameter.__movement_params_identifier__ property to identify whether a node in a PackedScene is a MovementParameter.
      • I had instead been requiring MovementParameter nodes be named exactly MovementParameter, but this private property makes more sense for the consumer.
    • Update initial-surface-attachment to also be configurable programmatically, rather than just through a SpawnPosition.
    • Update initial-surface-attachment to also work with Surface on PositionAlongSurface instances, instead of just SurfaceSide.
    • Fix issues with initial-surface-attachment when swapping between duckling and run-away-duckling instances.
    • Updated my devlog Blogger custom-CSS and sidebar-widget-content in order to show links to interesting context from my sabbatical.
    • Mention the behavior system in the README.
    • Prevent ducklings from running away when close to momma.
    • Fix a bug with edge calculations failing when the origin and destination are at the same position.
    • Implement an Array splice utility function.
    • Add support for dynamically including extra face-left/face-right instructions during playback in order to keep the player facing the direction of motion.
    • Update platform-graph inspector-selector clicks to use the character from the last selected inspector item.
      • The inspector selector lets you click on the level to indicate which inter-surface edge you would like to open up to debug in the inspector panel.
      • This used to always just target edges for the default player character.
      • Now it will consider edges for whichever player was last selected within the inspector.
    • Re-enable fox collide ends_with_a_jump.
    • Slightly increase duckling jump-height, to fix a can't-reach-surface regression.
    • Fix a Sc.level-assignment bug when pre-calculating platform graphs.
    • Add action-handler, surface-state, movement-params, and animator support for crawling on ceilings.
    • Update Squirrel Away for latest framework changes, and tested some recent updates.
    • Fix a bug with using app base_path when saving platform-graph files.
    • Flip destination defaults for run-away behavior.
    • Update Squirrel Away players and levels for recent framework changes.
    • I started writing an extended series of posts on how the various layers of character-movement systems in the Surfacer framework.

What's next?

  • Add support for characters that crawl on ceilings.
  • Implement climb_adjacent_surfaces character behavior.

🎉 Cheers!

This is a simple icon representing my sabbatical.