(quest: Quest, pos: Pos)
| 12 | |
| 13 | // Constructor |
| 14 | constructor(quest: Quest, pos: Pos){ |
| 15 | super(quest, |
| 16 | pos, |
| 17 | new Naming("A wolf", "a wolf"), |
| 18 | new RenderArea(7, 3), |
| 19 | new Pos(0, 0), |
| 20 | new CollisionBoxCollection(new CollisionBox(this, new Pos(0, 1), new Pos(7, 2))), |
| 21 | new QuestEntityMovement() |
| 22 | ); |
| 23 | |
| 24 | // At first, we're not taking the decision to begin running |
| 25 | this.takeTheDecisionToRunTimer = null; |
| 26 | |
| 27 | // Set the area transparency |
| 28 | this.setTransparency(new RenderTransparency(" ")); |
| 29 | |
| 30 | // At first we're looking left and standing |
| 31 | this.setIsLookingLeft(true); |
| 32 | this.setIsStanding(true); |
| 33 | |
| 34 | // Set gravity |
| 35 | this.getQuestEntityMovement().setGravity(true); |
| 36 | |
| 37 | // Set destructible |
| 38 | this.setDestructible(true); |
| 39 | this.setMaxHp(45); |
| 40 | this.setHp(45); |
| 41 | |
| 42 | // Set the weapon and its delay |
| 43 | this.addQuestEntityWeapon(new QuestEntityWeapon(this.getQuest(), this, new Naming("Its fangs", "its fangs"), new CollisionBoxCollection(new CollisionBox(this, new Pos(-1, 0), new Pos(9, 3))), 10)); |
| 44 | this.getLastQuestEntityWeapon().getCloseCombatDelay().setFixedDelay(2); |
| 45 | } |
| 46 | |
| 47 | // update() |
| 48 | public update(): void{ |
nothing calls this directly
no test coverage detected