mirror of
https://github.com/eaglerforge/EaglerForgeInjector
synced 2025-07-26 15:29:26 -09:00
fix goofy ahh bug
This commit is contained in:
parent
077ccc919a
commit
f2c6adaab8
18
postinit.js
18
postinit.js
@ -374,18 +374,14 @@ globalThis.modapi_postinit = "(" + (() => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//Iteratively load the superclasses' prototype methods.
|
//Make it extend the parent. Used to iteratively load the superclasses' prototype methods.
|
||||||
ModAPI.reflect.prototypeStack = function prototypeStack(reflectClass, classFn) {
|
ModAPI.reflect.prototypeStack = function prototypeStack(reflectClass, classFn) {
|
||||||
var stack = [reflectClass.class.prototype];
|
classFn.prototype = Object.create(reflectClass.class.prototype);
|
||||||
var currentSuperclass = reflectClass.superclass;
|
classFn.prototype.constructor = classFn;
|
||||||
while (currentSuperclass) {
|
classFn.$meta = {
|
||||||
stack.push(currentSuperclass.prototype);
|
item: null,
|
||||||
currentSuperclass = currentSuperclass?.$meta?.superclass;
|
supertypes: [reflectClass.class]
|
||||||
}
|
};
|
||||||
stack.reverse();
|
|
||||||
stack.forEach(proto => {
|
|
||||||
Object.assign(classFn.prototype, proto);
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var reloadDeprecationWarnings = 0;
|
var reloadDeprecationWarnings = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user