Advertisement
Luninariel

textGame - Human

Dec 11th, 2018
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.44 KB | None | 0 0
  1. public class Human extends Entity{
  2. public Human (){
  3. this(1.0);
  4. }
  5.  
  6. public Human(double health){
  7. super();
  8. setSymbol();
  9. setHealth(health);
  10. setStamina(0.80);
  11. strength = 1.0;
  12. aggressiveness = Math.random();
  13. attackMessage = "Swings a sword";
  14. }
  15. private void setSymbol(){
  16.  
  17. symbol = (Math.random() > 0.5)? "\uD83D\uDC69" : "\uD83D\uDC68";
  18. }
  19.  
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement