Approved Zombie classes

Gameplay Addons
User avatar
DarkZombie
Member
Member
Hungary
Posts: 69
Joined: 11 Months Ago
Has thanked: 16 times
Been thanked: 0
Contact:

Re: Zombie classes

#21

Post by DarkZombie » 8 Months Ago

Jack GamePlay wrote:
8 Months Ago
DarkZombie wrote:
8 Months Ago
ze_zombie_class.sma can not be converted to amxx, this is the error: (image)
Make a new file called "zombie_class_const.inc" & put in it the code in the first post.
Thanks its works now.
In the main menu to appear, what to do?
And in Zombie Class menu the exit button (0) write ML NOTFOUND ZEXIT.

User avatar
DarkZombie
Member
Member
Hungary
Posts: 69
Joined: 11 Months Ago
Has thanked: 16 times
Been thanked: 0
Contact:

#22

Post by DarkZombie » 8 Months Ago

image
Attachments
hl 2018-11-05 22-01-25-38.jpg

User avatar
Jack GamePlay
Mod Developer
Mod Developer
Egypt
Posts: 576
Joined: 2 Years Ago
Location: Egypt
Has thanked: 34 times
Been thanked: 47 times
Age: 19
Contact:

#23

Post by Jack GamePlay » 8 Months Ago

DarkZombie wrote:
8 Months Ago
Thanks its works now.
In the main menu to appear, what to do?
And in Zombie Class menu the exit button (0) write ML NOTFOUND ZEXIT.
Updated the ze_zombie_class.sma's code, recompile it.
These users thanked the author Jack GamePlay for the post:
DarkZombie (8 Months Ago)
Not interested in CS/Pawn anymore.
Accepting web projects.

User avatar
DarkZombie
Member
Member
Hungary
Posts: 69
Joined: 11 Months Ago
Has thanked: 16 times
Been thanked: 0
Contact:

#24

Post by DarkZombie » 8 Months Ago

Jack GamePlay wrote:
8 Months Ago
DarkZombie wrote:
8 Months Ago
Thanks its works now.
In the main menu to appear, what to do?
And in Zombie Class menu the exit button (0) write ML NOTFOUND ZEXIT.
Updated the ze_zombie_class.sma's code, recompile it.
Done, its works, thank you.
The other question: In the main menu to appear, what to do? Like when i press "m" and i will see the Zombie Classes menu.

User avatar
Jack GamePlay
Mod Developer
Mod Developer
Egypt
Posts: 576
Joined: 2 Years Ago
Location: Egypt
Has thanked: 34 times
Been thanked: 47 times
Age: 19
Contact:

#25

Post by Jack GamePlay » 8 Months Ago

DarkZombie wrote:
8 Months Ago
Done, its works, thank you.
The other question: In the main menu to appear, what to do? Like when i press "m" and i will see the Zombie Classes menu.
I don't understand.
Not interested in CS/Pawn anymore.
Accepting web projects.

User avatar
DarkZombie
Member
Member
Hungary
Posts: 69
Joined: 11 Months Ago
Has thanked: 16 times
Been thanked: 0
Contact:

#26

Post by DarkZombie » 8 Months Ago

The [ZE] Main Menu list, included. Such as knife menu, weapons, etc. 4.th is Zombie Classes
Attachments
hl 2018-11-07 16-04-21-77.jpg

User avatar
DarkZombie
Member
Member
Hungary
Posts: 69
Joined: 11 Months Ago
Has thanked: 16 times
Been thanked: 0
Contact:

#27

Post by DarkZombie » 8 Months Ago

so?

User avatar
DarkZombie
Member
Member
Hungary
Posts: 69
Joined: 11 Months Ago
Has thanked: 16 times
Been thanked: 0
Contact:

#28

Post by DarkZombie » 8 Months Ago

Something about it, Jack?

User avatar
Jack GamePlay
Mod Developer
Mod Developer
Egypt
Posts: 576
Joined: 2 Years Ago
Location: Egypt
Has thanked: 34 times
Been thanked: 47 times
Age: 19
Contact:

#29

Post by Jack GamePlay » 8 Months Ago

