Raised This Month: $ Target: $400
 0% 

Exclude ladders from Entity Map Control


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Moonrider
New Member
Join Date: Oct 2021
Old 10-24-2021 , 06:55   Exclude ladders from Entity Map Control
Reply With Quote #1

Hello! I am using this plugin to remove some of the entities in maps.
However, this plugin removes the ladders models too. Is it possible to exclude the ladders from the plugin and leave them in maps?

Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <fakemeta>
#include <engine>

#define PLUGIN ""
#define VERSION "0.0.1"
#define AUTHOR "SpeeDeeR@amxmodxbg"

new const skipp[][] = {
	"info_player_deathmatch",
	"info_player_start",
	"BCM_ServerFrame",
	"BCM_Hud"
};

public plugin_init() {
	register_plugin(PLUGIN, VERSION, AUTHOR)
	
	new classname[32];
	
	new bool: skip;
	
	new count = 0;
	
	static victim =-1
	while((victim = engfunc(EngFunc_FindEntityInSphere, victim, Float:{0.0, 0.0, 0.0}, 10000.0))) 
	{
		pev(victim, pev_classname, classname, charsmax(classname));
		
		for(new i=0;i<sizeof(skipp);i++) {
			if(equal(skipp[i],classname))  {
				skip = true;
				break;
			}
		}
		
		if(!skip) {
			remove_entity(victim);
			
			count++;
		}
		
		skip = false;
	} 
	
	server_print("%d entities cleared!", count);
}
Thanks in advance!
Moonrider is offline
 



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 11:36.


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