Tree trunk is not working

Why doesn’t this work???

The z index isn’t working. You can test this by clicking the box to start the game and the box to end it and it DOESNT WORK!!! The trunk is in front of the tree. Why?!?!!

I always have the dumbest issues and I don’t know why I can’t do anything without having to make a topic everytime I try to make something like you’d think by now I wouldn’t be this bad at making games

I also have had other issues with z-index and clones before

@ShiningStars @CodeHelp

6 Likes

When Game Starts
Check Once If Clone Index = 0 and RunOnce = 0
Set RunOnce to 1
//code
End
End

4 Likes

Thanks! Can you tell me why my code didn’t work though please? With the z-index not working

3 Likes

each time you enter the scene, the original object is cloning 6 (or 5?) clones. because the original object is the trunk, and all clones follow the original object properties, 6 trunks are in front of everybody. to avoid that i simply added a conditional to not have the overcloning issue

3 Likes

Oops the whole reason it didn’t work was because I removed this block for debugging purposes but then it caused a bug so you put something similar in to stop it lol

this stuff always happens

2 Likes

if you have that code with 7 instead of 6, your trunk wont appear on the top

4 Likes

I have another z-index problem which is a similar thing except look at the top bar. I did everything like you did and it worked with the other objects I don’t know what I did differently

2 Likes

or you can use my technique too
btw instead of stalking multiple check if, you can bring them in one single check if with an AND logic

2 Likes

Oh I didn’t know it also counted, thanks!!

Thanks!

Also btw do you think it looks good so far now?

2 Likes

im not sure what game youre working so i cant tell

but yea the tree is cute lol

2 Likes

It’s a

Maple syrup tapper game for fall

2 Likes

ok, def very cool

2 Likes

Now am I going to be allowed to take the model or what?

1 Like

I used to think it was sap!

1 Like