DarkZombie wrote:
8 Months Ago
Something about it, Jack?
Give your main menu code.
Not interested in CS/Pawn anymore.
Accepting web projects.

User avatar
DarkZombie
Member
Member
Hungary
Posts: 69
Joined: 11 Months Ago
Has thanked: 16 times
Been thanked: 0
Contact:

#30

Post by DarkZombie » 8 Months Ago

Here it is:

Code: Select all

#include <zombie_escape>

native ze_open_knife_menu(id)

// Keys
const OFFSET_CSMENUCODE = 205
const KEYSMENU = MENU_KEY_1|MENU_KEY_2|MENU_KEY_3|MENU_KEY_4|MENU_KEY_5|MENU_KEY_6|MENU_KEY_7|MENU_KEY_8|MENU_KEY_9|MENU_KEY_0

public plugin_init()
{
	register_plugin("[ZE] Main Menu", ZE_VERSION, AUTHORS)
	
	// Commands
	register_clcmd("chooseteam", "Cmd_ChooseTeam")
	register_clcmd("say /ze", "Cmd_ChooseTeam")
	register_clcmd("say_team /ze", "Cmd_ChooseTeam")
	
	// Register Menus
	register_menu("Main Menu", KEYSMENU, "Main_Menu")
}

public Cmd_ChooseTeam(id)
{
	if (!is_user_connected(id))
		return PLUGIN_CONTINUE;
	
	if (get_member(id, m_iTeam) == TEAM_TERRORIST || get_member(id, m_iTeam) == TEAM_CT)
	{
		Show_Menu_Main(id)
		return PLUGIN_HANDLED // Kill the Choose Team Command
	}
	
	// Player in Spec? Allow him to open choose team menu so he can join
	return PLUGIN_CONTINUE
}

// Main Menu
public Show_Menu_Main(id)
{
	static szMenu[250]
	new iLen
    
	// Title
	iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\w%L^n^n", id, "MAIN_MENU_TITLE")
	
	// 1. Buy Weapons
	if (!ze_is_auto_buy_enabled(id)) // AutoBuy not enabled - normal case
	{
		if (is_user_alive(id))
		{
			iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\w1.\r %L^n", id, "MENU_WEAPONBUY")
		}
		else
		{
			iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d1. %L^n", id, "MENU_WEAPONBUY")
		}
	}
	else
	{
		// Auto-Buy enabled - Re-enable case
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\w1.\r %L^n", id, "MENU_WEAPONBUY_RE_ENABLE")
	}
	
	// 2. Extra Items
	if (is_user_alive(id))
	{
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\w2.\r %L^n", id, "MENU_EXTRABUY")
	}
	else
	{
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d2. %L^n", id, "MENU_EXTRABUY")
	}
	
	// 3. Knife menu
	if (is_user_alive(id))
	{
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\w3.\r Knife menu^n")
	}
	else
	{
		iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "\d3. Knife menu^n")
	}
    
	// 0. Exit
	iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen, "^n^n\w0.\r %L", id, "EXIT")
    
	// Fix for AMXX custom menus
	set_pdata_int(id, OFFSET_CSMENUCODE, 0)
	show_menu(id, KEYSMENU, szMenu, -1, "Main Menu")
}

// Main Menu
public Main_Menu(id, key)
{
	// Player disconnected?
	if (!is_user_connected(id))
		return PLUGIN_HANDLED
    
	switch (key)
	{
		case 0: // Buy Weapons
		{
			if (!ze_is_auto_buy_enabled(id))
			{
				ze_show_weapon_menu(id)
			}
			else
			{
				ze_disable_auto_buy(id)
				Show_Menu_Main(id)
			}
		}
		case 1: // Extra Items
		{
			if (is_user_alive(id))
			{
				ze_show_items_menu(id)
			}
			else
			{
				ze_colored_print(id, "%L", id, "DEAD_CANT_BUY_WEAPON")
			}
		}
		case 2: // Knife menu
		{
			if (is_user_alive(id))
			{
				ze_open_knife_menu(id)
			}
			else
			{
				ze_colored_print(id, "%L", id, "DEAD_CANT_BUY_WEAPON")
			}
		}
	}
	return PLUGIN_HANDLED
}

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests