I’ve spent an enormous amount of time getting the various bits of my TTT server working, but now I’m really out of my depth. I’m brand new to coding in GMOD, but not to programming in general. I’m trying to get some more playermodels in my pointshop, some of them I’ve had no trouble with, others are stuck in the T-pose and will not animate as they run. They will, however, react to jumping or falling and will crouch as they land.
I’m told that this is because they are NPCs, and NPCs don’t work in the same way as playermodels. I’d like to give these models the right animations, I’ve used them in sandbox and seen them running around properly- I just want them to do that as a playermodel! It’d be great if you could do this for me, but I’d prefer to learn how to do it so that I can do it with some of the others I have. I’ve also got a few that are just ragdolls but I really like, is it possible to convert them?
Anyway, this is the model I’m currently using:
And this is the LUA code I’m running on the server:
Any help you could give me would be grand. So many of the guides I’ve found are incomplete or out of date- I’ve been able to teach myself everything else I’ve done on this server, but I feel like I’ve hit a wall here!
I’d also like to highlight the lack of Trek, Firefly or BSG models in general, I kinda want to learn to model to try and fill in the gaps! If only I had the time.
If I’m correct, the NPCs have neither the bones nor the animations to be used as player models. In order to make an NPC into a player model you would have to decompile the mdl of the NPC and a current player model, delete all of the bones from the NPC and replace them with the bones from the playermodel, and rig each bone, then recompile the SMD files produced by this, including the animation files for players. It probably sounds confusing but if you google something along the lines of Mario’s Guide To Ragdolling it’ll probably make a lot more sense.
The problem is, you’d likely have to clean out the animations used by the NPCs since they do not support 9-way animations like in Team Fortress, Left 4 Dead, even Counter-Strike… Too bad we’ll never be able to have things like HL2DM; the exact same models used by NPCs, and only added player animations.
What if the NPC animations (that are by default “8-way?”) get priority? Combining move_yaw with move_x and _y don’t seem to make good mixes… if I’m not wrong. Though, I will always have to look back at my thoughts about using the NPC models (like Half Life 2: DM does) and only adding player animations. There are some other suggestions I made on the GMOD Google Moderator that might’ve gone unanswered, like being able to fingerpose other currently non-fingerposable models in the Valve games, like Chell and the Vortigaunts, that includes DOG.