46
Suggestions / Re: Realistic gun movement
« on: 29-03-2011, 05:03:42 »
BF2142 has this code in several handweapons
the code may also somehow be linked to some sort of animation,not sure
it definately works in BF2142 regarding the projectile moving in sync with the weapon,and with an unlock allows the shift key to stabilize it for a short period of time
unfortunately this code doesnt work in BF2
Quote
rem ---BeginComp:DefaultGunSwayComp ---
ObjectTemplate.createComponent DefaultGunSwayComp
ObjectTemplate.sway.gunSwayUseZoom 1
ObjectTemplate.sway.gunSwayPitchSteps 40
ObjectTemplate.sway.gunSwayPitchFactor 3
ObjectTemplate.sway.gunSwayPitchMax 7
ObjectTemplate.sway.gunSwayPitchUpdateRate 0
ObjectTemplate.sway.gunSwayPitchSmoothFactor 0.005
ObjectTemplate.sway.gunSwayPitchSmoothMax .5
ObjectTemplate.sway.gunSwayPitchSmoothThreshold 2.4
ObjectTemplate.sway.stabilityRecoverTime 1
ObjectTemplate.sway.stabilityTime 1
ObjectTemplate.sway.stabilityDuration 1.4
ObjectTemplate.sway.stabilityDurationRecoverTime 4
rem ---EndComp ---
the code may also somehow be linked to some sort of animation,not sure
it definately works in BF2142 regarding the projectile moving in sync with the weapon,and with an unlock allows the shift key to stabilize it for a short period of time
unfortunately this code doesnt work in BF2