Did At the beginning of the Scene mess up?

For some reason At the Beginning of the Scene doesn’t really trigger all events, I noticed that some of the events are flat out missing.

would you mind explaining further and show your event sheet?

Actually I just noticed that even if I remove At the Beginning of the Scene, and replace it with Trigger Once, it still doesn’t do the things I want (like creating objects at the beginning of the scene). I wonder if this is performance related? I’ve noticed there is a slight hang at game start on newer versions of GD.

im afraid i still cannot help you without more information. Trigger Once, assuming its at the beginning of the scene, would do exactly the same thing anyway.

Performance ≠ failing code (usually), and the details matter, especially for a bug report.


So for example, Hide the Cursor doesn’t work, like some stuff triggers, some stuff doesn’t. Performance related maybe?

This seems to just be unlucky code.

Firstly, Hide the cursor will not work if your cursor started outside of the window. Try putting your cursor in the window right before the game finishes loading, it will disappear.

Secondly, you mentioned objects not creating, (so id assume the cursor?). Check if that position is obviously on the screen, ensure the layers are configured properly, ensure if it is off screen that you are constantly setting its position to the cursor’s position.

Lastly, if it will help you debug the issue, just try placing the object manually rather than creating it. I understand if this approach is not clean to you though, but just do it to see what might happen. Also, check the debugger, it will tell you the amount of instances of any object that is currently in the scene, where you will very likely see a 1.

Your code looks like it should be working, it makes sense for it to be on its own layer, it makes sense to create it rather than drag it in as its the code is more reusable that way, so im going to assume you know what youre doing, and that this might be a misunderstanding.

Everything functions normally when the scene is returned to from another scene, or when the functions are placed immediately after the first event. So my guess is something is happening at the very beginning of the scene where stuff just doesn’t get triggered due to some weird hang.

Enter a preview, press control shift i, click console, and tell me the errors you see (likely only errors past RenderTexture matter)

Also, can you replicate this error in another project? if so, give us an example that we can test.

It’s really bizarre, when I remove all of the subevents from the initial Trigger Once or At the Beginning of the Scene event, it seems to work just fine, everything triggers as intended.

subevents? you didnt tell me that…

You are messing it up not at beginning of the scene or trigger once
For example if you do too much stuff at beginning of the scene then cursor will not hide properly

You should instead use
INVERTED at beginning of the scene
Trigger once

Or in case of events you can afford to spam

Using Compare numbers

TimeFromStart() is less than 0.5
Hide cursor

im afraid i dont understand the point of that. personally i wouldve found a way for it to check if the cursor is within the window, and trigger once that it hides it. so each time it enters the window it will trigger to hide it

If something does not trigger with condition
At beginning of the scene

You make condition
INVERTED at beginning of the scene
Trigger once

So it happens once after scene started

Compare two numbers with TImeFromStart() less than 0.5
Gives you some extra time to do something constantly you can even put there less than 4
So something gonna get spammed for 4 secs

You can find other ways to do it and nobody will care how you did it but does it work
Cause that is idea here to make something happen

These 2 tricks are ones i found easiest to pull and always work
If you have something better i am all ears

uh…what about just putting the wait action and the code in a subevent? i think that would work but whatever it doesnt matter

Problem with wait is the fact its asynchronous
And then its 1 trigger after some period of time
So it can mess up whatever you are doing
For example wait 1 sec hide cursor so for 1 sec you are seeing cursor

AGAIN nobody gonna care how you do it or i do it
Only thing ppl will care is if the method suggested works
These two i proposed works for me and never failed me
And so far i didn’t find anything better
Where you i see did not even search but just try to came up with something different not even realizing disadvantages it brings along

btw i don’t see anything “stressing” in that at the beginning action, i’ve more in my game and always worked perfectly..i dunno how the Steamthing works, but i believe that read the user name require an online? check which probably delay the events though still strange the cursor isn’t hiding.

Cursor bug with not hiding is at least here from over 3.5 years since that is when i noticed it 1st time
But like i said it happens (IN MY CASE) only when i do too much stuff at beginning of the scene

100% positive it has to do with the hang on game load. Opening a new scene it doesn’t have this problem at all. My best bet is that something goes wrong with how the game is loaded into action and just skips over some events for some reason.

I wanted to clarify what you just said but i realized i will just repeat same thing in other words
At beginning of the scene = when very first frame happens

Now question would be is the issue that condition know its 1st frame but fail to do SOME tasks cause it don’t fail to do all but just specific ones if there is too much workload?

Or

Is it so that some task are less important and are omitted during 1st frame if there is too much workload?

Actually Johnny can you replace at beginning of the scene with trigger once?
And we will see is it issue with how much stuff you have to do when scene starts
Or is it with at beginning of the scene itself

Trigger once is the exact same thing. I think other Trigger Once subevents don’t trigger during the game load.

When I separate the events into single events (not subevents) it works fine.

So my guess it’s just something that happens when a game is loaded.