How to create a custom AntiBot
-
@NoobDev638
i dont fucking care if for-cycle is wrong or entityplayer getter is wrong smhboolean isBot; for(Entity o : mc.theWorld.getLoadedEntityList[o]) { final EntityPlayer retard = (EntityPlayer) o; if (retard.getInventory().getHeldItem().getItem() instanceof ItemSword) { isBot = true; } }
-
for (var i = 0; i < mc.theWorld.getLoadedEntityList().length; i++) { var ent = mc.theWorld.getLoadedEntityList()[i]; if (!(ent instanceof EntityPlayer)) continue; if (ent.getHeldItem() != null && ent.getHeldItem().getItem() instanceof cool item); //no more cool items bro thats illegal }
-
This post is deleted!
-
@idk-my-name said in How to create a custom AntiBot:
@aftery what retard did make ++ when ++ is -
-
@idk-my-name said in How to create a custom AntiBot:
@NoobDev638
i dont fucking care if for-cycle is wrong or entityplayer getter is wrong smhboolean isBot; for(Entity o : mc.theWorld.getLoadedEntityList[o]) { final EntityPlayer retard = (EntityPlayer) o; if (retard.getInventory().getHeldItem().getItem() instanceof ItemSword) { isBot = true; } }
Thank you for your answer!
But how do I make it so that the killaura is not attacking the player anymore?
I mean just because isBot is true for a player doesent mean he is flagged as a bot by the killaura and aimbot etc.
Also I'm european so sorry for the late answers but I was asleep. -
@noobdev638 The best way to prevent KillAura from attacking it is just by removing the entity from world. There are other ways, such as adding the target as a friend or somehow spamming KillAura.target to null or smth like that, those ways aren't ideal, at all.
-
@noobdev638 Smth like
if (isBot) { mc.theWorld.removeEntityFromWorld(retard); }
-
@czechhek @idk-my-name
Thank you for your suggestions!
Removing the entity from the world seems like a pretty good way to do it. -
why does everyone have such retarded ways to get entities bruhhhh, as most bots are player entities just do this (please don't use Object to get entities if not needed, because that's just not logical even tough it works)
for(EntityPlayer entity : mc.theWorld.playerEntities) { if(!(entity instanceof EntityPlayerSP)) { [C O D E] } }
-
@foreheadchan wdym
if(!(entity instanceof EntityPlayerSP))
for each (entity in mc.theWorld.playerEntities) print(entity); or for (i in mc.theWorld.playerEntities) print(mc.theWorld.playerEntities[i]); or mc.theWorld.playerEntities.forEach(function (entity) print(entity));
-
@foreheadchan oh yeah makes sense
entity != mc.thePlayer is straight-forwarder (tf is that word)