[Modificare plugin] Player Model

Modificari necesare ale pluginurilor

Moderators: Moderatori ajutatori, Moderatori, Echipa eXtreamCS.com

Post Reply
Ykaru
Membru, skill 0
Membru, skill 0
Posts: 27
Joined: 29 Jul 2019, 00:33
Detinator Steam: Nu
CS Status: Citesc forumul eXtreamCS.com...!
Fond eXtream: 0
Has thanked: 1 time

31 Jul 2019, 03:10

Salut, am gasit acest plugin care dupa cum zice ar trebui sa modifice modelele playerilor si adminilor, dar dupa ce-l compilez si adaug pe server primesc eroarea :
Host_Error: PF_precache_model_I: Bad string 'models/player/F_Model_T/F_T.mdl'
FATAL ERROR (shutting down): Host_Error: PF_precache_model_I: Bad string 'models/player/F_Model_T/F_T.mdl'

Daca poate cineva sa-l rezolve sau daca stiti voi un plugin pentru modificare skinuri, dar sa fie pe permisii ca sa pot da adminilor un model si playerilor alt model.
| Afiseaza codul
/* Plugin generated by AMXX-Studio */

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

new const PLUGIN[] = "New Plug-In";
new const VERSION[] = "1.0";

new const g_szPlayerModels[][] =
{
	"models/player/F_Model_T/F_T.mdl",
	"models/player/F_Model_Ct/F_Ct.mdl",
	"models/player/A_Model_T/A_T.mdl",
	"models/player/A_Model_Ct/A_Ct.mdl",
	"models/player/P_Model_Ct/P_Ct.mdl"
}

public plugin_precache()
{
	for (new i = 0; i < sizeof g_szPlayerModels; i++)
		engfunc(EngFunc_PrecacheModel, g_szPlayerModels);
}

public plugin_init()
{
	register_plugin(PLUGIN, VERSION, "Adventx")
	
	RegisterHam(Ham_Spawn, "player", "fw_PlayerSpawn_Post", 1);
	
	// Add your code here...
}

public fw_PlayerSpawn_Post(id)
{
	if (!is_user_alive(id))
		return HAM_IGNORED;
	
	if (get_user_flags(id) && ADMIN_IMMUNITY)
	{
		switch (cs_get_user_team(id))
		{
			case CS_TEAM_T:cs_set_user_model(id, g_szPlayerModels[0]);
			case CS_TEAM_CT:cs_set_user_model(id, g_szPlayerModels[1]);
		}
	}
	
	if (get_user_flags(id) && ADMIN_RESERVATION)
	{
		switch (cs_get_user_team(id))
		{
			case CS_TEAM_T:cs_set_user_model(id, g_szPlayerModels[2]);
			case CS_TEAM_CT:cs_set_user_model(id, g_szPlayerModels[3]);
		}
	}
	
	else
	{
		switch (cs_get_user_team(id))
		{
			case CS_TEAM_CT:cs_set_user_model(id, g_szPlayerModels[4]);
		}
	}
	
	return HAM_IGNORED;
}

/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1033\\ f0\\ fs16 \n\\ par }
*/
User avatar
Sorinel
Fost moderator
Fost moderator
Posts: 5189
Joined: 25 Aug 2014, 20:31
Detinator Steam: Da
CS Status: All i ever wanted was a Rolli Rolli
SteamID: Jandarmeria
Reputatie: Fost Membru Club eXtreamCS ( o luna )
Fost eXtream Mod
Fost Intermediar
Nume anterior: Christmas, A k c 3 n 7
Fond eXtream: 0
Location: Ploiesti
Been thanked: 7 times

31 Jul 2019, 17:46

Esti sigur ca ai pus models/player/F_Model_T/F_T.mdl in folder si cu numele care trebuie?
Ykaru
Membru, skill 0
Membru, skill 0
Posts: 27
Joined: 29 Jul 2019, 00:33
Detinator Steam: Nu
CS Status: Citesc forumul eXtreamCS.com...!
Fond eXtream: 0
Has thanked: 1 time

01 Aug 2019, 01:28

Da, oricum am rezolvat.
Multumesc oricum.
Cer T/C
Post Reply

Return to “Modificari pluginuri”

  • Information