This may not be a strictly code question ;)

You can have the player models show up and available by placing them into
the directory structure as follows:
yourmod/models/player/modelname/modelname.mdl

Depending on whether the model selection is done by the player in the
advanced options screen or not, then you would need to add no code, as I
understand it.

Otherwise, you can use this type of code to select models for the players:
g_engfuncs.pfnSetClientKeyValue(entindex(),
g_engfuncs.pfnGetInfoKeyBuffer(edict()), "model", "usmc-regenlistee");

Note, that you may have scoping issues, entindex() and edict() are
CBasePlayer (not totally correct*) function, and we happen to set player
models in a function in that class, otherwise, if you already have a pointer
to a CBasePlayer kicking around, then call it like pWhatever->edict()

"usmc-regenlistee" would be your model name - .mdl (still need same
directory structure for game to load it).

To my knowledge, player models are not precached, at least we don't, and we
have no troubles.

Cheers,


Pat 'sluggo' Magnan
Tour of Duty mod
http://www.tourofdutymod.com

* I believe that they are CBaseEntity member functions as well, but anyway,
you get my point :P
----- Original Message -----
From: "Brandon Robertson" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, May 12, 2002 1:56 PM
Subject: [hlcoders] (no subject)


> Where is the code for placing player models in my game? I already have the
> models made, i just wanna know how to get them in my mod.
>
>
> _________________________________________________________________
> Join the world's largest e-mail service with MSN Hotmail.
> http://www.hotmail.com
>
> _______________________________________________
> To unsubscribe, edit your list preferences, or view the list archives,
please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders

_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders

Reply via email to