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

Method save

code/main/Resource.ts:42–46  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

40 }
41
42 public save(): void{
43 Saving.saveNumber(this.savingPrefix + "Accumulated", this.getAccumulated());
44 Saving.saveNumber(this.savingPrefix + "Current", this.getCurrent());
45 Saving.saveNumber(this.savingPrefix + "Max", this.getMax());
46 }
47
48 public transferTo(resource: Resource, howMany: number = -1, ratio: number = 1): boolean{
49 // If howMany is below 0, then we transfer everything

Callers

nothing calls this directly

Calls 3

getAccumulatedMethod · 0.95
getCurrentMethod · 0.95
getMaxMethod · 0.95

Tested by

no test coverage detected