Raised This Month: $ Target: $400
 0% 

random models without change team ?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
abdobiskra
Veteran Member
Join Date: Jul 2014
Location: Algeria
Old 03-12-2017 , 13:16   random models without change team ?
Reply With Quote #1

Hi.
I hope you are fine, geeks
my idea :
i want change model team whithout change the team

I will explain in short detail
I hope you understand me
first code :
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>


#define PLUGIN   "Test"
#define AUTHOR   "LetiLetiLepestok"
#define VERSION   "1.0"

new g_asModels[33][32]

public 
plugin_init()
{
   
register_plugin(PLUGINVERSIONAUTHOR)
   
register_forward(FM_SetClientKeyValue"SetClientKeyValue");
   
register_clcmd("set_model""set_player_mdl")
}


public 
set_player_mdl(player)
{
   new 
sModel[32]
   
read_argv(1sModelcharsmax(sModel))
   
trim(sModel)
   
remove_quotes(sModel)
   if(
equal(sModel""))
      
g_asModels[player] = ""

   
g_asModels[player] = sModel
   
   set_user_info
(player"model"g_asModels[player])   
   return 
PLUGIN_HANDLED
}


public 
SetClientKeyValue(player, const szInfoBuffer[], const szKey[], const szValue[])
{
   if( 
equal(szKey"model") && is_user_connected(player) && !equal(g_asModels[player], ""))
      return 
FMRES_SUPERCEDE

   
return FMRES_IGNORED

this its work without change team

but im using this function to chage team without killing the player for other case :
PHP Code:
set_user_team(id,"zombie",false,false
In the end :
I want to merge both cases into one job

so ! ( i need change team without killing and get the players this team random models )

PHP Code:
#define RANDOMSKINS 3

new g_asModels[33][32]


new const 
Set_Zombies_modelsRANDOMSKINS][] =
{
    
"red",
    
"clawler",
    
"blue"

__________________

Last edited by abdobiskra; 03-12-2017 at 13:18.
abdobiskra is offline
Send a message via Skype™ to abdobiskra
 



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 18:00.


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