Sprite Game Object is not rendering?

Hi! I just started using Defold and I’m excited to learn more about it as I try to make my own games using it. But one problem I’ve run in to is that there seems to be an issue with the player sprite game object, which causes it not to render?

I initially thought I was causing this problem, but I started a new project using the Platformer Template and even that has the same issue when I Ctrl+B or build it. Everything but the player object shows up.

Before build:

After build:

I have no idea what the problem is. This is a template so I would trust it to work, but it’s not. Any ideas?

Have you changed the z position of the player game object or the player sprite? The default range of z value that will be rendered is within -1 and 1

Hi. Thank you for your response to this issue. I tried changing the Z values of the player object but it didn’t seem to change anything. It’s possible that I am overlooking something here, but I will keep trying to change the Z value to see any change. I’ve read through some of the documentation regarding Rendering and have a basic idea of how Defold prioritizes rendering for each object. But I just started today so this is tough for me to figure out.

Also I’m using the latest version, 1.2.186 (I think that’s correct?)

Correct! Which OS are you using? Windows?

Edit: Could you try Project->Build HTML5

I use Windows 10. I will try what you sent me.

Which kind of GPU do you have?

And what about this?

Not sure if you mean I should start a new project like this:

would I choose “Web Monetized game?”

I have: Intel(R) HD Graphics 610

Oh. I think you actually meant inside the project I should select Project > Build HTML5? Sorry :sweat:

So I tried Project > Build HTML5 and it is working all good and well.

Here is a screenshot:

When I build it normally so that a window comes up to play, I can move the player around properly but only the sprite doesn’t show up.

1 Like

I believe there’s a problem with these integrated GPUs on Windows.

@jhonny.goransson and @JCash what would be the first step to debug this?

1 Like

I’m not sure what the first step would be.

I’m wondering if it’s either a state issue, or a shader issue.
One way would perhaps be to debug it using RenderDoc on windows

Yep. @Pawel didn’t you have the same issue with sprites disappearing?

1 Like

Yes, for me it is the same issue, workaround is to reduce atlases amount - it is always happening for one atlas (e.g player’s atlas like here), and when you move player’s sprite to the background’s atlas everything is OK.
Also I am confirming that HTML5 and Windows builds are working without such issue, and in Editor view everything is OK, yet it occurs only when running from Project->Run.
Also Windows (64bit), laptop with integrated graphics

1 Like

Thanks to all of you for helping me figure this out.

How would I do this?

Edit: I am wondering if there is such documentation or any other information regarding this issue with the gpu.

Thanks. @JCash could you provide Pawel with instructions for running renderdoc?

1 Like

I had run it already and it was attached to the regarding topic, I will try to find it :wink:

EDIT:
This is the thread, some more findings are there and there is a Github issue reported for this. Regards atlases used for both GUI and GO.

1 Like

When you say “Window build”, you mean you’ve bundled for Windows?
I mean, “Build and run” from the editor, is a Windows build too (if your’re using windows)

If that’s the case, there seems to be a difference in how the content is created between the editor build pipeline and bob (bob is used for HTML5 and bundling).

2 Likes

Yes, yes

1 Like

Oh! I missed this bit of information. So it’s only when you do Project->Build that the problem happens?

2 Likes

I can confirm yes for myself. This only happens when doing project > build.

2 Likes