- Xy$
- -0.10
I'm having troubles aliasing the Datamanger properly. I'm currently writing a plugin that I want to save new values to the save file. How would I properly alias this function, because I've tried both call and apply.
this results in an error... not sure why.
EDIT: I've left the makeSaveContents part default for now (besides adding in my 2 variables at the bottom properly, this works fine as long as I don't alias extractSaveContents)
JavaScript:
var fp_dmexc = DataManager.extractSaveContents
DataManager.extractSaveContents = function(contents) {
fp_dmexc.call(this);
FS_VARS = contents.fpData;
FP = contents.fpAmount;
};
EDIT: I've left the makeSaveContents part default for now (besides adding in my 2 variables at the bottom properly, this works fine as long as I don't alias extractSaveContents)