# Cargo Helicopter changelog

## 0.8.0 (ATC-AUTHORED-YARD-ROUTING)

- Replaced the heliport AssetBundle with the supplied `Heliport_ATC_Complex` model, optimized to nine renderers while preserving the named roll door, two lifts and four hatch panels used by runtime animation.
- Added an authored `ContainerYardAnchor` at the centre/top of `CY_Deck`; parked containers and tanks now use the elevated platform surface instead of terrain underneath the deck.
- Recalibrated the 1:1 model: main pad and garage floor at 6.05 m, assembly lifts at 6.45 m, 7.1 m lift travel, mirrored Unity garage interior, tower bays, footprint and occupancy height.
- Replaced the direct yard-to-pad route with `yard -> exterior gate -> pad overhead -> vertical descent`. The game navigator can no longer draw a horizontal line through the hangar footprint.
- Height gates now read the actual interpolated Transform pose, not FuturePosition. Visible Y converges smoothly on wall time, preventing the render model from lagging below a roof-safe simulation pose.
- Removed the SIM-tick winch timeout that let an upper-layer attachment enter the garage. Landing cannot begin until physical grounding and successful static-visual handoff are both confirmed.
- Storage drops lock the sling to the platform's world rotation from the start of the descent, eliminating the crooked-lowering then instant-straight snap.
- The authored platform uses a centred 2x2 footprint with five strictly owned layers for twenty helicopter attachments.

## 0.7.10 (VERTICAL-OVERHEAD-PAD-APPROACH)

- Returning helicopters now use hard three-phase arrival legs: lock X/Z and climb above the measured depot roof, fly horizontally at that safe altitude, then descend vertically only after capturing the exact helipad centre.
- The incoming holding-to-container-yard leg uses the same vertical clearance barrier, so a helicopter carrying its attachment cannot cut diagonally through the hangar while approaching the drop point.
- Every horizontal arrival leg retains the roof-safe minimum altitude until its destination is reached. Landing clearance is still withheld until pad-centre capture.
- Added transition logging with actual and required world altitude, making it possible to verify that roof clearance was genuinely reached before navigation resumed.

## 0.7.9 (SINGLE-PAYLOAD-SAFE-APPROACH)

- Removed the unreliable ProductsRenderer/cosmetic handoff entirely. Every helicopter now uses one persistent sling attachment mesh for empty, loading, loaded, unloading and flight states, so a queued GPU render can never make the container disappear.
- Product type and icon still update from the authoritative cargo/planned pickup; only the unstable duplicate renderer was removed.
- Returning helicopters keep a hard roof-clearance altitude from the yard all the way to the exact pad centre. Landing clearance is granted only after centre capture, preventing the yard-to-pad route from descending through the heliport building.
- Reasserts whole-sling hiding after the static yard handoff so the intentional empty return-to-hangar phase has no confusing dangling spider/cables.

## 0.7.8 (TRANSFER-VISIBLE-ROOF-CLEARANCE)

- A lowered sling now always uses one stable cosmetic container/tank during loading and unloading. GPU unit-cargo rendering is enabled again only after the sling is reeled up, so the container cannot disappear at zero/partial transfer quantity.
- Hangar rotor spin-up and vertical climb use fixed sync steps instead of near-zero DeltaSimStepsApprox; takeoff no longer spends ~11 sim seconds in state 3.
- Storage departure receives a hard minimum altitude above the measured heliport roof before any horizontal yard/job leg is allowed.
- Normal airborne altitude correction uses a stable minimum sync interval, allowing LineMax roof detection to raise the helicopter before its horizontal simulation path reaches factories.
- The fixed TakeoffStartY target now also incorporates the depot roof-clearance altitude.

## 0.7.7 (ATOMIC-PAYLOAD-TAKEOFF)

