Raised This Month: $130 Target: $400
 32% 

Special weapon (help)


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
alex123pavlov
Junior Member
Join Date: Jun 2018
Old 06-10-2018 , 00:40   Special weapon (help)
Reply With Quote #1

Hi how to make so when you select the menu were issued the weapon for himself?

How to do if a player in the hands of ak 47 then give him extra health?

Sorry for the bad English I used the translator.
Code:
#include <sourcemod>

public OnPluginStart()
{
	RegConsoleCmd("wepmen", wepmen);
}

public Action:wepmen(client, args)
{
	if (client > 0 && args < 1) ShowMyMenu(client);
	return Plugin_Handled;
}

public Action:wepmen(client, args)
{
	if (client > 0 && args < 1) ShowMyPanel(client);
	return Plugin_Handled;
}

ShowMyPanel(client)
{
	new Handle:panel = CreatePanel();
	SetPanelTitle(panel, "Животные:\n \n");
	DrawPanelItem(panel, "AK47");
	DrawPanelItem(panel, "Выход");
	SendPanelToClient(panel, client, Select_Panel, 0);
	CloseHandle(panel);
	ClientCommand(client, "playgamesound items/nvg_off.wav");
}

public Select_Panel(Handle:panel, MenuAction:action, client, option)
{
	if (action == MenuAction_Select)
	{
		PrintToChat(client, "%d", option);
		if (option < 2) ShowMyPanel(client);
	}
}

Last edited by alex123pavlov; 06-10-2018 at 01:20.
alex123pavlov is offline
mug1wara
Member
Join Date: Jun 2018
Location: Under my bed
Old 06-12-2018 , 06:04   Re: Special weapon (help)
Reply With Quote #2

I'm having a hard time understanding what you're trying to say. But let me get this right, you want so when a player selects the desired weapon, it will be given to the player? Also when selecting a AK-47, the player will be given extra health? If so, how much health?
__________________
I take private requests, add me on Steam
mug1wara is offline
alex123pavlov
Junior Member
Join Date: Jun 2018
Old 06-14-2018 , 02:47   Re: Special weapon (help)
Reply With Quote #3

Quote:
Originally Posted by mug1wara View Post
I'm having a hard time understanding what you're trying to say. But let me get this right, you want so when a player selects the desired weapon, it will be given to the player? Also when selecting a AK-47, the player will be given extra health? If so, how much health?
Yeah, right. 100 health
alex123pavlov is offline
Reply


Thread Tools
Display Modes

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


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