SSM/CSM Soldier Sprint code

Lots of cool and useful tips to mod either serverside or clientside

SSM/CSM Soldier Sprint code

Postby LightSpeed/// » Wed Oct 21, 2009 2:02 am

Note: This was written by PLAYER, this was a great discovery so I am transferring it here so it is always within reach (also slightly edited by me)

I just wanted to share this here.. as it may apply to the retail versions as well.

There are a number of other mods that can be done altering the animations.
Including changing the speed of swimming , climbing , walking , running , jumping. These changes are suprisingly SSM.

Some things can easily be changed using the AnimationStateMachine.SetActiveState

Code: Select all
.setSpeed <Forward&Back> <turn> <strafe>


Extract Animations.rfa

Review the con and inc files.

Sprint

This will change the [SHIFT] walk key to be a Run or Sprint Key

Code: Select all
rem Solider Sprint

AnimationStateMachine.SetActiveState Lb_WalkForward
AnimationStateMachine.setSpeed 10 0.5 10

AnimationStateMachine.SetActiveState Lb_WalkBackward
AnimationStateMachine.setSpeed 10 0.5 10

rem Solider Sprint


=====================================================================

CSM only

The following improves the 3rd Person Animations for the increase speed. These changes can not be seen by the remote client. Only for the host of "NON Dedicated" servers, which is still good for those who make videos.

Code: Select all
rem 3RD Person Animation Tweak

AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardThompson 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardK98 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardK98Sniper 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardNo4Sniper 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardPanzershreck 0.30
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardWalterP38 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardSg44 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardBazooka 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardExpPack 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardDetonator 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardMedPack 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardLandmine 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardRepairPack 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardColt 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardNo4 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardBar1918 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardGrenadeAllies 1.00
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardGrenadeAxis 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardMp40 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardMp18 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardBinoculars 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardKnifeAllies 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkForwardKnifeAxis 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardThompson 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardK98 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardK98Sniper 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardNo4Sniper 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardPanzershreck 0.30
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardWalterP38 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardSg44 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardBazooka 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardExpPack 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardDetonator 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardMedPack 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardLandmine 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardRepairPack 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardColt 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardNo4 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardBar1918 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardGrenadeAllies 1.00
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardGrenadeAxis 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardMp40 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardMp18 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardBinoculars 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardKnifeAllies 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_WalkBackwardKnifeAxis 2.3
AnimationStateMachine.set1pAnimationSpeed Ub_SwimForward 2.30
AnimationStateMachine.set1pAnimationSpeed Ub_SwimBackward 2.30
AnimationStateMachine.set3pAnimationSpeed Lb_WalkForward 2.2
AnimationStateMachine.set3pAnimationSpeed Lb_WalkBackward -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardThompson 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardK98 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardK98Sniper 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardNo4Sniper 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardPanzershreck 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardWalterP38 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardSg44 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardBazooka 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardExpPack 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardDetonator 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardMedPack 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardLandmine 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardRepairPack 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardColt 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardNo4 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardBar1918 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardGrenadeAllies 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardGrenadeAxis 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardMp40 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardMp18 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardBinoculars 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardKnifeAllies 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkForwardKnifeAxis 2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardThompson -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardK98 -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardK98Sniper -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardNo4Sniper -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardPanzershreck -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardWalterP38 -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardSg44 -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardBazooka -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardExpPack -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardDetonator -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardMedPack -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardLandmine -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardRepairPack -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardColt -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardNo4 -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardBar1918 -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardGrenadeAllies -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardGrenadeAxis -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardMp40 -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardMp18 -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardBinoculars -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardKnifeAllies -2.2
AnimationStateMachine.set3pAnimationSpeed Ub_WalkBackwardKnifeAxis -2.2
AnimationStateMachine.set3pAnimationSpeed WeaponGrenadeAlliesWalk 1.90

