aboutsummaryrefslogtreecommitdiff
path: root/crates/fparkan-runtime/src/player_weapon.rs
Commit message (Collapse)AuthorAgeFilesLines
* feat(game): cycle warbot cockpit control modesValentin Popov36 hours1-0/+6
|
* feat(ui): enable manual control from the bunker listValentin Popov2 days1-3/+11
| | | | | | Use the active Control camera record and its separate CPT origin and direction for the fixed turret. The original hand control opens the cockpit, its two weapon slots and aim tracks while leaving the operator at the command post. Verified from the stock Two Fortresses start against the GOG cockpit with Vulkan validation. The licensed tests cover the native camera pose, mounted weapon selection and stationary bunker and operator.
* feat(ui): show live weapon readings in the hero cockpitValentin Popov3 days1-5/+89
|
* feat(control): replenish ammunition on repair padsValentin Popov3 days1-6/+4
|
* feat(audio): announce exhausted weapon ammunitionValentin Popov4 days1-10/+46
|
* feat(audio): announce low cockpit weapon chargeValentin Popov4 days1-0/+32
|
* fix(audio): play flamer sound from the firing nodeValentin Popov4 days1-17/+65
| | | | Feed initial node-attached Op2 rows from the same Control blends as their firing nodes. Keep them separate from projectile one-shots and opcode 10 wind-up sounds. The original Effect.dll confirmed the strict 0.01 threshold. The Constructor replay ordered and boarded the stock warbot, played the heavy flamer before projectile release, and captured the hangar.
* fix(render): drive warbot muzzle flashes with firing phasesValentin Popov4 days1-11/+25
| | | | Use the first CPT node when the effect has no explicit override. Feed the autonomous weapon banks into the same phase sampling path as manual weapons. Confirm the effect constructor and phase reads in the original DLLs, and compare the two cannon flashes in a live AutoDemo window at the same clock sample.
* fix(gameplay): keep selected suit weapons deployedValentin Popov4 days1-8/+36
|
* fix(combat): let projectiles destroy mounted warbot partsValentin Popov4 days1-0/+12
| | | | Resolve mounted model triangles through the sampled socket chain and publish the damage to the assembled Control provider. Remove the damaged geometry, stop weapons whose provider was depleted, and preserve already separated ranges when the chassis later dies. Confirmed with a licensed AutoDemo ray query and two frames around a controlled hit in the Vulkan window.
* fix(combat): load CPT launch points for rocket racksValentin Popov4 days1-1/+20
| | | | | | | | | | Read the component's authored CPT when its weapon records reference firing rows. The stock medium and heavy racks have no muzzle flash row, but their 16 and 9 launch points belong to the weapon cycle. The licensed battery test verifies both rack layouts. A runtime replay from the stock Two Fortresses start records heavy rocket launches from the restored racks. All 29 stock missions reach 900 simulation seconds.
* fix(combat): accept weapon CPT points with distinct metadata wordsValentin Popov4 days1-2/+40
| | | | | | | | | | | | Control.dll caches the node from CPT offset +4 at RVA 0xb210 and uses that node for the point and direction at RVA 0x1b4f0. A native call with the medium cannon's words 3 and 2 selected node 3. Rejecting those different words disabled the authored bb_m_02 cannon. The licensed regression finds the cannon in the stock medium warbot. Both enemy medium warbots fire in the normal-start input replay of Two Fortresses. The 29 stock missions still reach 900 simulated seconds. Rocket racks without resolved CPT lists remain outside the weapon bank.
* fix(gameplay): fire hero projectiles along the posed muzzleValentin Popov8 days1-7/+21
| | | | Use the CPT direction after the current node, component mount, and body transforms. Validate the raised barrel axis with the original Constructor resources.
* fix(gameplay): deploy the hero's weapons before firingValentin Popov8 days1-32/+124
| | | | Sample the CTL 24 mount tracks before the firing track advances. Preserve a single click through deployment and wait for recoil before stowing. Verified from the stock Constructor start with Vulkan validation.
* fix(render): drive manual firing flashes from linked barrel nodesValentin Popov8 days1-15/+112
| | | | | | Use the current authored barrel blend as Effect mode 4 input when Control links the effect to that node. Leave projectile release and direct shot audio on their existing clocks. Verified the bound node and phase flags against GOG AniMesh and Effect, covered the stock Constructor cannon, and compared the flash at two phases in a validation-clean mission window.
* fix(combat): show muzzle flashes for manual fireValentin Popov8 days1-3/+24
| | | | Send the player's linked Control row through the existing firing flash sampler. On the stock Constructor start, the 25 mm cannon emits the authored sprite and a light at the muzzle from an external camera. Full node-driven mode-4 phase remains open.
* fix(audio): start node-attached laser sounds during wind-upValentin Popov8 days1-1/+48
| | | | | | | | | | | Use the weapon descriptor's Control group to select the mode-1 sound rows. Update them through the existing FX clock and spatial Op2 playback for both manual and autonomous weapons. The GOG Control/Effect entry points confirm the selector, epoch and phase threshold, including retriggering after a sample at the exact phase peak. The stock Two Fortresses helicopter started the original sound at both weapon nodes in a Vulkan window.
* fix(combat): use authored range for autonomous weaponsValentin Popov9 days1-3/+6
|
* feat(render): animate player weapon tracks during firingValentin Popov9 days1-0/+60
| | | | Sample the authored barrel tracks on the existing weapon clock before resolving the muzzle. Check Control phase interpolation against the original DLL and verify plasma rifle travel in a fixed-camera capture on the stock firing range.
* feat(combat): enable the authored weapons of hostile animalsValentin Popov9 days1-1/+2
| | | | The armed Constructor creatures use the shared enemy search and fire their CTL weapon from Gun_Y. The stock start is outside range. The close encounter fixture shows the projectile in the Vulkan window and leaves the hero at 30 percent after one hit.
* feat(audio): drive chassis engine loops from actual movementValentin Popov9 days1-2/+3
| | | | Prepare the authored root-node CTL attachments and feed Control speed limits plus observed motion into FX modes 5 and 15. The stock AutoDemo window queues ground and flight engine loops from the starting scene.
* feat(combat): activate mounted flash effects on autonomous shotsValentin Popov9 days1-14/+19
| | | | | | Carry the prepared effect row with each shot. Use the existing mode 4 visual effect for that component at release, with its authored geometry, lights and CPT placement. Keep the one-shot sound on its existing event path. Verified stock AutoDemo shot frames submit the authored muzzle light with Vulkan validation clean. A matched on-screen comparison and the full flash curve remain open.
* feat(combat): play spatial sounds for autonomous weapon shotsValentin Popov9 days1-20/+46
| | | | | | Carry the firing effect and muzzle position on the shot event. Resolve single-gun effects by their matching muzzle point when there is no node link. Play each one-shot as its simulation frame arrives. Verified a stock gun sound enqueues a spatial voice with the flight starting position. AutoDemo ran with Vulkan validation clean and no playback errors. Comparison by ear with the original remains open.
* feat(combat): feed weapon charge from Control energy budgetsValentin Popov9 days1-3/+55
| | | | | | | | | | | | | | | | | | | | | | | | | Keep factory-2/30 charge in the owner's Control table. AI and player banks read it before firing, debit completed shots and wait for regeneration. Preserve one charge across bank changes and accumulate energy waits by object, including an idle bank publishing after an active bank. Mobile owners now run the resource budget. Restore the shared factory-1 callbacks, factory-2/30 charging and factory-10 passive upkeep. Factory 30 uses the weapon constructor's native disabled default. Motion demand is still an explicit zero-rate stub; unsupported budgets disable charge limiting for that owner and record the reason. Execute unmodified GOG Control.dll callbacks at RVA 0x29a40/0x29a90, 0x264b0/0x26510 and 0x21860/0x21890; check the common constructor at 0x294c0. Rust golden vectors cover disabled refill, zero capacity, negative charge and x87 rounding at control word 0x007f. SHA-256: bcb86318089028548a178b03a21accdce15df0cc85ddd91674cf3c2f55012c6e. Validated fmt, workspace check/tests, release, licensed shared-bank charge exhaustion/recovery, stock combat and damaged-profile regressions. All 29 stock missions reached 900 seconds; the only mobile-budget stub was the known motion input. Observed stock window combat and replenishment. Full live native mission comparison and motion energy remain open.
* fix(combat): launch AI projectiles from mounted weapon CPTsValentin Popov9 days1-1/+10
| | | | | | | | | | | | | | | | | | Resolve weapon node poses and EXTO socket chains on the CPU, replace each mounted component root with its socket, and transform the selected CPT into the world. Test terrain sight lines from each barrel rather than the hull. Share initial Control pose sampling with the window renderer. Count missing mounts and animation fallbacks by original object ID without losing history when an object dies. Checked Control.dll RVA 0x1b4f0 by native invocation, including nonuniform scale and a rotated world matrix. cargo fmt/check/test workspace pass, as do licensed stock AutoDemo and scripted patrol/factory regressions. All 29 stock missions reach --sim-report 900 with no script interruption or weapon pose fallback. Both games were observed in stock AutoDemo windows. AI turret aim, recoil and first-shot chronology remain approximate; this change does not establish full G7 or G8 gameplay parity.
* feat(runtime): fire from boarded warbotsValentin Popov2026-11-141-5/+32
|
* feat(runtime): replenish AutoDemo clans after combat lossesValentin Popov2026-11-141-2/+4
|
* feat(runtime): engage hostile robots in AutoDemoValentin Popov2026-11-141-0/+11
|
* fix(game): schedule player fire from authored weapon phasesValentin Popov2026-11-141-72/+158
|
* fix(game): stop firing when weapon ammunition runs outValentin Popov2026-11-141-4/+29
|
* feat(game): render player projectiles in flightValentin Popov2026-11-141-0/+7
|
* feat(game): play authored sounds on manual fireValentin Popov2026-11-141-0/+196