AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Suggestions / Requests (https://forums.alliedmods.net/forumdisplay.php?f=12)
-   -   [REQ][CS 1.6] Vip Menu (https://forums.alliedmods.net/showthread.php?t=302644)

Sunra 11-05-2017 13:39

[REQ][CS 1.6] Vip Menu
 
the plugin Will Start after 0 rounds and it looks like that With Access


Vip Menu
Awp - Vip Only - Others Will See it Grey And Cant Press It
Ak47 - VIp Only
M4A1 - Anyone
Deagle - Anyone

Relaxing 11-05-2017 14:14

Re: [REQ][CS 1.6] Vip Menu
 
Code:
#include <amxmodx> #include <cstrike> #include <fun> #include <hamsandwich> #define int new int bool:has_acces[33]; public plugin_init()     RegisterHam(Ham_Spawn, "player", "calledSpawn", 1); public calledSpawn(id){     if(is_user_alive(id))         set_task(2.0, "calledTask"); } public calledTask(id){     int menu = menu_create("Weapon Menu", "handler");     int szOption[32], szOption2[32];     if(get_user_flags(id) & ADMIN_LEVEL_H){         formatex(szOption, charsmax(szOption), "AWP");         formatex(szOption2, charsmax(szOption2), "AK47");         has_acces[id] = true;     }     else {         formatex(szOption, charsmax(szOption), "\dAWP - Only VIP");         formatex(szOption2, charsmax(szOption2), "\dAK47 - Only VIP");         has_acces[id] = false;     }     menu_additem(menu, szOption);     menu_additem(menu, szOption2);     menu_additem(menu, "M4A1");     menu_additem(menu, "DEAGLE");     menu_setprop(menu, MPROP_EXIT, MEXIT_ALL);     menu_display(id, menu); } public handler(id, menu, item){     if(item == MENU_EXIT){         menu_destroy(menu);         return 1;     }     switch(item){         case 0: {             if(has_acces[id]){                 give_item(id, "weapon_awp");                 cs_set_user_bpammo(id, CSW_AWP, 30);             }             else {                 client_print(id, print_chat, "VIP Only");             }         }         case 1: {             if(has_acces[id]){                 give_item(id, "weapon_ak47");                 cs_set_user_bpammo(id, CSW_AK47, 90);             }             else {                 client_print(id, print_chat, "VIP Only");             }         }         case 2: {             give_item(id, "weapon_m4a1");             cs_set_user_bpammo(id, CSW_M4A1, 90);         }         case 3: {             give_item(id, "weapon_deagle");             cs_set_user_bpammo(id, CSW_DEAGLE, 30);         }     }     return 0; }

Sunra 11-05-2017 15:01

Re: [REQ][CS 1.6] Vip Menu
 
Look I Tried To Do It With Pictures

http://doctorsatla.ddns.net/upload/r...Access%20T.png
http://doctorsatla.ddns.net/upload/r...o%20Access.png

Relaxing 11-05-2017 16:37

Re: [REQ][CS 1.6] Vip Menu
 
Code above edited.

Sunra 11-10-2017 10:51

Re: [REQ][CS 1.6] Vip Menu
 
Quote:

Originally Posted by Relaxing (Post 2558795)
Code above edited.

Crashing The Server

Ayman Khaled 11-10-2017 13:54

Re: [REQ][CS 1.6] Vip Menu
 
Quote:

Originally Posted by Relaxing (Post 2558757)
Code:
#include <amxmodx> #include <cstrike> #include <fun> #include <hamsandwich> #define int new int bool:has_acces[33]; public plugin_init()     RegisterHam(Ham_Spawn, "player", "calledSpawn", 1); public calledSpawn(id){     if(is_user_alive(id))         set_task(2.0, "calledTask"); } public calledTask(id){     int menu = menu_create("Weapon Menu", "handler");     int szOption[32], szOption2[32];     if(get_user_flags(id) & ADMIN_LEVEL_H){         formatex(szOption, charsmax(szOption), "AWP");         formatex(szOption2, charsmax(szOption2), "AK47");         has_acces[id] = true;     }     else {         formatex(szOption, charsmax(szOption), "\dAWP - Only VIP");         formatex(szOption2, charsmax(szOption2), "\dAK47 - Only VIP");         has_acces[id] = false;     }     menu_additem(menu, szOption);     menu_additem(menu, szOption2);     menu_additem(menu, "M4A1");     menu_additem(menu, "DEAGLE");     menu_setprop(menu, MPROP_EXIT, MEXIT_ALL);     menu_display(id, menu); } public handler(id, menu, item){     if(item == MENU_EXIT){         menu_destroy(menu);         return 1;     }     switch(item){         case 0: {             if(has_acces[id]){                 give_item(id, "weapon_awp");                 cs_set_user_bpammo(id, CSW_AWP, 30);             }             else {                 client_print(id, print_chat, "VIP Only");             }         }         case 1: {             if(has_acces[id]){                 give_item(id, "weapon_ak47");                 cs_set_user_bpammo(id, CSW_AK47, 90);             }             else {                 client_print(id, print_chat, "VIP Only");             }         }         case 2: {             give_item(id, "weapon_m4a1");             cs_set_user_bpammo(id, CSW_M4A1, 90);         }         case 3: {             give_item(id, "weapon_deagle");             cs_set_user_bpammo(id, CSW_DEAGLE, 30);         }     }     return 0; }

what is the point from this?
PHP Code:

#define int new 


DjSoftero 11-10-2017 14:16

Re: [REQ][CS 1.6] Vip Menu
 
Quote:

Originally Posted by Ayman Khaled (Post 2559617)
what is the point from this?
PHP Code:

#define int new 


it`s probably because he is used to c++ or something else and always mistypes int for new.
when i`m at school. i always type new, and it`s an annoying habit of mine

Sunra 11-10-2017 15:11

Re: [REQ][CS 1.6] Vip Menu
 
Quote:

Originally Posted by Ayman Khaled (Post 2559617)
what is the point from this?
PHP Code:

#define int new 


Hey All I Appreciate All Your Help But I Found The Mod
http://i.imgur.com/eNIIh0D.png
https://files.gamebanana.com/img/ss/...046dbaf6b6.jpg


All times are GMT -4. The time now is 09:59.

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