Assertion failure: Drawing instance on wrong layer

Discussion and feedback on Construct 2

Post » Thu May 28, 2015 10:44 am

Please, if you have this problem, report it to the bugs forum following all the guidelines.
Scirra Founder
B
400
S
237
G
89
Posts: 24,550
Reputation: 195,537

Post » Thu Apr 28, 2016 9:20 pm

I know this is an old thread, but I had this "Assertion Failure: drawing instance on wrong layer" and I figure for anyone who has this, maybe this will help. For my situation, I discovered that it was a global sprite that was on layer 2. Then I created a new layout, which only had one layer. That's when I got the error. Simply added two more layers to this new layout and it was fine.
B
11
S
3
Posts: 58
Reputation: 805

Post » Tue Mar 14, 2017 9:24 pm

Yeah, i had the same error. The error ocur when I switch layouts using the multiplayer plugin and I have synced objects that aren't on the same layer. Looks like a bug to me.

The work around is to create the same number of layers (the name of the layers doesn't matter) on both layouts, the one you're leaving to the one you're going to. Works fine for me.
B
15
S
7
Posts: 11
Reputation: 1,247

Post » Thu Mar 23, 2017 10:32 pm

I had something similar happen to me. I would create 8 objects on layer6 but for no reason that I could find it would always put 1 object on layer3. The only reason I found out was the object had a blend mode associated with it and it made 1 object the wrong color. The system wasn't giving any errors and I seemingly didn't have anything else associated with the objects or interfering with it.

All I did was erased the "Create Object" Action and remade it. It seems to be working now.
B
67
S
37
G
13
Posts: 241
Reputation: 12,760

Post » Wed Jul 19, 2017 7:18 pm

- One tip for everyone, maybe i wad solved this problem. In my case i have this problem: when i change layout and click on left mouse key, my player fires a bullet and have this bug/error, and when my enemies, shoot me/create objects bullets too.
- So the thing is, on your first layout, the objects you will create or the "system" will create, need to have one essencial behavior, it's call "PERSISTENT".

- Follow my logic, if you create objects on the next or preview layout, and you have the same objects will be create on future, you will need put all the object on all layouts, right? soo try put "PERSISTENT" behavior! :)

This resolve my problem, hope help someone :)
B
12
S
4
Posts: 2
Reputation: 918

Previous

Return to Construct 2 General

Who is online

Users browsing this forum: irina and 2 guests