Raised This Month: $30 Target: $400
 7% 

Suggestion / Subplugin Request Checking if zombies has weapons and remove them


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Gamewar
Junior Member
Join Date: Mar 2020
Location: Somewhere
Old 01-11-2022 , 16:09   Checking if zombies has weapons and remove them
Reply With Quote #1

Hello again
I wanted to Request for plugin which reads Zombie weapon set and if it finds any guns then it removes it


I had that problem when putting custom buymenu. I guess podbot buys weapons right in the first frame when turning into zombies..


weird but when turned into human... another bot grabs weapon



Anyway I guess my request is easy to understand
Gamewar is offline
zXCaptainXz
Member
Join Date: May 2017
Old 01-12-2022 , 00:16   Re: Checking if zombies has weapons and remove them
Reply With Quote #2

Can you send your custom buy menu .sma here please?
zXCaptainXz is offline
Gamewar
Junior Member
Join Date: Mar 2020
Location: Somewhere
Old 01-12-2022 , 01:15   Re: Checking if zombies has weapons and remove them
Reply With Quote #3

Quote:
Originally Posted by zXCaptainXz View Post
Can you send your custom buy menu .sma here please?
Yea sure. I already gonna warn that its not mine but some random Russia what is also reading stuff from ini


Also you need use these 2 plugins together to make ini file work
Attached Files
File Type: sma Get Plugin or Get Source (zp_buymenu.sma - 21 views - 37.8 KB)
File Type: sma Get Plugin or Get Source (zp_buymenu_all.sma - 26 views - 5.5 KB)
Gamewar is offline
zXCaptainXz
Member
Join Date: May 2017
Old 01-12-2022 , 05:13   Re: Checking if zombies has weapons and remove them
Reply With Quote #4

i'm not really sure what's going on, if you're saying that zombies are picking up weapons from the ground, then ZP43 should prevent them by default, so in-case you modified something there, add this plugin and it should prevent zombies from picking weapons up

Code:
#include <amxmodx>
#include <hamsandwich>
#include <zombieplague>

public plugin_init()
{
	register_plugin("[ZP] Prevent Zombie Weapon","1.0","ZP Team")
	RegisterHam(Ham_Touch, "weaponbox", "fw_TouchWeapon")
	RegisterHam(Ham_Touch, "armoury_entity", "fw_TouchWeapon")
	RegisterHam(Ham_Touch, "weapon_shield", "fw_TouchWeapon")
}

// Ham Weapon Touch Forward
public fw_TouchWeapon(weapon, id)
{
	// Not a player
	if (!is_user_connected(id))
		return HAM_IGNORED;
	
	// Dont pickup weapons if zombie or survivor (+PODBot MM fix)
	if (zp_get_user_zombie(id) || (zp_get_user_survivor(id) && !is_user_bot(id)))
		return HAM_SUPERCEDE;
	
	return HAM_IGNORED;
}
zXCaptainXz is offline
Gamewar
Junior Member
Join Date: Mar 2020
Location: Somewhere
Old 01-12-2022 , 12:13   Re: Checking if zombies has weapons and remove them
Reply With Quote #5

Quote:
Originally Posted by zXCaptainXz View Post
i'm not really sure what's going on, if you're saying that zombies are picking up weapons from the ground, then ZP43 should prevent them by default, so in-case you modified something there, add this plugin and it should prevent zombies from picking weapons up

Code:
#include <amxmodx>
#include <hamsandwich>
#include <zombieplague>

public plugin_init()
{
	register_plugin("[ZP] Prevent Zombie Weapon","1.0","ZP Team")
	RegisterHam(Ham_Touch, "weaponbox", "fw_TouchWeapon")
	RegisterHam(Ham_Touch, "armoury_entity", "fw_TouchWeapon")
	RegisterHam(Ham_Touch, "weapon_shield", "fw_TouchWeapon")
}

// Ham Weapon Touch Forward
public fw_TouchWeapon(weapon, id)
{
	// Not a player
	if (!is_user_connected(id))
		return HAM_IGNORED;
	
	// Dont pickup weapons if zombie or survivor (+PODBot MM fix)
	if (zp_get_user_zombie(id) || (zp_get_user_survivor(id) && !is_user_bot(id)))
		return HAM_SUPERCEDE;
	
	return HAM_IGNORED;
}
Yea it fixed all problems what I had

yea I eddited the ZP43 file but only for changing menu commands like "say /knife" when menu 2 is pressed and etc

Also all the problems happened when I imported the buymenu so thats why I Was making that lot of requests. The "CSO themed" was one of the problems that didn't worked and then this weird stuff with bots

Its actually really weird how its happening.. SOmetimes its happening 1 out of 10 rounds but sometimes in most of the rounds and it also depends on gun addons. I had 2 weapon addons (1 still have) which made them grapping weapon like each round..sometimes when they infect they didn't dropped the weapon which also seems weird

anyway the problem is fixed
Gamewar 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 03:46.


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