Package games.stendhal.server.entity.creature.impl.poison

Examples of games.stendhal.server.entity.creature.impl.poison.Poisoner.attack()


    final String poisontype = "greater poison";
    final ConsumableItem poison = (ConsumableItem) SingletonRepository.getEntityManager().getItem(poisontype);

    final Poisoner poisoner = new Poisoner(100, poison);
    final Player victim = PlayerTestHelper.createPlayer("bob");
    poisoner.attack(victim);
    assertTrue(victim.isPoisoned());
  }

  /**
   * Tests for poisonerProbabilityZero.
View Full Code Here


    final String poisontype = "greater poison";
    final ConsumableItem poison = (ConsumableItem) SingletonRepository.getEntityManager().getItem(poisontype);

    final Poisoner poisoner = new Poisoner(0, poison);
    final Player victim = PlayerTestHelper.createPlayer("bob");
    poisoner.attack(victim);
    assertFalse(victim.isPoisoned());
  }
}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.