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

menu help pls


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
ZaKaRiAMaGh
Junior Member
Join Date: Apr 2020
Location: Morocco
Old 07-23-2020 , 13:03   menu help pls
Reply With Quote #1

i guys

i need help , how to load a model djtable

i have a music menu Contains the following :
1.Music Menu (works)
2.Djtable [ON/OFF] (not working)
now i want when i m turning on this == load model
and when i m turning off == remove model
3.Stop Music (works)

when i open the cmd it doesnt work i dont know why

i was trying for week
for script contact me on my fb : https://www.facebook.com/zakaria.tendo/


i am so sorry about bad english language
ZaKaRiAMaGh is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 07-23-2020 , 13:46   Re: menu help pls
Reply With Quote #2

What model?! Where is your script?! If you want help, post your code here, otherwise search for help on Facebook.
__________________

Last edited by OciXCrom; 07-23-2020 at 13:46.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
ZaKaRiAMaGh
Junior Member
Join Date: Apr 2020
Location: Morocco
Old 07-23-2020 , 14:06   Re: menu help pls
Reply With Quote #3

this the script

model its djtable
i name it HBDJ on this script
the problem is in menu
option 2 [ON/OFF]

thanks

Last edited by ZaKaRiAMaGh; 07-23-2020 at 14:17.
ZaKaRiAMaGh is offline
Old 07-23-2020, 14:07
ZaKaRiAMaGh
This message has been deleted by ZaKaRiAMaGh. Reason: nothing
Old 07-23-2020, 14:12
ZaKaRiAMaGh
This message has been deleted by ZaKaRiAMaGh.
Old 07-23-2020, 14:19
ZaKaRiAMaGh
This message has been deleted by ZaKaRiAMaGh.
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 07-23-2020 , 16:47   Re: menu help pls
Reply With Quote #4

First put the code in proper [code] tags instead of [quote], then we can discuss things.
__________________

Last edited by OciXCrom; 07-23-2020 at 16:47.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
ZaKaRiAMaGh
Junior Member
Join Date: Apr 2020
Location: Morocco
Old 07-23-2020 , 17:11   Re: menu help pls
Reply With Quote #5

[QUOTE=OciXCrom;2711337]First put the code in proper [code] tags instead of
Quote:
, then we can discuss things.
i don't understand whatdo you mean

i dont know how to add a site to download the file

Last edited by ZaKaRiAMaGh; 07-23-2020 at 17:15.
ZaKaRiAMaGh is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 07-23-2020 , 18:17   Re: menu help pls
Reply With Quote #6

If you know how to put the code in [quote] tags, you know how to do the same with [cоde].

[cоde]insert code here[/code]
__________________

Last edited by OciXCrom; 07-23-2020 at 18:17.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Old 07-23-2020, 19:48
ZaKaRiAMaGh
This message has been deleted by ZaKaRiAMaGh. Reason: not working
ZaKaRiAMaGh
Junior Member
Join Date: Apr 2020
Location: Morocco
Old 07-23-2020 , 19:56   Re: menu help pls
Reply With Quote #7

Brother i new in this community
i dont know all things
thank you very much for your services
Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <hamsandwich>
#include <fakemeta>
#include <engine>
#include <fun>
#include <engine>
#include <xs>

#define PLUGIN "Menu Sounds"
#define VERSION "1.0"
#define AUTHOR "ReD [M]"
#define IsPlayer(%1)                    (1 <= %1 <= g_max_clients)

new smiya[64]
new const g_HBDJmdl[] = "models/HB-PrisonBreak/HBDJ.mdl"

new bool: dj_table = false

