Page 2 of 2

Re: [ZE] Owner Skin

Posted: 15 Oct 2019, 19:53
by Night Fury
Just write the model name.
So if it's blabla.mdl, just write blabla & make sure it's located in a folder named blabla as well.

Re: [ZE] Owner Skin

Posted: 28 Nov 2019, 13:23
by BandiT
Can someone to make this plugin to work for vip model, because inhave this plugin it’s working very weel i have skin for human and skin for zombie, but i want one like that for vip, to put another skin for vip human and zombie, can someone help me with that ?

Re: [ZE] Owner Skin

Posted: 28 Nov 2019, 17:57
by sPe3doN
BandiT wrote: 4 years ago Can someone to make this plugin to work for vip model, because inhave this plugin it’s working very weel i have skin for human and skin for zombie, but i want one like that for vip, to put another skin for vip human and zombie, can someone help me with that ?
Just search in the code ADMIN_RECON And change it to ADMIN_LEVEL_H

Re: [ZE] Owner Skin

Posted: 28 Nov 2019, 19:05
by BandiT
Ok, i will try

Re: [ZE] Owner Skin

Posted: 28 Nov 2019, 20:41
by BandiT
Is no working bro

Re: [ZE] Owner Skin

Posted: 29 Nov 2019, 22:43
by sPe3doN
BandiT wrote: 4 years ago Is no working bro
here you go

Code: Select all

#include <zombie_escape>

// Setting file
new const ZE_SETTING_RESOURCES[] = "zombie_escape.ini"

#define VIP_MODELS_ACCESS ADMIN_LEVEL_H

// Default models
new const szAdminHumanModel[][] = 
{
	"human_VIP"
}

// Dynamic Arrays: Models
new Array:g_szAdminHumanModel

public plugin_init()
{
	register_plugin("[ZE] VIP Skin", ZE_VERSION, AUTHORS)
}

public plugin_precache()
{
	// Initialize arrays
	g_szAdminHumanModel = ArrayCreate(32, 1)
	
	// Load from external file
	amx_load_setting_string_arr(ZE_SETTING_RESOURCES, "Player Models", "HUMAN VIP", g_szAdminHumanModel)
	
	// Load our default Values
	new iIndex
	
	if(ArraySize(g_szAdminHumanModel) == 0)
	{
		for(iIndex = 0; iIndex < charsmax(szAdminHumanModel); iIndex++)
			ArrayPushString(g_szAdminHumanModel, szAdminHumanModel[iIndex])
		
		// Save to external file
		amx_save_setting_string_arr(ZE_SETTING_RESOURCES, "Player Models", "HUMAN VIP", g_szAdminHumanModel)
	}

	// Precache
	new szPlayerModel[32], szModelPath[128]
	
	for (iIndex = 0; iIndex < ArraySize(g_szAdminHumanModel); iIndex++)
	{
		ArrayGetString(g_szAdminHumanModel, iIndex, szPlayerModel, charsmax(szPlayerModel))
		formatex(szModelPath, charsmax(szModelPath), "models/player/%s/%s.mdl", szPlayerModel, szPlayerModel)
		precache_model(szModelPath)
	}
}

public ze_user_humanized(id)
{
	if(ze_is_user_zombie(id) || !is_user_alive(id) || !(get_user_flags(id) & VIP_MODELS_ACCESS))
		return
		
	new szPlayerModel[32]

	// Set owner model
	ArrayGetString(g_szAdminHumanModel, random_num(0, ArraySize(g_szAdminHumanModel) - 1), szPlayerModel, charsmax(szPlayerModel))
	rg_set_user_model(id, szPlayerModel)
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1036\\ f0\\ fs16 \n\\ par }
*/

Re: [ZE] Owner Skin

Posted: 02 Dec 2019, 10:22
by BandiT
Thanks it’s working :)

Re: [ZE] Owner Skin

Posted: 24 Jan 2020, 17:42
by Spir0x
sorry i can't help, i just deleted my pack since 5 months ago and i forgot 90% of the zombie escape mod.