mindcraft/src/agent/memory_bank.js

21 lines
271 B
JavaScript
Raw Normal View History

export class MemoryBank {
constructor() {
this.memory = {};
}
rememberPlace(name, x, y, z) {
this.memory[name] = [x, y, z];
}
recallPlace(name) {
return this.memory[name];
}
getJson() {
return this.memory
}
loadJson(json) {
this.memory = json;
}
}