Changing the viewmodel bob

From Valve Developer Community
Jump to navigation Jump to search

Stub

This article or section is a stub. You can help by expanding it.

Viewmodel bob is the "movement" of your weapon whenever the player walks, runs, or moves. It's not hard to change it and all it requires is changing some values in one file.


basehlcombatweapon_shared.cpp

Go to this file and scroll down until you find "AddViewModelBob". You should see values for LaternalBob, Vertical bob, and "Z bob". Change those to whatever and compile, your weapon should have different viewmodel bob.


To do: add an example.