Raised This Month: $48 Target: $400
 12% 

Solved a lot of error


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Dragos
Junior Member
Join Date: Oct 2018
Location: Romania
Old 02-10-2019 , 07:25   a lot of error
Reply With Quote #1

hi i modifi these plugin but idk why i get again chatcolor error
PHP Code:
/* Plugin generated by AMXX-Studio */ 

#include < amxmodx > 
#include < fakemeta_util >  
#include < hamsandwich > 
#include < cstrike > 
#include < fun > 

#define PLUGIN "Furien Weapon's Gold" 
#define VERSION "1.1" 
#define AUTHOR "none" 

// = Damage Arme VIP ================= 
#define IsPlayer(%0)    ( 1 <= %0 <= g_iMaxPlayers ) 
#define VIP_FLAG ADMIN_LEVEL_F // Flag-ul T  
new g_iMaxPlayers

new 
bool:Ak47Gold33 ], M4a1Gold33 ],DeagleGold33 ], AwpGold 33 ], M249Gold 33 ], AidjaOarma33 ]; 

new const 
Ak47Gold_v_Model66 ] = "models/v_golden_ak47.mdl"
new const 
Ak47Gold_p_Model64 ] = "models/p_golden_ak47.mdl"

new const 
M4a1Gold_v_Model66 ] = "models/v_golden_m4a1.mdl"
new const 
M4a1Gold_p_Model64 ] = "models/p_golden_m4a1.mdl"

new const 
AwpGold_v_Model66 ] = "models/v_golden_awp.mdl"
new const 
AwpGold_p_Model64 ] = "models/p_golden_awp.mdl"

new const 
DeagleGold_v_Model66 ] = "models/v_golden_deagle.mdl"
new const 
DeagleGold_p_Model64 ] = "models/p_golden_deagle.mdl";

new const 
M249Gold_v_Model 66 ] = "models/v_golden_m249.mdl";
new const 
M249Gold_p_Model 64 ] = "models/p_golden_m249.mdl";

public 
plugin_init() { 
    
register_plugin(PLUGINVERSIONAUTHOR
     
    
// Add your code here... 
    
register_clcmd("say /weapons","ClcmdWeapons"); 
    
RegisterHam(Ham_Spawn"player""Inceput_runda"1); 
     
    
register_event"CurWeapon""Event_CurWeapon""be""1=1" 
    
RegisterHamHam_TakeDamage"player""DamageVip" 
     
    
// Damage VIP  
    
g_iMaxPlayers get_maxplayers ( ); 



public 
ClcmdWeapons(id) { 
    if(
AidjaOarma[id] ) { 
        
ChatColor(id"!g[Anti-furien Menu] !tAi ales aceasta runda arma"); 
        return 
PLUGIN_HANDLED
    } 
    if( 
get_user_teamid ) == ) { 
        
WeaponMenu(id
    } 
    return 
PLUGIN_HANDLED


public 
Inceput_runda(id) { 
    if(
is_user_alive(id)) { 
        
give_item(id"weapon_knife"); 
        
AidjaOarma[id] = false
        
Ak47Goldid ] = false
        M4a1Gold
id ] = false 
        DeagleGold
id ] = false
    AwpGold
id ] = false
    M249Gold
id ] = false
    
        
if(get_user_team(id) == 2) { 
            
WeaponMenu(id); 
        } 
    } 