rem 3RD Person Animation Tweak
AKA WhatThe
LightSpeed///
 
Posts: 44
Joined: Sun Oct 18, 2009 3:06 pm

Re: SSM/CSM Soldier Sprint code

Postby fo0k » Wed Oct 21, 2009 12:15 pm

great, thanks.

can we ensure that people are asked/informed before replicating here though.. just so were on side with everyone..
User avatar
fo0k
 
Posts: 1423
Joined: Fri Oct 16, 2009 4:21 pm
Location: UK

Re: SSM/CSM Soldier Sprint code

Postby LightSpeed/// » Wed Oct 21, 2009 10:04 pm

He says its cool
AKA WhatThe
LightSpeed///
 
Posts: 44
Joined: Sun Oct 18, 2009 3:06 pm

Re: SSM/CSM Soldier Sprint code

Postby LightSpeed/// » Sun Dec 20, 2009 2:05 am

What did you put for the 3rd integer
AKA WhatThe
LightSpeed///
 
Posts: 44
Joined: Sun Oct 18, 2009 3:06 pm

Re: SSM/CSM Soldier Sprint code

Postby =ArA=DeathFromAbove » Sun Jan 24, 2010 12:00 am

I have never been able to get this code to work on my server even back in the ssm days.

Today i tried making the change directly in the animations file (animationstateslower.con) as opposed to using the active command which I assumed went into the OST file.

Still when i shit click W the player walks slowly not run.
=ArA=DeathFromAbove
 
Posts: 48
Joined: Sun Oct 18, 2009 11:38 pm

Re: SSM/CSM Soldier Sprint code

Postby Player » Sun Jan 24, 2010 7:52 am

=ArA=DeathFromAbove wrote:I have never been able to get this code to work on my server even back in the ssm days.

Today i tried making the change directly in the animations file (animationstateslower.con) as opposed to using the active command which I assumed went into the OST file.

Still when i shit click W the player walks slowly not run.


I'm not to sure why it's not working for you but It does indeed work from versions 1.0 of the Demo to 1.61b of the retail for BF1942.

I never place any mods in OST file I prefer keeping everything in mods.con, but to each thier own.. Truth of the matter is mods can be placed anywhere so long as you are activating the object after it's been created in memory.
Player
 
Posts: 28
Joined: Sat Oct 24, 2009 5:06 pm

Re: SSM/CSM Soldier Sprint code

Postby =ArA=DeathFromAbove » Sun Jan 24, 2010 8:20 am

Hmm, how about version 1.21 of BFV?
=ArA=DeathFromAbove
 
Posts: 48
Joined: Sun Oct 18, 2009 11:38 pm

Re: SSM/CSM Soldier Sprint code

Postby Player » Sun Jan 24, 2010 6:37 pm

=ArA=DeathFromAbove wrote:Hmm, how about version 1.21 of BFV?


Never tested, nore advertised as such. I don't own or play BFV.
Player
 
Posts: 28
Joined: Sat Oct 24, 2009 5:06 pm

Re: SSM/CSM Soldier Sprint code

Postby LightSpeed/// » Sun Jan 24, 2010 7:57 pm

There is an different way in BFV, you can do it on a per kit basis even
Code: Select all
ObjectTemplate.active (kit name here)
ObjectTemplate.setKitSpeedFactor 1 (change this number for top speed)
ObjectTemplate.setKitAccelFactor 1
AKA WhatThe
LightSpeed///
 
Posts: 44
Joined: Sun Oct 18, 2009 3:06 pm

Re: SSM/CSM Soldier Sprint code

Postby =ArA=DeathFromAbove » Mon Jan 25, 2010 2:43 am

Lol, this code works nicely for constant speed. Normally speed is set at 1.05, i made it 10 and the soldiers were leaping from hills and buildings.

I assume therefore, there is no way in BFV to adjust the walk speed function as noted above so that hitting the shift W key can become the sprint key.
=ArA=DeathFromAbove
 
Posts: 48
Joined: Sun Oct 18, 2009 11:38 pm

Next

Return to General Modding Tutorials

Who is online

Users browsing this forum: No registered users and 7 guests