You've already forked ParticleEffectForUGUI
mirror of
https://github.com/mob-sakai/ParticleEffectForUGUI.git
synced 2026-05-14 20:20:06 +00:00
feat: add project settings
This commit is contained in:
@@ -137,6 +137,7 @@ namespace Coffee.UIExtensions
|
||||
{
|
||||
base.OnEnable();
|
||||
|
||||
hideFlags = UIParticleProjectSettings.globalHideFlags;
|
||||
if (!s_CombineInstances[0].mesh)
|
||||
{
|
||||
s_CombineInstances[0].mesh = new Mesh
|
||||
@@ -161,7 +162,7 @@ namespace Coffee.UIExtensions
|
||||
// Create renderer object.
|
||||
var go = new GameObject("[generated] UIParticleRenderer", typeof(UIParticleRenderer))
|
||||
{
|
||||
hideFlags = HideFlags.HideAndDontSave,
|
||||
hideFlags = UIParticleProjectSettings.globalHideFlags,
|
||||
layer = parent.gameObject.layer
|
||||
};
|
||||
|
||||
@@ -416,7 +417,7 @@ namespace Coffee.UIExtensions
|
||||
_lastBounds = bounds;
|
||||
|
||||
// Convert linear color to gamma color.
|
||||
if (canvas.ShouldGammaToLinearInMesh())
|
||||
if (UIParticleProjectSettings.enableLinearToGamma && canvas.ShouldGammaToLinearInMesh())
|
||||
{
|
||||
workerMesh.LinearToGamma();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user