Sandbox+ for SRTT

Decker rollerblader dash animations working. :)

276663593E513BC566A003B940304A1413CB06AE


Added the blue fx and sped it up with the superpowers function

19CC5E4040546F92CB85B97DF0F1A8716DBDD7E1


Now to start working on the teleporting and shooting while laid back.
 
Your mod turned out to be invaluable for testing xtbl tweaks, texture replacements, and so on. I wonder, does the engine allow to manually cycle through the available weather stages (clear sky, overcast, rain, etc) in the same way you can cycle the times of day?
 
Your mod turned out to be invaluable for testing xtbl tweaks, texture replacements, and so on. I wonder, does the engine allow to manually cycle through the available weather stages (clear sky, overcast, rain, etc) in the same way you can cycle the times of day?

My memory is a bit fuzzy, but I do remember attempting to add weather changing. It didn't work and just bombed out the threads, if memory serves.
 
Sure, switching off to the police shooting and other anims should be easy.
 
Rather than just work this out all myself, I'm going to detail out how it works so other modders can pitch in and help.

The trick with animation changes is that all the newly modded animation tables files must be packed in misc_tables.vpp_pc. They will not load from the root or from patch_compressed.vpp_pc. Here are the files you would want to look at in misc_tables.vpp_pc:
plym.xtbl <- player male animations
plyf.xtbl <- player female animations
brute.xtbl <- brute animations
rollerblader.xtbl <- decker specialist animations
cop.xtbl <- cop animations
avatar.xtbl <- avatar animations

The problem is that these non-player animation tables do not have animations attached to normal player actions. They are mostly unique actions that the player never does. The trick to getting these animations to work for the player is to copy over entries from plym.xtbl (or plyf.xtbl) into the new animation table. For example, here's what the states look like in vanilla rollerblader.xtbl:
Code:
<root><Table><Skeleton_Set>
<Name>RollerBlader</Name>
<Parent_Skeleton>COP</Parent_Skeleton>
<Groups>
<Group><group>Default</group><States>
<State><ID>Dash A</ID><Animation><Filename>rblade_dash_a.animx</Filename></Animation></State>
<State><ID>Dash B</ID><Animation><Filename>rblade_dash_b.animx</Filename></Animation></State>
<State><ID>Stand</ID><Animation><Filename>rblade_sd.animx</Filename></Animation></State>
<State><ID>Dash C</ID><Animation><Filename>rblade_dash_c.animx</Filename></Animation></State>

The player never uses anything except "Stand" from plym(f).xtbl, so you copy over entries from plym(f).xtbl into rollerblader.xtbl and reference the existing animations for the specialist. So, it would look like this:

Code:
<root><Table><Skeleton_Set>
<Name>RollerBlader</Name>
<Parent_Skeleton>COP</Parent_Skeleton>
<Groups>
<Group><group>Default</group><States>
<State><ID>Dash A</ID><Animation><Filename>rblade_dash_a.animx</Filename></Animation></State>
<State><ID>Dash B</ID><Animation><Filename>rblade_dash_b.animx</Filename></Animation></State>
<State><ID>Stand</ID><Animation><Filename>rblade_sd.animx</Filename></Animation></State>
<State><ID>Dash C</ID><Animation><Filename>rblade_dash_c.animx</Filename></Animation></State>
 
<State><ID>run</ID><Animation><Filename>player_base_move</Filename></Animation></State>
<State><ID>walk</ID><Animation><Filename>player_base_move</Filename></Animation></State>
<State><ID>sprint</ID><Animation><Filename>rblade_dash_b.animx</Filename></Animation></State>
<State><ID>weapon sprint</ID><Animation><Filename>rblade_dash_b.animx</Filename></Animation></State>

Notice that there are 4 new entries for run, walk, sprint, and weapon sprint. Run and walk are actually unchanged so the player uses the plym animations for those rather than just sliding around with no animation. Sprint and weapon sprint simply copy rblade_dash_b.animx for those states so they do the fast rollerblading animation.

To trigger the change you would use this Sandbox+ command:
customization_swap_player_rig( "cm_body.rig", "Rollerblader" )

You would substitute one of the other animation tables for "Rollerblader" in the second parameter if you wanted to use cop, brute, or other animation sets. Most sets are missing the basic player animations though, so you would need to copy over the entries from plym or plyf and then change the actual file it uses to one of the special ones.

Each section in each animation table is broken up into states and actions. A state would be like standing, running, crouching, and an action would be like attacking. Furthermore, each group (comprised of a state and action section) would generally be a type of weapon, like unarmed, pistol, shotgun, etc.

The next step with the decker specialist would be to copy over plym action moves into rollerblader.xtbl and then change the actual animation for that copied over player action line to one of the decker special animations from the action section.

If anyone wants to start working on any of these, including the decker specialist anims, then feel free. It's going to take a lot of testing and tweaking to figure out which animations to tie to which player actions to get it working well. Don't forget that you will need to repacked your changed animation tables back into misc_tables.vpp_pc for it to actually work in-game.

EDIT:
I also added the superpowers function for the rollerblader so that it only triggers the dash animation when sprinting at super speed:
Code:
                    customization_swap_player_rig( "cm_body.rig", "Rollerblader" )
                    player_super_powered(LOCAL_PLAYER, true)
                    sandboxplus_message("Animations set to Decker Specialist")
 
Dancing, dancing everywhere.
I only don't understand the customization_swap_player_rig thing from the roller blader animations.
 
I managed to enable Avatar's animations by preloading them. It seems that we have to try harder, though:
1) Camera is totally off
2) Avatar's 3D model is rendered very distorted when morphed from a female character (sic)
3) Bits of mesh are stretching too far while moving:
avatar_bug.JPG

As you probably guess, I have no idea what might be causing that.
 
Back
Top