HelpAnit-Invisibility

Posts 1–3 of 3 · Page 1 of 1
Anit-Invisibility
When anything other than a player gets invisibility, whether my hack is on or off they show up with particles and still appear visible until i reload world.

Code:
if (Var.antiIvis)
        {
        	this.setInvisible(false);
        }else
        {
            this.setInvisible(this.isPotionActive(Potion.invisibility.id));
        }
        
        
        if (this.potionsNeedUpdate)
        {
            if (!this.worldObj.isRemote)
            {
                if (this.activePotionsMap.isEmpty())
                {
                    this.dataWatcher.updateObject(8, Byte.valueOf((byte)0));
                    this.dataWatcher.updateObject(7, Integer.valueOf(0));
                    this.setInvisible(false);                    
                }
                else
                {
                    var11 = PotionHelper.calcPotionLiquidColor(this.activePotionsMap.values());
                    this.dataWatcher.updateObject(8, Byte.valueOf((byte)(PotionHelper.func_82817_b(this.activePotionsMap.values()) ? 1 : 0)));
                    this.dataWatcher.updateObject(7, Integer.valueOf(var11));
                }
            }

            this.potionsNeedUpdate = false;
        }

Applying invis while anti invis is off


reloading world
So is your problem.. That your code isn't working? You'd might need a for loop, cycling through the datawatcher and active pot; instead of ifs. I had a code using for statements, which allowed me to cycle through the entity list and check each if potion is true. If is, then set visible.
Code:
if (Var.antiIvis)
{
   //make sure this is called as soon as the hack is enabled.
   for(int i = 0; i < mc.theWorld.loadedEntityList.size(); i++)
	{
		Entity e = (Entity) mc.theWorld.getLoadedEntityList().get(i); 		
		e.setInvisible(false);
		System.out.println("Entities are now visible");
		//If you toggle your hack and do not see this in Eclipse's console, you are not calling it right.
	}
}
Posts 1–3 of 3 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Talk with us