GameMaker-Bugs
GameMaker-Bugs copied to clipboard
Phantom feather error will say a variable wasn't declared in the create event when it was. Error will appear and disappear based on what event was most recently edited.
trafficstars
Description
This particular error will appear if I edit the create event, and then disappear if I edit the step event. The error will also appear if I close GameMaker and then restart it.
Steps To Reproduce
//in Object 2 create event
dir = 0;
spd = 0;
//in Object 1
testMethod = function() {
with instance_create_layer(x, y, "Instances", Object2) {
dir = 5;
spd = 5;
}
}
//step
testMethod(); //error here, says spd and dir were not set in the create event even though they were
Making any kind of edit in the step event will make the error disappear. Going back to the create event and making any edit will make it reappear.
This may be the same bug as #2163 , but I submitted a separate bug report since the code is slightly different and I wanted to attach another project showing this alternate version of the bug.
Still present on IDE v2024.4.1.144 Runtime v2024.4.1.178 also happening with other error types (as GM1041).