Warning for large scripts that are too big for 1 bank.
BANKED_DATA_TOO_LARGE now also says what scece/actor,
how far over 16384 bytes, and to use invoke actor instead.
@@ -84,6 +84,17 @@ const compileEntityEvents = (input = [], options = {}) => {
if (!branch) {
output.push(0); // End script
+ if (output.length > 16383) {
+ warnings(
+ `This script is too big for 1 bank, was ${output.length} bytes, must be under 16384.
+ ${JSON.stringify( location )}
+ `
+ );
+ warnings(
+ 'Try splitting this script across multiple actors with *Actor invoke*.'
+ );
+ }
+
for (let oi = 0; oi < output.length; oi++) {
if (typeof output[oi] === "string" || output[oi] < 0) {
const intCmd = Number(output[oi]);