public 
WeaponMenu(id) { 
    if(
is_user_alive(id) && get_user_team(id) == 2) { 
        new 
menu menu_create ("\w[Furien Weapons] \rGold Menu""CaseWeaponMenu"); 
         
        
menu_additem(menu"Normal's Players Weapon""1"
        
menu_additem(menu"V.I.P's Weapons \r[Sannty]""2"
         
        
menu_setprop(menuMPROP_EXITMEXIT_ALL); 
        
menu_display(idmenu); 
    } 


public 
CaseWeaponMenu(idmenuitem) { 
    if(
item == MENU_EXIT || !is_user_alive(id) || get_user_team(id) != 2) { 
        
menu_destroy(menu); 
        return 
PLUGIN_HANDLED
    } 
     
    new 
data [6], szName [64]; 
    new 
accesscallback
    
menu_item_getinfo (menuitemaccessdata,charsmax (data), szName,charsmax (szName), callback); 
    new 
key str_to_num (data); 
     
    switch (
key
    { 
        case 
1: { 
            
PlayersMenu(id)  
        } 
        case 
2: { 
            if( 
get_user_flagsid ) & VIP_FLAG )  { 
                
VipMenu(id)  
            } 
            else 
            { 
                
ChatColor(id"!g[AntiFurien Weapons] !nNu ai Vip Pentru a acesa VIP Menu Cumpara VIP Si vei avea aces"); 
                
WeaponMenu(id
                return 
PLUGIN_HANDLED
            } 
        } 
    } 
    
menu_destroy(menu); 
    return 
PLUGIN_HANDLED


public 
PlayersMenu(id) { 
    if(
is_user_alive(id) && get_user_team(id) == 2) { 
        new 
menu menu_create ("Normal's Weapons""CasePlayersMenu"); 
         
        
menu_additem(menu"Ak47""1"); 
        
menu_additem(menu"M4a1""2"); 
        
menu_additem(menu"MP5 Navy""3"); 
        
menu_additem(menu"XM1014""4"); 
        
menu_additem(menu"M3""5"); 
        
menu_additem(menu"AUG""6"); 
        
        
menu_setprop(menuMPROP_EXITMEXIT_ALL); 
        
menu_display(idmenu); 
    } 


public 
CasePlayersMenu(idmenuitem) { 
    if(
item == MENU_EXIT || !is_user_alive(id) || get_user_team(id) != 2) { 
        
menu_destroy(menu); 
        return 
PLUGIN_HANDLED
    } 
     
    new 
data [6], szName [64]; 
    new 
accesscallback
    
menu_item_getinfo (menuitemaccessdata,charsmax (data), szName,charsmax (szName), callback); 
    new 
key str_to_num (data); 
     
    switch (
key
    { 
        case 
1
        { 
            
give_item(id"weapon_ak47"); 
            
cs_set_user_bpammo(idCSW_AK47,250); 
            
ChatColor(id"!g[AntiFurien Weapons] !nAi ales Ak47"); 
            
AidjaOarmaid ] = true
            
PistolSpawn(id
        } 
        case 
2
        { 
            
give_item(id"weapon_m4a1"); 
            
cs_set_user_bpammo(idCSW_M4A1,250); 
            
ChatColor(id"!g[AntiFurien Weapons] !nAi ales M4a1"); 
            
AidjaOarmaid ] = true
            
PistolSpawn(id
        } 
        case 
3
        { 
            
give_item(id"weapon_mp5navy"); 
            
cs_set_user_bpammo(idCSW_MP5NAVY,250); 
            
ChatColor(id"!g[AntiFurien Weapons] !nAi ales Mp5Navy"); 
            
AidjaOarmaid ] = true
            
PistolSpawn(id
        } 
        case 
4
        { 
            
give_item(id"weapon_xm1014"); 
            
cs_set_user_bpammo(idCSW_XM1014,250); 
            
ChatColor(id"!g[AntiFurien Weapons] !nAi ales Xm1014"); 
            
AidjaOarmaid ] = true
            
PistolSpawn(id
        } 
        case 
5
        { 
            
give_item(id"weapon_m3"); 
            
cs_set_user_bpammo(idCSW_M3,250); 
            
ChatColor(id"!g[AntiFurien Weapons] !nAi ales M3"); 
            
AidjaOarmaid ] = true
            
PistolSpawn(id
        } 
        case 
6
        { 
            
give_item(id"weapon_aug"); 
            
cs_set_user_bpammo(idCSW_M249,250); 
            
ChatColor(id"!g[AntiFurien Weapons] !nAi Ales Aug"); 
            
AidjaOarmaid ] = true
            
PistolSpawn(id
        }
    } 
     
    
menu_destroy (menu); 
    return 
PLUGIN_HANDLED


public 
VipMenu(id) { 
    if(
is_user_alive(id) && get_user_team(id) == 2) { 
        new 
menu menu_create ("V.I.P's Menu""CaseVipMenu"
         
        
menu_additem(menu"Ak47 Gold""1"
        
menu_additem(menu"M4a1 Gold""2"
        
menu_additem(menu"Awp Gold""3")
        
menu_additem(menu"M249 Gold""4")
    
        
menu_setprop(menuMPROP_EXITMEXIT_ALL); 
        
menu_display(idmenu); 
    } 


public 
CaseVipMenu(idmenuitem) { 
    if(
item == MENU_EXIT || !is_user_alive(id) || get_user_team(id) != 2) { 
        
menu_destroy(menu); 
        return 
PLUGIN_HANDLED
    } 
     
    new 
data [6], szName [64]; 
    new 
accesscallback
    
menu_item_getinfo (menuitemaccessdata,charsmax (data), szName,charsmax (szName), callback); 
    new 
key str_to_num (data); 
     
    switch (
key
    { 
        case 
1: { 
            
give_item(id"weapon_ak47"); 
            
cs_set_user_bpammo(idCSW_AK47,250); 
            
set_pevidpev_viewmodel2Ak47Gold_v_Model 
            
set_pevidpev_weaponmodel2Ak47Gold_p_Model 
            
AidjaOarmaid ] = true
            
Ak47Goldid ] = true 
            PistolSpawn
(id
        } 
        case 
2: { 
            
give_item(id"weapon_m4a1"); 
            
cs_set_user_bpammo(idCSW_M4A1,250); 
            
set_pevidpev_viewmodel2M4a1Gold_v_Model 
            
set_pevidpev_weaponmodel2M4a1Gold_p_Model 
            
AidjaOarmaid ] = true
            
M4a1Goldid ] = true 
            PistolSpawn
(id
        } 
        case 
3: { 
            
give_item(id"weapon_awp"); 
            
cs_set_user_bpammo(idCSW_AWP250); 
            
set_pevidpev_viewmodel2AwpGold_v_Model 
            
set_pevidpev_weaponmodel2AwpGold_p_Model 
            
AidjaOarma id ] = true
            
AwpGold id ] = true 
            PistolSpawn 
(id
        }
    case 
4: {
       
give_item(id"weapon_m249");
            
cs_set_user_bpammo(idCSW_M249250); 
            
set_pevidpev_viewmodel2M249Gold_v_Model 
            
set_pevidpev_weaponmodel2M249Gold_v_Model 
            
AidjaOarma id ] = true
            
M249Gold id ] = true
            PistolSpawn 
(id)
       }
    } 
    
menu_destroy(menu); 
    return 
PLUGIN_HANDLED


public 
PistolSpawn(id) { 
    if(
is_user_alive(id) && get_user_team(id) == 2) { 
        new 
menu menu_create ("Secundary \rWeapon""CaseWeaponSecundar"); 
         
        if( 
get_user_flagsid ) & VIP_FLAG )  { 
            
menu_additem(menu"Deagle Gold \r[Sannty]""1"); 
        } 
        else 
        { 
            
menu_additem(menu"Deagle Gold \d[Sannty]""1"); 
        } 
         
        
menu_additem(menu"Fiveseven""2"); 
        
menu_additem(menu"Usp""3"); 
         
        
menu_setprop(menuMPROP_EXITMEXIT_ALL); 
        
menu_display(idmenu); 
    } 


public 
CaseWeaponSecundar(idmenuitem) { 
    if(
item == MENU_EXIT || !is_user_alive(id) || get_user_team(id) != 2) { 
        
menu_destroy(menu); 
        return 
PLUGIN_HANDLED
    } 
     
    new 
data [6], szName [64]; 
    new 
accesscallback
    
menu_item_getinfo (menuitemaccessdata,charsmax (data), szName,charsmax (szName), callback); 
    new 
key str_to_num (data); 
     
    switch (
key
    { 
        case 
1: { 
            if( 
get_user_flagsid ) & VIP_FLAG )  { 
                
give_item(id"weapon_deagle"); 
                
cs_set_user_bpammo(idCSW_DEAGLE50); 
                
set_pevidpev_viewmodel2DeagleGold_v_Model 
                
set_pevidpev_weaponmodel2DeagleGold_p_Model 
                
AidjaOarmaid ] = true
                
DeagleGoldid ] = true 
            

            else 
            { 
                
ChatColor(id"!g[AntiFurien Weapons] !nDeagle Gold este doar pentru VIP"); 
                
PistolSpawn(id
                return 
PLUGIN_HANDLED
            } 
        } 
        case 
2
        { 
            
give_item(id"weapon_fiveseven"); 
            
cs_set_user_bpammo(idCSW_FIVESEVEN50); 
            
AidjaOarmaid ] = true
        } 
        case 
3
        { 
            
give_item(id"weapon_usp"); 
            
cs_set_user_bpammo(idCSW_USP50); 
            
AidjaOarmaid ] = true
        } 
    } 
    
menu_destroy (menu); 
    return 
PLUGIN_HANDLED



public 
plugin_precache() { 
    
precache_modelAk47Gold_v_Model 
    
precache_modelAk47Gold_p_Model 
    
precache_modelM4a1Gold_v_Model 
    
precache_modelM4a1Gold_p_Model 
    
precache_modelDeagleGold_v_Model 
    
precache_modelDeagleGold_p_Model 
    
precache_modelAwpGold_v_Model 
    
precache_modelAwpGold_p_Model 
    
precache_modelM249Gold_v_Model 
    
precache_modelM249Gold_p_Model 
     



public 
Event_CurWeaponid )  { 
    new 
Arma read_data
     
    if( 
Arma == CSW_AK47 && Ak47Goldid ] )  
    { 
        
set_pevidpev_viewmodel2Ak47Gold_v_Model 
        
set_pevidpev_weaponmodel2Ak47Gold_p_Model 
    } 
     
    if( 
Arma == CSW_M4A1 && M4a1Goldid ] )  
    { 
        
set_pevidpev_viewmodel2M4a1Gold_v_Model 
        
set_pevidpev_weaponmodel2M4a1Gold_p_Model 
    } 
     
    if( 
Arma == CSW_DEAGLE && DeagleGoldid ] )  
    { 
        
set_pevidpev_viewmodel2DeagleGold_v_Model 
        
set_pevidpev_weaponmodel2DeagleGold_p_Model 
    }
    
    if( 
Arma == CSW_AWP && AwpGoldid ] )  
    { 
        
set_pevidpev_viewmodel2AwpGold_v_Model 
        
set_pevidpev_weaponmodel2AwpGold_p_Model )
    
    if( 
Arma == CSW_M249 && M249Goldid ] )  
    { 
        
set_pevidpev_viewmodel2M249Gold_v_Model 
        
set_pevidpev_weaponmodel2M249Gold_p_Model )
    } 
}


public 
DamageVip iVictimiInflictoriAttackerFloat:fDamageiDamageBits )  { 
    if ( 
IsPlayer iAttacker ) ) { 
        if( 
iInflictor == iAttacker && Ak47Gold iAttacker ] && is_user_aliveiAttacker ) && get_user_weaponiAttacker ) == CSW_AK47 && get_user_teamiAttacker ) == ) { 
            
SetHamParamFloat4fDamage 2.0); 
            return 
