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

[AUN SIN SOLUCION]Como puedo separar los items extras por zm y hm


  
 
 
Thread Tools Display Modes
Author Message
zlChileanFlylz
Member
Join Date: Feb 2013
Location: Chile e,e
Old 04-27-2013 , 09:24   [AUN SIN SOLUCION]Como puedo separar los items extras por zm y hm
#1

Como Dise El Titulo...

Algo Como Haci

Extra Items

1.Humanos
2.Zombies
__________________
My Steam
-------Proyect's-------
Zp Edit 20%
-----------------------
I Speak Spanish No English

Last edited by zlChileanFlylz; 04-27-2013 at 16:45.
zlChileanFlylz is offline
Kikeado
Member
Join Date: Apr 2013
Old 04-27-2013 , 12:02   Re: Como puedo separar los items extras por zm y hm
#2

HUMZ...

Code:
cs_get_user_team(id) == CS_TEAM_CT cs_get_user_team(id) == CS_TEAM_T
Kikeado is offline
MexPower
Veteran Member
Join Date: Nov 2012
Old 04-27-2013 , 12:18   Re: Como puedo separar los items extras por zm y hm
#3

Muestra el menu de tus items extras
__________________
Allied Modders En Español
MexPower is offline
zlChileanFlylz
Member
Join Date: Feb 2013
Location: Chile e,e
Old 04-27-2013 , 12:25   Re: Como puedo separar los items extras por zm y hm
#4

