1
Engines / Re: I wanna be a minimalistic engine
« on: April 08, 2015, 02:36:22 PM »I got an In Object TriggerParent, in Event CollisionEvent_34 action number 1 at line 7 : unknown function or script execute_string
Compile Failed - Please check the Compile window for any additional information
Here is the strip of code.
if (!triggered) {
with (object_index) {
triggered = true;
}
if (variable_local_exists("code")) {
execute_string(code);
}
}
I can't find the variable/TriggerParent inside the script or anywhere else, so that's probably missing. Hopefully you know how to fix it.
I'm afraid that cannot be fixed unless you switch to Game Maker 8.1 or older. I assume you're using Game Maker Studio.
Since the very first version, all dynamic functions have been deprecated, and "execute_string" is one of them.
A workaround for that specific problem can be made, but generally, using Game Maker Studio with this engine is not a good idea, sorry >-<
Workaround:
Simply remove this functionality by deleting the block:
Code: [Select]
if (variable_local_exists("code")) {
execute_string(code);
}
You won't be able to specify instance-specific code for triggers (that's what it was for), but you can always create a new special trigger object with the desired code inside by doing something similar to the following:
Code: [Select]
triggerWithCode01:
Create:
event_inherited();
executed = false;
Step:
if (triggered && !executed) {
executeSomeCode();
executed = true;
}
Changing this will probably break some of the samples, but at least it should compile.
If you find any other error I'll be glad to help, maybe I'll even do a Game Maker Studio-friendly version.
(Although given the low amount of responses my motivation isn't the highest right now >-<)