MCPcopy Create free account
hub / github.com/candybox2/candybox2.github.io / addTroll

Method addTroll

code/main/Bridge.ts:98–103  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

96 }
97
98 private addTroll(): void{
99 var troll: Troll = new Troll(this, new Pos(100, 8));
100 troll.setQuestEntityMovement(new QuestEntityMovement(new Pos(-1, 0), 12));
101 troll.setHealthBar(new QuestEntityHealthBar(troll, new Pos(100, 1), new Pos(0, 0), QuestEntityHealthBarPositionType.FIXED_ON_PAGE, true, true, BarType.HEALTH));
102 this.addEntity(troll);
103 }
104
105 private thePlayerWon(): boolean{
106 // If the player is at the right of the desert, we return true

Callers 1

constructorMethod · 0.95

Calls 3

setHealthBarMethod · 0.80
addEntityMethod · 0.80

Tested by

no test coverage detected