Raised This Month: $ Target: $400
 0% 

[ZP] Añadiendo Opción para mandar mod armagedon desde adminmenu(solucionado)


  
 
 
Thread Tools Display Modes
Author Message
SkiGz
BANNED
Join Date: Aug 2010
Location: Venezuela
Old 02-05-2011 , 12:29   [ZP] Añadiendo Opción para mandar mod armagedon desde adminmenu(solucionado)
#1

hola bueno tengo un problema quise añadir la opcion de mandar mod armagedon en el menu del admin abajo de start plague mod ej:

Code:
5. Start Mod Swarm
6. Start Multi Infection
7. Start Plague Mod
8. Start Mod Armagedon <----


Intenté este metodo

PHP Code:
// Admin Menu
show_menu_admin(id)
{
    static 
menu[250], len
    len 
0
    
    
// Title
    
len += formatex(menu[len], sizeof menu len"\r%L^n^n"id"MENU_ADMIN_TITLE")
    
    
// 1. Zombiefy/Humanize command
    
if (!g_endround && !g_swarmround && !g_nemround && !g_survround && !g_plagueround && !task_exists(TASK_WELCOMEMSG))
        
len += formatex(menu[len], sizeof menu len"\r1.\y %L^n"id"MENU_ADMIN1")
    else
        
len += formatex(menu[len], sizeof menu len"\r1. %L^n"id"MENU_ADMIN1")
    
    
// 2. Nemesis command
    
if (g_newround && !g_endround && get_pcvar_num(cvar_nem) && !task_exists(TASK_WELCOMEMSG))
        
len += formatex(menu[len], sizeof menu len"\r2.\y %L^n"id"MENU_ADMIN2")
    else
        
len += formatex(menu[len], sizeof menu len"\r2. %L^n"id"MENU_ADMIN2")
    
    
// 3. Survivor command
    
if (g_newround && !g_endround && get_pcvar_num(cvar_surv) && !task_exists(TASK_WELCOMEMSG))
        
len += formatex(menu[len], sizeof menu len"\r3.\y %L^n"id"MENU_ADMIN3")
    else
        
len += formatex(menu[len], sizeof menu len"\r3. %L^n"id"MENU_ADMIN3")
    
    
// 4. Respawn command
    
if (!g_endround && !g_survround && !g_swarmround && !g_nemround && !g_plagueround)
        
len += formatex(menu[len], sizeof menu len"\r4.\y %L^n"id"MENU_ADMIN4")
    else
        
len += formatex(menu[len], sizeof menu len"\r4. %L^n"id"MENU_ADMIN4")
    
    
// 5. Swarm mode command
    
if (allowed_swarm())
        
len += formatex(menu[len], sizeof menu len"\r5.\y %L^n"id"MENU_ADMIN5")
    else
        
len += formatex(menu[len], sizeof menu len"\r5. %L^n"id"MENU_ADMIN5")
    
    
// 6. Multi infection command
    
if (allowed_multi())
        
len += formatex(menu[len], sizeof menu len"\r6.\y %L^n"id"MENU_ADMIN6")
    else
        
len += formatex(menu[len], sizeof menu len"\r6. %L^n"id"MENU_ADMIN6")
    
    
// 7. Plague mode command
    
if (allowed_plague())
        
len += formatex(menu[len], sizeof menu len"\r7.\y %L^n"id"MENU_ADMIN7")
    else
        
len += formatex(menu[len], sizeof menu len"\r7. %L^n"id"MENU_ADMIN7")
    
    
// 8. Armagedon mode command
    
if (allowed_armagedon())
        
len += formatex(menu[len], sizeof menu len"\r8.\y %L^n"id"MENU_ADMIN8")
    else
        
len += formatex(menu[len], sizeof menu len"\r8. %L^n"id"MENU_ADMIN8")
    
    
// 0. Exit
    
len += formatex(menu[len], sizeof menu len"^n\r0.\y %L"id"MENU_EXIT")
    
    
show_menu(idKEYSMENUmenu, -1"Admin Menu")

pero al compilar salta un error

PHP Code:
if (allowed_armagedon()) // en esta linea salta el error 


Code:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Error: Undefined symbol "allowed_lnj" on line 2906

1 Error.
anteriormente seguí otro metodo pero tampoco funcionó!!! desde ya gracias

Last edited by SkiGz; 02-05-2011 at 14:39.
SkiGz is offline
Send a message via MSN to SkiGz
Calaverazo
Senior Member
Join Date: Dec 2009
Old 02-05-2011 , 12:59   Re: [ES][ZP] Añadiendo Opción para mandar mod armagedon desde adminmenu
#2

Porque no definiste allowed_armagedon() y allowed_lnj()
Calaverazo is offline
SkiGz
BANNED
Join Date: Aug 2010
Location: Venezuela
Old 02-05-2011 , 14:36   Re: [ES][ZP] Añadiendo Opción para mandar mod armagedon desde adminmenu(solucionado)
#3

Quote:
Originally Posted by Calaverazo View Post
Porque no definiste allowed_armagedon() y allowed_lnj()

allowed_lnj lo tome como ejemplo - allowed_armagedon() ya lo solucioné gracias !!!

Code:
// 8. Armagedon mode command     if (allowed_armagedon())         len += formatex(menu[len], sizeof menu - 1 - len, "\r8.\y %L^n", id, "MENU_ADMIN8")     else         len += formatex(menu[len], sizeof menu - 1 - len, "\r8. %L^n", id, "MENU_ADMIN8")         // 0. Exit     len += formatex(menu[len], sizeof menu - 1 - len, "^n\r0.\y %L", id, "MENU_EXIT")         show_menu(id, KEYSMENU, menu, -1, "Admin Menu") }

Last edited by SkiGz; 02-06-2011 at 11:07.
SkiGz is offline
Send a message via MSN to SkiGz
 



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 07:37.


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