qvm: impact only contact events
Browse files- docs/ASSET_PIPELINE_TODO.md +3 -0
- docs/FINDINGS.md +3 -0
- docs/PROVISIONAL_TODO.md +3 -0
- docs/RESEARCH_LEDGER.md +5 -0
- docs/REVERSE_ENGINEERING_TODO.md +3 -0
- docs/research/QVM_CONTACT_IMPACT.md +7 -0
- docs/research/README.md +3 -0
- docs/research/qvm-contact-impact.json +0 -0
- scripts/analyze_qvm_contact_impact.py +14 -0
- scripts/test_qvm_contact_impact.py +25 -0
docs/ASSET_PIPELINE_TODO.md
CHANGED
|
@@ -823,3 +823,6 @@ Research progress: RE-718 [report](research/QVM_CONTACT_EVENT_VALUE.md); remaini
|
|
| 823 |
|
| 824 |
|
| 825 |
Research progress: RE-719 [report](research/QVM_CONTACT_FEEDBACK.md); remaining native/content/runtime/platform scope stays open.
|
|
|
|
|
|
|
|
|
|
|
|
| 823 |
|
| 824 |
|
| 825 |
Research progress: RE-719 [report](research/QVM_CONTACT_FEEDBACK.md); remaining native/content/runtime/platform scope stays open.
|
| 826 |
+
|
| 827 |
+
|
| 828 |
+
Research progress: RE-720 [report](research/QVM_CONTACT_IMPACT.md); remaining native/content/runtime/platform scope stays open.
|
docs/FINDINGS.md
CHANGED
|
@@ -1169,3 +1169,6 @@ RE-703–712 batch complete: [damage factor and contact dispatch](research/QVM_D
|
|
| 1169 |
|
| 1170 |
|
| 1171 |
**RE-719 — Contact event vector and actual feedback ledger:** Contact event104 receives truncated global forward×500 or exact muzzle for weapon27; positive encoded feedback calls actual285142, which requires enabled mode, attacker client and target ID0–64. [Evidence](research/QVM_CONTACT_FEEDBACK.md).
|
|
|
|
|
|
|
|
|
|
|
|
| 1169 |
|
| 1170 |
|
| 1171 |
**RE-719 — Contact event vector and actual feedback ledger:** Contact event104 receives truncated global forward×500 or exact muzzle for weapon27; positive encoded feedback calls actual285142, which requires enabled mode, attacker client and target ID0–64. [Evidence](research/QVM_CONTACT_FEEDBACK.md).
|
| 1172 |
+
|
| 1173 |
+
|
| 1174 |
+
**RE-720 — Complete impact-only contact branch:** Impact-only contacts return0 and emit event109 for weapon30 or63 otherwise only with nonzero flag and clear trace surface bit32; weapon27 copies exact muzzle. [Evidence](research/QVM_CONTACT_IMPACT.md).
|
docs/PROVISIONAL_TODO.md
CHANGED
|
@@ -1158,3 +1158,6 @@ Research progress: RE-718 [report](research/QVM_CONTACT_EVENT_VALUE.md); remaini
|
|
| 1158 |
|
| 1159 |
|
| 1160 |
Research progress: RE-719 [report](research/QVM_CONTACT_FEEDBACK.md); remaining native/content/runtime/platform scope stays open.
|
|
|
|
|
|
|
|
|
|
|
|
| 1158 |
|
| 1159 |
|
| 1160 |
Research progress: RE-719 [report](research/QVM_CONTACT_FEEDBACK.md); remaining native/content/runtime/platform scope stays open.
|
| 1161 |
+
|
| 1162 |
+
|
| 1163 |
+
Research progress: RE-720 [report](research/QVM_CONTACT_IMPACT.md); remaining native/content/runtime/platform scope stays open.
|
docs/RESEARCH_LEDGER.md
CHANGED
|
@@ -1235,3 +1235,8 @@ Event204 truncates ordinary scalar or weapon4 accumulator×100 with upper cap100
|
|
| 1235 |
## 2026-10-21 — RE-719 Contact event vector and actual feedback ledger (separate task commit)
|
| 1236 |
|
| 1237 |
Contact event104 receives truncated global forward×500 or exact muzzle for weapon27; positive encoded feedback calls actual285142, which requires enabled mode, attacker client and target ID0–64. 80 mode/team/client/ID/value fixtures verify vector words, request gates and actual sum/time ledger writes, including inclusive ID64. Full suite: 1324 tests pass. Report regenerates byte-identically (523925 bytes). Storage/filter, links and whitespace checks pass. No assets/Rust runtime/shared VM evaluator changed; native/reference/legal/full platform scope remains open.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1235 |
## 2026-10-21 — RE-719 Contact event vector and actual feedback ledger (separate task commit)
|
| 1236 |
|
| 1237 |
Contact event104 receives truncated global forward×500 or exact muzzle for weapon27; positive encoded feedback calls actual285142, which requires enabled mode, attacker client and target ID0–64. 80 mode/team/client/ID/value fixtures verify vector words, request gates and actual sum/time ledger writes, including inclusive ID64. Full suite: 1324 tests pass. Report regenerates byte-identically (523925 bytes). Storage/filter, links and whitespace checks pass. No assets/Rust runtime/shared VM evaluator changed; native/reference/legal/full platform scope remains open.
|
| 1238 |
+
|
| 1239 |
+
|
| 1240 |
+
## 2026-10-21 — RE-720 Complete impact-only contact branch (separate task commit)
|
| 1241 |
+
|
| 1242 |
+
Impact-only contacts return0 and emit event109 for weapon30 or63 otherwise only with nonzero flag and clear trace surface bit32; weapon27 copies exact muzzle. 48 weapon/flag/surface/normal combinations check every event word, actual child order, early suppression and numeric return. Full suite: 1328 tests pass. Report regenerates byte-identically (490508 bytes). Storage/filter, links and whitespace checks pass. No assets/Rust runtime/shared VM evaluator changed; native/reference/legal/full platform scope remains open.
|
docs/REVERSE_ENGINEERING_TODO.md
CHANGED
|
@@ -1201,3 +1201,6 @@ Purpose: turn the supplied installation into an evidence-backed specification of
|
|
| 1201 |
|
| 1202 |
|
| 1203 |
- [x] RE-719 Contact event vector and actual feedback ledger ([report](research/QVM_CONTACT_FEEDBACK.md)).
|
|
|
|
|
|
|
|
|
|
|
|
| 1201 |
|
| 1202 |
|
| 1203 |
- [x] RE-719 Contact event vector and actual feedback ledger ([report](research/QVM_CONTACT_FEEDBACK.md)).
|
| 1204 |
+
|
| 1205 |
+
|
| 1206 |
+
- [x] RE-720 Complete impact-only contact branch ([report](research/QVM_CONTACT_IMPACT.md)).
|
docs/research/QVM_CONTACT_IMPACT.md
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Complete impact-only contact branch
|
| 2 |
+
|
| 3 |
+
RE-720. Reproduce with `python3 scripts/analyze_qvm_contact_impact.py`; check with `python3 scripts/test_qvm_contact_impact.py`. The [machine report](qvm-contact-impact.json) retains source identity and bounded fixtures.
|
| 4 |
+
|
| 5 |
+
Actual293630–293729 handles the nondamageable/nonspecial contact branch. Caller flag148 must be nonzero and trace48 bit32 clear. The branch constructs event109 for weapon30, event63 otherwise, using actual277695/278138 with supplied allocation/native link boundary. Actual60317 encodes trace24 normal to event184. Event192 stores weapon,88 stores trace44,140 stores attacker ID and204 stores1. Weapon27 copies exact global muzzle bytes to104. Every path returns numeric0; damage factor, feedback and211239 are not invoked. Independent constructor/codec/payload expectations verify the complete880-byte record.
|
| 6 |
+
|
| 7 |
+
No original executable/full QVM/native collision/physics/rendering executes. Native responses and legal input domains are supplied or unverified where stated; full runtime/macOS/Linux Rust/Bevy/Solari gameplay remains open.
|
docs/research/README.md
CHANGED
|
@@ -759,3 +759,6 @@ The extension collector adds five focused tests for native tail calls, command-r
|
|
| 759 |
|
| 760 |
|
| 761 |
[RE-719: Contact event vector and actual feedback ledger](QVM_CONTACT_FEEDBACK.md). Reproduce with `python3 scripts/analyze_qvm_contact_feedback.py`; check with `python3 scripts/test_qvm_contact_feedback.py`.
|
|
|
|
|
|
|
|
|
|
|
|
| 759 |
|
| 760 |
|
| 761 |
[RE-719: Contact event vector and actual feedback ledger](QVM_CONTACT_FEEDBACK.md). Reproduce with `python3 scripts/analyze_qvm_contact_feedback.py`; check with `python3 scripts/test_qvm_contact_feedback.py`.
|
| 762 |
+
|
| 763 |
+
|
| 764 |
+
[RE-720: Complete impact-only contact branch](QVM_CONTACT_IMPACT.md). Reproduce with `python3 scripts/analyze_qvm_contact_impact.py`; check with `python3 scripts/test_qvm_contact_impact.py`.
|
docs/research/qvm-contact-impact.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
scripts/analyze_qvm_contact_impact.py
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
"""Complete impact-only contact branch with actual event constructor and codec."""
|
| 3 |
+
import itertools
|
| 4 |
+
from pathlib import Path
|
| 5 |
+
from qvm_research_support import source
|
| 6 |
+
from qvm_contact_support import seed,run
|
| 7 |
+
from analyze_qvm import write_json
|
| 8 |
+
|
| 9 |
+
def main():
|
| 10 |
+
q,raw,h,ins=source();rows=[]
|
| 11 |
+
for w,flag,surface_flags,normal in itertools.product([3,27,30],[0,1],[0,1,32,33],[(0,0,0),(0,0,1)]):
|
| 12 |
+
a=dict(weapon=w,flag=flag,surface_flags=surface_flags,normal=normal);_,p=run(ins,seed(raw,h,**a),293630,293730,include_event=True);p['input']=a;rows.append(p)
|
| 13 |
+
write_json(Path('docs/research/qvm-contact-impact.json'),{'source':q['source'],'sha256':q['sha256'],'probes':rows,'limits':'Actual293630..293729 with actual277695/278138/60317; allocation supplied and native link captured. No health, geometry, damage-factor or feedback execution.'})
|
| 14 |
+
if __name__=='__main__':main()
|
scripts/test_qvm_contact_impact.py
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import json,unittest
|
| 2 |
+
from pathlib import Path
|
| 3 |
+
from test_qvm_temp_event import event_record
|
| 4 |
+
from test_qvm_direction_codec import best
|
| 5 |
+
from test_qvm_ground import word
|
| 6 |
+
class ContactImpactTests(unittest.TestCase):
|
| 7 |
+
@classmethod
|
| 8 |
+
def setUpClass(cls):cls.ps=json.loads(Path('docs/research/qvm-contact-impact.json').read_text())['probes'];cls.table=json.loads(Path('docs/research/qvm-direction-codec.json').read_text())['table']
|
| 9 |
+
def test_flag_and_surface_bit32_truth_table(self):
|
| 10 |
+
for p in self.ps:
|
| 11 |
+
a=p['input'];self.assertEqual(len(p['effects']['events']),int(bool(a['flag'] and not a['surface_flags']&32)))
|
| 12 |
+
def test_entire_record_independent_constructor_and_payload(self):
|
| 13 |
+
for p in self.ps:
|
| 14 |
+
a=p['input']
|
| 15 |
+
if not p['effects']['events']:self.assertTrue(all(v==0 for v in p['event_record'].values()));continue
|
| 16 |
+
e=p['effects']['events'][0];self.assertEqual(e['event'],109 if a['weapon']==30 else 63);r=event_record(e);r.update({'184':best(list(map(word,a['normal'])),self.table),'192':a['weapon'],'88':99,'140':7,'204':1})
|
| 17 |
+
if a['weapon']==27:
|
| 18 |
+
for j,v in enumerate(map(word,[1.25,-2.5,3.75])):r[str(104+4*j)]=v
|
| 19 |
+
self.assertEqual(p['event_record'],r)
|
| 20 |
+
def test_numeric_zero_return_and_no_damage_or_feedback(self):
|
| 21 |
+
self.assertEqual(len(self.ps),48)
|
| 22 |
+
for p in self.ps:self.assertEqual(p['execution']['return'],0);self.assertEqual(p['effects']['damage'],[]);self.assertEqual(p['effects']['feedback'],[])
|
| 23 |
+
def test_exact_actual_children_only_when_event_emitted(self):
|
| 24 |
+
for p in self.ps:self.assertEqual([c['target'] for c in p['execution']['calls']],[277695,60317] if p['effects']['events'] else [])
|
| 25 |
+
if __name__=='__main__':unittest.main()
|