public plugin_init() {
	register_plugin(PLUGIN, VERSION, AUTHOR)
	
	register_concmd("playermusic","PlayerMusic")
	register_clcmd("playermusic","PlayerMusic")
	register_clcmd("say /effect","PlayerMusic")
	
	register_clcmd("say /mzika", "ShowMusicMenu");
	
}
public PlayerMusic(id)
{
	if(cs_get_user_team(id) == CS_TEAM_CT)
	{
         new menu = menu_create("\r[HB] \wMusic Menu [2]","MenuMusic")
         menu_additem(menu, "\wCoronaVirus Remix","1",0);
         menu_additem(menu, "\r69 GOOBA","2",0);
         menu_additem(menu, "\wBlack M [Frerot]","3",0);
         menu_additem(menu, "\rStromae [Alors On Danse]","4",0);
         menu_additem(menu, "\wSoolking [Melegim]","5",0);
         menu_additem(menu, "\rEdwardMaya [HAREM]","6",0);
	menu_additem(menu, "\wBabyshark Remix","7",0);
	menu_additem(menu, "\rMusic For Denis","8",0);
	menu_additem(menu, "\w","9",0);

         menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
         menu_display(id, menu, 0);
         return PLUGIN_HANDLED
	}
	else
	if(cs_get_user_team(id) == CS_TEAM_T)
	{
	ColorChat(id,"^4[HB]^1You are a Prisonner");
	}
	return PLUGIN_HANDLED
}
public MenuMusic(id, menu, item)
{
	new data[6], szName[64];
	new access, callback;
	menu_item_getinfo(menu, item, access, data,charsmax(data), szName,charsmax(szName), callback);
	new key = str_to_num(data);
	
	if(cs_get_user_team(id) == CS_TEAM_CT)
	{
	switch(key)
	{
		case 1:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/1.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[CoronaRemix]",smiya);
		}
		case 2:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/2.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[GOOBA]",smiya);
		}
		case 3:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/3.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[Frerot]",smiya);
		}
		case 4:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/4.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[Alors On Danse]",smiya);
		}
		case 5:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/5.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[Melegim]",smiya);
		}
		case 6:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/6.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[HAREM]",smiya);
		}
		case 7:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/7.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[Babyshark]",smiya);
		}
		case 8:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/8.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[Denis]",smiya);
		}
		case 9:
		{
		client_cmd( 0, "mp3 play ^"sound/HB-PrisonBreak/HB-Music2/9.mp3^"" );
		get_user_name(id,smiya,32)
		ColorChat(0,"^4[HB] ^1CT ^3[ %s ] ^1Playing Music ^4[Soon]",smiya);
		}
	   }
	  }
}
/*--------------------------------------------------------------------*/
public plugin_precache() 
{
  precache_sound("HB-PrisonBreak/HB-Music2/1.mp3")
  precache_sound("HB-PrisonBreak/HB-Music2/2.mp3")
  precache_sound("HB-PrisonBreak/HB-Music2/3.mp3")
  precache_sound("HB-PrisonBreak/HB-Music2/4.mp3")
  precache_sound("HB-PrisonBreak/HB-Music2/5.mp3")
  precache_sound("HB-PrisonBreak/HB-Music2/6.mp3")
  precache_sound("HB-PrisonBreak/HB-Music2/7.mp3")
  precache_sound("HB-PrisonBreak/HB-Music2/8.mp3")
  precache_sound("HB-PrisonBreak/HB-Music2/9.mp3")
  
  precache_model("models/HB-PrisonBreak/HBDJ.mdl")
  return PLUGIN_CONTINUE
}
/*--------------------------------------------------------------------*/
public ShowMusicMenu(id)
{
	new menu = menu_create("\rMusic Menu^n \yMenu By \rReD M ", "mh_gMenu");
	if(cs_get_user_team(id) == CS_TEAM_CT)
	{
	menu_additem(menu, "\wMusic Menu\r", "", 0);
	new szText[555 char]
	formatex(szText , charsmax(szText) , "Dj Table [ %s \w]", dj_table? "\yON" : "\rOff")
	menu_additem(menu, szText , "1" , 0)
	menu_additem(menu, "\rStop Music \r^n", "", 0); 

	menu_setprop(menu, MPROP_EXIT, MEXIT_ALL);
	menu_setprop(menu, MPROP_BACKNAME, "Back");
	menu_setprop(menu, MPROP_NEXTNAME, "Next");
	menu_setprop(menu, MPROP_EXITNAME, "Exit");
	menu_setprop(menu, MPROP_NOCOLORS, 1);

	menu_display(id, menu, 0);
	}
	return PLUGIN_HANDLED;
}

public mh_gMenu(id, menu, item)
{
	if(item == MENU_EXIT)
	{
		menu_cancel(id);
		return PLUGIN_HANDLED;
	}
	new command[6], name[64], access, callback;
	menu_item_getinfo(menu, item, access, command, sizeof command - 1, name, sizeof name - 1, callback);
	switch(item)
	{
		case 0: client_cmd(id, "say /effect");
		case 1 :
		{
			if(dj_table = false)
			{
			new origin[3]
			pev( id, pev_origin, origin )
			new ent = engfunc( EngFunc_CreateNamedEntity, engfunc(EngFunc_AllocString, "info_target" ) )
			entity_set_string(ent, EV_SZ_classname, "HBDJ")
			set_pev( ent, pev_origin, origin)
			engfunc( EngFunc_SetModel, ent, g_HBDJmdl )
			set_pev( ent, pev_framerate, 1.0)
			ColorChat( 0, "CT Deleted DJ Table" );
			}
			else if(dj_table != false)
			{
			new origin[3]
			pev( id, pev_origin, origin )
			new ent = engfunc( EngFunc_CreateNamedEntity, engfunc(EngFunc_AllocString, "info_target" ) )
			entity_set_string(ent, EV_SZ_classname, "HBDJ")
			set_pev( ent, pev_origin, origin)
			engfunc( EngFunc_SetModel, ent, g_HBDJmdl )
			set_pev( ent, pev_framerate, 1.0)		
			}

		}
		case 2: client_cmd(id,"mp3 stop;stopsound")
	}

	menu_destroy(menu);

	return PLUGIN_HANDLED;
}

/*----------------------------------------- Chat Color ----------------------------------------------------------*/
	
stock ColorChat(const id, const input[], any:...) {
	new count = 1, players[32];
	static msg[191];
	vformat(msg, 190, input, 3);
 
	replace_all(msg, 190, "!x04", "^4");
	replace_all(msg, 190, "!x01", "^1");
	replace_all(msg, 190, "!x03", "^3");
 
	if(id) players[0] = id;
	else get_players(players, count, "ch"); {
	for(new i = 0; i < count; i++) {
	if(is_user_connected(players[i])) {
	message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("SayText"), _, players[i]);
	write_byte(players[i]);
	write_string(msg);
	message_end();
	}
	}
	} 
}

Last edited by ZaKaRiAMaGh; 07-23-2020 at 19:58.
ZaKaRiAMaGh is offline
Reply



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 23:29.


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