Commit graph

21 commits

Author SHA1 Message Date
935ee797dc Hop up to the ceiling after holding up on the floor
Holding up on the floor for MAX_SECS_TO_UNSTICK hops just high enough to
reach a ceiling up to HOP_MAX_HEIGHT (64px) above the slime's top, where
it then sticks. With no ceiling in reach it does a little 16px hop.
Against a wall, up still climbs it instead.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 16:21:31 -07:00
31f1de7d68 Halve edgeSensorRange to 12 so edge wraps need the slime at the edge
Pressing into a surface now only wraps around its edge when the slime's
center is within 12px of it, i.e. the slime is touching the edge (about
1px gap), instead of up to 13px away with the old 24. Walking up to an
edge still always works, since the edge hold stops the slime there.

Measured with a headless sweep of 24/16/14/12/10/8/6/4 on floors,
ceilings and wall bottoms.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 15:54:34 -07:00
ad9e8d62fa Stop the edge sensors from hitting the player's own collider
Since the sensors moved under the EdgeSensors pivot, exclude_parent
excludes the pivot rather than the player. With edgeSensorRange equal to
the slime's radius the rays start on the edge of its circle and hit it,
so edge wraps never triggered. Add the player as an exception.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 15:54:15 -07:00
c212748b8d Don't treat tile seams or the foot of a wall as an edge
The level's TileMapLayer is made of separate collision shapes, and the
ray that looks for the side of a platform could hit the inside face of
a neighbouring tile. That made walking along the floor stop and "hold"
at tile seams and next to walls. A corner now only counts as an edge if
there's empty space just past it, behind the surface.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 15:14:07 -07:00
e5c176f1f6 Hold at the edge of any surface before letting go
Moving along a floor, ceiling or down a wall towards its edge now stops
at the edge, and only carries on over it after holding towards it for
MAX_SECS_TO_UNSTICK. Before, only ceilings had this (the lip, which
started after leaving), so walking off a floor sideways or crawling off
the bottom of a wall dropped instantly. Climbing up past a wall top
still swings over onto it straight away.

- While holding at an edge, pressing into the surface still wraps
  around it.
- After wrapping onto a ceiling, a held down doesn't count towards
  letting go until it's released (like walls already did).
- Pull the corner finding out of _try_edge_wrap into _find_edge_corner.
- project.godot: settings re-sorted by the editor, no change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 15:02:33 -07:00
20f4785d56 Smoother movement feel, plus landing/wrap sounds and splat particles
- Accelerate to full speed in 4 frames and stop in 6, on floors, walls
  and ceilings, instead of snapping.
- Keep momentum when leaving a surface; air steering is gentler and
  extra speed fades slowly. Fall speed capped at 400.
- Edge wraps ease in from a standstill and carry their speed out onto the
  new surface.
- Pull back onto a wall/ceiling that's drifted up to 4px away instead of
  falling off (floor_snap_length matches).
- Physics interpolation and pixel-snapped 2D transforms. Sprite rotation
  moved into _physics_process and made frame-rate independent.
- Squish sound + slime particles on landing, bubble sound on wraps.
  Placeholder CC0 sounds by rubberduck from OpenGameArt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 13:37:54 -07:00
01eb5adbd1 Rotate edge sensors with the surface so edges work on walls and ceilings
The edge sensors now live under an EdgeSensors pivot that's rotated to
point into whatever surface the slime is on. Pressing into the surface
(down on floors, up on ceilings, towards the wall on walls) near an edge
slides over it onto the side of the platform. The other axis picks the
side; otherwise facing decides (last direction moved along a wall).

- Ceiling edge -> wall above, wall top -> floor, wall bottom -> ceiling
  underneath, floor edge -> wall below, all through one code path.
- Skip sensors that start inside something (inside corners).
- _begin_wrap takes the normal of the surface to end up on and works
  out the sprite rotation from it; wraps can now end on a ceiling.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 13:11:14 -07:00
815444f3af Slide over floor edges onto the wall below when pressing down
Two RayCast2D edge sensors point down into the floor edgeSensorRange to
each side of the slime. When one stops touching floor there's an edge in
range on that side, and pressing down slides to it, swings over the
corner and carries on down the wall so the slime ends flat against it.

- Down + a direction picks that side; down alone goes the way the slime
  is facing, or the other way if only that side has an edge in range.
- Down in the middle of a platform does nothing.
- edgeSensorRange is exported (default 24, tuned with a headless sweep).
- Wraps can now start with a straight move to the arc, and end with a
  move_and_slide so is_on_floor()/is_on_wall() aren't stale afterwards.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 13:02:05 -07:00
b098b78934 Stay on the wall after wrapping around a lip
The wrap ended with the slime level with the corner and WRAP_MARGIN away
from the wall. The wall stick push only covers ~0.33px a frame, so it
often didn't touch the wall on the next move_and_slide, stopped sticking
and fell.

- After the arc, carry on straight up the wall by the radius (or onto the
  platform for wall tops) so the slime ends flat against the surface.
- Close the remaining gap with move_and_collide when the wrap finishes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 12:46:08 -07:00
43380dd72c Smoothly wrap around ceiling lips and wall tops
Instead of relying on physics to slide the round collider around a
corner, find the corner with raycasts and swing the slime around it on
a quarter circle at crawling speed, rotating the sprite along with it.

- Hanging on a ceiling lip + up: swing onto the wall above.
- Climbing up past the top of a wall: swing over onto the floor on top.
- Tapping up up to 0.15s before reaching a lip still counts.
- Falls back to the old behaviour if the corner can't be found or there
  is no room at the end of the swing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 12:41:11 -07:00
c72708e63e Merge pull request 'Fix climbing from a ceiling lip onto the wall above' (#1) from fix-lip-wall-climb into main
Reviewed-on: #1
2026-10-31 14:38:25 -05:00
485553df3e Fix climbing from a ceiling lip onto the wall above
- Pressing up while hanging on a lip now moves the slime up and back
  towards the platform so it wraps onto the wall instead of staying frozen.
- Only walking off a ceiling edge starts a lip hang (not landing on a
  ceiling or dropping off it with down).
- Don't count the held direction towards unsticking from the wall right
  after climbing on from a lip, until it's released.
- Remove leftover debug print.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 12:30:08 -07:00
0db36e2526 Added lip climbing 2026-10-30 23:59:38 -07:00
64188a72d3 Revert "blah"
This reverts commit 454624856d1f686e4ce5e3df4e6a5e2b47cfc83d.
2026-10-30 23:16:23 -07:00
f70cc0b97a Added extra code for sticking to the wall or ceiling.
- Slight delay before unsticking from a wall/ceiling.
2026-10-29 14:25:36 -07:00
4df996690e - Removed jumping code
- Add clinging to ceiling upon touch
2026-10-29 01:28:37 -07:00
ca14c26a2d - New placeholder slime sprite
- testing removing jump from player
2026-10-26 23:28:46 -07:00
696a89d1ec Add jump buffering to player slime. 2026-10-18 20:14:18 -07:00
46cac1e3c7 - Added options menu with Claude. Complete with keybindings and volume sliders. 2026-10-18 18:21:27 -07:00
8cb47464dd - Added in-game pausem menu. Generated with Claude! 2026-10-17 23:51:15 -07:00
164aaaaeb7 Initial upload of Slime Platformer. 2026-10-14 01:50:16 -07:00