The help file from RPG Maker MV tells us about a very useful feature, the ability to use the "Notes" field from the Database to setup custom metadata for any object:
For example, I added a <foo:bar> to a Enemy "Note".
I have said enemy in a variable called "battler".
console.log(battler.meta.foo);console.log(battler.meta);Both come up undefined.
No sign of a property called "meta" anywhere.
Obviously throw an error because battler.meta.foo is undefined.
I've taken a look at the DataManager.extractMetadata function, and it seems to be correct.
So I'm not sure what I might be doing incorrectly. Any help is appreciated. Thanks!
I've been trying to make use of this, but to no success.
For example, I added a <foo:bar> to a Enemy "Note".
I have said enemy in a variable called "battler".
console.log(battler.meta.foo);console.log(battler.meta);Both come up undefined.
Code:
console.log(battler)
Code:
if (battler.meta.foo === 'bar')
I've taken a look at the DataManager.extractMetadata function, and it seems to be correct.
So I'm not sure what I might be doing incorrectly. Any help is appreciated. Thanks!