- Fixed missing attachments: an unknown/empty FlatBed snapshot is no longer treated as a real GPU-rendered product, and stale render-success state can no longer suppress the cosmetic fallback.
- Restored twenty strictly owned visual attachment places per depot in a non-overlapping compact 3x2 yard with up to four correctly seated layers.
- Yard pickup is now atomic: the rig and cable descend while the static ground payload remains the only visible payload; after the main thread confirms that ground GameObject is destroyed, exactly one slung payload appears and reels in.
- Fixed the moving takeoff threshold by capturing a fixed TakeoffStartY. Storage departures climb straight up rapidly to StartY+12 instead of waiting 9--11 sim seconds for an unreachable moving target.
- Before releasing JobHeld, the dispatcher clears its terminal yard DrivingTarget, allowing the untouched real job to issue its source/destination immediately instead of circling or becoming idle again.
- Aborted storage sequences restore the slung payload whenever their owned static yard model is removed.

## 0.7.6 (OWNED-YARD-JOB-HANDOFF)

- Final hangar landing now eases for 0.9 seconds from the actually visible helicopter pose and writes altitude only; it no longer snaps from an already-advanced FuturePosition.
- While a stored helicopter exits and retrieves its attachment, only its real job advancement is held. Game movement continues normally, eliminating the fight between the yard target and the job target that caused circles and U-turns. The untouched job resumes immediately after reel-in.
- Yard slots are atomically reserved and carry an explicit owner ID: one helicopter has exactly one container/tank slot, and a stale helicopter cannot park in or remove another helicopter's slot.
- The owned yard model is changed to the known next pickup kind before departure, so liquid jobs use that helicopter's tank instead of briefly showing a container.
- Fixed `ReRenderAtSling` overload resolution (`Proto`) which previously logged `AmbiguousMatchException` and disabled genuine product re-rendering for the session.

## 0.7.5 (CLEAN-HANGAR-SEQUENCE)

- Parked attachment visuals now use terrain height only and are rejected if the complete yard footprint is not open ground; they can no longer inherit a roof/occupancy height and float above the heliport.
- Replaced the overlapping 20-object cosmetic grid with a correctly spaced 2x2 two-layer yard. The hangar still stores 20 helicopters logically.
- Storage landing is now a fast, continuous vertical descent after precise game-navigation alignment. Removed the landing `TeleportTo` snap.
- Replaced the scripted U-turn/corridor departure with: taxi to pad centre, normal vertical takeoff at full rotor RPM, direct game-navigation leg to the yard, grounded winch pickup, reel-in, then release to the job.
- Scripted poses are reasserted while paused, eliminating the pause/unpause visual position jump.
- Landed rotors stop fully; lift starts only at full rotor speed. Travel attachments reel tightly to the helicopter.

## 0.7.4 (LOADGATE-FIX)

- Fixed a Linux/Steam-Proton crash where the game could fail to load with the mod enabled (peach-coloured background, resetting loading bar, half-built HUD, then a crash). The mod's Harmony patches were being applied on a fixed ~1-second timer that, on slower machines loading larger saves, still fired while the game was still initializing the scene (its "delayed deserialization" stage plus a tail of forced warm-up frames) — interrupting the load. The one-time patching now waits until the scene is fully initialized and the loading screen is gone (IMain.IsInitializingScene turns false) before applying, so it can no longer land mid-load however long the load takes.

## 0.7.3 (LANDING-YARD-HARDFIX)

- Helicopter build time cut ~4x: Tier I/II/III now take 30/45/60 seconds (only these three helicopters; other vehicles unchanged).
- The build-complete emerge (hatch, elevator ride, lift-off) is now ~2.5 seconds instead of ~7, with the hatch opening faster in step so the helicopter never rides up through it.

## 0.7.2 (LANDING-YARD-HARDFIX)

- The cargo yard now anchors to an authored ContainerYardAnchor transform if the heliport model provides one (and logs its chosen world position either way), so the drop zone can be placed precisely instead of guessed near the pad edge.

## 0.7.1 (LANDING-YARD-HARDFIX)

- Rewrote the final touchdown as a deterministic, frame-driven descent (the helicopter briefly pauses, is set straight down onto the pad centre in ~2 seconds, and is committed to the simulation there) instead of relying on the physics/render path to settle a landing that could hang for tens of seconds.

## 0.7.0 (LANDING-YARD-HARDFIX)

