Black buying extra items in freeze Time
-
- Veteran Member
- Posts: 598
- Joined: 7 years ago
- Contact:
Black buying extra items in freeze Time
Hey I would like to block buying extra items in freeze time but only for zombies. Can someone help me?
This will block zombies from buying items while in the pre-release time (Frozen):
- #include <zombie_escape>
- new bool:g_bCanBuy
- public plugin_init()
- {
- register_plugin("Block Buy", "1.0", "Raheem")
- }
- public ze_zombie_appear()
- {
- g_bCanBuy = false;
- }
- public ze_zombie_release()
- {
- g_bCanBuy = true;
- }
- public ze_select_item_pre(id, itemid)
- {
- if (ze_is_user_zombie(id) && !g_bCanBuy)
- return ZE_ITEM_UNAVAILABLE
- return ZE_ITEM_AVAILABLE
- }
He who fails to plan is planning to fail
-
- Veteran Member
- Posts: 598
- Joined: 7 years ago
- Contact:
Create an account or sign in to join the discussion
You need to be a member in order to post a reply
Create an account
Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute
Sign in
Who is online
Users browsing this forum: Ahrefs [Bot] and 1 guest