Code doesn't work with the minifier, but i'm not running the minifier so i'd expect behaviour to be identical to preview. It's my own plugin yes.
As an example I have specific functions in Acts.prototype, like Acts.prototype.foo, and Acts.prototype.bar .
to test i made an event in a blank project with my plugin like "on key z pressed : alert something" and that causes the following js code to execute:
alert(Acts.prototype.foo)
alert(Acts.prototype.bar)
in preview:
the first alert returns the contents of a function as expected.
the second alert returns the contents of a function as expected.
in export:
the first alert returns the contents of a function as expected.
the second alert returns undefined.
if i attempt to run the action which returns undefined in my project, i get the "cannot call .apply on undefined" bug
The fact that some of my actions just don't exist on export is very confusing, and I can't figure out why this is happening on export only, unless C2 is parsing things completely different than in preview.