Repository navigation
Partial reloads 24: Model the Supa-7 tube and chamber - #2309
Closed
sunzenshen wants to merge 1 commit into
Closed
sunzenshen wants to merge 1 commit into
sunzenshen wants to merge 1 commit into
Conversation
With sv_neo_reload_experimental, the Supa-7 holds six rounds in a tube and one in the chamber, seven in all as before. The tube and the chamber are networked and predicted, and the HUD shows the tube count and the chambered round through the chamber queries of the phase code. Reload input, the shell cadence, slugs and early fire stay as they were; a held alt-fire queues one slug at a time. Each round enters the tube at the reloadinsert frame where the hatch closes behind it, so a switch or a shot before then leaves it in the reserve. A slug loaded on a live shell goes into the tube. With no live round chambered, the gun plays the reloadend rack before it can fire, and the round is fed when the pump is home. A switch or a drop cancels a rack or an insert that has not reached that point. The tube logic sits in TubePhasesOn* hooks, so master's reload, fire, drop and frame functions gain one-line calls. Each hook checks the flag itself: with the cvar at 0 the weapon behaves as before. The pump after the first shell moves onto the tube: the shot that empties the tube leaves the hull chambered, the step after the first insert racks it with reloadpump (the pump's home frame feeds the chamber from the tube), and a shot or the trigger rack waits while that feed is pending.
sunzenshen
force-pushed
the
stack/reload-zr68c/170-flag-off
branch
from
November 10, 2026 02:11
5582e1f to
94fae98
Compare
sunzenshen
force-pushed
the
stack/reload-zr68c/180-supa7
branch
from
November 10, 2026 02:11
4ea1cac to
4bbc0a5
Compare
sunzenshen
force-pushed
the
stack/reload-zr68c/180-supa7
branch
from
November 10, 2026 03:37
4bbc0a5 to
f1a2ab9
Compare
sunzenshen
changed the base branch from
stack/reload-zr68c/170-flag-off
to
stack/reload-zr68c/175-supa7-pump
November 10, 2026 03:37
This was referenced Nov 10, 2026
This was referenced Nov 13, 2026
Closed
Closed
Closed
Contributor
Author
|
Closing to clear the board in favor of the PR stack of sunzenshen#34 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Partial reloads 24: the Supa-7 tube reload. This PR builds on layer 23 (#2312, the pump after the first shell).
It has no neoAssets pair: the Supa-7 plays its shipped clips and the
reloadpumpof layer 23(NeotokyoRebuild/neoAssets#197).
With
sv_neo_reload_experimental 1, the Supa-7 holds six rounds in a tube and one in the chamber, seven in all as onmaster. The tube and the chamber are networked and predicted. The HUD shows the rounds through the chamber queries of
the phase code (#2293, made
virtualin #2301).reloadinsertframe where the hatch closes behind it. A switch, adrop or a shot before that frame leaves the shell in the reserve; a switch after it keeps the shell.
first insert with layer 23's
reloadpump; the round is fed when the pump is home, and a shot waits for it. Thereload then fills the tube and ends with
reloadendshort, so a dry reload ends at 7 (6 + 1). A slug loaded asthat first round ends the reload with the shipped
reloadendrack instead.reloadendrack on the trigger. A switch or a drop cancels a rack that has not fed its round.
reloadpumpin the viewmodel, the last shot pumps as on master and a dry reload fills the tube, thenracks with
reloadend: it ends at 6 (5 + 1).slug at a time.
TubePhasesOn*hooks; each checks the flag itself. With the flag at 0 (thedefault since Partial reloads 22: Disable experimental reloads by default #2308) the Supa-7 behaves as on master.
How to review
weapon_supa7.h: the chamber query overrides, the tube state (m_nTubeCount,m_nTubeSlugs,m_nChamber,m_nInsertand the two times) and the hook list.weapon_supa7.cpp: master's functions gain one-line hook calls; the hooks and the tube helpers follow.Layer 23's checks now read the tube:
UsesPumpAfterInsert(flag and model),IsLastShotWithoutPump(tubeempty), and
TubePhasesOnNextInsertstarts the pump;IsRackPendingholds a shot until the feed.How to test
sv_neo_reload_experimental 1and load a map. Take the Supa-7.sv_neo_reload_experimental 0(set before the map loads): master behavior.Results
Layer 24 build (this PR on layer 23 + neoAssets layer 23), Linux Debug,
ntre_engage_ctg, owner Supa-7 plus abot_mimicbot of the same class (Assault) with the same gun. Times are from the reload press, from the owner's statesamples.
fire2without the pump, hull stays;reloadstart, insert 1,reloadpumpat +0.885 s chambers it (+1.455 s), the tube fills: 7 (6 + 1) at +4.71 s,reloadendshort, idle +5.22 saltfirewith its pump; 7 at +3.95 s,reloadendrack, idle +4.97 sfire1with no pump; the reload pumps after its first shell and refillsreloadendrack chambers it; reload then fills with shells to 7reloadendrack; reload then loads onreloadstart, thenreloadpumpat once, then the inserts to 7match_end=True, 0 asserts, 0 crashes (Supa-7 use by the bots not confirmed)The dry, switch and flag-0 cases give the same owner states as the same sequences with layer 25 on top. Cases this
layer shares with its previous base and that layer 23 does not touch (tactical reload from 4, a switch after the first
shell, a slug behind a live shell, held alt-fire) were measured before layer 23 went in below this PR and are not
repeated here.
Toolchain
Linked Issues