254c7dc997
- Gun harness: virtual bullet tracker, rolling fitness, auto-selector - Guns: head-on, linear (extrapolation), circular (integrated formula), tsetlin machine (learning) - Movement: phantom meteor gravity engine (danger histograms, phantom bullets, fire detection) - Radar: harness + radar_lock adapter - Color-coded modules: turret/bullet color per gun, body per movement, scan per radar - Beats Target, SpinBot, Crazy, TrackFire in 10-round battles
16 lines
443 B
Nim
16 lines
443 B
Nim
## Radar harness — shared RadarModule concept.
|
|
## Coordinate system: 0° = East, CCW positive (Tank Royale standard).
|
|
|
|
import ../gun_harness/gun_interface
|
|
|
|
export gun_interface # re-export WorldState
|
|
|
|
## Radar concept — any type T implementing computeScan is a valid radar module.
|
|
template isRadarModule*(T: typedesc): bool =
|
|
compiles(
|
|
block:
|
|
var r: T
|
|
let ws = WorldState()
|
|
let rate: float = r.computeScan(ws)
|
|
)
|