RE: [hlcoders] CreateServerRagdoll, please i need help with this. To Jay
> When I comment the SyncAnimation function, the problem solved > Yes, I use MOVETYPE_STEP instead maintain the PHYSICS move. Ok. Commenting this out is ok if you don't have other server ragdolls that are MOVETYPE_VPHYSICS. But it also means that somewhere you have an invisible strider head with wheels on it being physically simualted (at least that's what I'd expect to happen if you attached a strider.mdl to a prop_vehicle_driveable and made it MOVETYPE_STEP). If you turn on the bbox debug overlay (ent_bbox strider_vehicle) you can probably see it. So you might get physics objects colliding with something invisible if you don't fix this. Maybe it's not a big deal... IServerVehicle is the interface that does all of the player/vehicle stuff unrelated to physics. It puts your view in there, it routes your input to the vehicle, etc. You could use it to make a func_tank kind of thing that the player gets inside. It doesn't have anything to do with wheels, suspensions, & physics. But the fourwheelvehiclephysics (and the IPhysicsVehicleController you get with it) is what implements the physical tire/engine/suspension kind of stuff. So I'd guess you want to use IServerVehicle for your mod, but not IPhysicsVehicleController. CPropVehicleDriveable is giving you both. > I have another vehicle_strider.cpp derived from > CBaseAnimating with the Iservervehicle interface derived. > > I will put this vehicle in my mod instead the other. > > One question, what's the better class to implement this type > of vehicle? I'm thinking in BaseCombatCharacter > > Instead CBaseAnimating, with the Iservervehicle interface. > What do you recommended me? That doesn't matter as much as the above choice. The main difference between basecombatcharacter and baseanimating is that combatcharacter has all of the stuff to deal with weapons, ammo, line of sight, & combat relationships. So if you expect it to use weapons or have AI characters attack it, then you probably want basecombatcharacter - otherwise baseanimating will be fine. Jay ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] CreateServerRagdoll, please i need help with this. To Jay
> I use InvalidateBoneCache before calling CreateServerRagdoll > and don't work, still appears in Spawn point. Did you try the other tests I mentioned? Do other server ragdolls appear in the right places in your mod? It's important to figure out which code is broken. You need to isolate the problem to a small section of code or data to make it easier to figure out what is wrong. If other server ragdolls can be created fine in your mod, then the problem is likely related to the state or implementation of the strider entity, not the server ragdoll code itself. > I tell you what I'm doing. I create a driveable strider in my > mod: Pilotable Strider Mod. > > I derived it from CPropVehicleDrivable and I use the > calculateIKlocks functions in npc_strider and c_strider. It would be a lot less complex if you derived CNPC_Strider from IServerVehicle and implemented the relevant vehicle stuff in the strider. Are you using a four-wheel simulation for the strider? (that's the main thing you gain by using CPropVehicleDriveable) How does the strider move? It's really hard to know what could be wrong - there isn't much information here. I'd want to step through CreateServerRagdoll in your mod in the debugger and see where the positions are wrong. But I can offer another guess - perhaps you are creating a four-wheel vehicle for the strider. But you aren't using the physics for that vehicle in your mod - you're just animating the strider and moving it like the NPC code does. So the strider ragdoll is synchronized to the position of the vehicle instead of the animated entity. Anyway, the easiest way to fix that would be to teleport the vehicle (or destroy it) before you create the ragodll. What is the movetype of your strider? I guess another simple way to check this is to do this: Physics_prop_ragdoll.cpp CBaseEntity *CreateServerRagdoll( CBaseAnimating *pAnimating, int forceBone, const CTakeDamageInfo &info, int collisionGroup, bool bUseLRURetirement ) { // comment out this line! //SyncAnimatingWithPhysics( pAnimating ); //... If that fixes the problem, then you've got some physics object attached to the strider that is causing the ragdoll to spawn at the other location. This shouldn't be possible if your movetype is MOVETYPE_VPHYSICS, but if you're using MOVETYPE_STEP then it's likely to be the problem. Jay ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] CreateServerRagdoll, please i need help with this.
It's hard to debug this with such a small amount of information, but I can try to help: Server-side ragdolls don't have this bug in Half-Life 2. The people you grab with the super gravity gun, the citizens who get skewered by striders, and enemies you kill by running over with the jeep are all server-side ragdolls that are correctly positioned (modulo client-side animation transitions & IK) by the code. Do any of those things still work in your mod? Try them. This test will tell you if the underlying system is at fault, or the particular entity. The most likely bug is that your mod is updating the bones of the entity on the server differently than HL2. The simplest thing to check is the bone cache. Before you call CreateServerRagdoll, call InvalidateBoneCache() on your entity. If you've disabled server-side animation or something like that in your mod, then the server code could have an incorrect notion of where the bones should be. Jay > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of > Jose Luis Gonzalez > Sent: Wednesday, February 16, 2005 1:44 AM > To: hlcoders@list.valvesoftware.com > Subject: [hlcoders] CreateServerRagdoll, please i need help with this. > > This is a multi-part message in MIME format. > -- > [ Picked text/plain from multipart/alternative ] > > > Please, can someone help in this???. What is the problem with > CreateServerRagdoll? > > > > How I can create the ragdoll in the point I wanted??. When I > call the function, the ragdoll creates just in the spawn point > > ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders