Game works in editor, in pc build it breaks: sprite disappears going left

NEW NOTE:

Oh to add to the fun, built on my other pc, ran. No disappearing sprite! Thought maybe my player settings were different. Took the game .exe that was built ran it on the original pc i discovered the issue, sprites disappear. This is a grave driver issue or something ? I have no hope of fixing this it seems :frowning: especially when the same build that doesnt run on this pc runs fine in the editor on this pc. :frowning:

So I have my main sprite, and when i walk left in the PC build the image disappears…in the editor things work flawlessly. I noticed also my gui texture i have for a meter in my game looks all chopped up too (screenshot provided). very bizarre, is there some player setting i’m missing? This is unity 5. I know in older unity versions it worked fine during pc build, this was a while ago though but I don’t think its anything I have done in my game. This is frustrating not sure what is so different about a PC Build, works fine in a web build too!

I did notice a few things. I am using NGUI and 2D Tool Kit plug ins and unity 5. I have a line in my code:

NGUIDebug.Log("len: " + pointCount.Length);

and that NEVER shows up except for in this pc build. So i am not sure what is going on but it is also any sprite that moves left does not render. I change my sprites direction using this;

        forceX = standing ? speed * controller.moving.x : (speed * controller.moving.x * airSpeedMultiplier);
                       
                            transform.localScale = new Vector3 (forceX > 0 ? 1 : -1, 1, 1);

This works fine in editor and web version. I am using Unity v. 5.0.1f1 I did get something going when i mucked with the player values for standalone…though one setting did get the sprites to show up when facing left yet broke all my other graphics (think it was legacy deferred) deferred no graphics showed up…forward works best but the left facing sprites are invisible…and yah that damn collision changes. i need a player option that says “make it work like in editor” yah…that’s the ticket.

I’m sorry, but this is pretty bizarre :hushed:.

Please report a bug, preferable with a reproducible project, and in your case, a detailed GPU and driver might be helpful. Thank you!

Okay, I am narrowing it down. On my laptop it has two cards (it is a MSI GS60) and has an integrated graphics card and an nvidia card. I will get the details, but if I use the optima graphics center to make it use the gpu for the game I build, it runs fine, the integrated card has the disappearing left sprites. Though doesn’t explain why the Editor works and a build doesn’t unless the editor chooses the GPU. I will figure out how to submit this as a bug once I narrow more things down. I think it has to do with the NVIDIA Optimus technology…though the integrated graphics card is Intel graphics 4600, gpu is GTX 870M

I see. One issue for this kind of flipping is the shader/material of the sprite might not supporting it (enabled backface cull). Are you using the default sprite shader for the sprite renderer?

Indeed I am using the default sprite material. (I think it is even called ShadeR: Sprite/default) . But maybe in general the backface cull is enabled, though why does it work fine in the editor and not when built?

I’m afraid I do not know the cause now without a reproducible method, especially when you already using the default sprite shader. Please file it as a bug, then we can give a better look at it. Thanks!