HAM_HANDLED
        } 
    } 
     
    if ( 
IsPlayer iAttacker ) ) { 
         
        if( 
iInflictor == iAttacker && M4a1Gold iAttacker ] && is_user_aliveiAttacker ) && get_user_weaponiAttacker ) == CSW_M4A1 && get_user_teamiAttacker ) == ) { 
            
SetHamParamFloat4fDamage 2.0); 
            return 
HAM_HANDLED
        } 
    } 
     
    if ( 
IsPlayer iAttacker ) ) { 
         
        if( 
iInflictor == iAttacker && DeagleGold iAttacker ] && is_user_aliveiAttacker ) && get_user_weaponiAttacker ) == CSW_DEAGLE && get_user_teamiAttacker ) == ) { 
            
SetHamParamFloat4fDamage 2.0); 
            return 
HAM_HANDLED
        } 
    } 
     
    if ( 
IsPlayer iAttacker ) ) { 
         
        if( 
iInflictor == iAttacker && AwpGold iAttacker ] && is_user_aliveiAttacker ) && get_user_weaponiAttacker ) == CSW_AWP && get_user_teamiAttacker ) == ) { 
            
SetHamParamFloat4fDamage 2.0); 
            return 
HAM_HANDLED
        
    if ( 
IsPlayer iAttacker ) ) { 
         
        if( 
iInflictor == iAttacker && M249Gold iAttacker ] && is_user_aliveiAttacker ) && get_user_weaponiAttacker ) == CSW_M249 && get_user_teamiAttacker ) == ) { 
            
SetHamParamFloat4fDamage 2.0); 
            return 
