RSBDOCS
Getting startedPlayer controller

Player with weapon

Connect the sample sniper rifle, effects and ammo UI.

Replace Player Without Weapon with SAMPLES/Prefabs/Player With Weapon.prefab, positioned at (0, 1, 0). Reassign its Main Camera to the system's Fire Transform and the scope's Main Camera.

Remove or disable TutorialShooter so both scripts do not fire or aim on the same input. Keep the separate hit listener if you still need it; remove duplicate listeners if using the configured system prefab.

Under the player's Main Camera, the Weapon object contains PlayerWeaponController and a MotionController. Complete the weapon's scene references:

ReferenceAssign
Bullet PropertiesThe cartridge asset used by this weapon.
Bullet Time BulletThe inactive scene instance of SAMPLES/Prefabs/Bullet Time - Bullet.prefab.
Shell PoolerA pool using Objects/Bullet/Bullet Shell.prefab.
Muzzle Flash PoolerA pool using Objects/Particles/Muzzle Flash.prefab.
Ammo TextAmmo Display Text from SAMPLES/Prefabs/CANVAS - Crosshair & Ammo.prefab.

Preserve the prefab's barrel/ejection transforms, animation, audio and motion references. PlayerWeaponController activates its bullet properties in Awake and handles cooldown, magazine state, reload, aiming, recoil, scope calls and effect spawning.

The sample is a bolt-action rifle example. For other weapons, adapt the logic and animation events to your weapon rather than only swapping the mesh. PlayerWeaponAnimationEvents forwards animation events to weapon actions such as shell ejection and sounds.

With desktop input, left mouse fires, right mouse aims, R reloads, B/V adjust zero distance while aiming, and left Shift holds breath while aiming. Public FireInput(), ReloadInput() and AimInput(bool) let other controls drive these actions.

Separate shell and muzzle-flash pools.
Original RSB manual capture. Follow the current instructions on this page for paths and setup. Click the image for full size.
The sample weapon controller with its scene references.
Original RSB manual capture. Follow the current instructions on this page for paths and setup. Click the image for full size.
The example sniper rifle and player in action.
Original RSB demo recording. Follow the current instructions on this page for setup. Click the image for full size.