Raised This Month: $ Target: $400
 0% 

Setting Player Models


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 07-11-2010 , 19:09   Setting Player Models
Reply With Quote #1

Correct me if I'm wrong.

PHP Code:
new const gszHomerModel[] = "models/player/ignfreezetag/homer.wav"
PHP Code:
public plugin_precache( )
{
    
precache_model(gszHomerModel);

Then, in the menu, when they select homer, I use:

PHP Code:
cs_set_user_modelidgszHomerModel 
And when a new round begins

PHP Code:
cs_reset_user_modelid 
Edit: When I choose homer it crashes.
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.

Last edited by GXLZPGX; 07-11-2010 at 19:14.
GXLZPGX is offline
minato
Senior Member
Join Date: May 2010
Location: Rosario
Old 07-11-2010 , 19:22   Re: Setting Player Models
Reply With Quote #2

It is an extension .wav not .mdl you cannot put a sound since I shape a player

PHP Code:
new const gszHomerModel[] = "models/player/ignfreezetag/homer.wav"
---->

PHP Code:
new const gszHomerModel[] = "models/player/ignfreezetag/yourmodel.mdl"

Last edited by minato; 07-11-2010 at 19:24. Reason: type fail xP
minato is offline
Send a message via MSN to minato
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 07-11-2010 , 19:26   Re: Setting Player Models
Reply With Quote #3

Quote:
Originally Posted by minato View Post
It is an extension .wav not .mdl you cannot put a sound since I shape a player

PHP Code:
new const gszHomerModel[] = "models/player/ignfreezetag/homer.wav"
---->

PHP Code:
new const gszHomerModel[] = "models/player/ignfreezetag/yourmodel.mdl"
Yes I noticed that earlier when I tested it. I fixed that Thanks for pointing it out though. For some reason, when I choose homer, the server crashes..


Edited the post:

Alright, so I found the problem. When you set a player model up the file name in models/player has to be the same as the model. So I used:

new const gszHomerModel[] = "models/player/homer/homer.mdl";

Then I precached. Now, the server doesn't crash when I choose homer, it just doesnt set the model. I did this:

PHP Code:
cs_set_user_modelidgszHomerModel 
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.

Last edited by GXLZPGX; 07-11-2010 at 20:10.
GXLZPGX is offline
Kreation
Veteran Member
Join Date: Jan 2010
Location: Illinois
Old 07-11-2010 , 20:22   Re: Setting Player Models
Reply With Quote #4

Try using:

PHP Code:
cs_set_user_modelid"homer" ); 
I don't know if that will work but it should.
__________________
Hi.
Kreation is offline
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 07-11-2010 , 21:06   Re: Setting Player Models
Reply With Quote #5

Quote:
Originally Posted by Kreation View Post
Try using:

PHP Code:
cs_set_user_modelid"homer" ); 
I don't know if that will work but it should.
That worked. But look, his head is sideways and he has a knife up his ass:



:/
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.
GXLZPGX is offline
PattyBiena
BANNED
Join Date: Jul 2010
Location: Argentina
Old 07-11-2010 , 21:21   Re: Setting Player Models
Reply With Quote #6

The model is wrong.
PattyBiena is offline
Kreation
Veteran Member
Join Date: Jan 2010
Location: Illinois
Old 07-11-2010 , 22:27   Re: Setting Player Models
Reply With Quote #7

The knife is up his ass because that's toast.. of course he has something up his ass.
__________________
Hi.
Kreation is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-12-2010 , 01:34   Re: Setting Player Models
Reply With Quote #8

"models/player/SAME_MODEL_NAME/SAME_MODEL_NAME.mdl"

but you obviously figured it out.

Try to find another model, that one doesn't seems to be a player model.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
joropito
AlliedModders Donor
Join Date: Mar 2009
Location: pfnAddToFullPack
Old 07-12-2010 , 09:26   Re: Setting Player Models
Reply With Quote #9

Quote:
Originally Posted by GXLZPGX View Post
That worked. But look, his head is sideways and he has a knife up his ass:



:/
Set pev_controller (0 to 3) to 125

But that model will have problem when you try to turn the body with the mouse.
It will turn like a "cube" and not like a human. Ok, Homer is not human
__________________

Divide et vinces
approved plugins | steam account

I don't accept PM for support. Just ask on forums.
If you're looking for private work, PM me.

Last edited by joropito; 07-12-2010 at 09:30.
joropito is offline
Send a message via MSN to joropito
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 07-12-2010 , 09:31   Re: Setting Player Models
Reply With Quote #10

Quote:
Originally Posted by joropito View Post
Set pev_controller (0 to 3) to 125

But that model will have problem when you try to turn the body with the mouse.
It will turn like a "cube" and not like a human. Ok, Homer is not human
set_pev( id, pev_controller, 125 )
set_pev( id, pev_controller_0, 125 )
set_pev( id, pev_controller_1, 125 )
set_pev( id, pev_controller_2, 125 )
set_pev( id, pev_controller_3, 125 )

You're saying the you wont be able to turn normally with your mouse if you choose homer?
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.
GXLZPGX 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 07:10.


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