HAM_HANDLED
        }
    }
    return 
PLUGIN_HANDLED
}

stock ChatColor(const id, const input[], any:...) { 
    new 
count 1players[32]; 
    static 
msg[191]; 
    
vformat(msg190input3); 
     
    
replace_all(msg190"!g""^4"); // Green Color 
    
replace_all(msg190"!n""^1"); // Default Color 
    
replace_all(msg190"!t""^3"); // Team Color 
    
replace_all(msg190"!t2""^0"); // Team2 Color 
     
    
if (idplayers[0] = id; else get_players(playerscount"ch"); { 
        for (new 
0counti++) { 
            if (
is_user_connected(players[i])) { 
                
message_begin(MSG_ONE_UNRELIABLEget_user_msgid("SayText"), _players[i]); 
                
write_byte(players[i]); 
                
write_string(msg); 
                
message_end(); 
            } 
        } 
    } 


Last edited by Bugsy; 02-10-2019 at 11:38.
Dragos is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 02-10-2019 , 08:16   Re: a lot of error
Reply With Quote #2

If you get an error, post the error. It's that simple.
__________________

Last edited by OciXCrom; 02-10-2019 at 08:16.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Dragos
Junior Member
Join Date: Oct 2018
Location: Romania
Old 02-10-2019 , 08:44   Re: a lot of error
Reply With Quote #3

nvm i fix
Dragos is offline
Reply


Thread Tools
Display Modes

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 15:58.


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