Im programming a game wich has a platform that should deals 1 damage. But if he touch it all of his health goes away. Can someone please help me!
public void lavaBlock() { Ritter r = new Ritter(); if(isTouching(Ritter.class)) { r.leben = r.leben -1; } }
public void lavaBlock() { private int Immunity=120; Ritter r = new Ritter(); if(isTouching(Ritter.class)&&Immunity<=0) { r.leben = r.leben -1; Immunity=120; }else{Immunity--;} }