Raised This Month: $ Target: $400
 0% 

Setting custom model


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
moosewanted
Member
Join Date: May 2009
Old 05-26-2009 , 21:34   Setting custom model
Reply With Quote #1

Hey, I am using this stock I found in a tutorial.
PHP Code:
stock fm_set_user_modelplayer, const modelname[] )
{
    
// Set new model
    
engfuncEngFunc_SetClientKeyValueplayerengfuncEngFunc_GetInfoKeyBufferplayer ), "model"modelname )
    
    
// Remember this player has a custom model
    
g_has_custom_model[player] = true

what should modelname be? for example, should it be "models/player/custom.mdl"

Thanks.
moosewanted is offline
Hunter-Digital
Veteran Member
Join Date: Aug 2006
Location: In the Game [ro]
Old 05-26-2009 , 23:19   Re: Setting custom model
Reply With Quote #2

Model should be the model's name...
ex:
filename: models/player/custom/custom.mdl
modelname: custom

you need the filename to precache it and the name to use it
also, the filename format is REQUIRED, you can't use other models from other folders, only from "player" folder with the aproppiate folder for each model (gign folder for gign.mdl, custom folder for custom.mdl, etc)
__________________
Hunter-Digital is offline
moosewanted
Member
Join Date: May 2009
Old 05-27-2009 , 13:12   Re: Setting custom model
Reply With Quote #3

Quote:
Originally Posted by Hunter-Digital View Post
Model should be the model's name...
ex:
filename: models/player/custom/custom.mdl
modelname: custom

you need the filename to precache it and the name to use it
also, the filename format is REQUIRED, you can't use other models from other folders, only from "player" folder with the aproppiate folder for each model (gign folder for gign.mdl, custom folder for custom.mdl, etc)
No wonder it wasn't working. It has to be a model from the /player/ folder? How would I go about setting the model using a model already in half-life on a player if it isn't in the /player/ folder, the chickenmod way?
moosewanted is offline
ot_207
Veteran Member
Join Date: Jan 2008
Location: Romania The Love Country
Old 05-27-2009 , 14:14   Re: Setting custom model
Reply With Quote #4

The player model needs to respect this format (when we talk about target):
PHP Code:
"models/player/NAME/NAME.mdl" 
So yes it needs to be in the player folder!

To set it use this as the string argument:
PHP Code:
"NAME" 
And about the model on half-life that is in player folder in valve it is possible but I don't know (without model precache!)!
__________________
My approved plug-ins | Good for newbies! | Problems?

Back, will come around when I have time.
ot_207 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:27.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode