Skip to main content

Where to Go From Here

Vetra has a lot of surface area. This page is a map.


"I just want to fire bullets."

Start at Getting Started. You need three things: a solver, a behavior, and a context. The intro page covers all of them in order and gets you to a working gun in under 20 lines.


"My bullets are tunnelling through walls."

That's not a bug in your code, it's a mathematical property of how most projectile systems work. Why Your Bullets Miss explains exactly what's happening and how Vetra's analytic trajectory and high-fidelity sub-segment raycasting solve it.


"I want drag, spin drift, or realistic ballistics."

Making Bullets Feel Real goes through every physics feature, drag models, Magnus effect, gyroscopic drift, tumble, fragmentation, Coriolis, with practical guidance on when each one is worth using and what values to start with.

The quick reference for every field lives in TypeDefinitions under VetraBehavior.


"I want full 6DOF aerodynamics, lift, pitching moment, gyroscopic precession."

Enable SixDOFBuilder via :SixDOF():Enabled(true). At minimum you need BulletMass, ReferenceArea, ReferenceLength, and MomentOfInertia set. Everything else defaults to physically neutral values you can layer on incrementally.

The 6DOF FAQ in the FAQ covers common setup mistakes, unit questions, and tuning guidance. The field reference is in SixDOFBuilder.


"I need multiplayer, server authority, cosmetics, hit validation."

Networking and Trust explains the architecture: why trusting the client is dangerous, how VetraNet's trajectory reconstruction works, and what each rejection reason means.

The API reference for setup and signals is VetraNet and BehaviorRegistry.


"I need to handle hundreds or thousands of bullets."

Performance covers LOD, spatial partitioning, OnTravelBatch vs OnTravel, and when the parallel solver is actually worth using.

The Benchmarks page has the raw numbers, serial vs parallel across four profiles and 13 bullet counts, and instructions for running the benchmarker against your own weapon behaviors.


"I need to customise physics mid-flight."

VetraCast, the object returned by Solver:Fire(), exposes SetVelocity, SetAcceleration, SetPosition, Pause, Resume, and state reset methods. Use these from signal handlers to override physics on a live bullet.

For mutating a bounce or pierce as it resolves (before the math finalises), see the hook signals OnPreBounce, OnMidBounce, OnPrePierce, and OnMidPierce in the Vetra signals table.


"I want to build behaviors with typed setters and validation."

BehaviorBuilder is the fluent builder, chain :Physics(), :Bounce(), :Pierce(), :Drag(), :Magnus(), :Homing(), and so on, then call :Build() to get a validated frozen table. Every VetraBehavior field is covered by a typed setter.

The individual sub-builders are documented in SubBuilders: PhysicsBuilder, HomingBuilder, PierceBuilder, BounceBuilder, HighFidelityBuilder, CornerTrapBuilder, CosmeticBuilder, DebugBuilder, DragBuilder, WindBuilder, MagnusBuilder, GyroDriftBuilder, TumbleBuilder, FragmentationBuilder, SpeedProfilesBuilder, SixDOFBuilder, TrajectoryBuilder, LODBuilder.

DragModel enum

Use BehaviorBuilder.DragModel.G7 instead of the raw string "G7". Typos on raw strings pass the type checker silently and only fail at :Build(). BehaviorBuilder.DragModel is a direct re-export of Vetra.Enums.DragModel, they are the same table.

"I need to compare against a termination reason or drag model."

Enums documents every named constant table exposed on Vetra.Enums. Use Vetra.Enums.TerminateReason.Hit instead of the raw string "hit" in OnPreTermination handlers, if a value is ever renamed, every reference site produces a nil rather than silently passing the wrong value.

Signals.OnPreTermination:Connect(function(context, reason, mutate)
if reason == Vetra.Enums.TerminateReason.Hit then
mutate(true, nil) -- cancel termination
end
end)

"I need to track a live bullet's state."

BulletContext is the object you create before firing and receive in every signal handler. It exposes position, velocity, path length, lifetime, and UserData.


Quick Reference

I want to…Go to
Fire a bulletGetting Started
Understand why bullets tunnelWhy Your Bullets Miss
Add drag, spin, tumble, CoriolisMaking Bullets Feel Real
Set up multiplayer hit validationNetworking and Trust
Scale to hundreds of bulletsPerformance
See benchmark numbersBenchmarks
Look up every behavior fieldTypeDefinitions
Configure the solverVetra
Read or modify a live bulletVetraCast
Access bullet state in signalsBulletContext
Build behaviors with typed settersBehaviorBuilder
Configure 6DOF aerodynamicsSixDOFBuilder
Look up enum valuesEnums
Set up VetraNet networkingVetraNet