I am so confused right now. Isn't the solution to this problem (the walking not being animated) that he's not setting m_flPoseParameters values on the entity? S'how it works for TF2. I wrote up a brief pastebin doc about pose parameters and how to set them, including examples of making an entity mimic a player's body movements. Here it is: http://pastebin.com/raw/YMDDrN9n
If you're too lazy to click that link, but not lazy enough to be able to click the Show spoilers button, I put the contents of the paste in the spoiler below.
Spoiler
PHP Code:
// Big credit to Pelipoika /* Make pet match client's look up/look down Why divide the retrieved client's value in half? Well I was setting the modelscale keyvaluefloat of the "pet" to around 0.5 When I did so, the pet's looking up/down was faster for some reason. With a little math, I fixed the issue. Therefore, depending on model scale, you may or may not have to either multiply or divide to fix speed issues if you're trying to do a "Pets" plugin or something where you're grabbing a client's poseparam values and using them for another entity's poseparam values. For a larger modelscales, let's use 2.0 scale as an example, you would multiply the retrieved client's m_flPoseParameter value by 4. */ SetEntPropFloat(pet[iClient], Prop_Send, "m_flPoseParameter", (GetEntPropFloat(iClient, Prop_Send, "m_flPoseParameter", 0) / 2), 0);
/* Make pet match client's look left/look right. This oddly didn't seem to be affected by the modelscale decrease. */ SetEntPropFloat(pet[iClient], Prop_Send, "m_flPoseParameter", GetEntPropFloat(iClient, Prop_Send, "m_flPoseParameter", 1), 1);
/* These values are TF2 values, mostly for the player models and/or MvM robot models
Values and what they control will vary based on the game and model. Use HLMV's Sequence tab (check the right side of the GUI) after loading up the model of your choice to see what options you have for pose parameters
When viewing the pose parameter values in HLMV, you'll notice that they'll use odd value ranges. As an example, body_pitch ranges from -45.0 to 90.0.
When using SetEntPropFloat, you won't be using those values. Ignore them. Use GetEntPropFloat ingame instead. I think the game converts the values to -1 and 1 range anyway for that netprop.
If you're really wanting to get into pose parameters, check out AlliedMods user Arthurdead's extension "UtilsExt"; - https://forums.alliedmods.net/showthread.php?p=2454694 - https://github.com/arthurdead/utilsext */
/* 2 = I think this varies by model. For an example, demoman's is r_hand_grip. I didn't experiment with this. */ SetEntPropFloat(pet[iClient], Prop_Send, "m_flPoseParameter", 0, 2);
/* 3 = Same as above, but for the demoman, 3 would be r_arm. I didn't experiment with this either. */ SetEntPropFloat(pet[iClient], Prop_Send, "m_flPoseParameter", 0, 3);
/* 4 = move_y < 0 = run left 0 = stop running > 0 = run right */ SetEntPropFloat(pet[iClient], Prop_Send, "m_flPoseParameter", 0, 4);
This stuff should work for CS:GO as well...I mean, same engine...same model system...gotta be the same m_flPoseParameters thing then. Do a datamaps dump (with an empty server, via rcon do sm_dump_datamaps datamaps.txt, then check your server's tf/, if memory serves me well), find the player entity in the datamaps text dump and look for m_flPoseParameters in its variables. If so, then there's your solution for making the legs move and his torso and such move so he can look in all directions and walk properly.
Also, what you're trying to do sounds suspiciously like what the TF2 Pets plugin already does. It just lacks the whole m_flPoseParameters thing for making player models walk, so we've been stuck using a shitty animation system that needs an overhaul....but with a little conversion, it could be un-TF2'd and made to work in CS:GO, I believe. Not very hard at all...just time consuming. Or you could pick at the code and use it as a reference point or somethin'.
Also also, arthurdead's UtilsExt extension may be of use in CS:GO? Arthur? Is it CS:GO compatible? I forget.
EDIT: I may be a bit of a doof. I'm guessing your issue is the prop_dynamic wasn't moving or following a player or whatever you set it to do? If so, check out the [TF2] Pets plugin link up above and see how the 3 varying "pet" plugins out there do it.
If your issue isn't that, and it is the models legs not "walking" and the model just kind of glides along the ground, see the above m_flPoseParameters bit.
If it's neither, please explain further
Last edited by 404UserNotFound; 02-03-2017 at 09:32.