I’m trying to make it that the player spawns to the position of a certain object at the beginning of the scene. Only problem is that the object is loading from an external layout, which leads to the player spawning at 0, 0. Judging by the fact that spawning at the object works correctly in every other instance, I can only assume the issue is that the external layout is loaded after the first frame of the scene.
Does anyone know any fixes, or ways to solve the issue?
Hi @Yhac10 .you could either try a 'number of instances of spawner greater than 1 as a condition to move player or send player to spawner Y()-20 or …hide player use a scene timer greater than timedelta and then show player, or turn off platform behavior at beginning of scene and turn on again when player moves to spawner or have the player on the external layout. I don’t think that you can refer to objects created in an external layout in the same event as they’re created …but it doesn’t look as if you,'ve done that.
Thanks for the suggestions. While the suggestion about having the player in the external event is risky for me, as I don’t know how it will affect the online multiplayer, that and the way I set up the level system, your suggestion did remind me that I could just move the spawn point to the main scene instead of an event. The reason I put this of is because I would have the spawn point in the main scenes, while having the checkpoint and other points be in the external layout, although now that I think about it, it shouldn’t matter to much.
What is the order of your events on the event sheet? Is the layout added before the player is positioned?
I can’t tell from your screenshot if they’re subevents or if they’re placed in the event sheet in the order that you posted them. The location matters even with the at the beginning condition.
You can do them at the same time but just remember that layouts aren’t added until after an event, so they’re not available immediately in the event or subevents.
This wouldn’t work
At the beginning
… Add layout
… … Position player using spawn object
But this should
At the beginning
… Add layout
… Position player using spawn object
In the 2nd one they’re in seperate subevents but at equal indentations. Putting them in the same subevent also doesn’t work.
Thanks for the solution, although it wouldn’t really work for me since both the events I use to spawn playertypes and external layouts are in two different event sheets (one in an external event sheet and another in a scene event sheet)
It shouldn’t be an issue with the way layouts are added then, it’s probably the sequence that the events are triggered. The layout needs to be added first.