Open HannulaTero opened 2 weeks ago
After a discussion with Russell, this is actually a bug in the current runtime VM which should be fixed. The behaviour will not change on GMRT, see also #7690.
So this issue is to be closed as Not Planned and instead 7690 is going to be changed?
There is a minor quirk with the VM right now which needs to be resolved so it's on parity with YYC and GMRT, so I've kept this issue open for now. 7690 is a separate, additional thing.
new
Description
Behaviour when calling another constructor function without "new" keyword inside constructor is different between GMS2 Runtime and GMRT. Doing this in GMRT will change static/parent of struct.
Although I don't usually use constructors functions like normal functions, I would thing expected behaviour should be like GMS2 Runtime has.
Steps To Reproduce
1) Create constructor function Thing() 2) Create constructor function whoopse() 3) Inside Thing constructor, call whoopsie without using "new". 4) Create a new Thing. 4a) In GMS2 Runtime you get struct of Thing, which executed whoopsie. 4b) In GMRT you get struct of whoopsie. 5) Check with instanceof(...)
Which version of GameMaker are you reporting this issue for?
IDE v2024.800.0.618 Runtime v2024.800.0.642
Which operating system(s) are you seeing the problem on?
Windows 10.0.19045.0
aed7ebe2-24a5-417a-8ad7-3dda67640ae7