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

Method update

code/main/Inventory.ts:19–40  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

17
18 // Public methods
19 public update(): void{
20 // yGap, can increase depending on the stats panel
21 var yGap: number = 0;
22
23 // Erase everything
24 this.renderArea.resetAllButSize();
25
26 // Draw the inventory top
27 this.renderArea.drawArray(Database.getAscii("general/inventoryTop"));
28
29 // Draw equipment
30 this.drawEquipment();
31
32 // Draw statistics
33 yGap += this.drawStats(0, 52);
34
35 // Draw the inventory bottom
36 this.renderArea.drawArray(Database.getAscii("general/inventoryBottom"), 0, 55 + yGap);
37
38 // Draw items
39 this.drawGridItems(4, 57 + yGap);
40 }
41
42 // getRenderArea()
43 public getRenderArea(): RenderArea{

Callers 2

constructorMethod · 0.95
selectedEqItemMethod · 0.95

Calls 6

drawEquipmentMethod · 0.95
drawStatsMethod · 0.95
drawGridItemsMethod · 0.95
resetAllButSizeMethod · 0.80
drawArrayMethod · 0.80
getAsciiMethod · 0.80

Tested by

no test coverage detected