(quest: Quest, pos: Pos)
| 3 | class SmallestFish extends QuestEntity{ |
| 4 | // Constructor |
| 5 | constructor(quest: Quest, pos: Pos){ |
| 6 | super(quest, |
| 7 | pos, |
| 8 | new Naming("A very small fish", "a very small fish"), |
| 9 | new RenderArea(3, 1), |
| 10 | new Pos(0, 0), |
| 11 | new CollisionBoxCollection(new CollisionBox(this, new Pos(0, 0), new Pos(3, 1))), |
| 12 | new QuestEntityMovement(new Pos(-1, 0)) |
| 13 | ); |
| 14 | |
| 15 | // Set destructible |
| 16 | this.setDestructible(true); |
| 17 | this.setMaxHp(10); |
| 18 | this.setHp(10); |
| 19 | |
| 20 | // Set the ascii art |
| 21 | this.getRenderArea().drawArray(Database.getAscii("places/quests/theSea/smallestFish")); |
| 22 | |
| 23 | // Set the weapon and its delay |
| 24 | this.addQuestEntityWeapon(new QuestEntityWeapon(this.getQuest(), this, new Naming("Its fins", "its fins"), new CollisionBoxCollection(new CollisionBox(this, new Pos(-1, -1), new Pos(5, 2))), 1)); |
| 25 | this.getLastQuestEntityWeapon().getCloseCombatDelay().setFixedDelay(6); |
| 26 | } |
| 27 | } |
nothing calls this directly
no test coverage detected