Vetra
Every shot lands where physics says it should.
Vetra is an analytic-trajectory projectile simulation module for Roblox. Where most weapon systems move bullets by nudging position += velocity * dt each frame, drifting, tunnelling, disagreeing between client and server, Vetra uses the exact kinematic formula P(t) = Origin + V₀t + ½At². No drift. No frame-rate dependency. A shared ground truth.
Features
- Analytic trajectory, exact position at any time, independent of frame rate
- High-fidelity sub-segment raycasting, no bullet tunnels through thin geometry
- Pierce, multi-surface penetration with momentum modeling and exit-point detection
- Bounce, restitution, per-material coefficients, normal perturbation, corner-trap detection
- Drag, linear, quadratic, or G-series empirical models (G1, G5, G6, G7, G8, GL, Custom)
- Magnus effect, lateral force on spinning projectiles
- Gyroscopic drift, long-range directional yaw from spin precession
- 6DOF aerodynamics, lift, pitching moment, pitch/yaw damping, roll damping, gyroscopic precession
- Coriolis deflection, configurable per map, latitude-accurate with exaggeration scale
- Tumble, destabilisation on speed loss or pierce, chaotic drag multiplier
- Fragmentation, cone-distributed child bullets on pierce
- Hitscan, single-frame hit resolution that skips kinematics; full pierce, bounce, and signal support with no per-frame cost
- Homing, frame-by-frame steering with strength, duration, and acquisition radius
- Trajectory provider, replace kinematics with any custom position curve
- Supersonic / subsonic profiles, different drag, restitution, and scatter per speed regime
- LOD and spatial partitioning, HOT / WARM / COLD tiers, interest-point driven
- Parallel physics, distributes raycasts across Roblox Actors; ~flat 4–10ms up to 20,000 bullets
- VetraNet, full networking middleware: serialization, rate limiting, origin validation, trajectory reconstruction, cosmetic replication, drift correction, all over one
RemoteEvent - Typed builder,
BehaviorBuilderwith build-time validation and frozen output - MIT licensed
Installation
Get Vetra from the Roblox Creator Store:
Then drop the Vetra folder into ReplicatedStorage and require it from your weapon scripts.
local Vetra = require(game.ReplicatedStorage.Vetra)
Quick Start
local Vetra = require(ReplicatedStorage.Vetra)
local BulletContext = Vetra.BulletContext
local Solver = Vetra.new()
local Signals = Solver:GetSignals()
Signals.OnHit:Connect(function(context, result, velocity)
if result then
print("Hit", result.Instance.Name)
end
end)
local Behavior = Vetra.BehaviorBuilder.Sniper():Build()
local context = BulletContext.new({
Origin = muzzlePosition,
Direction = direction,
Speed = 900,
})
Solver:Fire(context, Behavior)
Performance
Parallel solver frame times measured on a live Roblox server, 120-frame samples:
| Active bullets | Serial | Parallel | Speedup |
|---|---|---|---|
| 50 | 10.3 ms | 4.2 ms | 2.5x |
| 200 | 14.0 ms | 4.2 ms | 3.4x |
| 1,000 | 45.2 ms | 4.2 ms | 10.8x |
| 5,000 | 174.7 ms | 5.5 ms | 32x |
| 20,000 | - | 10.3 ms | - |
The parallel solver's frame time is essentially flat from 25 to 2,000 bullets. See the Benchmarks page for full data across all four profiles.
Documentation
Full documentation at vel136.github.io/Vetra
- Getting Started
- Why Your Bullets Miss
- Making Bullets Feel Real
- Networking and Trust
- Performance
- Benchmarks
- FAQ
Community
License
MIT License, Copyright © 2026 VeDevelopment