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

Method draw

code/main/Troll.ts:41–46  ·  view source on GitHub ↗
(renderArea: RenderArea)

Source from the content-addressed store, hash-verified

39
40 // Public methods
41 public draw(renderArea: RenderArea): void{
42 super.draw(renderArea);
43
44 // We add the missing "<" on the troll's bludgeon as a tag
45 renderArea.addTag(new RenderTagLt(this.getQuest().getRealQuestPosition().x + this.getGlobalPosition().x + this.getRenderAreaPosition().x + 9), this.getQuest().getRealQuestPosition().y + this.getGlobalPosition().y + this.getRenderAreaPosition().y + 1);
46 }
47
48 public willDie(): void{
49 this.getQuest().getGame().getQuestLog().addMessage(new QuestLogMessage(this.getDeathMessage() + " (and found " + Algo.pluralFormat(this.getQuest().foundCandies(500), " candy", " candies") + ")", this.getQuest().getCandiesFoundMessage()));

Callers 15

drawEntitiesMethod · 0.45
drawPlayerSpellsMethod · 0.45
drawQuestLogMethod · 0.45
updateMethod · 0.45
drawFloorsMethod · 0.45
drawFireMethod · 0.45
getForRenderingMethod · 0.45
updateMethod · 0.45
drawCauldronMethod · 0.45
reDrawMethod · 0.45
drawWaysMethod · 0.45
drawGameMethod · 0.45

Calls 5

addTagMethod · 0.80
getRealQuestPositionMethod · 0.80
getQuestMethod · 0.80
getGlobalPositionMethod · 0.80
getRenderAreaPositionMethod · 0.80

Tested by

no test coverage detected