AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Solved Setting player models. (https://forums.alliedmods.net/showthread.php?t=320937)

Napoleon_be 01-16-2020 15:07

Setting player models.
 
So i've been trying to set a player model for the entire 2 hours and i've done research and tried everything such as, cs_set_user_model() & engfunc() but it doesn't seem to work. Allthough, i've tried selecting different terrorist classes but the model seems to stay the same. Are there any server commands that can block my plugin from showing the model?

my settings:
cl_minmodels 1
cl_min_ct 2
cl_min_t 1

my current code
PHP Code:

/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <hamsandwich>
#include <cstrike>

#define PLUGIN "VIP Model: Terrorist"
#define VERSION "1.0"
#define AUTHOR "NapoleoN#"

new const szModel[] = "models/player/female_t/female_t.mdl";

public 
plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR);
    
    
RegisterHam(Ham_Spawn"player""PostPlayerSpawn"1);
}

public 
plugin_precache()
{
    
precache_model(szModel);
}

public 
PostPlayerSpawn(id)
{
    if(
is_user_alive(id)) 
    {
        
cs_set_user_model(id"female_t");
    }



OciXCrom 01-16-2020 15:15

Re: Setting player models.
 
Quote:

cl_minmodels 1
0

PS: the other 2 cvars don't even exist.

Napoleon_be 01-16-2020 15:28

Re: Setting player models.
 
Quote:

Originally Posted by OciXCrom (Post 2680537)
0

PS: the other 2 cvars don't even exist.

they came up in my game console, that's why lol
Thanks, cl_minmodels 0 worked, stupid me


All times are GMT -4. The time now is 05:11.

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