witam
jak zrobic takie wybieranie teamu jak na jb? Bo normalnie jest takie czarne okno. a jak zrobic takie male menu?
Menu:
Wybierz team
TT
CT
SPEC
Witamy w Nieoficjalnym polskim support'cie AMX Mod X, jak w większości społeczności internetowych musisz się zarejestrować aby móc odpowiadać lub zakładać nowe tematy, ale nie bój się to jest prosty proces w którym wymagamy minimalnych informacji.
|
Napisano 22.08.2013 09:39
witam
jak zrobic takie wybieranie teamu jak na jb? Bo normalnie jest takie czarne okno. a jak zrobic takie male menu?
Menu:
Wybierz team
TT
CT
SPEC
Napisano 23.09.2013 18:20
Jest to baaardzo stary kod + miał w sobie zamianę modeli, ale zobacz czy trybi
/* Plugin generated by AMXX-Studio */ #include <amxmodx> #include <amxmisc> #include <cstrike> #include <fun> #include <hamsandwich> #include <fakemeta_util> #include <engine> #define PLUGIN "Menu Teamow" #define VERSION "1.0" #define AUTHOR "AMXX" #define KeysMenu1 (1<<0)|(1<<1)|(1<<5)|(1<<9) // Keys: 1260 #define KeysMenu2 (1<<0)|(1<<1)|(1<<5) // Keys: 126 new g_msgid[33], g_hidemotd[33]; public plugin_init() { register_plugin(PLUGIN, VERSION, AUTHOR) register_message(get_user_msgid("ShowMenu"), "message_show_menu"); register_message(get_user_msgid("VGUIMenu"), "message_vgui_menu"); register_message(get_user_msgid("MOTD"), "message_motd"); register_menucmd(register_menuid("mainmenu"), KeysMenu1, "_menu_chooseteam") register_menucmd(register_menuid("mainmenu"), KeysMenu2, "_menu_chooseteam") register_clcmd("jointeam 1", "wybierz_tt") register_clcmd("jointeam 2", "wybierz_ct") register_clcmd("jointeam 5", "zmiana_auto_wybor") } public client_connect(id) g_hidemotd[id] = 1; public zmiana_auto_wybor(id){ return PLUGIN_HANDLED } public message_motd(MsgId, MsgDest, MsgEntity) { if(g_hidemotd[MsgEntity]) { if(get_msg_arg_int(1) == 1) { g_hidemotd[MsgEntity] = 0; return PLUGIN_HANDLED; } } return PLUGIN_CONTINUE; } public message_vgui_menu(msgid, dest, id) { if (get_msg_arg_int(1) != 2) return PLUGIN_CONTINUE g_msgid[id] = msgid menu_chooseteam(id) return PLUGIN_HANDLED; } public message_show_menu(msgid, dest, id) { static team_select[] = "#Team_Select" static menu_text_code[sizeof team_select] get_msg_arg_string(4, menu_text_code, sizeof menu_text_code - 1) if (!equal(menu_text_code, team_select)) { return PLUGIN_CONTINUE } g_msgid[id] = msgid menu_chooseteam(id) return PLUGIN_HANDLED } public menu_chooseteam(id) { if (is_user_connected(id)) { new text[512], len len += format(text[len], 511 - len, "\rWybierz team^n") len += format(text[len], 511 - len, "\r1. \wTerrorysci^n") len += format(text[len], 511 - len, "\r2. \wObroncy^n^n") len += format(text[len], 511 - len, "\r6. \wWidzowie^n^n") len += format(text[len], 511 - len, "^n\r0. \wWyjdz^n") show_menu(id, KeysMenu1, text, -1, "mainmenu") } } public _menu_chooseteam(id, key) { switch(key) { case 0: { wybierz_tt(id); } case 1: { wybierz_ct(id); } case 5: { engclient_cmd(id, "jointeam", "6") } case 9: { return PLUGIN_HANDLED; } } return PLUGIN_HANDLED; } public wybierz_tt(id) { new menu_msg = g_msgid[id]; new msg_blocke = get_msg_block(menu_msg) set_msg_block(menu_msg, BLOCK_SET) engclient_cmd(id, "jointeam", "1") set_msg_block(menu_msg, msg_blocke) new menu_msgid = g_msgid[id] new msg_block = get_msg_block(menu_msgid) set_msg_block(menu_msgid, BLOCK_SET) engclient_cmd(id, "joinclass", "1") set_msg_block(menu_msgid, msg_block) return PLUGIN_HANDLED; } public wybierz_ct(id) { new menu_msg = g_msgid[id]; new msg_blocke = get_msg_block(menu_msg) set_msg_block(menu_msg, BLOCK_SET) engclient_cmd(id, "jointeam", "2") set_msg_block(menu_msg, msg_blocke) new menu_msgid = g_msgid[id] new msg_block = get_msg_block(menu_msgid) set_msg_block(menu_msgid, BLOCK_SET) engclient_cmd(id, "joinclass", "1") set_msg_block(menu_msgid, msg_block) return PLUGIN_HANDLED; }
Napisano 24.09.2013 17:21
dobra. sprawdze. a co to wogóle robi?
Blokuje to czarne menu (to takie jakby cale okno) i wyswietla menu normlane?
Napisano 27.09.2013 20:18
Napisano 27.09.2013 21:30
Posiadam TBM (inaczej PTB), które działa dużo lepiej niż zwykłe PTB, nawet na modach z lvlami. Zainteresowany? Proszę bardzo
0 użytkowników, 0 gości, 0 anonimowych