- After a helicopter sets its load down in the yard, the sling — spider, straps, cable and hook — now fully disappears, so it no longer flies to the pad with an empty rig dangling underneath.
- Stored yard attachments now rest with their bottom face on the ground surface instead of floating, and a stacked second layer sits on the actual top of the object below it.
- A full yard no longer overwrites another helicopter's parked model; when full, the helicopter simply stores without a cosmetic drop.
- Storage commands are no longer silently dropped if issued a moment before the helicopter's first render.
- Startup now logs a unique build banner so a game log unambiguously shows which build actually loaded.

## 0.6.8

- Fixed a yard slot and its model leaking (and a possible duplicate attachment) when a helicopter was pulled back to work or force-released after it had already requested a yard drop.
- Hardened the departure simulation-commit against a game method being overloaded in a future update.

## 0.6.7

- Fixed the wrong attachment (container) flashing for a frame when a helicopter reappears from storage or switches load type: attachment visibility is now resolved in one place and never blank-enables all attachment meshes at once.
- A helicopter now sets its attachment in the yard only once the permanent yard model actually exists (no blink/gap), and only after the load has truly reached the ground (never a model left floating in the air).
- Departing helicopters now commit their scripted takeoff to the simulation once at the exit waypoint, so the real job continues from outside the complex instead of snapping back through the building.
- The vertical-takeoff height now uses the building's measured height instead of a fixed guess.

## 0.6.6

- Fixed parked yard attachments (tanks/containers) flickering: they are now permanent objects in the scene instead of being redrawn each frame from an unreliable render hook, so they stay visible in every frame.

## 0.6.5

- Fixed helicopters hanging for tens of seconds directly over the pad centre before touching down: touchdown is now confirmed from the simulation position (the helicopter stops driving when centred) instead of a render-interpolation speed that never settled at zero distance.
- Fixed a helicopter's job-state check throwing inside the game and briefly flipping the helicopter between busy and idle, which disrupted storage.

## 0.6.4

- Helicopters now leave the hangar safely: they taxi to the pad centre, take off STRAIGHT UP above the roof, then head out — the real job can no longer drag a departing helicopter straight through the hangar.
- A departing helicopter reclaims its own attachment from the yard (drops to it, picks it up, lifts back up) before flying out to a waypoint clear of the complex, and only then is handed to its job.
- Hardened patch loading: if a future game update renames a hooked method, only that one hook is skipped instead of disabling the whole mod.
- Fixed a yard slot that could stay marked "occupied" if a drop was abandoned.

## 0.6.3

- The hangar cargo yard now shows the actual helicopter ATTACHMENT (container, tank or logs) that a returning helicopter sets down — tanks and logs finally appear, where the old product-render could only show container-type cargo.
- A returning helicopter always leaves its attachment in the yard and stores/leaves empty, so the same attachment is never shown both on the helicopter and in the yard.
- Attachment visuals never touch real cargo; the game's Truck.Cargo is unchanged.

## 0.6.2

- Idle helicopters are now distributed across ALL heliports by a distance + load score (nearest, least-loaded, free pad), instead of every idle helicopter piling onto whichever port happened to tick first.
- Holding points now form a validated fan on the open sides of the complex (never through the hangar or tower), each checked against the building occupancy map and kept apart from other ports' holding points.
- A helicopter now flies to its holding point and only then joins the landing queue, so a distant helicopter no longer reserves the pad before it has arrived.
- Recall timing no longer speeds up as you build more heliports.

## 0.6.1

- Fixed slow storage landing: a recalled helicopter now descends to a firm deck target and touches down only when centred over the pad (not hanging above it). Storage descent uses a faster, storage-only speed.
- The removed the blind per-approach re-issue of the landing command that was restarting the descent; added a one-shot stuck-recovery with a diagnostic log and approach-time logging.
- Fixed the next-load silhouette: a helicopter heading to a liquid pickup now shows the tank (not a container). The next attachment type is applied as soon as the pickup job is assigned; an unknown next type keeps the current attachment instead of defaulting to a container.
- Made the pickup-job hook type-safe (no reflection / no swallowed errors).

## 0.6.0

