- Home /
Can Someone Please Tell Why Graphics Do Not Look The Same as Editor When I Build my Game
My Game is 2D, I have Particle Systems That Look Completely Different When I Build my project, Some Sprites are completely replaced with others and some graphics are completely black or pink instead of how they should look, the scene ordering at times appears wrong even though I'm certain that the drawing order in Editor is correct, some sprites are not being rendered at all and I just see the background map,
Why Are my Graphics Working In Editor and Not in Build??
How can I solve this??
why would material go missing, i get no error from the build
Are you changing materials or shaders at runtime? What quality settings are you using for your player? What is your target platform anyway? There's plenty of reasons why a game would look different in the editor on PC than a build on Android, say.
@ tanoshimi no I dont recall any shader or mats being changed at runtime, Im using a medium quality, the target platform is desktop pc not android.. theres doesnt seem to be a good reason why it shouldnt build correctly on my pc, Im confinced that this is a unity problem with compiling a large amount of 2d sprites graphics
Sounds like the shader on the particles is incompatible for your target platform.
@Jessespike its a test build on pc so why would there be a problem, i havent even gotten as far as a build for a specific platform
every build is for a specific platform... yours is Windows PC Standalone, from the sound of things.
Im using a build-in Particle/Additive to make a clouds from a Particle System. The following image should how they turn out in build $$anonymous$$y quality settings are Unity Default and I tried running it on everything from the fastest to the fantastic setting, the map is quite large but no larger than a map you'd see when playing something like sonic, however my sprite are quite large and take up quite some memory but I'm running this on a very powerful 16Gb PC and my editor has no trouble so why should my build go all wrong, as well as that my dude who's fully animated in 2d keeps appearing shaded out at times and other objects in scene appear shaded out and some chunk of map are replaced by a completely different sprite or not rendered at all in some cases, all my sprites use the same default sprite shader, only my various particle systems use a different shader, the one in question is using a default particle/additive but its material or something else is changed completely
Did you include the shader in the Always Included Shaders list in Project -> Graphics Settings?
YES I TRIED ADDING ALL THE SHADERS I'$$anonymous$$ USING TO THAT LIST WITH NO I$$anonymous$$PROVE$$anonymous$$ENT, IN FACT IT $$anonymous$$ADE THE GRAPHICS WORSE AND TURNED $$anonymous$$ORE OF THE GRAPHICS PIN$$anonymous$$, I HONESTLY THIN$$anonymous$$ UNITY JUST CANT COPE WITH THE SIZE OF ALL THE SPRITES WHEN BUILT, IF I BUILD A S$$anonymous$$ALLER VERSION OF THE $$anonymous$$AP WITH THE SA$$anonymous$$E SPRITES AND PARTICLE SYSTE$$anonymous$$ THEY WOR$$anonymous$$, BUT THAT ISN'T A SOLUTION BECAUSE I WANT $$anonymous$$Y $$anonymous$$AP TO BE AS LARGE AS IT IS.. HOW CAN $$anonymous$$A$$anonymous$$E IT RUN WITHOUT SO $$anonymous$$UCH OVERHEAD. I DID CREATE AN EFFICIENCY SCRIPT THAT ENABLES AND DISABLES THE PARTS OF THE $$anonymous$$AP THAT ARE NOT IN CA$$anonymous$$ERA IN THE HOPE A SAVING OVERHEAD BUT THAT HAS NOT CONTRIBUTED ANYTHING TO THIS PARTICULAR PROBLE$$anonymous$$
Check the shaders themselves and see if they have a "Fallback" shader listed. Check these fallbacks are added to the Always Added shader list.
Look specifically at the shaders on the models you are having trouble with and see if they do not in fact have a fallback.
Having a fallback will obviously give you very different results to what you expect and having no fallback will leave you pink, in the event that the shader is not supported.
Answer by Stankiem · May 11, 2016 at 09:59 PM
jessespike has it right I think:
Sounds like the shader on the particles is incompatible for your target platform.
Try changing the shader for those objects and see if they work, then you confirmed your issue. might be out of date plugins etc... Try updating them.
Black is bad lighting, the lighting doesn't actually render as it would at runtime in the editor, look into your quality settings more.
@Stankiem I'm building in 2d with sprites that use a default-sprite shader so they shouldn't have lighting problem because lighting has no effect on that particular shader and some 2d particle systems use a range of materials but certain particle systems are having their material changed to something that looks nothing like the ones used originally
"some 2d particle systems use a range of materials" So how are you assigning those materials? We really don't have enough information here to help you - please post some screenshots of your setup - your particle system and quality settings - and also some that demonstrate the issue you're seeing. Have you tried other quality settings? Have you checked the player log for any errors?
Im using a build-in Particle/Additive to make a clouds from a Particle System. The following image should how they turn out in build $$anonymous$$y quality settings are Unity Default and I tried running it on everything from the fastest to the fantastic setting, the map is quite large but no larger than a map you'd see when playing something like sonic, however my sprite are quite large and take up quite some memory but I'm running this on a very powerful 16Gb PC and my editor has no trouble so why should my build go all wrong, as well as that my dude who's fully animated in 2d keeps appearing shaded out at times and other objects in scene appear shaded out and some chunk of map are replaced by a completely different sprite or not rendered at all in some cases, all my sprites use the same default sprite shader, only my various particle systems use a different shader, the one in question is using a default particle/additive but its material or something else is changed completely
Answer by rowena_indiesoft · May 18, 2016 at 10:32 AM
I reset the editor, quality and graphics settings and now I am getting these errors
1:An asset is marked with HideFlags.DontSave but is included in the build: Asset: 'Library/unity default resources' (You are probably referencing internal Unity data in your build.) UnityEditor.HostView:OnGUI()
2:Building - Failed to write file: Temp/StagingArea/Data/Resources/unity_builtin_extra UnityEditor.HostView:OnGUI()
I don't know what they mean, Ive searched the web and there's little info about these particular errors, and unity doesn't tell me what is causing these errors.