#72: The packet ship, the lifeline mortar and the gull-kite

Eric chose option B on #72. The drop is now the GDD's launch:

- A packet ship sails a seeded straight line past the island, offshore,
  as close in as it can while keeping 45 m of open water from any land
  (eight-way probes; up to 32 headings, then the four world sides).
- Jump fires the lifeline mortar along the look heading. How high the
  player aims sets the charge (-10 to 45 degrees: 16 to 110 m/s over
  the ground; every shot climbs at 75 m/s). The climb can't be steered
  and the kite can't open until the arc tops out. Riders still aboard at
  the end are fired towards the middle of the island.
- Drop.reach() mirrors the fall for both ways down (kite at the top, or
  a fall with the kite opening by itself); bots, the soak and autoplay
  clients and the tutorial pilot aim with Drop.aim_charge().
- Bots fire at their landing spot once abeam of it, when in easy reach
  at their own staggered moment, or just before the route ends, and open
  the kite early only when the spot is beyond the rest of a fall.
- Art: VesselModels.ship() (two-masted packet, tanned square sails, a
  salt-white boot-top, a bowsprit and the mortar on its bed, mirrored to
  face the island), the figure's gull-kite (figure.py), and a lifeline
  cord from the muzzle to each player still climbing.
- Renamed barge to ship and wing-sail to gull-kite throughout code,
  tests, captures, docs and the tutorial text. make match now defaults to
  seed 2, where the scripted player still harvests and builds.

Closes #72

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-15 12:49:21 -05:00
co-authored by Claude Opus 5.5
parent 4357861bd4
commit aa797580a7
69 changed files with 1753 additions and 847 deletions
+2 -2
View File
@@ -7,7 +7,7 @@
## packets to receive() and sends whatever advance() leaves in `outbox`.
##
## The client generates the match's island itself from the seed in the MATCH notice
## (`world`, a Simulation that is never stepped) and plans the same barge route, so it
## (`world`, a Simulation that is never stepped) and plans the same ship route, so it
## can run the same movement code as the server on the same ground. WORLD messages keep
## that world's built pieces, props, chests and tide in line with the server's, and OWN
## messages say what the player carries (`replica`, a ClientWorld). Pieces the player
@@ -322,7 +322,7 @@ func _take_snapshot() -> void:
_recent.clear()
return
if not prediction.active:
# The barge's route is drawn from the seed alone, at the match's first tick.
# The ship's route is drawn from the seed alone, at the match's first tick.
prediction.begin(world.ground, Drop.plan(world.ground, SimRng.new(world_seed), 0))
clock.start(receiver.sim_tick)
clock.observe(receiver.sim_tick, receiver.command_tick)
+9 -9
View File
@@ -5,7 +5,7 @@
## pieces, props, chests and tide in line with the server. This adds the rest of the
## picture, afresh every frame: every entity the server has told this client about,
## where it is being drawn now (everyone else from the recent past, the client's own
## player where it was predicted), the barge, the clock and the sea level. Nothing
## player where it was predicted), the ship, the clock and the sea level. Nothing
## here is authoritative, and nothing reads it back but views and the client's own
## check before placing a piece.
class_name ClientMirror
@@ -16,8 +16,8 @@ extends RefCounted
var watched_id: int = 0
## The client's own player while it is in the match, or 0.
var own_id: int = 0
## Where the barge is being drawn, or Vector3.INF when it isn't crossing.
var barge_at: Vector3 = Vector3.INF
## Where the ship is being drawn, or Vector3.INF when it isn't crossing.
var ship_at: Vector3 = Vector3.INF
## The moment being drawn, in simulation ticks.
var time: float = 0.0
@@ -35,7 +35,7 @@ func sync(game: ClientGame) -> void:
var world: Simulation = game.world
watched_id = 0
own_id = 0
barge_at = Vector3.INF
ship_at = Vector3.INF
if world == null:
return
var receiver: SnapshotReceiver = game.receiver
@@ -60,7 +60,7 @@ func sync(game: ClientGame) -> void:
_drop.finished = _drop.is_over(world.tick)
world.drop = _drop
if not _drop.finished:
barge_at = _drop.barge_position(world.tick).lerp(_drop.barge_position(world.tick + 1), time - floorf(time))
ship_at = _drop.ship_position(world.tick).lerp(_drop.ship_position(world.tick + 1), time - floorf(time))
else:
world.drop = null
@@ -154,8 +154,8 @@ func _show_player(entity: SimEntity, record: PackedInt32Array, shown: Dictionary
entity.use_ticks = 1 if flags & NetSnapshot.FLAG_USING != 0 else 0
# What is in the player's hands, for whoever draws it: the item's code, or -1.
entity.item = record[NetSnapshot.R_HELD] - 1
if entity.drop_state == Drop.ABOARD and barge_at != Vector3.INF:
entity.position = barge_at
if entity.drop_state == Drop.ABOARD and ship_at != Vector3.INF:
entity.position = ship_at
## The client's own player: where and how it was predicted, not where the server last
@@ -172,5 +172,5 @@ func _show_own(entity: SimEntity, game: ClientGame) -> void:
entity.velocity = me.velocity
entity.reload_ticks = me.reload_ticks
entity.use_ticks = me.use_ticks
if me.drop_state == Drop.ABOARD and barge_at != Vector3.INF:
entity.position = barge_at
if me.drop_state == Drop.ABOARD and ship_at != Vector3.INF:
entity.position = ship_at
+1 -1
View File
@@ -157,7 +157,7 @@ func _run(tick: int) -> void:
return
_drop.ride(player, command, tick)
if player.drop_state == Drop.ABOARD and _drop.is_over(tick + 1):
_drop.leap(player, tick + 1)
_drop.fire_at_end(player, tick + 1)
return
var water: float = _water_at(player.position)
Movement.step(player, command, _ground, water)