- Heliport now brings idle helicopters home into a real airborne holding queue (distinct ring points) instead of stacking them.
- A single pad/door is served one helicopter at a time (FIFO), with stored helicopters that get a job taking priority to leave.
- Faster storage landings: the authorised pad helicopter descends during its final approach.
- Helicopters carrying a container set it down in the hangar's cosmetic cargo yard (20-slot 5x2x2 grid) before parking; the real cargo is never altered.
- Stored helicopters are hidden (virtual storage of 20) while the model, its selection collider and the sim entity stay intact and clickable.
- Hangar roll-door now moves the single authored door (no runtime split/scale); strict open-before-drive handshake, never clips through a closed door.
- Fixed the heliport collider warning and the helicopter becoming unclickable (asset bundles were silently stripped of colliders/particles - Unity physics/particle modules re-added and bundles force-rebuilt).
- Fixed duplicate prototype registration ("equal IDs") and the sling re-render AmbiguousMatch error.

## 0.5.3

- Helicopters no longer reserve the exclusive ground-vehicle queue at cargo buildings.
- Multiple helicopters can now load, unload and refuel at the same building simultaneously.
- Regular trucks and every non-helicopter vehicle continue to use the vanilla queue unchanged.
- Wider per-aircraft altitude lanes remain active during transfer to reduce rotor/model overlap.
- Existing queued jobs remain save-safe and finish once; newly dispatched jobs use parallel service.

## 0.5.2

- Fixed wood cargo using the generic container instead of the log sling (`Product_Wood` ID handling).
- Cleared all vehicle-id keyed landing, cargo-ground and next-load state on save changes and despawn.
- Removed temporary per-helicopter cargo/display diagnostic log spam.
- Avoided a misleading `HasTrueJob` warning during the renderer/job-queue initialization edge.
- Added safe high-speed terrain waypoint handling for helicopter routes.
- Added a compatibility fix for the truck light controller's material lookup on the helicopter prefab.
- Added idle return to the nearest vehicle depot.
- Synchronized manifest, assembly and file versions.
- Made builds/deployments include ParticleSystemModule, all three icons and every AssetBundle.
- Added a reproducible release script and validated package layout.

## 0.5.1

- Idle helicopters only land on dry, open and unoccupied ground.
- Helicopters over water or buildings remain at a safe hover altitude.
- Added job hysteresis to stop idle landing/takeoff oscillation.
- Empty idle helicopters reel the sling tight against the hull.
- Idle hovering uses the vanilla parked-vehicle fuel behavior.

## 0.2.0

Big update, focused on **how it flies** and **how it looks**. Huge thanks to everyone testing — and especially **@Vladovlak**, whose screenshots and notes drove most of this. 🙌

## Replying to your points, Vladovlak:
- 🌀 **Rotor** — you were right, it was basically a war machine. It's now **6 blades at ~half the diameter**, and spins correctly.
- 🌊 **"Turning into a submarine"** — fixed. Over deep water it no longer sinks below the surface; it flies **above the water** now.
- 🍿 **"Jumping over the bridge like popcorn"** — this was the big one, and the altitude is **completely reworked**. The heli now looks at the **highest point along its route ahead**, climbs to it **gradually while flying** (no more last-second leaps), holds a **steady height** over the mountains/stacks on the way, and **descends smoothly** as it nears the destination. Ascending/descending is gentle now, not a rocket. 🚁

## Full changelog
- ✈️ **Flight altitude fully rewritten** — smooth, route-aware; no more popcorn/jumping over mountains, cliffs, bridges or tall buildings
- 🌊 Flies **above water** instead of submerging
- 🏭 Climbs **over tall buildings / smokestacks** instead of clipping through them
- 🌀 New rotor: 6 blades, correct size
- 📦 Slung cargo is now **frame-locked** to the heli — the load stopped jittering under it
- 🖱️ You can now **click the helicopter itself** to select it (added a proper hitbox)
- ⏸️ On **pause** it freezes correctly now (no drifting, rotor stops)
- 🎨 **De-militarized** (weapons removed) + new civilian paint
- 🖼️ Custom **icon** in the vehicle factory
- ⚡ **Faster** and a **higher** cruise altitude
- 🔕 Hides the false *"building can't be reached by vehicles"* warning while a heli is around

Still a **test build** — please keep the feedback coming, it genuinely shapes the mod. If anything still looks off (altitude, cargo, the model), drop a screenshot and I'll fix it. Thanks again! 🚁