PHP Code:
// Extra Items Menu
show_menu_extras(id)
{
    static 
menu[400], lenitem
    len 
0
    
    
// Title
    
len += formatex(menu[len], sizeof menu len"\y%L [%L] \r[%d-%d]^n^n"id"MENU_EXTRA_TITLE"id, (g_zombie[id]) ? "CLASS_ZOMBIE" "CLASS_HUMAN"EXTRAS_STARTID+1min(EXTRAS_STARTID+7g_extraitem_i))
    
    
// 1-7. Item List
    
for (item EXTRAS_STARTIDitem min(EXTRAS_STARTID+7g_extraitem_i); item++)
    {
        
// Unavailable item
        
if ((g_zombie[id] && g_extraitem_team[item] == ZP_TEAM_HUMAN) || (!g_zombie[id] && g_extraitem_team[item] == ZP_TEAM_ZOMBIE) || (item == EXTRA_NVISION && !get_pcvar_num(cvar_extranvision)) || (item == EXTRA_ANTIDOTE && !get_pcvar_num(cvar_extraantidote)) || (item == EXTRA_MADNESS && !get_pcvar_num(cvar_extramadness))
        || (
item == EXTRA_INFBOMB && (!get_pcvar_num(cvar_extrainfbomb) || g_infbombcounter >= get_pcvar_num(cvar_infbomblimit))) || (item >= EXTRA_WEAPONS_STARTID && item <= EXTRAS_CUSTOM_STARTID-&& !get_pcvar_num(cvar_extraweapons)))
        {
            
// Check if it's one of the hardcoded items and set the correct caption
            
switch (item)
            {
                case 
EXTRA_NVISIONlen += formatex(menu[len], sizeof menu len"\d%d %L"item-EXTRAS_STARTID+1id"MENU_EXTRA1")
                case 
EXTRA_ANTIDOTElen += formatex(menu[len], sizeof menu len"\d%d. %L"item-EXTRAS_STARTID+1id"MENU_EXTRA2")
                case 
EXTRA_MADNESSlen += formatex(menu[len], sizeof menu len"\d%d. %L"item-EXTRAS_STARTID+1id"MENU_EXTRA3")
                case 
EXTRA_INFBOMBlen += formatex(menu[len], sizeof menu len"\d%d. %L"item-EXTRAS_STARTID+1id"MENU_EXTRA4")
                default: 
len += formatex(menu[len], sizeof menu len"\d%d. %s"item-EXTRAS_STARTID+1g_extraitem_name[item])
            }
            
// Item Cost
            
len += formatex(menu[len], sizeof menu len" %d %L^n"g_extraitem_cost[item], id"AMMO_PACKS2")
        }
        else
        {
            
// Check if it's one of the hardcoded items and set the correct caption
            
switch (item)
            {
                case 
EXTRA_NVISIONlen += formatex(menu[len], sizeof menu len"\r%d.\w %L"item-EXTRAS_STARTID+1id"MENU_EXTRA1")
                case 
EXTRA_ANTIDOTElen += formatex(menu[len], sizeof menu len"\r%d.\w %L"item-EXTRAS_STARTID+1id"MENU_EXTRA2")
                case 
EXTRA_MADNESSlen += formatex(menu[len], sizeof menu len"\r%d.\w %L"item-EXTRAS_STARTID+1id"MENU_EXTRA3")
                case 
EXTRA_INFBOMBlen += formatex(menu[len], sizeof menu len"\r%d.\w %L"item-EXTRAS_STARTID+1id"MENU_EXTRA4")
                default: 
len += formatex(menu[len], sizeof menu len"\r%d.\w %s"item-EXTRAS_STARTID+1g_extraitem_name[item])
            }
            
// Item Cost
            
len += formatex(menu[len], sizeof menu len" \y%d %L^n"g_extraitem_cost[item], id"AMMO_PACKS2")
        }
    }
    
    
// 8. Back - 9. Next - 0. Exit
    
len += formatex(menu[len], sizeof menu len"^n\r8.\w %L^n\r9.\w %L^n^n\r0.\w %L"id"MENU_BACK"id"MENU_NEXT"id"MENU_EXIT")
    
    
show_menu(idKEYSMENUmenu, -1"Extra Items")

El Otro
PHP Code:
// Extra Items Menu
public menu_extras(idkey)
{
    
// Nemesis or Survivor shouldnt get extra items
    
if (g_survivor[id] || g_nemesis[id] || !is_user_alive(id))
    {
        
zp_colored_print(id"^x04[ZP]^x01 %L"id"CMD_NOT")
        return 
PLUGIN_HANDLED;
    }
    
    
// Special keys / items list exceeded
    
if (key >= MENU_KEY_BACK || EXTRAS_SELECTION >= g_extraitem_i)
    {
        switch (
key)
        {
            case 
MENU_KEY_BACK// back
            
{
                if (
EXTRAS_STARTID->= 0EXTRAS_STARTID -= 7
            
}
            case 
MENU_KEY_NEXT// next
            
{
                if (
EXTRAS_STARTID+g_extraitem_iEXTRAS_STARTID += 7
            
}
            case 
MENU_KEY_EXIT// exit
            
{
                return 
PLUGIN_HANDLED;
            }
        }
        
        
// Show extra items menu again
        
show_menu_extras(id)
        return 
PLUGIN_HANDLED;
    }
    
    
// Try to buy the item
    
buy_extra_item(idEXTRAS_SELECTION);
    
    return 
PLUGIN_HANDLED;

__________________
My Steam
-------Proyect's-------
Zp Edit 20%
-----------------------
I Speak Spanish No English

Last edited by zlChileanFlylz; 04-27-2013 at 12:27.
zlChileanFlylz is offline
Matians
Veteran Member
Join Date: Nov 2010
Location: ME QUIEREN ROBAR
Old 04-27-2013 , 20:41   Re: [AUN SIN SOLUCION]Como puedo separar los items extras por zm y hm
#5

Vos queres que el primer botón diga.

Item extra [Humanos] Y si lo tocas diga Item extra [Zombies]?
Matians is offline
TimooCS
Veteran Member
Join Date: Dec 2012
Location: Argentina
Old 04-28-2013 , 02:31   Re: [AUN SIN SOLUCION]Como puedo separar los items extras por zm y hm
#6

seria mejor chekear que si es zombie le aparesca los de zombies y si es humanos los de humanos, no es mejor?
__________________
TimooCS is offline
Send a message via MSN to TimooCS Send a message via Skype™ to TimooCS
baneado
Veteran Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 04-28-2013 , 04:59   Re: [AUN SIN SOLUCION]Como puedo separar los items extras por zm y hm
#7

en el zp 4.3 al darle al menú de items extra si eres humano te salen los de humano y si eres zombie los de zombie

edit: y me olvidé que también puedes poner items extra para nemesis y survivor

Last edited by baneado; 04-28-2013 at 05:00.
baneado is offline
zlChileanFlylz
Member
Join Date: Feb 2013
Location: Chile e,e
Old 04-28-2013 , 09:30   Re: [AUN SIN SOLUCION]Como puedo separar los items extras por zm y hm
#8

Quote:
Originally Posted by Matians View Post
Vos queres que el primer botón diga.

Item extra [Humanos] Y si lo tocas diga Item extra [Zombies]?
Si.
__________________
My Steam
-------Proyect's-------
Zp Edit 20%
-----------------------
I Speak Spanish No English
zlChileanFlylz is offline
TimooCS
Veteran Member
Join Date: Dec 2012
Location: Argentina
Old 04-28-2013 , 15:30   Re: [AUN SIN SOLUCION]Como puedo separar los items extras por zm y hm
#9

Quote:
Originally Posted by baneado View Post
en el zp 4.3 al darle al menú de items extra si eres humano te salen los de humano y si eres zombie los de zombie

edit: y me olvidé que también puedes poner items extra para nemesis y survivor
Gracias ahor me fijo
__________________
TimooCS is offline
Send a message via MSN to TimooCS Send a message via Skype™ to TimooCS
MexPower
Veteran Member
Join Date: Nov 2012
Old 04-28-2013 , 16:37   Re: [AUN SIN SOLUCION]Como puedo separar los items extras por zm y hm
#10

Quote:
Originally Posted by TimooCS View Post
Gracias ahor me fijo
Lol, doble cuenta?
__________________
Allied Modders En Español
MexPower is offline
 



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 11:04.


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