添加体积光插件,调整摄像机距离脚本,调整背景图位置与大小,修改摄像机抗锯齿,场景添加两盏聚光灯模拟开启大灯效果
|
@ -21,24 +21,27 @@ Material:
|
||||||
m_PrefabInstance: {fileID: 0}
|
m_PrefabInstance: {fileID: 0}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_Name: BG
|
m_Name: BG
|
||||||
m_Shader: {fileID: 4800000, guid: 650dd9526735d5b46b79224bc6e94025, type: 3}
|
m_Shader: {fileID: 4800000, guid: 13c02b14c4d048fa9653293d54f6e0e1, type: 3}
|
||||||
m_Parent: {fileID: 0}
|
m_Parent: {fileID: 0}
|
||||||
m_ModifiedSerializedProperties: 0
|
m_ModifiedSerializedProperties: 0
|
||||||
m_ValidKeywords:
|
m_ValidKeywords: []
|
||||||
|
m_InvalidKeywords:
|
||||||
- _ALPHATEST_ON
|
- _ALPHATEST_ON
|
||||||
m_InvalidKeywords: []
|
|
||||||
m_LightmapFlags: 4
|
m_LightmapFlags: 4
|
||||||
m_EnableInstancingVariants: 0
|
m_EnableInstancingVariants: 0
|
||||||
m_DoubleSidedGI: 0
|
m_DoubleSidedGI: 0
|
||||||
m_CustomRenderQueue: 2450
|
m_CustomRenderQueue: -1
|
||||||
stringTagMap:
|
stringTagMap: {}
|
||||||
RenderType: TransparentCutout
|
|
||||||
disabledShaderPasses:
|
disabledShaderPasses:
|
||||||
- MOTIONVECTORS
|
- MOTIONVECTORS
|
||||||
m_LockedProperties:
|
m_LockedProperties:
|
||||||
m_SavedProperties:
|
m_SavedProperties:
|
||||||
serializedVersion: 3
|
serializedVersion: 3
|
||||||
m_TexEnvs:
|
m_TexEnvs:
|
||||||
|
- _AlphaTex:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
- _BaseMap:
|
- _BaseMap:
|
||||||
m_Texture: {fileID: 2800000, guid: 8458f75d2c1c11443848cb47f56c8bd3, type: 3}
|
m_Texture: {fileID: 2800000, guid: 8458f75d2c1c11443848cb47f56c8bd3, type: 3}
|
||||||
m_Scale: {x: 1, y: 1}
|
m_Scale: {x: 1, y: 1}
|
||||||
|
@ -47,6 +50,10 @@ Material:
|
||||||
m_Texture: {fileID: 0}
|
m_Texture: {fileID: 0}
|
||||||
m_Scale: {x: 1, y: 1}
|
m_Scale: {x: 1, y: 1}
|
||||||
m_Offset: {x: 0, y: 0}
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _ClearCoatMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
- _DetailAlbedoMap:
|
- _DetailAlbedoMap:
|
||||||
m_Texture: {fileID: 0}
|
m_Texture: {fileID: 0}
|
||||||
m_Scale: {x: 1, y: 1}
|
m_Scale: {x: 1, y: 1}
|
||||||
|
@ -67,10 +74,18 @@ Material:
|
||||||
m_Texture: {fileID: 2800000, guid: 8458f75d2c1c11443848cb47f56c8bd3, type: 3}
|
m_Texture: {fileID: 2800000, guid: 8458f75d2c1c11443848cb47f56c8bd3, type: 3}
|
||||||
m_Scale: {x: 1, y: 1}
|
m_Scale: {x: 1, y: 1}
|
||||||
m_Offset: {x: 0, y: 0}
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MaskTex:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
- _MetallicGlossMap:
|
- _MetallicGlossMap:
|
||||||
m_Texture: {fileID: 0}
|
m_Texture: {fileID: 0}
|
||||||
m_Scale: {x: 1, y: 1}
|
m_Scale: {x: 1, y: 1}
|
||||||
m_Offset: {x: 0, y: 0}
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _NormalMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
- _OcclusionMap:
|
- _OcclusionMap:
|
||||||
m_Texture: {fileID: 0}
|
m_Texture: {fileID: 0}
|
||||||
m_Scale: {x: 1, y: 1}
|
m_Scale: {x: 1, y: 1}
|
||||||
|
@ -97,6 +112,7 @@ Material:
|
||||||
m_Offset: {x: 0, y: 0}
|
m_Offset: {x: 0, y: 0}
|
||||||
m_Ints: []
|
m_Ints: []
|
||||||
m_Floats:
|
m_Floats:
|
||||||
|
- PixelSnap: 0
|
||||||
- _AddPrecomputedVelocity: 0
|
- _AddPrecomputedVelocity: 0
|
||||||
- _AlphaClip: 1
|
- _AlphaClip: 1
|
||||||
- _AlphaToMask: 1
|
- _AlphaToMask: 1
|
||||||
|
@ -104,15 +120,17 @@ Material:
|
||||||
- _BlendModePreserveSpecular: 1
|
- _BlendModePreserveSpecular: 1
|
||||||
- _BlendOp: 0
|
- _BlendOp: 0
|
||||||
- _BumpScale: 1
|
- _BumpScale: 1
|
||||||
|
- _ClearCoat: 0
|
||||||
- _ClearCoatMask: 0
|
- _ClearCoatMask: 0
|
||||||
- _ClearCoatSmoothness: 0
|
- _ClearCoatSmoothness: 0
|
||||||
- _Cull: 2
|
- _Cull: 2
|
||||||
- _Cutoff: 0.5
|
- _Cutoff: 0.528
|
||||||
- _DetailAlbedoMapScale: 1
|
- _DetailAlbedoMapScale: 1
|
||||||
- _DetailNormalMapScale: 1
|
- _DetailNormalMapScale: 1
|
||||||
- _DstBlend: 0
|
- _DstBlend: 0
|
||||||
- _DstBlendAlpha: 0
|
- _DstBlendAlpha: 0
|
||||||
- _EnvironmentReflections: 1
|
- _EnableExternalAlpha: 0
|
||||||
|
- _EnvironmentReflections: 0
|
||||||
- _GlossMapScale: 0
|
- _GlossMapScale: 0
|
||||||
- _Glossiness: 0
|
- _Glossiness: 0
|
||||||
- _GlossyReflections: 0
|
- _GlossyReflections: 0
|
||||||
|
@ -120,11 +138,11 @@ Material:
|
||||||
- _OcclusionStrength: 1
|
- _OcclusionStrength: 1
|
||||||
- _Parallax: 0.005
|
- _Parallax: 0.005
|
||||||
- _QueueOffset: 0
|
- _QueueOffset: 0
|
||||||
- _ReceiveShadows: 1
|
- _ReceiveShadows: 0
|
||||||
- _SampleGI: 0
|
- _SampleGI: 0
|
||||||
- _Smoothness: 0.5
|
- _Smoothness: 0
|
||||||
- _SmoothnessTextureChannel: 0
|
- _SmoothnessTextureChannel: 0
|
||||||
- _SpecularHighlights: 1
|
- _SpecularHighlights: 0
|
||||||
- _SrcBlend: 1
|
- _SrcBlend: 1
|
||||||
- _SrcBlendAlpha: 1
|
- _SrcBlendAlpha: 1
|
||||||
- _Surface: 0
|
- _Surface: 0
|
||||||
|
@ -134,6 +152,7 @@ Material:
|
||||||
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
|
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
|
||||||
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
|
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
|
||||||
|
- _RendererColor: {r: 1, g: 1, b: 1, a: 1}
|
||||||
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
|
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
|
||||||
m_BuildTextureStacks: []
|
m_BuildTextureStacks: []
|
||||||
m_AllowLocking: 1
|
m_AllowLocking: 1
|
||||||
|
|
|
@ -56,7 +56,7 @@ Material:
|
||||||
m_Ints: []
|
m_Ints: []
|
||||||
m_Floats:
|
m_Floats:
|
||||||
- _CoatMask: 1
|
- _CoatMask: 1
|
||||||
- _FlakeIntensity: 3.4
|
- _FlakeIntensity: 2.5
|
||||||
- _FlakeScale: 1
|
- _FlakeScale: 1
|
||||||
- _FresnelPower: 4
|
- _FresnelPower: 4
|
||||||
- _Metallic: 1
|
- _Metallic: 1
|
||||||
|
|
|
@ -121,7 +121,7 @@ Material:
|
||||||
- _QueueOffset: 0
|
- _QueueOffset: 0
|
||||||
- _ReceiveShadows: 1
|
- _ReceiveShadows: 1
|
||||||
- _SampleGI: 0
|
- _SampleGI: 0
|
||||||
- _Smoothness: 0.333
|
- _Smoothness: 0.093
|
||||||
- _SmoothnessTextureChannel: 0
|
- _SmoothnessTextureChannel: 0
|
||||||
- _SpecularHighlights: 1
|
- _SpecularHighlights: 1
|
||||||
- _SrcBlend: 1
|
- _SrcBlend: 1
|
||||||
|
|
|
@ -0,0 +1,140 @@
|
||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &-3305027883947979572
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 11
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 0}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
version: 9
|
||||||
|
--- !u!21 &2100000
|
||||||
|
Material:
|
||||||
|
serializedVersion: 8
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_Name: Selfluminous
|
||||||
|
m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3}
|
||||||
|
m_Parent: {fileID: 0}
|
||||||
|
m_ModifiedSerializedProperties: 0
|
||||||
|
m_ValidKeywords:
|
||||||
|
- _EMISSION
|
||||||
|
- _SPECULAR_SETUP
|
||||||
|
m_InvalidKeywords: []
|
||||||
|
m_LightmapFlags: 2
|
||||||
|
m_EnableInstancingVariants: 0
|
||||||
|
m_DoubleSidedGI: 0
|
||||||
|
m_CustomRenderQueue: 2000
|
||||||
|
stringTagMap:
|
||||||
|
RenderType: Opaque
|
||||||
|
disabledShaderPasses:
|
||||||
|
- MOTIONVECTORS
|
||||||
|
m_LockedProperties:
|
||||||
|
m_SavedProperties:
|
||||||
|
serializedVersion: 3
|
||||||
|
m_TexEnvs:
|
||||||
|
- _BaseMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _BumpMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailAlbedoMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailMask:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailNormalMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _EmissionMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MainTex:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MetallicGlossMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _OcclusionMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _ParallaxMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _SpecGlossMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- unity_Lightmaps:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- unity_LightmapsInd:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- unity_ShadowMasks:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
m_Ints: []
|
||||||
|
m_Floats:
|
||||||
|
- _AddPrecomputedVelocity: 0
|
||||||
|
- _AlphaClip: 0
|
||||||
|
- _AlphaToMask: 0
|
||||||
|
- _Blend: 0
|
||||||
|
- _BlendModePreserveSpecular: 1
|
||||||
|
- _BlendOp: 0
|
||||||
|
- _BumpScale: 1
|
||||||
|
- _ClearCoatMask: 0
|
||||||
|
- _ClearCoatSmoothness: 0
|
||||||
|
- _Cull: 2
|
||||||
|
- _Cutoff: 0.5
|
||||||
|
- _DetailAlbedoMapScale: 1
|
||||||
|
- _DetailNormalMapScale: 1
|
||||||
|
- _DstBlend: 0
|
||||||
|
- _DstBlendAlpha: 0
|
||||||
|
- _EnvironmentReflections: 1
|
||||||
|
- _GlossMapScale: 0
|
||||||
|
- _Glossiness: 0
|
||||||
|
- _GlossyReflections: 0
|
||||||
|
- _Metallic: 0
|
||||||
|
- _OcclusionStrength: 1
|
||||||
|
- _Parallax: 0.005
|
||||||
|
- _QueueOffset: 0
|
||||||
|
- _ReceiveShadows: 1
|
||||||
|
- _SampleGI: 0
|
||||||
|
- _Smoothness: 0.953
|
||||||
|
- _SmoothnessTextureChannel: 0
|
||||||
|
- _SpecularHighlights: 1
|
||||||
|
- _SrcBlend: 1
|
||||||
|
- _SrcBlendAlpha: 1
|
||||||
|
- _Surface: 0
|
||||||
|
- _WorkflowMode: 0
|
||||||
|
- _ZWrite: 1
|
||||||
|
m_Colors:
|
||||||
|
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
- _EmissionColor: {r: 0.18725492, g: 0.18725492, b: 0.18725492, a: 1}
|
||||||
|
- _SpecColor: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_BuildTextureStacks: []
|
||||||
|
m_AllowLocking: 1
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5577222a9a67c5841906d5ed66e548cb
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 2100000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,58 @@
|
||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 0}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: fed3f3d91454db34f894abc9ea1d8ec4, type: 3}
|
||||||
|
m_Name: VLBConfigOverride
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
geometryOverrideLayer: 1
|
||||||
|
geometryLayerID: 1
|
||||||
|
geometryTag: Untagged
|
||||||
|
geometryRenderQueue: 3000
|
||||||
|
geometryRenderQueueHD: 3100
|
||||||
|
m_RenderPipeline: 1
|
||||||
|
m_RenderingMode: 1
|
||||||
|
ditheringFactor: 0
|
||||||
|
useLightColorTemperature: 1
|
||||||
|
sharedMeshSides: 24
|
||||||
|
sharedMeshSegments: 5
|
||||||
|
hdBeamsCameraBlendingDistance: 0.5
|
||||||
|
urpDepthCameraScriptableRendererIndex: -1
|
||||||
|
globalNoiseScale: 0.5
|
||||||
|
globalNoiseVelocity: {x: 0.07, y: 0.18, z: 0.05}
|
||||||
|
fadeOutCameraTag: MainCamera
|
||||||
|
noiseTexture3D: {fileID: 11700000, guid: e4c4c1cbfaa63db45b17891f8f2caf6d, type: 2}
|
||||||
|
dustParticlesPrefab: {fileID: 19822582, guid: 472bc216b0f362147943a3cedc36711f, type: 3}
|
||||||
|
ditheringNoiseTexture: {fileID: 2800000, guid: 52f46dcaae8132a4090a9a8d14ece711, type: 3}
|
||||||
|
jitteringNoiseTexture: {fileID: 2800000, guid: 7c156dffca1e1ef4c916c6237a9d5f16, type: 3}
|
||||||
|
featureEnabledColorGradient: 1
|
||||||
|
featureEnabledDepthBlend: 1
|
||||||
|
featureEnabledNoise3D: 1
|
||||||
|
featureEnabledDynamicOcclusion: 1
|
||||||
|
featureEnabledMeshSkewing: 1
|
||||||
|
featureEnabledShaderAccuracyHigh: 1
|
||||||
|
featureEnabledShadow: 1
|
||||||
|
featureEnabledCookie: 1
|
||||||
|
m_RaymarchingQualities:
|
||||||
|
- name: Fast
|
||||||
|
stepCount: 5
|
||||||
|
_UniqueID: 1
|
||||||
|
- name: Balanced
|
||||||
|
stepCount: 10
|
||||||
|
_UniqueID: 2
|
||||||
|
- name: High
|
||||||
|
stepCount: 20
|
||||||
|
_UniqueID: 3
|
||||||
|
m_DefaultRaymarchingQualityUniqueID: 2
|
||||||
|
pluginVersion: 20002
|
||||||
|
_DummyMaterial: {fileID: 2100000, guid: 6206c1f06d9d96b42a4c4f53aaaa830a, type: 2}
|
||||||
|
_DummyMaterialHD: {fileID: 2100000, guid: 5c420c01b9826e34bb11fa3994f64a85, type: 2}
|
||||||
|
_BeamShader: {fileID: 4800000, guid: 1f6dcfbce9379804a94d4f55cbacf77d, type: 3}
|
||||||
|
_BeamShaderHD: {fileID: 4800000, guid: 8d149066e32a2d54c8a793b8636e3d67, type: 3}
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 57b1a33949d082e4387b4b6225281936
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -309,6 +309,10 @@ PrefabInstance:
|
||||||
propertyPath: 'm_Materials.Array.data[0]'
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 2100000, guid: b677a3821c00fa944b419e6b57bae762, type: 2}
|
objectReference: {fileID: 2100000, guid: b677a3821c00fa944b419e6b57bae762, type: 2}
|
||||||
|
- target: {fileID: -5672746841103945473, guid: b61a2b8197bf8734882f3767aa216bd0, type: 3}
|
||||||
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
|
value:
|
||||||
|
objectReference: {fileID: 2100000, guid: 1d2c8c3faa51a23418adb3a75d61e86a, type: 2}
|
||||||
- target: {fileID: -5551976591639103817, guid: b61a2b8197bf8734882f3767aa216bd0, type: 3}
|
- target: {fileID: -5551976591639103817, guid: b61a2b8197bf8734882f3767aa216bd0, type: 3}
|
||||||
propertyPath: 'm_Materials.Array.data[0]'
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
value:
|
value:
|
||||||
|
@ -337,6 +341,10 @@ PrefabInstance:
|
||||||
propertyPath: 'm_Materials.Array.data[0]'
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 2100000, guid: 5569973d76e5e0949af5a2869d8eaf63, type: 2}
|
objectReference: {fileID: 2100000, guid: 5569973d76e5e0949af5a2869d8eaf63, type: 2}
|
||||||
|
- target: {fileID: -1910532907112686860, guid: b61a2b8197bf8734882f3767aa216bd0, type: 3}
|
||||||
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
|
value:
|
||||||
|
objectReference: {fileID: 2100000, guid: b677a3821c00fa944b419e6b57bae762, type: 2}
|
||||||
- target: {fileID: -1541359091028947840, guid: b61a2b8197bf8734882f3767aa216bd0, type: 3}
|
- target: {fileID: -1541359091028947840, guid: b61a2b8197bf8734882f3767aa216bd0, type: 3}
|
||||||
propertyPath: 'm_Materials.Array.data[0]'
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
value:
|
value:
|
||||||
|
@ -593,7 +601,7 @@ MonoBehaviour:
|
||||||
m_VolumeTrigger: {fileID: 0}
|
m_VolumeTrigger: {fileID: 0}
|
||||||
m_VolumeFrameworkUpdateModeOption: 2
|
m_VolumeFrameworkUpdateModeOption: 2
|
||||||
m_RenderPostProcessing: 1
|
m_RenderPostProcessing: 1
|
||||||
m_Antialiasing: 1
|
m_Antialiasing: 3
|
||||||
m_AntialiasingQuality: 2
|
m_AntialiasingQuality: 2
|
||||||
m_StopNaN: 0
|
m_StopNaN: 0
|
||||||
m_Dithering: 1
|
m_Dithering: 1
|
||||||
|
@ -712,8 +720,8 @@ MonoBehaviour:
|
||||||
min: 0
|
min: 0
|
||||||
max: 90
|
max: 90
|
||||||
distanceRange:
|
distanceRange:
|
||||||
min: 3
|
min: 3.5
|
||||||
max: 10
|
max: 5
|
||||||
damper: 3
|
damper: 3
|
||||||
--- !u!1001 &1000974354
|
--- !u!1001 &1000974354
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
|
@ -770,7 +778,7 @@ PrefabInstance:
|
||||||
- target: {fileID: -4665305535396987961, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
- target: {fileID: -4665305535396987961, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
||||||
propertyPath: 'm_Materials.Array.data[0]'
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 2100000, guid: a41607441a956b44695d986e66049316, type: 2}
|
objectReference: {fileID: 2100000, guid: 5577222a9a67c5841906d5ed66e548cb, type: 2}
|
||||||
- target: {fileID: 919132149155446097, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
- target: {fileID: 919132149155446097, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
||||||
propertyPath: m_Name
|
propertyPath: m_Name
|
||||||
value: HeadLamp
|
value: HeadLamp
|
||||||
|
@ -786,7 +794,7 @@ PrefabInstance:
|
||||||
- target: {fileID: 3241718991007327341, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
- target: {fileID: 3241718991007327341, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
||||||
propertyPath: 'm_Materials.Array.data[0]'
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 2100000, guid: a41607441a956b44695d986e66049316, type: 2}
|
objectReference: {fileID: 2100000, guid: 5577222a9a67c5841906d5ed66e548cb, type: 2}
|
||||||
- target: {fileID: 5620797306854830567, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
- target: {fileID: 5620797306854830567, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
||||||
propertyPath: 'm_Materials.Array.data[0]'
|
propertyPath: 'm_Materials.Array.data[0]'
|
||||||
value:
|
value:
|
||||||
|
@ -804,6 +812,199 @@ PrefabInstance:
|
||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
m_AddedComponents: []
|
m_AddedComponents: []
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
m_SourcePrefab: {fileID: 100100000, guid: 910cb36a8f2043d409234097562f7eca, type: 3}
|
||||||
|
--- !u!1 &1101601671
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 1101601672}
|
||||||
|
- component: {fileID: 1101601675}
|
||||||
|
- component: {fileID: 1101601674}
|
||||||
|
- component: {fileID: 1101601673}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Spot Light (1)
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &1101601672
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1101601671}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0.015860192, y: -0.9700445, z: 0.06595587, w: 0.23326384}
|
||||||
|
m_LocalPosition: {x: -0.362, y: 0.786, z: -2.492}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 1208501849}
|
||||||
|
m_LocalEulerAnglesHint: {x: 7.779, y: -152.958, z: 0}
|
||||||
|
--- !u!114 &1101601673
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1101601671}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 92b0a6142b2b0b449a62558873544363, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
pluginVersion: 20002
|
||||||
|
m_ColorFromLight: 0
|
||||||
|
m_ColorMode: 0
|
||||||
|
m_ColorFlat: {r: 1, g: 0.9913884, b: 0.9386792, a: 1}
|
||||||
|
m_ColorGradient:
|
||||||
|
serializedVersion: 2
|
||||||
|
key0: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
key1: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
key2: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key3: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key4: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key5: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key6: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key7: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
ctime0: 0
|
||||||
|
ctime1: 65535
|
||||||
|
ctime2: 0
|
||||||
|
ctime3: 0
|
||||||
|
ctime4: 0
|
||||||
|
ctime5: 0
|
||||||
|
ctime6: 0
|
||||||
|
ctime7: 0
|
||||||
|
atime0: 0
|
||||||
|
atime1: 65535
|
||||||
|
atime2: 0
|
||||||
|
atime3: 0
|
||||||
|
atime4: 0
|
||||||
|
atime5: 0
|
||||||
|
atime6: 0
|
||||||
|
atime7: 0
|
||||||
|
m_Mode: 0
|
||||||
|
m_ColorSpace: -1
|
||||||
|
m_NumColorKeys: 2
|
||||||
|
m_NumAlphaKeys: 2
|
||||||
|
m_BlendingMode: 0
|
||||||
|
m_Intensity: 1
|
||||||
|
m_IntensityMultiplier: 1
|
||||||
|
m_HDRPExposureWeight: 0
|
||||||
|
m_SpotAngle: 19.170658
|
||||||
|
m_SpotAngleMultiplier: 1
|
||||||
|
m_ConeRadiusStart: 0.12
|
||||||
|
m_Scalable: 1
|
||||||
|
m_FallOffStart: 0
|
||||||
|
m_FallOffEnd: 10
|
||||||
|
m_FallOffEndMultiplier: 1
|
||||||
|
m_AttenuationEquation: 1
|
||||||
|
m_SideSoftness: 2.17
|
||||||
|
m_RaymarchingQualityID: 2
|
||||||
|
m_JitteringFactor: 0
|
||||||
|
m_JitteringFrameRate: 60
|
||||||
|
m_JitteringLerpRange:
|
||||||
|
m_MinValue: 0
|
||||||
|
m_MaxValue: 0.33
|
||||||
|
m_NoiseMode: 0
|
||||||
|
m_NoiseIntensity: 0.5
|
||||||
|
m_NoiseScaleUseGlobal: 1
|
||||||
|
m_NoiseScaleLocal: 0.5
|
||||||
|
m_NoiseVelocityUseGlobal: 1
|
||||||
|
m_NoiseVelocityLocal: {x: 0.07, y: 0.18, z: 0.05}
|
||||||
|
--- !u!114 &1101601674
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1101601671}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 474bcb49853aa07438625e644c072ee6, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_Version: 3
|
||||||
|
m_UsePipelineSettings: 1
|
||||||
|
m_AdditionalLightsShadowResolutionTier: 2
|
||||||
|
m_LightLayerMask: 1
|
||||||
|
m_RenderingLayers: 1
|
||||||
|
m_CustomShadowLayers: 0
|
||||||
|
m_ShadowLayerMask: 1
|
||||||
|
m_ShadowRenderingLayers: 1
|
||||||
|
m_LightCookieSize: {x: 1, y: 1}
|
||||||
|
m_LightCookieOffset: {x: 0, y: 0}
|
||||||
|
m_SoftShadowQuality: 0
|
||||||
|
--- !u!108 &1101601675
|
||||||
|
Light:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1101601671}
|
||||||
|
m_Enabled: 1
|
||||||
|
serializedVersion: 11
|
||||||
|
m_Type: 0
|
||||||
|
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_Intensity: 1
|
||||||
|
m_Range: 10
|
||||||
|
m_SpotAngle: 19.170658
|
||||||
|
m_InnerSpotAngle: 10.972738
|
||||||
|
m_CookieSize: 10
|
||||||
|
m_Shadows:
|
||||||
|
m_Type: 0
|
||||||
|
m_Resolution: -1
|
||||||
|
m_CustomResolution: -1
|
||||||
|
m_Strength: 1
|
||||||
|
m_Bias: 0.05
|
||||||
|
m_NormalBias: 0.4
|
||||||
|
m_NearPlane: 0.2
|
||||||
|
m_CullingMatrixOverride:
|
||||||
|
e00: 1
|
||||||
|
e01: 0
|
||||||
|
e02: 0
|
||||||
|
e03: 0
|
||||||
|
e10: 0
|
||||||
|
e11: 1
|
||||||
|
e12: 0
|
||||||
|
e13: 0
|
||||||
|
e20: 0
|
||||||
|
e21: 0
|
||||||
|
e22: 1
|
||||||
|
e23: 0
|
||||||
|
e30: 0
|
||||||
|
e31: 0
|
||||||
|
e32: 0
|
||||||
|
e33: 1
|
||||||
|
m_UseCullingMatrixOverride: 0
|
||||||
|
m_Cookie: {fileID: 0}
|
||||||
|
m_DrawHalo: 0
|
||||||
|
m_Flare: {fileID: 0}
|
||||||
|
m_RenderMode: 0
|
||||||
|
m_CullingMask:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 4294967295
|
||||||
|
m_RenderingLayerMask: 1
|
||||||
|
m_Lightmapping: 4
|
||||||
|
m_LightShadowCasterMode: 0
|
||||||
|
m_AreaSize: {x: 1, y: 1}
|
||||||
|
m_BounceIntensity: 1
|
||||||
|
m_ColorTemperature: 6570
|
||||||
|
m_UseColorTemperature: 0
|
||||||
|
m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_UseBoundingSphereOverride: 0
|
||||||
|
m_UseViewFrustumForShadowCasterCull: 1
|
||||||
|
m_ForceVisible: 0
|
||||||
|
m_ShadowRadius: 0
|
||||||
|
m_ShadowAngle: 0
|
||||||
|
m_LightUnit: 1
|
||||||
|
m_LuxAtDistance: 1
|
||||||
|
m_EnableSpotReflector: 1
|
||||||
--- !u!1 &1160234425
|
--- !u!1 &1160234425
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
@ -887,6 +1088,8 @@ Transform:
|
||||||
- {fileID: 1894058896}
|
- {fileID: 1894058896}
|
||||||
- {fileID: 2076733340}
|
- {fileID: 2076733340}
|
||||||
- {fileID: 1631606062}
|
- {fileID: 1631606062}
|
||||||
|
- {fileID: 2101266204}
|
||||||
|
- {fileID: 1101601672}
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!4 &1338055599 stripped
|
--- !u!4 &1338055599 stripped
|
||||||
|
@ -1006,8 +1209,8 @@ Transform:
|
||||||
m_GameObject: {fileID: 1468052971}
|
m_GameObject: {fileID: 1468052971}
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||||
m_LocalPosition: {x: 0, y: 0, z: 11.499999}
|
m_LocalPosition: {x: 0, y: 0, z: 40}
|
||||||
m_LocalScale: {x: 24.100002, y: 14.100001, z: 15}
|
m_LocalScale: {x: 82.1, y: 46.2, z: 15}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 961739753}
|
m_Father: {fileID: 961739753}
|
||||||
|
@ -1248,6 +1451,199 @@ Transform:
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 1208501849}
|
m_Father: {fileID: 1208501849}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!1 &2101266203
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 2101266204}
|
||||||
|
- component: {fileID: 2101266206}
|
||||||
|
- component: {fileID: 2101266205}
|
||||||
|
- component: {fileID: 2101266207}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Spot Light
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &2101266204
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 2101266203}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0.015910285, y: -0.96986705, z: 0.065943755, w: 0.23400033}
|
||||||
|
m_LocalPosition: {x: -1.593, y: 0.786, z: -1.919}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 1208501849}
|
||||||
|
m_LocalEulerAnglesHint: {x: 7.779, y: -152.871, z: 0}
|
||||||
|
--- !u!114 &2101266205
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 2101266203}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 474bcb49853aa07438625e644c072ee6, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_Version: 3
|
||||||
|
m_UsePipelineSettings: 1
|
||||||
|
m_AdditionalLightsShadowResolutionTier: 2
|
||||||
|
m_LightLayerMask: 1
|
||||||
|
m_RenderingLayers: 1
|
||||||
|
m_CustomShadowLayers: 0
|
||||||
|
m_ShadowLayerMask: 1
|
||||||
|
m_ShadowRenderingLayers: 1
|
||||||
|
m_LightCookieSize: {x: 1, y: 1}
|
||||||
|
m_LightCookieOffset: {x: 0, y: 0}
|
||||||
|
m_SoftShadowQuality: 0
|
||||||
|
--- !u!108 &2101266206
|
||||||
|
Light:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 2101266203}
|
||||||
|
m_Enabled: 1
|
||||||
|
serializedVersion: 11
|
||||||
|
m_Type: 0
|
||||||
|
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_Intensity: 1
|
||||||
|
m_Range: 10
|
||||||
|
m_SpotAngle: 19.170658
|
||||||
|
m_InnerSpotAngle: 10.972738
|
||||||
|
m_CookieSize: 10
|
||||||
|
m_Shadows:
|
||||||
|
m_Type: 0
|
||||||
|
m_Resolution: -1
|
||||||
|
m_CustomResolution: -1
|
||||||
|
m_Strength: 1
|
||||||
|
m_Bias: 0.05
|
||||||
|
m_NormalBias: 0.4
|
||||||
|
m_NearPlane: 0.2
|
||||||
|
m_CullingMatrixOverride:
|
||||||
|
e00: 1
|
||||||
|
e01: 0
|
||||||
|
e02: 0
|
||||||
|
e03: 0
|
||||||
|
e10: 0
|
||||||
|
e11: 1
|
||||||
|
e12: 0
|
||||||
|
e13: 0
|
||||||
|
e20: 0
|
||||||
|
e21: 0
|
||||||
|
e22: 1
|
||||||
|
e23: 0
|
||||||
|
e30: 0
|
||||||
|
e31: 0
|
||||||
|
e32: 0
|
||||||
|
e33: 1
|
||||||
|
m_UseCullingMatrixOverride: 0
|
||||||
|
m_Cookie: {fileID: 0}
|
||||||
|
m_DrawHalo: 0
|
||||||
|
m_Flare: {fileID: 0}
|
||||||
|
m_RenderMode: 0
|
||||||
|
m_CullingMask:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 4294967295
|
||||||
|
m_RenderingLayerMask: 1
|
||||||
|
m_Lightmapping: 4
|
||||||
|
m_LightShadowCasterMode: 0
|
||||||
|
m_AreaSize: {x: 1, y: 1}
|
||||||
|
m_BounceIntensity: 1
|
||||||
|
m_ColorTemperature: 6570
|
||||||
|
m_UseColorTemperature: 0
|
||||||
|
m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_UseBoundingSphereOverride: 0
|
||||||
|
m_UseViewFrustumForShadowCasterCull: 1
|
||||||
|
m_ForceVisible: 0
|
||||||
|
m_ShadowRadius: 0
|
||||||
|
m_ShadowAngle: 0
|
||||||
|
m_LightUnit: 1
|
||||||
|
m_LuxAtDistance: 1
|
||||||
|
m_EnableSpotReflector: 1
|
||||||
|
--- !u!114 &2101266207
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 2101266203}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 92b0a6142b2b0b449a62558873544363, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
pluginVersion: 20002
|
||||||
|
m_ColorFromLight: 0
|
||||||
|
m_ColorMode: 0
|
||||||
|
m_ColorFlat: {r: 1, g: 0.9913884, b: 0.9386792, a: 1}
|
||||||
|
m_ColorGradient:
|
||||||
|
serializedVersion: 2
|
||||||
|
key0: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
key1: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
key2: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key3: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key4: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key5: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key6: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
key7: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
ctime0: 0
|
||||||
|
ctime1: 65535
|
||||||
|
ctime2: 0
|
||||||
|
ctime3: 0
|
||||||
|
ctime4: 0
|
||||||
|
ctime5: 0
|
||||||
|
ctime6: 0
|
||||||
|
ctime7: 0
|
||||||
|
atime0: 0
|
||||||
|
atime1: 65535
|
||||||
|
atime2: 0
|
||||||
|
atime3: 0
|
||||||
|
atime4: 0
|
||||||
|
atime5: 0
|
||||||
|
atime6: 0
|
||||||
|
atime7: 0
|
||||||
|
m_Mode: 0
|
||||||
|
m_ColorSpace: -1
|
||||||
|
m_NumColorKeys: 2
|
||||||
|
m_NumAlphaKeys: 2
|
||||||
|
m_BlendingMode: 0
|
||||||
|
m_Intensity: 1
|
||||||
|
m_IntensityMultiplier: 1
|
||||||
|
m_HDRPExposureWeight: 0
|
||||||
|
m_SpotAngle: 19.170658
|
||||||
|
m_SpotAngleMultiplier: 1
|
||||||
|
m_ConeRadiusStart: 0.12
|
||||||
|
m_Scalable: 1
|
||||||
|
m_FallOffStart: 0
|
||||||
|
m_FallOffEnd: 10
|
||||||
|
m_FallOffEndMultiplier: 1
|
||||||
|
m_AttenuationEquation: 1
|
||||||
|
m_SideSoftness: 2.17
|
||||||
|
m_RaymarchingQualityID: 2
|
||||||
|
m_JitteringFactor: 0
|
||||||
|
m_JitteringFrameRate: 60
|
||||||
|
m_JitteringLerpRange:
|
||||||
|
m_MinValue: 0
|
||||||
|
m_MaxValue: 0.33
|
||||||
|
m_NoiseMode: 0
|
||||||
|
m_NoiseIntensity: 0.5
|
||||||
|
m_NoiseScaleUseGlobal: 1
|
||||||
|
m_NoiseScaleLocal: 0.5
|
||||||
|
m_NoiseVelocityUseGlobal: 1
|
||||||
|
m_NoiseVelocityLocal: {x: 0.07, y: 0.18, z: 0.05}
|
||||||
--- !u!1 &2116198337
|
--- !u!1 &2116198337
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|
|
@ -18,13 +18,13 @@ MonoBehaviour:
|
||||||
m_Value: 1
|
m_Value: 1
|
||||||
threshold:
|
threshold:
|
||||||
m_OverrideState: 1
|
m_OverrideState: 1
|
||||||
m_Value: 25
|
m_Value: 10
|
||||||
intensity:
|
intensity:
|
||||||
m_OverrideState: 1
|
m_OverrideState: 1
|
||||||
m_Value: 0.1
|
m_Value: 0.1
|
||||||
scatter:
|
scatter:
|
||||||
m_OverrideState: 1
|
m_OverrideState: 1
|
||||||
m_Value: 1
|
m_Value: 0.5
|
||||||
clamp:
|
clamp:
|
||||||
m_OverrideState: 0
|
m_OverrideState: 0
|
||||||
m_Value: 65472
|
m_Value: 65472
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 127de06fc00814441afa5e082e33d98b
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: db9b532f8762be04da977168e18b0e6c
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,135 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
class ButtonToggleScope : System.IDisposable
|
||||||
|
{
|
||||||
|
SerializedProperty m_Property;
|
||||||
|
bool m_DisableGroup = false;
|
||||||
|
GUIContent m_Content = null;
|
||||||
|
|
||||||
|
void Enable()
|
||||||
|
{
|
||||||
|
EditorGUILayout.BeginHorizontal();
|
||||||
|
if (m_DisableGroup)
|
||||||
|
EditorGUI.BeginDisabledGroup(isPropertyToggled || m_Property.hasMultipleDifferentValues);
|
||||||
|
}
|
||||||
|
|
||||||
|
void Disable()
|
||||||
|
{
|
||||||
|
EndDisabledGroup();
|
||||||
|
DrawToggleButton();
|
||||||
|
EditorGUILayout.EndHorizontal();
|
||||||
|
m_Property = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void EndDisabledGroup()
|
||||||
|
{
|
||||||
|
if (m_DisableGroup)
|
||||||
|
EditorGUI.EndDisabledGroup();
|
||||||
|
m_DisableGroup = false; // prevent from calling EndDisabledGroup twice
|
||||||
|
}
|
||||||
|
|
||||||
|
public ButtonToggleScope(SerializedProperty prop, bool disableGroup, GUIContent content)
|
||||||
|
{
|
||||||
|
m_Property = prop;
|
||||||
|
m_DisableGroup = disableGroup;
|
||||||
|
m_Content = content;
|
||||||
|
Enable();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Dispose() { Disable(); }
|
||||||
|
|
||||||
|
static GUIStyle ms_ToggleButtonStyleNormal = null;
|
||||||
|
static GUIStyle ms_ToggleButtonStyleToggled = null;
|
||||||
|
static GUIStyle ms_ToggleButtonStyleMixedValue = null;
|
||||||
|
|
||||||
|
bool isPropertyToggled
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
switch(m_Property.propertyType)
|
||||||
|
{
|
||||||
|
case SerializedPropertyType.Boolean: return m_Property.boolValue;
|
||||||
|
case SerializedPropertyType.Float: return m_Property.floatValue >= 0.0f;
|
||||||
|
default: Debug.LogFormat("Invalid PropertyType {0}", m_Property.propertyType); return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void ToggleValue()
|
||||||
|
{
|
||||||
|
switch (m_Property.propertyType)
|
||||||
|
{
|
||||||
|
case SerializedPropertyType.Boolean: m_Property.boolValue = !m_Property.boolValue; break;
|
||||||
|
case SerializedPropertyType.Float:
|
||||||
|
{
|
||||||
|
if (m_Property.floatValue == 0f) m_Property.floatValue = float.MinValue;
|
||||||
|
else if (m_Property.floatValue == float.MinValue) m_Property.floatValue = 0f;
|
||||||
|
else m_Property.floatValue = -m_Property.floatValue;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
default: Debug.LogFormat("Invalid PropertyType {0}", m_Property.propertyType); break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void DrawToggleButton()
|
||||||
|
{
|
||||||
|
if (ms_ToggleButtonStyleNormal == null)
|
||||||
|
{
|
||||||
|
ms_ToggleButtonStyleNormal = new GUIStyle(EditorStyles.miniButton);
|
||||||
|
ms_ToggleButtonStyleToggled = new GUIStyle(ms_ToggleButtonStyleNormal);
|
||||||
|
ms_ToggleButtonStyleToggled.normal.background = ms_ToggleButtonStyleToggled.active.background;
|
||||||
|
ms_ToggleButtonStyleMixedValue = new GUIStyle(ms_ToggleButtonStyleToggled);
|
||||||
|
ms_ToggleButtonStyleMixedValue.fontStyle = FontStyle.Italic;
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
EditorGUI.showMixedValue = m_Property.hasMultipleDifferentValues;
|
||||||
|
|
||||||
|
var style = EditorGUI.showMixedValue ? ms_ToggleButtonStyleMixedValue : (isPropertyToggled ? ms_ToggleButtonStyleToggled : ms_ToggleButtonStyleNormal);
|
||||||
|
var calcSize = style.CalcSize(m_Content);
|
||||||
|
|
||||||
|
#if UNITY_2019_3_OR_NEWER
|
||||||
|
var defaultColor = GUI.backgroundColor;
|
||||||
|
if(isPropertyToggled)
|
||||||
|
GUI.backgroundColor = new Color(0.75f, 0.75f, 0.75f);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
GUILayout.Button(
|
||||||
|
m_Content,
|
||||||
|
style,
|
||||||
|
GUILayout.MaxWidth(calcSize.x));
|
||||||
|
|
||||||
|
#if UNITY_2019_3_OR_NEWER
|
||||||
|
GUI.backgroundColor = defaultColor;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
EditorGUI.showMixedValue = false;
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
ToggleValue();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static ButtonToggleScope FromLight(SerializedProperty prop, bool visible)
|
||||||
|
{
|
||||||
|
if (!visible) return null;
|
||||||
|
|
||||||
|
return new ButtonToggleScope(prop,
|
||||||
|
true, // disableGroup
|
||||||
|
EditorData.Instance.contentFromSpotLight);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static ButtonToggleScope Advanced(SerializedProperty prop, bool visible)
|
||||||
|
{
|
||||||
|
if (!visible) return null;
|
||||||
|
|
||||||
|
return new ButtonToggleScope(prop,
|
||||||
|
false, // disableGroup
|
||||||
|
EditorStrings.Beam.SD.IntensityModeAdvanced);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif // UNITY_EDITOR
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f6e5288f7265ad940adec22ce90353ce
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,44 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public class EditorData : ScriptableObject
|
||||||
|
{
|
||||||
|
[SerializeField] Texture2D buttonAddDustParticles = null;
|
||||||
|
[SerializeField] Texture2D buttonAddDynamicOcclusion = null;
|
||||||
|
[SerializeField] Texture2D buttonAddTriggerZone = null;
|
||||||
|
[SerializeField] Texture2D buttonAddEffect = null;
|
||||||
|
[SerializeField] Texture2D buttonFromSpotLight = null;
|
||||||
|
|
||||||
|
[SerializeField] Texture2D buttonAddCookieHD = null;
|
||||||
|
[SerializeField] Texture2D buttonAddShadowHD = null;
|
||||||
|
[SerializeField] Texture2D buttonAddTrackRealtimeChangesOnLightHD = null;
|
||||||
|
|
||||||
|
public GUIContent contentAddDustParticles { get { return new GUIContent(Instance.buttonAddDustParticles, EditorStrings.Beam.ButtonAddDustParticles); } }
|
||||||
|
public GUIContent contentAddDynamicOcclusion { get { return new GUIContent(Instance.buttonAddDynamicOcclusion, EditorStrings.Beam.ButtonAddDynamicOcclusion); } }
|
||||||
|
public GUIContent contentAddTriggerZone { get { return new GUIContent(Instance.buttonAddTriggerZone, EditorStrings.Beam.ButtonAddTriggerZone); } }
|
||||||
|
public GUIContent contentAddEffect { get { return new GUIContent(Instance.buttonAddEffect, EditorStrings.Beam.ButtonAddEffect); } }
|
||||||
|
public GUIContent contentFromSpotLight { get { return new GUIContent(Instance.buttonFromSpotLight, EditorStrings.Beam.FromSpotLight); } }
|
||||||
|
|
||||||
|
public GUIContent contentAddCookieHD { get { return new GUIContent(Instance.buttonAddCookieHD, EditorStrings.Beam.HD.ButtonAddCookie); } }
|
||||||
|
public GUIContent contentAddShadowHD { get { return new GUIContent(Instance.buttonAddShadowHD, EditorStrings.Beam.HD.ButtonAddShadow); } }
|
||||||
|
public GUIContent contentAddTrackRealtimeChangesOnLightHD { get { return new GUIContent(Instance.buttonAddTrackRealtimeChangesOnLightHD, EditorStrings.Beam.HD.ButtonAddTrackRealtimeChangesOnLight); } }
|
||||||
|
|
||||||
|
static EditorData ms_Instance = null;
|
||||||
|
public static EditorData Instance
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (ms_Instance == null)
|
||||||
|
{
|
||||||
|
ms_Instance = Resources.Load<EditorData>("VLBEditorData");
|
||||||
|
Debug.Assert(ms_Instance != null, "Failed to find asset 'VLBEditorData', please reinstall the 'Volumetric Light Beam' plugin.");
|
||||||
|
}
|
||||||
|
return ms_Instance;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f87284b87b8be7c4b9708f25ddb6669b
|
||||||
|
timeCreated: 1617782038
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,335 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEditor.IMGUI.Controls;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public static class EditorExtensions
|
||||||
|
{
|
||||||
|
public static class SD
|
||||||
|
{
|
||||||
|
public static GameObject NewBeam() { return new GameObject("Volumetric Light Beam SD", typeof(VolumetricLightBeamSD)); }
|
||||||
|
|
||||||
|
public static GameObject NewBeam2D()
|
||||||
|
{
|
||||||
|
var gao = new GameObject("Volumetric Light Beam SD (2D)", typeof(VolumetricLightBeamSD));
|
||||||
|
gao.GetComponent<VolumetricLightBeamSD>().dimensions = Dimensions.Dim2D;
|
||||||
|
return gao;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static GameObject NewBeamAndDust() { return new GameObject("Volumetric Light Beam SD + Dust", typeof(VolumetricLightBeamSD), typeof(VolumetricDustParticles)); }
|
||||||
|
|
||||||
|
public static GameObject NewSpotLightAndBeam()
|
||||||
|
{
|
||||||
|
var light = Utils.NewWithComponent<Light>("Spotlight and Beam SD");
|
||||||
|
light.type = LightType.Spot;
|
||||||
|
var gao = light.gameObject;
|
||||||
|
gao.AddComponent<VolumetricLightBeamSD>();
|
||||||
|
return gao;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class HD
|
||||||
|
{
|
||||||
|
public static GameObject NewBeam() { return new GameObject("Volumetric Light Beam HD", typeof(VolumetricLightBeamHD)); }
|
||||||
|
public static GameObject NewBeam2D() { return new GameObject("Volumetric Light Beam HD (2D)", typeof(VolumetricLightBeamHD2D)); }
|
||||||
|
public static GameObject NewBeamAndDust() { return new GameObject("Volumetric Light Beam HD + Dust", typeof(VolumetricLightBeamHD), typeof(VolumetricDustParticles)); }
|
||||||
|
|
||||||
|
public static GameObject NewSpotLightAndBeam()
|
||||||
|
{
|
||||||
|
var light = Utils.NewWithComponent<Light>("Spotlight and Beam HD");
|
||||||
|
light.type = LightType.Spot;
|
||||||
|
var gao = light.gameObject;
|
||||||
|
gao.AddComponent<VolumetricLightBeamHD>().scalable = false;
|
||||||
|
return gao;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void OnNewGameObjectCreated(GameObject gao, MenuCommand menuCommand)
|
||||||
|
{
|
||||||
|
Debug.Assert(gao != null);
|
||||||
|
Debug.Assert(menuCommand != null);
|
||||||
|
|
||||||
|
OnNewGameObjectCreated(gao, menuCommand.context as GameObject);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void OnNewGameObjectCreated(GameObject gao, GameObject parentGao)
|
||||||
|
{
|
||||||
|
Debug.Assert(gao != null);
|
||||||
|
|
||||||
|
if (parentGao == null)
|
||||||
|
{
|
||||||
|
#if UNITY_2021_2_OR_NEWER
|
||||||
|
var currentPrefabStage = UnityEditor.SceneManagement.PrefabStageUtility.GetCurrentPrefabStage();
|
||||||
|
#else
|
||||||
|
var currentPrefabStage = UnityEditor.Experimental.SceneManagement.PrefabStageUtility.GetCurrentPrefabStage();
|
||||||
|
#endif
|
||||||
|
if (currentPrefabStage != null)
|
||||||
|
{
|
||||||
|
// The user is in prefab mode without any GAO selected in the hierarchy. Get the current prefab root as parent.
|
||||||
|
parentGao = currentPrefabStage.prefabContentsRoot;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
GameObjectUtility.SetParentAndAlign(gao, parentGao); // Ensure it gets reparented if this was a context click (otherwise does nothing)
|
||||||
|
|
||||||
|
Undo.RegisterCreatedObjectUndo(gao, "Create " + gao.name); // Register the creation in the undo system
|
||||||
|
Selection.activeObject = gao;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static bool CanAddComponentFromEditor<TComp>(VolumetricLightBeamAbstractBase self) where TComp : Component
|
||||||
|
{
|
||||||
|
return !Application.isPlaying && self != null && self.GetComponent<TComp>() == null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void AddComponentFromEditor<TComp>(VolumetricLightBeamAbstractBase self) where TComp : Component
|
||||||
|
{
|
||||||
|
if (CanAddComponentFromEditor<TComp>(self))
|
||||||
|
{
|
||||||
|
/*var comp =*/ Undo.AddComponent<TComp>(self.gameObject);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Add a EditorGUILayout.ToggleLeft which properly handles multi-object editing
|
||||||
|
/// </summary>
|
||||||
|
public static void ToggleLeft(this SerializedProperty prop, GUIContent label, params GUILayoutOption[] options)
|
||||||
|
{
|
||||||
|
ToggleLeft(prop, label, prop.boolValue, options);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void ToggleLeft(this SerializedProperty prop, GUIContent label, bool forcedValue, params GUILayoutOption[] options)
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
EditorGUI.showMixedValue = prop.hasMultipleDifferentValues;
|
||||||
|
var newValue = EditorGUILayout.ToggleLeft(label, forcedValue, options);
|
||||||
|
EditorGUI.showMixedValue = false;
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
prop.boolValue = newValue;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static bool HasAtLeastOneValue(this SerializedProperty prop, bool value)
|
||||||
|
{
|
||||||
|
return (prop.boolValue == value) || prop.hasMultipleDifferentValues;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static bool HasAtLeastOnePositiveValue(this SerializedProperty prop)
|
||||||
|
{
|
||||||
|
return (prop.floatValue >= 0.0f) || prop.hasMultipleDifferentValues;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Create a EditorGUILayout.Slider which properly handles multi-object editing
|
||||||
|
/// We apply the 'convIn' conversion to the SerializedProperty value before exposing it as a Slider.
|
||||||
|
/// We apply the 'convOut' conversion to the Slider value to get the SerializedProperty back.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="prop">The value the slider shows.</param>
|
||||||
|
/// <param name="label">Label in front of the slider.</param>
|
||||||
|
/// <param name="leftValue">The value at the left end of the slider.</param>
|
||||||
|
/// <param name="rightValue">The value at the right end of the slider.</param>
|
||||||
|
/// <param name="convIn">Conversion applied on the SerializedProperty to get the Slider value</param>
|
||||||
|
/// <param name="convOut">Conversion applied on the Slider value to get the SerializedProperty</param>
|
||||||
|
public static bool FloatSlider(
|
||||||
|
this SerializedProperty prop,
|
||||||
|
GUIContent label,
|
||||||
|
float leftValue, float rightValue,
|
||||||
|
System.Func<float, float> convIn,
|
||||||
|
System.Func<float, float> convOut,
|
||||||
|
params GUILayoutOption[] options)
|
||||||
|
{
|
||||||
|
var floatValue = convIn(prop.floatValue);
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUI.showMixedValue = prop.hasMultipleDifferentValues;
|
||||||
|
{
|
||||||
|
floatValue = EditorGUILayout.Slider(label, floatValue, leftValue, rightValue, options);
|
||||||
|
}
|
||||||
|
EditorGUI.showMixedValue = false;
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
prop.floatValue = convOut(floatValue);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static bool FloatSlider(
|
||||||
|
this SerializedProperty prop,
|
||||||
|
GUIContent label,
|
||||||
|
float leftValue, float rightValue,
|
||||||
|
params GUILayoutOption[] options)
|
||||||
|
{
|
||||||
|
var floatValue = prop.floatValue;
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUI.showMixedValue = prop.hasMultipleDifferentValues;
|
||||||
|
{
|
||||||
|
floatValue = EditorGUILayout.Slider(label, floatValue, leftValue, rightValue, options);
|
||||||
|
}
|
||||||
|
EditorGUI.showMixedValue = false;
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
prop.floatValue = floatValue;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
public static void ToggleFromLight(this SerializedProperty prop)
|
||||||
|
{
|
||||||
|
ToggleLeft(
|
||||||
|
prop,
|
||||||
|
new GUIContent("From Spot", "Get the value from the Light Spot"),
|
||||||
|
GUILayout.MaxWidth(80.0f));
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
public static void ToggleUseGlobalNoise(this SerializedProperty prop)
|
||||||
|
{
|
||||||
|
ToggleLeft(
|
||||||
|
prop,
|
||||||
|
new GUIContent("Global", "Get the value from the Global 3D Noise"),
|
||||||
|
GUILayout.MaxWidth(55.0f));
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void CustomEnum<EnumType>(this SerializedProperty prop, GUIContent content, string[] descriptions = null)
|
||||||
|
{
|
||||||
|
if(descriptions == null)
|
||||||
|
descriptions = System.Enum.GetNames(typeof(EnumType));
|
||||||
|
|
||||||
|
Debug.Assert(System.Enum.GetNames(typeof(EnumType)).Length == descriptions.Length, string.Format("Enum '{0}' and the description array don't have the same size", typeof(EnumType)));
|
||||||
|
|
||||||
|
int enumValueIndex = prop.enumValueIndex;
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUI.showMixedValue = prop.hasMultipleDifferentValues;
|
||||||
|
{
|
||||||
|
#if UNITY_2018_1_OR_NEWER
|
||||||
|
enumValueIndex = EditorGUILayout.Popup(content, enumValueIndex, descriptions);
|
||||||
|
#else
|
||||||
|
enumValueIndex = EditorGUILayout.Popup(content.text, enumValueIndex, descriptions);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
EditorGUI.showMixedValue = false;
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
prop.enumValueIndex = enumValueIndex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void CustomMask<EnumType>(this SerializedProperty prop, GUIContent content, string[] descriptions = null)
|
||||||
|
{
|
||||||
|
if (descriptions == null)
|
||||||
|
descriptions = System.Enum.GetNames(typeof(EnumType));
|
||||||
|
|
||||||
|
Debug.Assert(System.Enum.GetNames(typeof(EnumType)).Length == descriptions.Length, string.Format("Enum '{0}' and the description array don't have the same size", typeof(EnumType)));
|
||||||
|
|
||||||
|
int intValue = prop.intValue;
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUI.showMixedValue = prop.hasMultipleDifferentValues;
|
||||||
|
{
|
||||||
|
intValue = EditorGUILayout.MaskField(content, intValue, descriptions);
|
||||||
|
}
|
||||||
|
EditorGUI.showMixedValue = false;
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
prop.intValue = intValue;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static void DrawLineSeparator()
|
||||||
|
{
|
||||||
|
DrawLineSeparator(Color.grey, 1, 10);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void DrawLineSeparator(Color color, int thickness = 2, int padding = 10)
|
||||||
|
{
|
||||||
|
Rect r = EditorGUILayout.GetControlRect(GUILayout.Height(padding + thickness));
|
||||||
|
|
||||||
|
r.x = 0;
|
||||||
|
r.width = EditorGUIUtility.currentViewWidth;
|
||||||
|
|
||||||
|
r.y += padding / 2;
|
||||||
|
r.height = thickness;
|
||||||
|
|
||||||
|
EditorGUI.DrawRect(r, color);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static bool GlobalToggleButton(ref bool boolean, GUIContent content, string saveString, float maxWidth = 999.0f)
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
boolean = GUILayout.Toggle(boolean, content, EditorStyles.miniButton, GUILayout.MaxWidth(maxWidth));
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
EditorPrefs.SetBool(saveString, boolean);
|
||||||
|
SceneView.RepaintAll();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public abstract class EditorGUIWidth : System.IDisposable
|
||||||
|
{
|
||||||
|
protected abstract void ApplyWidth(float width);
|
||||||
|
public EditorGUIWidth(float width) { ApplyWidth(width); }
|
||||||
|
public void Dispose() { ApplyWidth(0.0f); }
|
||||||
|
}
|
||||||
|
|
||||||
|
public class LabelWidth : EditorGUIWidth
|
||||||
|
{
|
||||||
|
public LabelWidth(float width) : base(width) { }
|
||||||
|
protected override void ApplyWidth(float width) { EditorGUIUtility.labelWidth = width; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public class FieldWidth : EditorGUIWidth
|
||||||
|
{
|
||||||
|
public FieldWidth(float width) : base(width) { }
|
||||||
|
protected override void ApplyWidth(float width) { EditorGUIUtility.fieldWidth = width; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public class ShowMixedValue : System.IDisposable
|
||||||
|
{
|
||||||
|
public ShowMixedValue(bool? value) { m_PrevValue = EditorGUI.showMixedValue; EditorGUI.showMixedValue = value ?? false; }
|
||||||
|
public ShowMixedValue(SerializedProperty prop) : this(prop?.hasMultipleDifferentValues) { }
|
||||||
|
public void Dispose() { EditorGUI.showMixedValue = m_PrevValue; }
|
||||||
|
bool m_PrevValue = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static ArcHandle ms_ArcHandle = null;
|
||||||
|
|
||||||
|
// HANDLES
|
||||||
|
public static ArcHandle DrawHandleRadius(float radius)
|
||||||
|
{
|
||||||
|
if (ms_ArcHandle == null)
|
||||||
|
ms_ArcHandle = new ArcHandle();
|
||||||
|
|
||||||
|
ms_ArcHandle.SetColorWithRadiusHandle(Color.white, 0f);
|
||||||
|
ms_ArcHandle.angle = 360f;
|
||||||
|
ms_ArcHandle.angleHandleSizeFunction = null;
|
||||||
|
ms_ArcHandle.angleHandleColor = Color.clear;
|
||||||
|
ms_ArcHandle.radius = radius;
|
||||||
|
ms_ArcHandle.DrawHandle();
|
||||||
|
return ms_ArcHandle;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static ArcHandle DrawHandleSpotAngle(float angle, float radius)
|
||||||
|
{
|
||||||
|
if (ms_ArcHandle == null)
|
||||||
|
ms_ArcHandle = new ArcHandle();
|
||||||
|
|
||||||
|
ms_ArcHandle.angleHandleSizeFunction = ArcHandle.DefaultAngleHandleSizeFunction;
|
||||||
|
ms_ArcHandle.SetColorWithRadiusHandle(Handles.color, Handles.color.maxColorComponent < 0.5f ? 0.25f : 0.1f);
|
||||||
|
ms_ArcHandle.angleHandleColor = Handles.color;
|
||||||
|
ms_ArcHandle.radius = radius;
|
||||||
|
ms_ArcHandle.angle = angle;
|
||||||
|
ms_ArcHandle.DrawHandle();
|
||||||
|
return ms_ArcHandle;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 554d3ed087749984585096b2d627574b
|
||||||
|
timeCreated: 1504871769
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,240 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public static class EditorMenuItems
|
||||||
|
{
|
||||||
|
const string kPrefix = "GameObject/Light/\U0001F4A1 Volumetric Light Beam/";
|
||||||
|
|
||||||
|
static class SD
|
||||||
|
{
|
||||||
|
const string kNewBeamPrefix = kPrefix + "SD Beam/";
|
||||||
|
|
||||||
|
[MenuItem(kNewBeamPrefix + "3D Beam", false, 100)]
|
||||||
|
static void Menu_CreateNewBeam(MenuCommand menuCommand) { EditorExtensions.OnNewGameObjectCreated(EditorExtensions.SD.NewBeam(), menuCommand); }
|
||||||
|
|
||||||
|
[MenuItem(kNewBeamPrefix + "3D Beam and Spotlight", false, 101)]
|
||||||
|
static void Menu_CreateSpotLightAndBeam(MenuCommand menuCommand) { EditorExtensions.OnNewGameObjectCreated(EditorExtensions.SD.NewSpotLightAndBeam(), menuCommand); }
|
||||||
|
|
||||||
|
[MenuItem(kNewBeamPrefix + "2D Beam", false, 102)]
|
||||||
|
static void Menu_CreateNewBeam2D(MenuCommand menuCommand) { EditorExtensions.OnNewGameObjectCreated(EditorExtensions.SD.NewBeam2D(), menuCommand); }
|
||||||
|
}
|
||||||
|
|
||||||
|
static class HD
|
||||||
|
{
|
||||||
|
const string kNewBeamPrefix = kPrefix + "HD Beam/";
|
||||||
|
|
||||||
|
[MenuItem(kNewBeamPrefix + "3D Beam", false, 200)]
|
||||||
|
static void Menu_CreateNewBeam(MenuCommand menuCommand) { EditorExtensions.OnNewGameObjectCreated(EditorExtensions.HD.NewBeam(), menuCommand); }
|
||||||
|
|
||||||
|
[MenuItem(kNewBeamPrefix + "3D Beam and Spotlight", false, 201)]
|
||||||
|
static void Menu_CreateSpotLightAndBeam(MenuCommand menuCommand) { EditorExtensions.OnNewGameObjectCreated(EditorExtensions.HD.NewSpotLightAndBeam(), menuCommand); }
|
||||||
|
|
||||||
|
[MenuItem(kNewBeamPrefix + "2D Beam", false, 202)]
|
||||||
|
static void Menu_CreateNewBeam2D(MenuCommand menuCommand) { EditorExtensions.OnNewGameObjectCreated(EditorExtensions.HD.NewBeam2D(), menuCommand); }
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
const string kAddVolumetricBeam = "CONTEXT/Light/\U0001F4A1 Attach a Volumetric Beam ";
|
||||||
|
static bool CanAddVolumetricBeam(Light light) { return !Application.isPlaying && light != null && light.type == LightType.Spot && light.GetComponent<VolumetricLightBeamAbstractBase>() == null; }
|
||||||
|
|
||||||
|
static T Menu_AttachBeam_Command<T>(MenuCommand menuCommand) where T : VolumetricLightBeamAbstractBase
|
||||||
|
{
|
||||||
|
var light = menuCommand.context as Light;
|
||||||
|
T comp = null;
|
||||||
|
if (CanAddVolumetricBeam(light))
|
||||||
|
comp = Undo.AddComponent<T>(light.gameObject);
|
||||||
|
return comp;
|
||||||
|
}
|
||||||
|
|
||||||
|
[MenuItem(kAddVolumetricBeam + "SD", false)]
|
||||||
|
static void Menu_AttachBeamSD_Command(MenuCommand menuCommand) { Menu_AttachBeam_Command<VolumetricLightBeamSD>(menuCommand); }
|
||||||
|
|
||||||
|
[MenuItem(kAddVolumetricBeam + "HD", false)]
|
||||||
|
static void Menu_AttachBeamHD_Command(MenuCommand menuCommand) {
|
||||||
|
var beamHD = Menu_AttachBeam_Command<VolumetricLightBeamHD>(menuCommand);
|
||||||
|
if (beamHD) beamHD.scalable = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
[MenuItem(kAddVolumetricBeam + "SD", true)]
|
||||||
|
[MenuItem(kAddVolumetricBeam + "HD", true)]
|
||||||
|
static bool Menu_AttachBeam_Validate() { return CanAddVolumetricBeam(GetActiveLight()); }
|
||||||
|
|
||||||
|
|
||||||
|
/////////////////////////////
|
||||||
|
// DOCUMENTATION
|
||||||
|
/////////////////////////////
|
||||||
|
const string kDocumentationSuffix = "/\u2754 Documentation";
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricLightBeamSD.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_BeamSD_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.SD.UrlBeam); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricLightBeamHD.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_BeamHD_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.HD.UrlBeam); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricDustParticles.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_DustParticles_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.UrlDustParticles); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + DynamicOcclusionRaycasting.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_DynamicOcclusionRaycasting_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.SD.UrlDynamicOcclusionRaycasting); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + DynamicOcclusionDepthBuffer.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_DynamicOcclusionDepthBuffer_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.SD.UrlDynamicOcclusionDepthBuffer); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + SkewingHandleSD.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_SkewingHandle_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.SD.UrlSkewingHandle); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + TriggerZone.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_TriggerZone_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.UrlTriggerZone); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + EffectFlicker.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_EffectFlicker_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.UrlEffectFlicker); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + EffectPulse.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_EffectPulse_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.UrlEffectPulse); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricCookieHD.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_CookieHD_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.HD.UrlCookie); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricShadowHD.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_ShadowHD_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.HD.UrlShadow); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + TrackRealtimeChangesOnLightHD.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_TrackRealtimeChangesOnLight_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.HD.UrlTrackRealtimeChangesOnLight); }
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + Config.ClassName + kDocumentationSuffix)]
|
||||||
|
static void Menu_Config_Doc(MenuCommand menuCommand) { Application.OpenURL(Consts.Help.UrlConfig); }
|
||||||
|
|
||||||
|
/////////////////////////////
|
||||||
|
// GLOBAL CONFIG
|
||||||
|
/////////////////////////////
|
||||||
|
const string kOpenConfigSuffix = "/\u2699 Open Global Config";
|
||||||
|
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricLightBeamAbstractBase.ClassName + kOpenConfigSuffix)]
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricDustParticles.ClassName + kOpenConfigSuffix)]
|
||||||
|
[MenuItem("CONTEXT/" + DynamicOcclusionAbstractBase.ClassName + kOpenConfigSuffix)]
|
||||||
|
[MenuItem("CONTEXT/" + SkewingHandleSD.ClassName + kOpenConfigSuffix)]
|
||||||
|
[MenuItem("CONTEXT/" + TriggerZone.ClassName + kOpenConfigSuffix)]
|
||||||
|
[MenuItem("CONTEXT/" + EffectAbstractBase.ClassName + kOpenConfigSuffix)]
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricCookieHD.ClassName + kOpenConfigSuffix)]
|
||||||
|
[MenuItem("CONTEXT/" + VolumetricShadowHD.ClassName + kOpenConfigSuffix)]
|
||||||
|
[MenuItem("CONTEXT/" + TrackRealtimeChangesOnLightHD.ClassName + kOpenConfigSuffix)]
|
||||||
|
public static void Menu_Beam_Config(MenuCommand menuCommand) { Config.EditorSelectInstance(); }
|
||||||
|
|
||||||
|
/////////////////////////////
|
||||||
|
// ADDITIONAL COMPONENTS
|
||||||
|
/////////////////////////////
|
||||||
|
const string kAddParticlesSD = "CONTEXT/" + VolumetricLightBeamSD.ClassName + "/Add Dust Particles";
|
||||||
|
[MenuItem(kAddParticlesSD, false)] static void Menu_AddDustParticles_CommandSD(MenuCommand menuCommand) => Menu_AddDustParticles_Command_Common(menuCommand);
|
||||||
|
[MenuItem(kAddParticlesSD, true)] static bool Menu_AddDustParticles_ValidateSD() => Menu_AddDustParticles_Validate_Common();
|
||||||
|
|
||||||
|
const string kAddParticlesHD = "CONTEXT/" + VolumetricLightBeamHD.ClassName + "/Add Dust Particles";
|
||||||
|
[MenuItem(kAddParticlesHD, false)] static void Menu_AddDustParticles_CommandHD(MenuCommand menuCommand) => Menu_AddDustParticles_Command_Common(menuCommand);
|
||||||
|
[MenuItem(kAddParticlesHD, true)] static bool Menu_AddDustParticles_ValidateHD() => Menu_AddDustParticles_Validate_Common();
|
||||||
|
|
||||||
|
static void Menu_AddDustParticles_Command_Common(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<VolumetricDustParticles>(menuCommand.context as VolumetricLightBeamAbstractBase); }
|
||||||
|
static bool Menu_AddDustParticles_Validate_Common() { return EditorExtensions.CanAddComponentFromEditor<VolumetricDustParticles>(GetActiveVolumetricLightBeam()); }
|
||||||
|
|
||||||
|
const string kAddDynamicOcclusionRaycasting = "CONTEXT/" + VolumetricLightBeamSD.ClassName + "/Add Dynamic Occlusion (Raycasting)";
|
||||||
|
[MenuItem(kAddDynamicOcclusionRaycasting, false)] static void Menu_AddDynamicOcclusionRaycasting_Command(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<DynamicOcclusionRaycasting>(menuCommand.context as VolumetricLightBeamSD); }
|
||||||
|
[MenuItem(kAddDynamicOcclusionRaycasting, true)] static bool Menu_AddDynamicOcclusionRaycasting_Validate() { return Config.Instance.featureEnabledDynamicOcclusion && EditorExtensions.CanAddComponentFromEditor<DynamicOcclusionAbstractBase>(GetActiveVolumetricLightBeam()); }
|
||||||
|
|
||||||
|
const string kAddDynamicOcclusionDepthBuffer = "CONTEXT/" + VolumetricLightBeamSD.ClassName + "/Add Dynamic Occlusion (Depth Buffer)";
|
||||||
|
[MenuItem(kAddDynamicOcclusionDepthBuffer, false)] static void Menu_AddDynamicOcclusionDepthBuffer_Command(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<DynamicOcclusionDepthBuffer>(menuCommand.context as VolumetricLightBeamSD); }
|
||||||
|
[MenuItem(kAddDynamicOcclusionDepthBuffer, true)] static bool Menu_AddDynamicOcclusionDepthBuffer_Validate() { return Config.Instance.featureEnabledDynamicOcclusion && EditorExtensions.CanAddComponentFromEditor<DynamicOcclusionAbstractBase>(GetActiveVolumetricLightBeam()); }
|
||||||
|
|
||||||
|
const string kAddTriggerZoneSD = "CONTEXT/" + VolumetricLightBeamSD.ClassName + "/Add Trigger Zone";
|
||||||
|
[MenuItem(kAddTriggerZoneSD, false)] static void Menu_AddTriggerZone_CommandSD(MenuCommand menuCommand) => Menu_AddTriggerZone_Command_Common(menuCommand);
|
||||||
|
[MenuItem(kAddTriggerZoneSD, true)] static bool Menu_AddTriggerZone_ValidateSD() => Menu_AddTriggerZone_Validate_Common();
|
||||||
|
|
||||||
|
const string kAddTriggerZoneHD = "CONTEXT/" + VolumetricLightBeamHD.ClassName + "/Add Trigger Zone";
|
||||||
|
[MenuItem(kAddTriggerZoneHD, false)] static void Menu_AddTriggerZone_CommandHD(MenuCommand menuCommand) => Menu_AddTriggerZone_Command_Common(menuCommand);
|
||||||
|
[MenuItem(kAddTriggerZoneHD, true)] static bool Menu_AddTriggerZone_ValidateHD() => Menu_AddTriggerZone_Validate_Common();
|
||||||
|
|
||||||
|
static void Menu_AddTriggerZone_Command_Common(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<TriggerZone>(menuCommand.context as VolumetricLightBeamAbstractBase); }
|
||||||
|
static bool Menu_AddTriggerZone_Validate_Common() { return EditorExtensions.CanAddComponentFromEditor<TriggerZone>(GetActiveVolumetricLightBeam()); }
|
||||||
|
|
||||||
|
const string kAddEffectFlickerSD = "CONTEXT/" + VolumetricLightBeamSD.ClassName + "/Add Effect Flicker";
|
||||||
|
[MenuItem(kAddEffectFlickerSD, false)] static void Menu_EffectFlicker_CommandSD(MenuCommand menuCommand) => Menu_EffectFlicker_Command_Common(menuCommand);
|
||||||
|
[MenuItem(kAddEffectFlickerSD, true)] static bool Menu_EffectFlicker_ValidateSD() => Menu_EffectFlicker_Validate_Common();
|
||||||
|
|
||||||
|
const string kAddEffectFlickerHD = "CONTEXT/" + VolumetricLightBeamHD.ClassName + "/Add Effect Flicker";
|
||||||
|
[MenuItem(kAddEffectFlickerHD, false)] static void Menu_EffectFlicker_CommandHD(MenuCommand menuCommand) => Menu_EffectFlicker_Command_Common(menuCommand);
|
||||||
|
[MenuItem(kAddEffectFlickerHD, true)] static bool Menu_EffectFlicker_ValidateHD() => Menu_EffectFlicker_Validate_Common();
|
||||||
|
|
||||||
|
static void Menu_EffectFlicker_Command_Common(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<EffectFlicker>(menuCommand.context as VolumetricLightBeamAbstractBase); }
|
||||||
|
static bool Menu_EffectFlicker_Validate_Common() { return EditorExtensions.CanAddComponentFromEditor<EffectAbstractBase>(GetActiveVolumetricLightBeam()); }
|
||||||
|
|
||||||
|
const string kAddEffectPulseSD = "CONTEXT/" + VolumetricLightBeamSD.ClassName + "/Add Effect Pulse";
|
||||||
|
[MenuItem(kAddEffectPulseSD, false)] static void Menu_EffectPulse_CommandSD(MenuCommand menuCommand) => Menu_EffectPulse_Command_Common(menuCommand);
|
||||||
|
[MenuItem(kAddEffectPulseSD, true)] static bool Menu_EffectPulse_ValidateSD() => Menu_EffectPulse_Validate_Common();
|
||||||
|
|
||||||
|
const string kAddEffectPulseHD = "CONTEXT/" + VolumetricLightBeamHD.ClassName + "/Add Effect Pulse";
|
||||||
|
[MenuItem(kAddEffectPulseHD, false)] static void Menu_EffectPulse_CommandHD(MenuCommand menuCommand) => Menu_EffectPulse_Command_Common(menuCommand);
|
||||||
|
[MenuItem(kAddEffectPulseHD, true)] static bool Menu_EffectPulse_ValidateHD() => Menu_EffectPulse_Validate_Common();
|
||||||
|
|
||||||
|
static void Menu_EffectPulse_Command_Common(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<EffectPulse>(menuCommand.context as VolumetricLightBeamAbstractBase); }
|
||||||
|
static bool Menu_EffectPulse_Validate_Common() { return EditorExtensions.CanAddComponentFromEditor<EffectAbstractBase>(GetActiveVolumetricLightBeam()); }
|
||||||
|
|
||||||
|
const string kAddShadow = "CONTEXT/" + VolumetricLightBeamHD.ClassName + "/Add Volumetric Shadow";
|
||||||
|
[MenuItem(kAddShadow, false)] static void Menu_AddShadow_Command(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<VolumetricShadowHD>(menuCommand.context as VolumetricLightBeamHD); }
|
||||||
|
[MenuItem(kAddShadow, true)] static bool Menu_AddShadow_Validate() { return Config.Instance.featureEnabledShadow && EditorExtensions.CanAddComponentFromEditor<VolumetricShadowHD>(GetActiveVolumetricLightBeam()); }
|
||||||
|
|
||||||
|
const string kAddCookie = "CONTEXT/" + VolumetricLightBeamHD.ClassName + "/Add Volumetric Cookie";
|
||||||
|
[MenuItem(kAddCookie, false)] static void Menu_AddCookie_Command(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<VolumetricCookieHD>(menuCommand.context as VolumetricLightBeamHD); }
|
||||||
|
[MenuItem(kAddCookie, true)] static bool Menu_AddCookie_Validate() { return Config.Instance.featureEnabledCookie && EditorExtensions.CanAddComponentFromEditor<VolumetricCookieHD>(GetActiveVolumetricLightBeam()); }
|
||||||
|
|
||||||
|
const string kAddTrackRealtime = "CONTEXT/" + VolumetricLightBeamHD.ClassName + "/Add Track Realtime Changes on Light";
|
||||||
|
[MenuItem(kAddTrackRealtime, false)] static void Menu_AddTrackRealtime_Command(MenuCommand menuCommand) { EditorExtensions.AddComponentFromEditor<TrackRealtimeChangesOnLightHD>(menuCommand.context as VolumetricLightBeamHD); }
|
||||||
|
[MenuItem(kAddTrackRealtime, true)] static bool Menu_AddTrackRealtime_Validate() { return EditorExtensions.CanAddComponentFromEditor<TrackRealtimeChangesOnLightHD>(GetActiveVolumetricLightBeam()) && GetActiveVolumetricLightBeam().GetComponent<Light>() != null; }
|
||||||
|
|
||||||
|
static Light GetActiveLight() { return Selection.activeGameObject != null ? Selection.activeGameObject.GetComponent<Light>() : null; }
|
||||||
|
static VolumetricLightBeamAbstractBase GetActiveVolumetricLightBeam() { return Selection.activeGameObject != null ? Selection.activeGameObject.GetComponent<VolumetricLightBeamAbstractBase>() : null; }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/////////////////////////////
|
||||||
|
// EDIT MENU
|
||||||
|
/////////////////////////////
|
||||||
|
const string kEditMenu = "Edit/Volumetric Light Beam/";
|
||||||
|
|
||||||
|
[MenuItem(kEditMenu + "\u2699 Open Config", false, 20001)]
|
||||||
|
static void Menu_EditOpenConfig() { Config.EditorSelectInstance(); }
|
||||||
|
|
||||||
|
#if UNITY_2019_3_OR_NEWER
|
||||||
|
[MenuItem(kEditMenu + "Enable scene Pickability on all beams", false, 20101)]
|
||||||
|
static void Menu_SetAllBeamsPickabilityEnabled() { SetAllBeamsPickability(true); }
|
||||||
|
|
||||||
|
[MenuItem(kEditMenu + "Disable scene Pickability on all beams", false, 20102)]
|
||||||
|
static void Menu_SetAllBeamsPickabilityDisable() { SetAllBeamsPickability(false); }
|
||||||
|
|
||||||
|
[MenuItem(kEditMenu + "Enable scene Visibility on all beams", false, 20201)]
|
||||||
|
static void Menu_SetAllBeamsVisibilityEnabled() { SetAllBeamsVisibility(true); }
|
||||||
|
|
||||||
|
[MenuItem(kEditMenu + "Disable scene Visibility on all beams", false, 20202)]
|
||||||
|
static void Menu_SetAllBeamsVisibilityDisable() { SetAllBeamsVisibility(false); }
|
||||||
|
|
||||||
|
static void SetAllBeamsVisibility(bool enabled)
|
||||||
|
{
|
||||||
|
var beams = Resources.FindObjectsOfTypeAll<VolumetricLightBeamAbstractBase>();
|
||||||
|
|
||||||
|
foreach (var beam in beams)
|
||||||
|
beam.gameObject.SetSceneVisibilityState(enabled);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void SetAllBeamsPickability(bool enabled)
|
||||||
|
{
|
||||||
|
var beams = Resources.FindObjectsOfTypeAll<VolumetricLightBeamAbstractBase>();
|
||||||
|
|
||||||
|
foreach (var beam in beams)
|
||||||
|
beam.gameObject.SetScenePickabilityState(enabled);
|
||||||
|
}
|
||||||
|
#endif // UNITY_2019_3_OR_NEWER
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 59bb1c7e6f7293443af232bd3ee62887
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,456 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public static class EditorStrings
|
||||||
|
{
|
||||||
|
public static class Common
|
||||||
|
{
|
||||||
|
public static readonly GUIContent ButtonOpenGlobalConfig = new GUIContent("Open Config asset in use");
|
||||||
|
public const string HelpNoiseLoadingFailed = "Fail to load 3D noise texture. Please check your Config.";
|
||||||
|
|
||||||
|
public static readonly string[] DimensionsEnumDescriptions = new string[]
|
||||||
|
{
|
||||||
|
"3D",
|
||||||
|
"2D",
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class Beam
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderBasic = new GUIContent("Basic", "Basic beam's properties (color, thickness...)");
|
||||||
|
public static readonly GUIContent HeaderShape = new GUIContent("Shape", "Tweak the shape of the cone (sport angle, range distance...)");
|
||||||
|
public static readonly GUIContent HeaderAttenuation = new GUIContent("Fall-Off Attenuation", "Control the beam's range distance and the light fall-off behaviour");
|
||||||
|
public static readonly GUIContent Header3DNoise = new GUIContent("3D Noise", "Simulate animated volumetric fog / mist / smoke effects.\nIt makes the volumetric lights look less 'perfect' and so much more realistic.\nTo achieve that, a tiled 3D noise texture is internally loaded and used by the beam shader.");
|
||||||
|
public static readonly GUIContent HeaderBlendingDistances = new GUIContent("Soft Intersections Blending Distances", "Because the volumetric beams are rendered using cone geometry, it is possible that it intersects with the camera's near plane or with the world's geometry, which could produce unwanted artifacts.\nThese properties are designed to fix this issue.");
|
||||||
|
public static readonly GUIContent HeaderGeometry = new GUIContent("Cone Geometry", "Control how the beam's geometry is generated.");
|
||||||
|
public static readonly GUIContent HeaderFadeOut = new GUIContent("Fade Out");
|
||||||
|
public static readonly GUIContent Header2D = new GUIContent("2D", "Tweak and combine the order when beams are rendered with 2D objects (such as 2D sprites)");
|
||||||
|
public static readonly GUIContent HeaderInfos = new GUIContent("Infos");
|
||||||
|
|
||||||
|
public const string FromSpotLight = "Get the value from the Light Spot";
|
||||||
|
|
||||||
|
public static readonly GUIContent ColorMode = new GUIContent("Color", "Apply a flat/plain/single color, or a gradient.");
|
||||||
|
public static readonly GUIContent ColorGradient = new GUIContent("", "Use the gradient editor to set color and alpha variations along the beam.");
|
||||||
|
public static readonly GUIContent ColorFlat = new GUIContent("", "Use the color picker to set a plain RGBA color (takes account of the alpha value).");
|
||||||
|
|
||||||
|
public const string IntensityMultiplier = "Multiplier to modulate the intensity from the attached Unity's spotlight.";
|
||||||
|
|
||||||
|
public static readonly GUIContent HDRPExposureWeight = new GUIContent("Exposure Weight", "Use this slider to set how much effect the exposure has on the beam intensity.");
|
||||||
|
|
||||||
|
public static readonly GUIContent BlendingMode = new GUIContent("Blending Mode", "Additive: highly recommended blending mode\nSoftAdditive: softer additive\nTraditional Transparency: support dark/black colors");
|
||||||
|
public static readonly GUIContent ShaderAccuracy = new GUIContent("Shader Accuracy", "- Fast: a lot of computation are done on the vertex shader to maximize performance.\n- High: most of the computation are done on the pixel shader to maximize graphical quality at some performance cost.\n\nWe recommend to keep the default 'Fast' shader accuracy to ensure best performance, except when using the 'Tilt Factor' feature or when using a very rich 'Gradient Color'.");
|
||||||
|
|
||||||
|
public static readonly GUIContent SpotAngle = new GUIContent("Spot Angle", "Define the angle (in degrees) at the base of the beam's cone");
|
||||||
|
public const string SpotAngleMultiplier = "Multiplier to modulate the angle from the attached Unity's spotlight.";
|
||||||
|
|
||||||
|
public static readonly GUIContent GlareFrontal = new GUIContent("Glare (frontal)", "Boost intensity factor when looking at the beam from the inside directly at the source.");
|
||||||
|
public static readonly GUIContent GlareBehind = new GUIContent("Glare (from behind)", "Boost intensity factor when looking at the beam from behind.");
|
||||||
|
|
||||||
|
public static readonly GUIContent TrackChanges = new GUIContent(
|
||||||
|
" Track changes during Playtime",
|
||||||
|
"Check this box to be able to modify properties during Playtime via Script, Animator and/or Timeline.\nEnabling this feature is at very minor performance cost. So keep it disabled if you don't plan to modify this light beam during playtime.");
|
||||||
|
|
||||||
|
public static readonly GUIContent FallOffStart = new GUIContent("Attenuation Start Distance", "Distance from the light source (in units) the beam intensity will start to fall-off.");
|
||||||
|
public static readonly GUIContent FallOffEnd = new GUIContent("Light Range Max Distance", "Distance from the light source (in units) the beam is entirely faded out.");
|
||||||
|
public const string FallOffEndMultiplier = "Distance multiplier to modulate the range from the attached Unity's spotlight.";
|
||||||
|
|
||||||
|
public static readonly GUIContent NoiseMode = new GUIContent("Enabled", "Enable 3D Noise effect and choose the mode:\n- World Space: the noise will look 'grounded' in the world\n- Local Space: the noise will look 'tied' to the beam");
|
||||||
|
public static readonly GUIContent NoiseIntensity = new GUIContent("Intensity", "Higher intensity means the noise contribution is stronger and more visible");
|
||||||
|
public static readonly GUIContent NoiseScale = new GUIContent("Scale", "3D Noise texture scaling: higher scale make the noise more visible, but potentially less realistic");
|
||||||
|
public static readonly GUIContent NoiseVelocity = new GUIContent("Velocity", "Direction and speed of the noise scrolling, simulating the fog/smoke movement");
|
||||||
|
public static readonly string[] NoiseModeEnumDescriptions = new string[]
|
||||||
|
{
|
||||||
|
"Disabled",
|
||||||
|
"Enabled (World Space)",
|
||||||
|
"Enabled (Local Space)",
|
||||||
|
};
|
||||||
|
|
||||||
|
public static readonly GUIContent CameraClippingDistance = new GUIContent("Camera", "Distance from the camera the beam will fade with.\n- 0.0: hard intersection\n- Higher values produce soft intersection when the camera is near the cone triangles.\n\nThis distance is NOT scaled according to the beam's GameObject scale. You'll have to set a consistent distance value when scaling your beams, specially with very tiny or very large scaling factors.");
|
||||||
|
public static readonly GUIContent DepthBlendDistance = new GUIContent("Opaque geometry", "Distance from the world geometry the beam will fade with.\n- 0.0 (feature disabled): hard intersection but faster (doesn't require to update the depth texture).\n- Higher values produce soft intersection when the beam intersects world's geometry, but require to update the camera's depth texture.\n\nThis distance is NOT scaled according to the beam's GameObject scale. You'll have to set a consistent distance value when scaling your beams, specially with very tiny or very large scaling factors.");
|
||||||
|
|
||||||
|
public static readonly GUIContent ConeRadiusStart = new GUIContent("Light Source Radius", "Radius (in units) at the beam's source (the top of the cone).\n0 will generate a perfect cone geometry.\nHigher values will generate truncated cones.");
|
||||||
|
|
||||||
|
public static readonly GUIContent GeomMeshType = new GUIContent("Mesh Type", "- Shared: Use the global shared mesh (recommended setting, since it will save a lot of memory). Will use the geometry properties set on configuration file.\n- Custom: Use a custom mesh instead. Will use the geometry properties set on the beam.");
|
||||||
|
public static readonly GUIContent GeomCap = new GUIContent("Cap", "Show Cap Geometry (only visible from inside)");
|
||||||
|
public static readonly GUIContent GeomSides = new GUIContent("Sides", "Number of Sides of the cone.\nHigher values make the beam looks more 'round', but require more memory and graphic performance.\nA recommended value for a decent quality while keeping the poly count low is 18.");
|
||||||
|
public static readonly GUIContent GeomSegments = new GUIContent("Segments", "Number of Segments of the cone.\nHigher values give better looking results but require more performance. We recommend at least 3 segments, specially regarding Attenuation and Gradient, otherwise the approximation could become inaccurate.\nThe longer the beam, the more segments we recommend to set.\nA recommended value is 4.");
|
||||||
|
|
||||||
|
public static readonly GUIContent Scalable = new GUIContent("Is Scalable?", "The scaling of the beam's GameObject (or any of its parent in the hierarchy)...\n-True: ...will be applied to the beam itself and will change its size.\n-False: ...won't be applied to the beam itself, so the beam won't have its size changed.\n\nIn short, we recommend to set the Scalable property at:\n-True when there is no Unity Light attached to the same GameObject, so you will be able to scale your beam easily.\n- False when there is a Unity Light attached to the same GameObject, because the Unity Light are NOT scalable: this way your beam will always fit the Unity Light size.");
|
||||||
|
|
||||||
|
public static readonly GUIContent FadeOutEnabled = new GUIContent("Enabled", "Enable the fade out of the beam according to the distance to the camera.");
|
||||||
|
public static readonly GUIContent FadeOutBegin = new GUIContent("Begin Distance", "Fade out starting distance. Beyond this distance, the beam intensity will start to be dimmed.");
|
||||||
|
public static readonly GUIContent FadeOutEnd = new GUIContent("End", "Fade out ending distance. Beyond this distance, the beam will be culled off to save on performance.");
|
||||||
|
|
||||||
|
public static readonly GUIContent Dimensions = new GUIContent("Dimensions", "- 3D: beam along the Z axis.\n- 2D: beam along the X axis, so you won't have to rotate it to see it in 2D.");
|
||||||
|
public const string SortingLayer = "Sorting Layer";
|
||||||
|
public static readonly GUIContent SortingOrder = new GUIContent("Order", "The overlay priority within its layer. Lower numbers are rendered first and subsequent numbers overlay those below.");
|
||||||
|
|
||||||
|
// BUTTONS
|
||||||
|
public static readonly GUIContent ButtonCreateOverridePerPlatform = new GUIContent("Create another Config asset for a specific platform", "");
|
||||||
|
public static readonly GUIContent ButtonResetProperties = new GUIContent("Default values", "Reset properties to their default values.");
|
||||||
|
public static readonly GUIContent ButtonGenerateGeometry = new GUIContent("Regenerate geometry", "Force to re-create the Beam Geometry GameObject.");
|
||||||
|
public static readonly GUIContent ButtonEditInScene = new GUIContent("Edit in Scene View", "Edit some beam's properties directly in the Scene View using convenient gizmos.");
|
||||||
|
public const string ButtonAddDustParticles = "+ Volumetric Dust Particles\nAdd highly detailed dustlight/mote particles on your beam.";
|
||||||
|
public const string ButtonAddDynamicOcclusion = "+ Dynamic Occlusion\nGives awareness to your beam so it reacts to changes in the world: it could be occluded by environment geometry.";
|
||||||
|
public const string ButtonAddDynamicOcclusionRaycasting = "+ Dynamic Occlusion (Raycasting)";
|
||||||
|
public const string ButtonAddDynamicOcclusionDepthBuffer = "+ Dynamic Occlusion (Depth Buffer)";
|
||||||
|
public const string ButtonAddTriggerZone = "+ Trigger Zone\nTrack objects passing through the light beam and track when the beam is passing over them.";
|
||||||
|
public const string ButtonAddEffect = "+ Effect\nAdd runtime FX to easily animate your light and/or beam with effects such as strobe/flickering and pulsing/flashing.";
|
||||||
|
public const string ButtonAddEffectFlicker = "+ Effect Flicker";
|
||||||
|
public const string ButtonAddEffectPulse = "+ Effect Pulse";
|
||||||
|
|
||||||
|
// HELP BOXES
|
||||||
|
public const string HelpNoSpotlight = "To bind properties from the Light and the Beam together, this component must be attached to a Light of type 'Spot'";
|
||||||
|
public const string HelpFadeOutNoMainCamera = "Fail to retrieve the main camera specified in the config.";
|
||||||
|
|
||||||
|
public const string PrefEditInScene = "VLB_BEAM_EDITINSCENE";
|
||||||
|
|
||||||
|
public static class SD
|
||||||
|
{
|
||||||
|
public static readonly GUIContent IntensityModeAdvanced = new GUIContent("Adv", "Advanced Mode: control inside and outside intensity values independently.");
|
||||||
|
public static readonly GUIContent IntensityGlobal = new GUIContent("Intensity", "Global beam intensity. If you want to control values for inside and outside independently, use the advanced mode.");
|
||||||
|
public static readonly GUIContent IntensityOutside = new GUIContent("Intensity (outside)", "Beam outside intensity (when looking at the beam from behind).");
|
||||||
|
public static readonly GUIContent IntensityInside = new GUIContent("Intensity (inside)", "Beam inside intensity (when looking at the beam from the inside directly at the source).");
|
||||||
|
|
||||||
|
public static readonly GUIContent SideThickness = new GUIContent("Side Thickness", "Thickness of the beam when looking at it from the side.\n1 = the beam is fully visible (no difference between the center and the edges), but produces hard edges.\nLower values produce softer transition at beam edges.");
|
||||||
|
|
||||||
|
public static readonly GUIContent AttenuationEquation = new GUIContent("Attenuation Equation", "Attenuation equation used to compute fading between 'Attenuation Start Distance' and 'Light Range Max Distance'.\n- Linear: Simple linear attenuation\n- Quadratic: Quadratic attenuation, which usually gives more realistic results\n- Blend: Custom blending mix between linear (0.0) and quadratic attenuation (1.0)");
|
||||||
|
public static readonly GUIContent AttenuationCustomBlending = new GUIContent("", "Blending value between Linear (0.0) and Quadratic (1.0) attenuation equations.");
|
||||||
|
|
||||||
|
public static readonly GUIContent SkewingLocalForwardDirection = new GUIContent("Skewing Factor", "Distort the shape of the beam horizontally and vertically while keeping its circular slice unchanged.");
|
||||||
|
public static readonly GUIContent ClippingPlane = new GUIContent("Clipping Plane", "Additional clipping plane transform. Will cut the beam according to the GameObject's position and rotation.");
|
||||||
|
public static readonly GUIContent EditorShowClippingPlane = new GUIContent("Debug", "Display the additional clipping plane.");
|
||||||
|
|
||||||
|
public static readonly GUIContent TiltFactor = new GUIContent("Tilt Factor", "Tilt the color and attenuation gradient compared to the global beam's direction.\nCan only be used with 'High' shader accuracy mode.");
|
||||||
|
public static readonly GUIContent EditorShowTiltDirection = new GUIContent("Debug", "Display the direction of the tilt factor in editor.");
|
||||||
|
|
||||||
|
public const string HelpDepthMobile = "On mobile platforms, the depth buffer precision can be pretty low. Try to keep a small depth range on your cameras: the difference between the near and far clip planes should stay as low as possible.";
|
||||||
|
public const string HelpTrackChangesEnabled = "This beam will keep track of the changes of its own properties and the spotlight attached to it (if any) during playtime. You can modify every properties except 'geomSides'.";
|
||||||
|
public const string HelpAnimatorWarning = "If you want to animate your light beam in real-time, you should enable the 'Track Changes During Playtime' property.";
|
||||||
|
public const string HelpTiltedWithShaderAccuracyFast = "We highly recommend to set the 'Shader Accuracy' property to 'High' when using 'Tilt Factor'.";
|
||||||
|
public const string PrefShowAddClippingPlane = "VLB_BEAM_SHOWADDCLIPPINGPLANE";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class HD
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderRaymarching = new GUIContent("Raymarching", "");
|
||||||
|
public static readonly GUIContent HeaderCookie = new GUIContent("Cookie", "");
|
||||||
|
|
||||||
|
public static readonly GUIContent SideSoftness = new GUIContent("Side Softness", "Smoothness of the beam when looking at it from the side, controlling how soft it looks on the edges.");
|
||||||
|
public static readonly GUIContent Intensity = new GUIContent("Intensity", "Controls the brightness of the beam.");
|
||||||
|
|
||||||
|
public static readonly GUIContent AttenuationEquation = new GUIContent("Attenuation Equation", "Attenuation equation used to compute fading between 'Attenuation Start Distance' and 'Light Range Max Distance'.\n- Linear: Simple linear attenuation\n- Quadratic: Quadratic attenuation, which usually gives more realistic results");
|
||||||
|
|
||||||
|
public static readonly GUIContent RaymarchingQuality = new GUIContent("Quality", "Specify which raymarching quality you want to use for this beam (the higher the steps, the better quality, the slower the performances).\n\nThe different qualities names and steps count can be configured from plugin's config.");
|
||||||
|
|
||||||
|
public static readonly GUIContent JitteringFactor = new GUIContent("Jittering Factor", "When using Shadow or Cookie with a raymarching quality with too low steps count, some banding artifacts can appear.\nIn this case, increase jittering to add noise to smooth raymarching inaccuracy.");
|
||||||
|
public static readonly GUIContent JitteringFrameRate = new GUIContent("Jittering Frame Rate", "Animate the jittering noise texture over the time:\n0 = the jittering won't be animated.\nhigher values = the jittering will be animated more often.");
|
||||||
|
public static readonly GUIContent JitteringLerpRange = new GUIContent("Jittering Lerp Range", "Configure where the jittering will be visible along the beam. This range is specified between 0 (the tip of the beam) and 1 (the end of the beam):\n- before the range: no jittering\n- in the range: jittering will lerp from 0 to 'jittering factor' value\n- after the range: 'jittering factor' value");
|
||||||
|
|
||||||
|
public const string TipJittering = "When using this feature, we highly recommend to increase the 'Jittering Factor' property on your HD beam.\nAdding jittering allows to have a decent rendering quality by smoothing banding artifact while keeping raymarching steps as low as possible(and so good performance).";
|
||||||
|
|
||||||
|
|
||||||
|
public const string ButtonAddShadow = "+ Volumetric Shadow\nGives awareness to your beam so it reacts to changes in the world: it could be occluded by environment geometry.";
|
||||||
|
public const string ButtonAddCookie = "+ Volumetric Cookie\nSpecify a cookie texture to the beam, which is a mask to simulate a shadow with a specific shape or color.";
|
||||||
|
|
||||||
|
public const string ButtonAddTrackRealtimeChangesOnLight = "+Track Realtime Changes On Light\nAdd this script be able to modify properties on the Unity's Light component during Playtime via Script, Animator and/or Timeline.\nEnabling this feature is at very minor performance cost. So keep it disabled if you don't plan to modify the Unity's Light component during playtime.";
|
||||||
|
public const string TipTrackRealtimeChangesOnLight = "Realtime changes on the Unity's Light component properties (via Script, Animator and/or Timeline) will be taken into account.";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class DustParticles
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderRendering = new GUIContent("Rendering");
|
||||||
|
public static readonly GUIContent HeaderDirectionAndVelocity = new GUIContent("Direction & Velocity");
|
||||||
|
public static readonly GUIContent HeaderCulling = new GUIContent("Culling");
|
||||||
|
public static readonly GUIContent HeaderSpawning = new GUIContent("Spawning");
|
||||||
|
public static readonly GUIContent HeaderInfos = new GUIContent("Infos");
|
||||||
|
|
||||||
|
public static readonly GUIContent Alpha = new GUIContent("Alpha", "Max alpha of the particles");
|
||||||
|
public static readonly GUIContent Size = new GUIContent("Size", "Max size of the particles");
|
||||||
|
|
||||||
|
public static readonly GUIContent Direction = new GUIContent("Direction", "Direction of the particles\n- Random: random direction.\n- Local Space: particles follow the velicity direction in local space (Z is along the beam).\n- World Space: particles follow the velicity direction in world space.");
|
||||||
|
public static readonly GUIContent Velocity = new GUIContent("Velocity", "Movement speed of the particles along the chosen direction");
|
||||||
|
|
||||||
|
public static readonly GUIContent CullingEnabled = new GUIContent("Enabled", "Enable particles culling based on the distance to the Main Camera.\nWe highly recommend to enable this feature to keep good runtime performances.");
|
||||||
|
public static readonly GUIContent CullingMaxDistance = new GUIContent("Max Distance", "The particles will not be rendered if they are further than this distance to the Main Camera");
|
||||||
|
|
||||||
|
public static readonly GUIContent Density = new GUIContent("Density", "Control how many particles are spawned. The higher the density, the more particles are spawned, the higher the performance cost is");
|
||||||
|
public static readonly GUIContent SpawnDistanceRange = new GUIContent("Distance Range", "The distance range (from the light source) where the particles are spawned.\n- Min bound: the higher it is, the more the particles are spawned away from the light source.\n- Max bound: the lower it is, the more the particles are gathered near the light source.");
|
||||||
|
|
||||||
|
// HELP BOXES
|
||||||
|
public const string HelpFailToInstantiate = "Fail to instantiate the Particles. Please check your Config.";
|
||||||
|
public const string HelpRecommendation = "We do not recommend to use this feature if you plan to move or change properties of the beam during playtime.";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class DynOcclusion
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderUpdateRate = new GUIContent("Update Rate");
|
||||||
|
public static readonly GUIContent HeaderRaycasting = new GUIContent("Raycasting");
|
||||||
|
public static readonly GUIContent HeaderOccluderSurface = new GUIContent("Occluder Surface");
|
||||||
|
public static readonly GUIContent HeaderClippingPlane = new GUIContent("Clipping Plane");
|
||||||
|
public static readonly GUIContent HeaderCamera = new GUIContent("Camera");
|
||||||
|
public static readonly GUIContent HeaderEditorDebug = new GUIContent("Editor Debug");
|
||||||
|
|
||||||
|
public static readonly GUIContent Dimensions = new GUIContent("Dimensions", "Should it interact with 2D or 3D occluders?\n- 3D: the beam will react against 3D Occluders.\n- 2D: the beam will react against 2D Occluders. This is useful when using the beams with 2D objects (such as 2D Sprites).");
|
||||||
|
|
||||||
|
public static readonly GUIContent LayerMask = new GUIContent("Layer Mask",
|
||||||
|
"The beam can only be occluded by objects located on the layers matching this mask.\nIt's very important to set it as restrictive as possible (checking only the layers which are necessary) to perform a more efficient process in order to increase the performance.");
|
||||||
|
public static readonly GUIContent ConsiderTriggers = new GUIContent("Consider Triggers",
|
||||||
|
"Should this beam be occluded by triggers or not?");
|
||||||
|
public const string ConsiderTriggersNoPossible = "In order to be able to consider triggers as 2D occluders, you should tick the 'Queries Hit Triggers' checkbox under the 'Physics 2D' settings menu.";
|
||||||
|
public static readonly GUIContent MinOccluderArea = new GUIContent("Min Occluder Area",
|
||||||
|
"Minimum 'area' of the collider to become an occluder.\nColliders smaller than this value will not block the beam.");
|
||||||
|
public static readonly GUIContent UpdateRate = new GUIContent("Update Rate", "How often will the occlusion be processed?\nTry to update the occlusion as rarely as possible to keep good performance.");
|
||||||
|
public static readonly string[] UpdateRateDescriptions = new string[]
|
||||||
|
{
|
||||||
|
"Never",
|
||||||
|
"On Enable (only once)",
|
||||||
|
"On Beam Move",
|
||||||
|
"Every X Frames",
|
||||||
|
"On Beam Move and Every X Frames",
|
||||||
|
};
|
||||||
|
|
||||||
|
public static readonly GUIContent WaitXFrames = new GUIContent("X frames to wait",
|
||||||
|
"How many frames we wait between 2 occlusion tests?\nIf you want your beam to be super responsive to the changes of your environment, update it every frame by setting 1.\nIf you want to save on performance, we recommend to wait few frames between each update by setting a higher value.");
|
||||||
|
public static readonly GUIContent MinSurfaceRatio = new GUIContent("Min Occluded %", "Approximated percentage of the beam to collide with the surface in order to be considered as occluder.");
|
||||||
|
public static readonly GUIContent MaxSurfaceDot = new GUIContent("Max Angle", "Max angle (in degrees) between the beam and the surface in order to be considered as occluder.");
|
||||||
|
public static readonly GUIContent PlaneAlignment = new GUIContent("Alignment", "Alignment of the computed clipping plane:\n- Surface: align to the surface normal which blocks the beam. Works better for large occluders such as floors and walls.\n- Beam: keep the plane aligned with the beam direction. Works better with more complex occluders or with corners.");
|
||||||
|
public static readonly GUIContent PlaneOffset = new GUIContent("Offset Units", "Translate the plane. We recommend to set a small positive offset in order to handle non-flat surface better.");
|
||||||
|
public static readonly GUIContent FadeDistanceToSurface = new GUIContent("Fade Distance Units", "Fade out the beam before the occlusion surface in order to soften the transition.");
|
||||||
|
public static readonly GUIContent EditorShowDebugPlane = new GUIContent("Show Debug Plane", "Draw debug plane on the scene view.");
|
||||||
|
public static readonly GUIContent EditorRaycastAtEachFrame = new GUIContent("Update in Editor", "Perform occlusion tests and raycasts in Editor.");
|
||||||
|
|
||||||
|
public static string GetUpdateRateAdvice<T>(DynamicOcclusionUpdateRate value)
|
||||||
|
{
|
||||||
|
switch (value)
|
||||||
|
{
|
||||||
|
case DynamicOcclusionUpdateRate.Never: return string.Format("The occlusion will never be updated.\nThe only way to update it is to manually call '{0}.ProcessOcclusionManually()' from script whenever you need.", typeof(T).Name);
|
||||||
|
case DynamicOcclusionUpdateRate.OnEnable: return "The occlusion will only be updated once on start, and each time the beam is enabled/activated (after being disabled/deactivated).\nIt's suitable for static beams located in static environment.";
|
||||||
|
case DynamicOcclusionUpdateRate.OnBeamMove: return "The occlusion will only be updated when the beam will move.\nIt's suitable for moving beams located in static environment.";
|
||||||
|
case DynamicOcclusionUpdateRate.EveryXFrames: return "The occlusion will be updated every {0} frame(s).\nIt's suitable for static beams located in moving environment.";
|
||||||
|
case DynamicOcclusionUpdateRate.OnBeamMoveAndEveryXFrames: return "The occlusion will be updated when the beam will move in addition to every {0} frame(s).\nIt's suitable for moving beams located in moving environment.";
|
||||||
|
default: return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static readonly GUIContent DepthBufferOcclusionCulling = new GUIContent("Occlusion Culling", "Whether or not the virtual camera will use occlusion culling during rendering from the beam's POV.");
|
||||||
|
public static readonly GUIContent DepthBufferDepthMapResolution = new GUIContent("Depth Map Resolution", "Controls how large the depth texture captured by the virtual camera is.\nThe lower the resolution, the better the performance, but the less accurate the rendering.");
|
||||||
|
|
||||||
|
public const string HelpDepthBufferAndBeam2D = "'Dynamic Occlusion (Depth Buffer)' doesn't work with 2D sprites nor 2D colliders. It will only track 3D objects.";
|
||||||
|
|
||||||
|
public const string HelpOverrideLayer = "To keep good performance, it's highly recommended to set an 'Override Layer' in the Config when using this feature, to prevent from having a LayerMark including any Volumetric Beam.";
|
||||||
|
public static string HelpLayerMaskIssues { get { return string.Format("The beams are generated on the layer '{0}' (set in the Config), but this LayerMask includes this layer.\nTo keep good performance, it's highly recommended to set a LayerMask which doesn't include this layer!", UnityEngine.LayerMask.LayerToName(VLB.Config.Instance.geometryLayerID)); } }
|
||||||
|
|
||||||
|
public const string HelpFeatureDisabled = "The Dynamic Occlusion features have been disabled in the plugin's Config.";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class TriggerZone
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderInfos = new GUIContent("Infos");
|
||||||
|
|
||||||
|
public static readonly GUIContent SetIsTrigger = new GUIContent("Set Is Trigger", "Define if the Collider will be created as a convex trigger (not physical, most common behavior) or as a regular collider (physical).");
|
||||||
|
public static readonly GUIContent RangeMultiplier = new GUIContent("Range Multiplier", "Change the length of the Collider.\nFor example, set 2.0 to make the Collider 2x longer than the beam.");
|
||||||
|
|
||||||
|
public const string HelpDescription2D = "Generate a 2D Polygon Collider with the same shape than the beam, supporting dynamic occlusion.";
|
||||||
|
public const string HelpDescription3D = "Generate a 3D Mesh Collider with the same shape than the beam. The collider doesn't support occlusion though.";
|
||||||
|
public const string HelpTrackChangesDuringPlaytimeEnabled = "The TriggerZone collider cannot be changed in realtime.\nIf you animate a property which change the shape of the beam, the collider shape won't fit anymore.";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class SkewingHandle
|
||||||
|
{
|
||||||
|
public static readonly GUIContent Beam = new GUIContent("Beam", "The Volumetric Light Beam you want to modify.");
|
||||||
|
public static readonly GUIContent ShouldUpdateEachFrame = new GUIContent("Should Update Each Frame", "Should the beam's skewing property be updated each frame or only once?");
|
||||||
|
|
||||||
|
public const string ErrorAttachedToSelf = "You should attach the 'SkewingHandle' component to another GameObject than the beam itself.";
|
||||||
|
public const string ErrorCannotSkew = "This beam can't be skewed because it doesn't use 'Custom' mesh type.";
|
||||||
|
public const string ErrorCannotUpdate = "This beam can't be updated each frame since its property 'Track Changes During Playtime' is disabled.";
|
||||||
|
|
||||||
|
public const string HelpFeatureDisabled = "The 'Mesh Skewing' feature has been disabled in the plugin's Config.";
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static class Shadow
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderUpdateRate = new GUIContent("Update Rate");
|
||||||
|
public static readonly GUIContent HeaderVisual = new GUIContent("Visual");
|
||||||
|
public static readonly GUIContent HeaderCamera = new GUIContent("Depth Camera");
|
||||||
|
|
||||||
|
public static readonly GUIContent Strength = new GUIContent("Strength", "Controls how dark the shadow cast by this Light Beam will be.\nThe bigger the value, the more the shadow will affect the visual.");
|
||||||
|
public static readonly GUIContent LayerMask = new GUIContent("Layer Mask",
|
||||||
|
"The beam can only be occluded by objects located on the layers matching this mask.\nIt's very important to set it as restrictive as possible (checking only the layers which are necessary) to perform a more efficient process in order to increase the performance.");
|
||||||
|
public static readonly GUIContent UpdateRate = new GUIContent("Update Rate", "How often will the occlusion be processed?\nTry to update the occlusion as rarely as possible to keep good performance.");
|
||||||
|
public static readonly string[] UpdateRateDescriptions = new string[]
|
||||||
|
{
|
||||||
|
"Never",
|
||||||
|
"On Enable (only once)",
|
||||||
|
"On Beam Move",
|
||||||
|
"Every X Frames",
|
||||||
|
"On Beam Move and Every X Frames",
|
||||||
|
};
|
||||||
|
|
||||||
|
public static readonly GUIContent WaitXFrames = new GUIContent("X frames to wait",
|
||||||
|
"How many frames we wait between 2 occlusion tests?\nIf you want your beam to be super responsive to the changes of your environment, update it every frame by setting 1.\nIf you want to save on performance, we recommend to wait few frames between each update by setting a higher value.");
|
||||||
|
|
||||||
|
public static string GetUpdateRateAdvice<T>(ShadowUpdateRate value)
|
||||||
|
{
|
||||||
|
switch (value)
|
||||||
|
{
|
||||||
|
case ShadowUpdateRate.Never: return string.Format("The occlusion will never be updated.\nThe only way to update it is to manually call '{0}.ProcessOcclusionManually()' from script whenever you need.", typeof(T).Name);
|
||||||
|
case ShadowUpdateRate.OnEnable: return "The occlusion will only be updated once on start, and each time the beam is enabled/activated (after being disabled/deactivated).\nIt's suitable for static beams located in static environment.";
|
||||||
|
case ShadowUpdateRate.OnBeamMove: return "The occlusion will only be updated when the beam will move.\nIt's suitable for moving beams located in static environment.";
|
||||||
|
case ShadowUpdateRate.EveryXFrames: return "The occlusion will be updated every {0} frame(s).\nIt's suitable for static beams located in moving environment.";
|
||||||
|
case ShadowUpdateRate.OnBeamMoveAndEveryXFrames: return "The occlusion will be updated when the beam will move in addition to every {0} frame(s).\nIt's suitable for moving beams located in moving environment.";
|
||||||
|
default: return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static readonly GUIContent OcclusionCulling = new GUIContent("Occlusion Culling", "Whether or not the virtual camera will use occlusion culling during rendering from the beam's POV.");
|
||||||
|
public static readonly GUIContent DepthMapResolution = new GUIContent("Depth Map Resolution", "Controls how large the depth texture captured by the virtual camera is.\nThe lower the resolution, the better the performance, but the less accurate the rendering.");
|
||||||
|
|
||||||
|
public const string HelpOverrideLayer = "To keep good performance, it's highly recommended to set an 'Override Layer' in the Config when using this feature, to prevent from having a LayerMark including any Volumetric Beam.";
|
||||||
|
public static string HelpLayerMaskIssues { get { return string.Format("The beams are generated on the layer '{0}' (set in the Config), but this LayerMask includes this layer.\nTo keep good performance, it's highly recommended to set a LayerMask which doesn't include this layer!", UnityEngine.LayerMask.LayerToName(VLB.Config.Instance.geometryLayerID)); } }
|
||||||
|
|
||||||
|
public const string HelpFeatureDisabled = "The Shadow feature has been disabled in the plugin's Config.";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class Cookie
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderVisual = new GUIContent("Visual");
|
||||||
|
public static readonly GUIContent HeaderTexture = new GUIContent("Texture");
|
||||||
|
public static readonly GUIContent HeaderTransform = new GUIContent("Transform");
|
||||||
|
|
||||||
|
public static readonly GUIContent Contribution = new GUIContent("Contribution", "How much the cookie texture will contribute to the beam rendering.");
|
||||||
|
public static readonly GUIContent CookieTexture = new GUIContent("Cookie Texture", "Specify the texture mask asset.\nIt can be a regular 'Cookie' texture or any other texture type.");
|
||||||
|
public static readonly GUIContent Channel = new GUIContent("Texture Channel", "Which channel(s) will be used to render the cookie.\nSpecify a unique channel with a black & white texture to render a regular cookie.\nSpecify RGBA with a colored texture to simulate light passing through a stained glass.");
|
||||||
|
public static readonly GUIContent Negative = new GUIContent("Negative", "- False: white/opaque value in chosen texture channel is visible.\n- True: white/opaque value in chosen texture channel is hidden.");
|
||||||
|
|
||||||
|
public static readonly GUIContent Translation = new GUIContent("Translation", "2D local translation applied to the cookie texture.");
|
||||||
|
public static readonly GUIContent Rotation = new GUIContent("Rotation", "Local rotation angle of the cookie texture (in degrees).");
|
||||||
|
public static readonly GUIContent Scale = new GUIContent("Scale", "2D local scale applied to the cookie texture.");
|
||||||
|
|
||||||
|
public const string TipCookieMipMaps = "The specified cookie texture generates mip maps.\nWe highly recommend to disable mip maps generation on it to prevent from having rendering artifacts around objects edges in front or inside volumetric light beams.";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class Config
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderBeamGeometry = new GUIContent("Beam Geometry", "");
|
||||||
|
public static readonly GUIContent HeaderRendering = new GUIContent("Rendering", "");
|
||||||
|
public static readonly GUIContent HeaderURPSpecific = new GUIContent("URP Specific Options", "");
|
||||||
|
public static readonly GUIContent HeaderSharedMesh = new GUIContent("Shared Mesh", "");
|
||||||
|
public static readonly GUIContent HeaderGlobal3DNoise = new GUIContent("Global 3D Noise", "");
|
||||||
|
public static readonly GUIContent HeaderFadeOutCamera = new GUIContent("Camera to compute Fade Out", "");
|
||||||
|
public static readonly GUIContent HeaderFeaturesEnabled = new GUIContent("Features Enabled", "Disable the features you don't use in your project to speed up export time, specially with URP and HDRP.");
|
||||||
|
public static readonly GUIContent HeaderInternalData = new GUIContent("Internal Data (do not change)", "");
|
||||||
|
|
||||||
|
public static readonly GUIContent GeometryOverrideLayer = new GUIContent("Override Layer", "- If enabled, we force the procedural beam geometry GameObjects to be created on the Layer specified here.\n- If disabled, the procedural beam geometry GameObjects inherit the Layer of their beam (the GameObject containing the 'VolumetricLightBeam' component).");
|
||||||
|
public static readonly GUIContent GeometryTag = new GUIContent("Tag", "The tag applied on the procedural geometry GameObjects");
|
||||||
|
public static readonly GUIContent GeometryRenderQueueSD = new GUIContent("Render Queue (SD beams)", "Determine in which order SD beams are rendered compared to other objects.\nThis way for example transparent objects are rendered after opaque objects, and so on.");
|
||||||
|
public static readonly GUIContent GeometryRenderQueueHD = new GUIContent("Render Queue (HD beams)", "Determine in which order HD beams are rendered compared to other objects.\nThis way for example transparent objects are rendered after opaque objects, and so on.");
|
||||||
|
public static readonly GUIContent GeometryRenderPipeline = new GUIContent("Render Pipeline", "Select the Render Pipeline (Built-In or SRP) in use.");
|
||||||
|
public static readonly GUIContent GeometryRenderingMode = new GUIContent("Rendering Mode",
|
||||||
|
@"- Multi-Pass: Use the 2 pass shader for SD beams (will generate 2 drawcalls per beam) and the 1 pass shader for HD beams (will generate 1 drawcall per beam). Not compatible with Scriptable Render Pipelines such as HDRP and URP.
|
||||||
|
- Default: Use the 1 pass shader. Will generate 1 drawcall per beam.
|
||||||
|
- GPU Instancing: Dynamically batch multiple beams to combine and reduce draw calls.
|
||||||
|
- SRP Batcher: Use the SRP Batcher to automatically batch multiple beams and reduce draw calls. Only available when using SRP.");
|
||||||
|
|
||||||
|
public static string GetErrorSrpAndMultiPassNotCompatible(ShaderMode shaderMode) { return string.Format("Using a Scriptable Render Pipeline with 'Multi-Pass' Rendering Mode is not supported: please choose another Rendering Mode, or '{0}' will be used.", VLB.Config.Instance.GetActualRenderingMode(shaderMode)); }
|
||||||
|
public static string GetErrorSrpBatcherOnlyCompatibleWithSrp(ShaderMode shaderMode) { return string.Format("The 'SRP Batcher' Rendering Mode is only compatible when using a SRP: please choose another Rendering Mode, or '{0}' will be used.", VLB.Config.Instance.GetActualRenderingMode(shaderMode)); }
|
||||||
|
public const string ErrorRenderPipelineMismatch = "It looks like the 'Render Pipeline' is not correctly set.\nPlease make sure to select the proper value depending on your pipeline in use.";
|
||||||
|
|
||||||
|
public static readonly GUIContent URPDepthCameraScriptableRendererIndex = new GUIContent("Custom renderer index for Depth Camera", "When using URP, specify a custom Renderer index used by the depth cameras for the 'Dynamic Occlusion (Depth Buffer)' and 'HD Shadow' features.\nThe 'Renderer list' is editable in the URP asset.\n\nWe recommend to specify a custom index referencing the URP default 'ForwardRenderer' when you are using a custom renderer that doesn't support writing to depth render texture. This is the case if you encounter errors like 'RenderTexture.Create failed: colorFormat & depthStencilFormat cannot both be none'.\n\nSet -1 to disable this feature.");
|
||||||
|
|
||||||
|
public static readonly GUIContent FadeOutCameraTag = new GUIContent("Fade Out Camera Tag", "Tag used to retrieve the camera used to compute the fade out factor on beams");
|
||||||
|
|
||||||
|
public static readonly GUIContent SharedMeshSides = new GUIContent("Cone Mesh Sides", "Number of Sides of the cone.\nHigher values make the beam looks more 'round', but require more memory and graphic performance.\nA recommended value for a decent quality while keeping the poly count low is 18.");
|
||||||
|
public static readonly GUIContent SharedMeshSegments = new GUIContent("Cone Mesh Segments", "Number of Segments of the cone.\nHigher values give better looking results but require more performance. We recommend at least 3 segments, specially regarding Attenuation and Gradient, otherwise the approximation could become inaccurate.\nThe longer the beam, the more segments we recommend to set.\nA recommended value is 4.");
|
||||||
|
public static readonly GUIContent GlobalNoiseScale = new GUIContent("Scale", "Global 3D Noise texture scaling: higher scale make the noise more visible, but potentially less realistic");
|
||||||
|
public static readonly GUIContent GlobalNoiseVelocity = new GUIContent("Velocity", "Global World Space direction and speed of the noise scrolling, simulating the fog/smoke movement");
|
||||||
|
public static readonly GUIContent NoiseTexture3D = new GUIContent("3D Noise Texture", "3D Texture storing noise data.");
|
||||||
|
public static readonly GUIContent DustParticlesPrefab = new GUIContent("Dust Particles Prefab", "ParticleSystem prefab instantiated for the Volumetric Dust Particles feature (Unity 5.5 or above)");
|
||||||
|
public static readonly GUIContent DitheringFactor = new GUIContent("Screen Space Dithering", "Depending on the quality of your screen, you might see some artifacts with high contrast visual (like a white beam over a black background).\nThese is a very common problem known as color banding.\nTo help with this issue, the plugin offers a Dithering factor: it smooths the banding by introducing a subtle pattern of noise.");
|
||||||
|
public static readonly GUIContent DitheringNoiseTexture = new GUIContent("Dithering Noise Texture", "Noise texture for dithering feature.");
|
||||||
|
public static readonly GUIContent UseLightColorTemperature = new GUIContent("Use Light Color Temperature", "Contribution of the attached spotlight temperature to the final beam color.\nOnly useful when:\n- The beams is attached to a Unity spotlight.\n- The beams color is linked to the Unity Light color.\n- The Unity light uses 'color temperature mode' and is specified with 'Filter' and 'Temperature' properties.");
|
||||||
|
public static readonly GUIContent OpenDocumentation = new GUIContent("Documentation", "Open the online documentation.");
|
||||||
|
public static readonly GUIContent CopyDebugInfo = new GUIContent("Copy debug info", "Copy to the clipboard system information useful for debugging. Please send use this data when you encounter a problem.");
|
||||||
|
public static readonly GUIContent ClearAssetStoreCache = new GUIContent("Clear Asset Store cache", "Delete the AssetStore download cache to force Unity to re-download the proper package.\nCan solve issues when changing Unity version or updating the asset.");
|
||||||
|
public static readonly GUIContent ResetToDefaultButton = new GUIContent("Default values", "Reset properties to their default values.");
|
||||||
|
public static readonly GUIContent ResetInternalDataButton = new GUIContent("Reset internal data", "Reset internal data to their default values.");
|
||||||
|
|
||||||
|
public static readonly GUIContent FeatureEnabledColorGradient = new GUIContent("Color Gradient", "- Off: do not support having a gradient as color.\n- High Only: support gradient color only for devices with Shader Level = 35 or higher.\n- High and Low: support gradient color for all devices");
|
||||||
|
public static readonly GUIContent FeatureEnabledNoise3D = new GUIContent("Noise 3D", "Support 'Noise 3D' feature or not.");
|
||||||
|
|
||||||
|
public static readonly string[] GeometryRenderPipelineEnumDescriptions = new string[]
|
||||||
|
{
|
||||||
|
"Built-In",
|
||||||
|
"URP",
|
||||||
|
"HDRP",
|
||||||
|
};
|
||||||
|
|
||||||
|
public static string GetErrorInvalidShader() { return string.Format("Fail to generate shader asset. Please try to reset the Config asset or reinstall the plugin."); }
|
||||||
|
|
||||||
|
public static readonly string InvalidPlatformOverride = string.Format(
|
||||||
|
"This Config asset has an invalid name. It should be named either:\n- '{0}{1}' for the default config.\n- '{0}PlatformName{1}' for a config specific to a platform, e.g. '{0}Android{1}'."
|
||||||
|
, VLB.Config.kAssetName
|
||||||
|
, VLB.Config.kAssetNameExt
|
||||||
|
);
|
||||||
|
|
||||||
|
public static readonly string WrongAssetLocation = string.Format(
|
||||||
|
"This Config asset is not the one in use, please make sure: it's directly located under a 'Resources' folder."
|
||||||
|
);
|
||||||
|
|
||||||
|
public static readonly string NotCurrentAssetInUse = string.Format(
|
||||||
|
"This Config asset is not the one in use for current Target Platform '{0}'."
|
||||||
|
, PlatformHelper.GetCurrentPlatformSuffix()
|
||||||
|
);
|
||||||
|
public static class SD
|
||||||
|
{
|
||||||
|
public static readonly GUIContent FeatureEnabledDepthBlend = new GUIContent("Soft Intersect w/ Opaque Geometry (SD only)", "Support having soft intersection when the beam intersects other opaque geometry or not.");
|
||||||
|
public static readonly GUIContent FeatureEnabledDynamicOcclusion = new GUIContent("Dynamic Occlusion (SD only)", "Support 'Dynamic Occlusion' features or not.");
|
||||||
|
public static readonly GUIContent FeatureEnabledMeshSkewing = new GUIContent("Mesh Skewing (SD only)", "Support 'Mesh Skewing' feature or not.");
|
||||||
|
public static readonly GUIContent FeatureEnabledShaderAccuracyHigh = new GUIContent("High Shader Accuracy (SD only)", "Support 'Shader Accuracy' property set to 'High' or not.");
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class HD
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HDSpecific = new GUIContent("HD Specific Options", "");
|
||||||
|
|
||||||
|
public static readonly GUIContent CameraBlendingDistance = new GUIContent("Camera Blending Distance", "Distance from the camera the beam will fade with (HD only. For SD beams, this option can be configured per beam).\n- 0.0: hard intersection\n- Higher values produce soft intersection when the camera is near the cone triangles.");
|
||||||
|
public static readonly GUIContent JitteringNoiseTexture = new GUIContent("Jittering Noise Texture (HD only)", "");
|
||||||
|
|
||||||
|
public static readonly GUIContent TitleRaymarchingQuality = new GUIContent("Raymarching Qualities (Name / Steps Count)", "Specify each different raymarching quality with:\n- an understandable name (to be chosen per HD beam)\n- a number specifying how many raymarching steps will be computed per pixel (the higher, the better quality, the slower the performance)\n\nA new HD beam shader variant will be generated per raymarching quality for the HD beam shader: the more different qualities you'll have, the slower it will get to compile all shader variants and to export standalone builds.");
|
||||||
|
public static readonly GUIContent DefaultRaymarchingQuality = new GUIContent("Default Raymarching Quality", "Raymarching Quality applied by default to newly created HD Volumetric Light Beams");
|
||||||
|
|
||||||
|
public static readonly GUIContent FeatureEnabledShadow = new GUIContent("Shadow (HD only)", "Support 'Volumetric Shadow' feature or not.");
|
||||||
|
public static readonly GUIContent FeatureEnabledCookie = new GUIContent("Cookie (HD only)", "Support 'Volumetric Cookie' featur or not.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static class Effects
|
||||||
|
{
|
||||||
|
public static readonly GUIContent HeaderTimings = new GUIContent("Timings", "");
|
||||||
|
public static readonly GUIContent HeaderPause = new GUIContent("Pause", "");
|
||||||
|
public static readonly GUIContent HeaderVisual = new GUIContent("Visual", "");
|
||||||
|
public static readonly GUIContent HeaderMisc = new GUIContent("Misc", "");
|
||||||
|
|
||||||
|
public static readonly GUIContent PerformPauses = new GUIContent("Perform Pauses", "If enabled, pauses will be added between 2 flickering sequences.");
|
||||||
|
public static readonly GUIContent FlickeringDuration = new GUIContent("Flickering Duration", "The duration of a flickering sequence.\nA random value will be picked each time inside this range.");
|
||||||
|
public static readonly GUIContent PauseDuration = new GUIContent("Pause Duration", "The duration of a pause sequence.\nA random value will be picked each time inside this range.");
|
||||||
|
public static readonly GUIContent RestoreIntensityOnPause = new GUIContent("Restore Intensity On Pause", "Restore the default intensity during the pause sequences.");
|
||||||
|
public static readonly GUIContent FrequencyFlicker = new GUIContent("Frequency", "Frequency of flickering.\nHigher value means the flickering will occur faster.");
|
||||||
|
public static readonly GUIContent FrequencyPulse = new GUIContent("Frequency", "Frequency of pulsing.\nHigher value means the pulsing will occur faster.");
|
||||||
|
public static readonly GUIContent IntensityAmplitude = new GUIContent("Intensity Amplitude", "The amplitude of intensity change which will be applied to the Light and/or Beam.\nA random value will be picked each time inside that range.");
|
||||||
|
public static readonly GUIContent Smoothing = new GUIContent("Smoothing", "How much intensity change will be smoothed.\nHigher value means the more smoothing.");
|
||||||
|
public static readonly GUIContent RestoreIntensityOnDisable = new GUIContent("Restore Intensity On Disable", "Restore the default intensity when this component is disabled.");
|
||||||
|
public static readonly GUIContent ComponentsToChange = new GUIContent("Components To Change", "Decide which component to change among:\n- Unity's Light\n- Volumetric Light Beam\n- Volumetric Dust Particles");
|
||||||
|
public static readonly GUIContent ChangeVolumetricBeamIntensity = new GUIContent("Change Volumetric Beam Intensity", "Apply the flicker on the Volumetric Beam Intensity.");
|
||||||
|
|
||||||
|
public const string HelpNoValidComponents = "This component must be applied with a 'Unity Light' and/or a 'Volumetric Light Beam SD/HD'.";
|
||||||
|
public const string HelpLightNotChangeable = "To apply this effect on the Unity Light's intensity, it must use 'Realtime' or 'Mixed' mode.";
|
||||||
|
public const string HelpBeamNotChangeable = "To apply this effect on the Volumetric Light Beam's intensity, it must have its 'Track Changes During Playtime' property enabled.";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 962298216d0e67f4c9294aa63ae5e9a4
|
||||||
|
timeCreated: 1525089533
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,129 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
#if UNITY_2019_1_OR_NEWER
|
||||||
|
#define UI_USE_FOLDOUT_HEADER_2019
|
||||||
|
#endif
|
||||||
|
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEditor.IMGUI.Controls;
|
||||||
|
using UnityEngine;
|
||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System;
|
||||||
|
using System.Linq.Expressions;
|
||||||
|
using System.Reflection;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public abstract class Editor_Common : Editor
|
||||||
|
{
|
||||||
|
protected virtual void OnEnable()
|
||||||
|
{
|
||||||
|
FoldableHeader.OnEnable();
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
serializedObject.Update();
|
||||||
|
#if UNITY_2019_3_OR_NEWER
|
||||||
|
// no vertical space in 2019.3 looks better
|
||||||
|
#else
|
||||||
|
EditorGUILayout.Separator();
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
protected static void ButtonOpenConfig(bool miniButton = true)
|
||||||
|
{
|
||||||
|
bool buttonClicked = false;
|
||||||
|
if (miniButton) buttonClicked = GUILayout.Button(EditorStrings.Common.ButtonOpenGlobalConfig, EditorStyles.miniButton);
|
||||||
|
else buttonClicked = GUILayout.Button(EditorStrings.Common.ButtonOpenGlobalConfig);
|
||||||
|
|
||||||
|
if (buttonClicked)
|
||||||
|
Config.EditorSelectInstance();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// SERIALIZED PROPERTY RETRIEVAL
|
||||||
|
string GetThisNamespaceAsString() { return GetType().Namespace; }
|
||||||
|
|
||||||
|
SerializedProperty FindProperty(string prefix, string name)
|
||||||
|
{
|
||||||
|
Debug.Assert(serializedObject != null);
|
||||||
|
var prop = serializedObject.FindProperty(name); // try first with the plain name
|
||||||
|
if (prop == null)
|
||||||
|
{
|
||||||
|
name = string.Format("{0}{1}{2}", prefix, char.ToUpperInvariant(name[0]), name.Substring(1)); // try with a different name to catch private props: get '_Name' from 'name'
|
||||||
|
prop = serializedObject.FindProperty(name);
|
||||||
|
}
|
||||||
|
return prop;
|
||||||
|
}
|
||||||
|
|
||||||
|
void RetrieveSerializedProperties(string prefix, Type t)
|
||||||
|
{
|
||||||
|
if (t == null) return;
|
||||||
|
if (t.Namespace != GetThisNamespaceAsString()) return;
|
||||||
|
|
||||||
|
var allEditorFields = t.GetFields(BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.DeclaredOnly);
|
||||||
|
foreach (var field in allEditorFields)
|
||||||
|
{
|
||||||
|
if (field.FieldType == typeof(SerializedProperty))
|
||||||
|
{
|
||||||
|
var runtimeFieldName = field.Name;
|
||||||
|
var serializedProp = FindProperty(prefix, runtimeFieldName);
|
||||||
|
Debug.AssertFormat(serializedProp != null, "Fail to find serialized field '{0}' in object {1}", runtimeFieldName, serializedObject.targetObject);
|
||||||
|
field.SetValue(this, serializedProp);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
RetrieveSerializedProperties(prefix, t.BaseType);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void RetrieveSerializedProperties(string prefix)
|
||||||
|
{
|
||||||
|
RetrieveSerializedProperties(prefix, GetType());
|
||||||
|
}
|
||||||
|
|
||||||
|
protected static void DrawMultiplierProperty(SerializedProperty property, string tooltip)
|
||||||
|
{
|
||||||
|
using (new EditorExtensions.LabelWidth(13f))
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
EditorGUILayout.PropertyField(property, new GUIContent("x", tooltip), GUILayout.MinWidth(35.0f), GUILayout.MaxWidth(55.0f));
|
||||||
|
if(EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
property.floatValue = Mathf.Max(property.floatValue, Consts.Beam.MultiplierMin);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
protected struct InfoTip
|
||||||
|
{
|
||||||
|
public MessageType type;
|
||||||
|
public string message;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected virtual void GetInfoTips(List<InfoTip> tips) {}
|
||||||
|
|
||||||
|
protected bool DrawInfos()
|
||||||
|
{
|
||||||
|
var tips = new List<InfoTip>();
|
||||||
|
GetInfoTips(tips);
|
||||||
|
|
||||||
|
if (tips != null && tips.Count > 0)
|
||||||
|
{
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Beam.HeaderInfos))
|
||||||
|
{
|
||||||
|
if (tips != null)
|
||||||
|
{
|
||||||
|
foreach (var tip in tips)
|
||||||
|
EditorGUILayout.HelpBox(tip.message, tip.type);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif // UNITY_EDITOR
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 11a6b248e0eebc44bb9ba203d8a8d77a
|
||||||
|
timeCreated: 1508779655
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,616 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
|
||||||
|
#if UNITY_2019_3_OR_NEWER
|
||||||
|
#define VLB_LIGHT_TEMPERATURE_SUPPORT
|
||||||
|
#endif
|
||||||
|
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEditorInternal;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(Config))]
|
||||||
|
public class Editor_Config : Editor_Common
|
||||||
|
{
|
||||||
|
SerializedProperty geometryOverrideLayer = null, geometryLayerID = null, geometryTag = null, geometryRenderQueue = null, geometryRenderQueueHD = null, renderPipeline = null, renderingMode = null;
|
||||||
|
SerializedProperty sharedMeshSides = null, sharedMeshSegments = null;
|
||||||
|
SerializedProperty hdBeamsCameraBlendingDistance = null;
|
||||||
|
SerializedProperty urpDepthCameraScriptableRendererIndex = null;
|
||||||
|
SerializedProperty globalNoiseScale = null, globalNoiseVelocity = null;
|
||||||
|
SerializedProperty fadeOutCameraTag = null;
|
||||||
|
SerializedProperty noiseTexture3D = null;
|
||||||
|
SerializedProperty dustParticlesPrefab = null;
|
||||||
|
SerializedProperty ditheringFactor = null, ditheringNoiseTexture = null, jitteringNoiseTexture = null;
|
||||||
|
SerializedProperty raymarchingQualities = null, defaultRaymarchingQualityUniqueID = null;
|
||||||
|
SerializedProperty featureEnabledColorGradient = null, featureEnabledDepthBlend = null, featureEnabledNoise3D = null, featureEnabledDynamicOcclusion = null, featureEnabledMeshSkewing = null, featureEnabledShaderAccuracyHigh = null;
|
||||||
|
SerializedProperty featureEnabledShadow = null, featureEnabledCookie = null;
|
||||||
|
#if VLB_LIGHT_TEMPERATURE_SUPPORT
|
||||||
|
SerializedProperty useLightColorTemperature = null;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Config m_TargetConfig = null;
|
||||||
|
RenderQueueDrawer m_DrawerRenderQueue;
|
||||||
|
RenderQueueDrawer m_DrawerRenderQueueHD;
|
||||||
|
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
RetrieveSerializedProperties("m_");
|
||||||
|
|
||||||
|
m_DrawerRenderQueue = new RenderQueueDrawer(geometryRenderQueue);
|
||||||
|
m_DrawerRenderQueueHD = new RenderQueueDrawer(geometryRenderQueueHD);
|
||||||
|
|
||||||
|
Noise3D.LoadIfNeeded(); // Try to load Noise3D, maybe for the 1st time
|
||||||
|
|
||||||
|
m_TargetConfig = this.target as Config;
|
||||||
|
|
||||||
|
RaymarchingQualitiesInit();
|
||||||
|
}
|
||||||
|
|
||||||
|
void RenderingModeGUIDraw(SerializedProperty sprop, GUIContent label)
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(sprop, label);
|
||||||
|
|
||||||
|
if (renderPipeline.enumValueIndex == (int)RenderPipeline.BuiltIn)
|
||||||
|
{
|
||||||
|
if (sprop.enumValueIndex == (int)RenderingMode.SRPBatcher)
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Config.GetErrorSrpBatcherOnlyCompatibleWithSrp(ShaderMode.SD), MessageType.Error);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (sprop.enumValueIndex == (int)RenderingMode.MultiPass)
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Config.GetErrorSrpAndMultiPassNotCompatible(ShaderMode.SD), MessageType.Error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnHeaderGUI()
|
||||||
|
{
|
||||||
|
GUILayout.BeginVertical("In BigTitle");
|
||||||
|
EditorGUILayout.Separator();
|
||||||
|
|
||||||
|
var title = string.Format("Volumetric Light Beam - Plugin Configuration");
|
||||||
|
EditorGUILayout.LabelField(title, EditorStyles.boldLabel);
|
||||||
|
EditorGUILayout.LabelField(string.Format("Current Version: {0}", Version.CurrentAsString), EditorStyles.miniBoldLabel);
|
||||||
|
EditorGUILayout.Separator();
|
||||||
|
GUILayout.EndVertical();
|
||||||
|
}
|
||||||
|
|
||||||
|
void OnAddConfigPerPlatform(object platform)
|
||||||
|
{
|
||||||
|
var p = (RuntimePlatform)platform;
|
||||||
|
var clone = UnityEngine.Object.Instantiate(m_TargetConfig);
|
||||||
|
Debug.Assert(clone);
|
||||||
|
var path = AssetDatabase.GetAssetPath(m_TargetConfig).Replace(m_TargetConfig.name + Config.kAssetNameExt, "");
|
||||||
|
Config.CreateAsset(clone, path + Config.kAssetName + p.ToString() + Config.kAssetNameExt);
|
||||||
|
Selection.activeObject = clone;
|
||||||
|
}
|
||||||
|
|
||||||
|
[System.Flags]
|
||||||
|
enum DirtyFlags
|
||||||
|
{
|
||||||
|
Target = 1 << 1,
|
||||||
|
Shader = 1 << 2,
|
||||||
|
Noise = 1 << 3,
|
||||||
|
GlobalMesh = 1 << 4,
|
||||||
|
AllBeamGeom = 1 << 5,
|
||||||
|
AllMeshes = 1 << 6
|
||||||
|
}
|
||||||
|
|
||||||
|
void SetDirty(DirtyFlags flags)
|
||||||
|
{
|
||||||
|
if (m_IsUsedInstance)
|
||||||
|
{
|
||||||
|
if (flags.HasFlag(DirtyFlags.Target)) EditorUtility.SetDirty(target);
|
||||||
|
if (flags.HasFlag(DirtyFlags.Shader)) m_NeedToRefreshShader = true;
|
||||||
|
if (flags.HasFlag(DirtyFlags.Noise)) m_NeedToReloadNoise = true;
|
||||||
|
if (flags.HasFlag(DirtyFlags.GlobalMesh)) GlobalMeshSD.Destroy();
|
||||||
|
if (flags.HasFlag(DirtyFlags.AllBeamGeom)) Utils._EditorSetAllBeamGeomDirty();
|
||||||
|
if (flags.HasFlag(DirtyFlags.AllMeshes)) Utils._EditorSetAllMeshesDirty();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool m_NeedToReloadNoise = false;
|
||||||
|
bool m_NeedToRefreshShader = false;
|
||||||
|
bool m_IsUsedInstance = false;
|
||||||
|
|
||||||
|
|
||||||
|
#region Raymarching Qualities
|
||||||
|
ReorderableList m_ListQualities;
|
||||||
|
|
||||||
|
void RaymarchingQualitiesInit()
|
||||||
|
{
|
||||||
|
m_ListQualities = new ReorderableList(serializedObject
|
||||||
|
, raymarchingQualities
|
||||||
|
, true // draggable
|
||||||
|
, true // displayHeader
|
||||||
|
, true // displayAddButton
|
||||||
|
, true // displayRemoveButton
|
||||||
|
);
|
||||||
|
m_ListQualities.drawHeaderCallback = RaymarchingQualitiesDrawHeader;
|
||||||
|
m_ListQualities.drawElementCallback = RaymarchingQualitiesDrawElement;
|
||||||
|
m_ListQualities.onAddCallback = RaymarchingQualitiesOnAdd;
|
||||||
|
m_ListQualities.onRemoveCallback = RaymarchingQualitiesOnRemove;
|
||||||
|
m_ListQualities.onChangedCallback = RaymarchingQualitiesOnChanged;
|
||||||
|
m_ListQualities.onCanRemoveCallback = RaymarchingQualitiesOnCanRemove;
|
||||||
|
}
|
||||||
|
|
||||||
|
void RaymarchingQualitiesDrawHeader(Rect rect)
|
||||||
|
{
|
||||||
|
EditorGUI.LabelField(rect, EditorStrings.Config.HD.TitleRaymarchingQuality);
|
||||||
|
}
|
||||||
|
|
||||||
|
void RaymarchingQualitiesDrawElement(Rect rect, int i, bool isActive, bool isFocused)
|
||||||
|
{
|
||||||
|
const float kBorder = 1.0f;
|
||||||
|
rect.yMin += kBorder;
|
||||||
|
rect.yMax -= kBorder * 2;
|
||||||
|
|
||||||
|
const float kPropSeparator = 5.0f;
|
||||||
|
const float kWidthSteps = 50.0f;
|
||||||
|
|
||||||
|
Rect rectName = rect;
|
||||||
|
rectName.width -= kWidthSteps + kPropSeparator;
|
||||||
|
|
||||||
|
Rect rectSteps = rect;
|
||||||
|
rectSteps.x = rect.xMax - kWidthSteps;
|
||||||
|
rectSteps.width = kWidthSteps;
|
||||||
|
|
||||||
|
var qual = m_TargetConfig.GetRaymarchingQualityForIndex(i);
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
qual.name = EditorGUI.TextField(rectName, qual.name);
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
SetDirty(DirtyFlags.Target);
|
||||||
|
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
qual.stepCount = Mathf.Max(EditorGUI.IntField(rectSteps, qual.stepCount), Consts.Config.HD.RaymarchingQualitiesStepsMin);
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
SetDirty(DirtyFlags.Target | DirtyFlags.Shader);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void RaymarchingQualitiesOnAdd(ReorderableList list)
|
||||||
|
{
|
||||||
|
var newQual = RaymarchingQuality.New();
|
||||||
|
m_TargetConfig.AddRaymarchingQuality(newQual);
|
||||||
|
SetDirty(DirtyFlags.Target);
|
||||||
|
}
|
||||||
|
|
||||||
|
void RaymarchingQualitiesOnRemove(ReorderableList list)
|
||||||
|
{
|
||||||
|
if (list.count < 1)
|
||||||
|
{
|
||||||
|
Debug.LogError("Having at least 1 RaymarchingQuality value is mandatory: cannot delete.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
var qual = m_TargetConfig.GetRaymarchingQualityForIndex(list.index);
|
||||||
|
if (qual != null)
|
||||||
|
{
|
||||||
|
if (qual.uniqueID == m_TargetConfig.defaultRaymarchingQualityUniqueID)
|
||||||
|
{
|
||||||
|
EditorUtility.DisplayDialog(string.Format("Can't remove Raymarching Quality '{0}'", qual.name)
|
||||||
|
, string.Format("We cannot remove Raymarching Quality '{0}' with {1} steps because it's the default quality", qual.name, qual.stepCount)
|
||||||
|
, "Ok");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (EditorUtility.DisplayDialog(string.Format("Remove Raymarching Quality '{0}'?", qual.name)
|
||||||
|
, string.Format("Do you really want to remove the Raymarching Quality '{0}' with {1} steps?\nAll Volumetric Light Beams using this quality will now use the default quality.", qual.name, qual.stepCount)
|
||||||
|
, "Ok"
|
||||||
|
, "Cancel"))
|
||||||
|
{
|
||||||
|
m_TargetConfig.RemoveRaymarchingQualityAtIndex(list.index);
|
||||||
|
SetDirty(DirtyFlags.Target | DirtyFlags.AllBeamGeom); // force beams in opened scenes to regenerate with default quality in case they used removed quality
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void RaymarchingQualitiesOnChanged(ReorderableList list)
|
||||||
|
{
|
||||||
|
SetDirty(DirtyFlags.Target | DirtyFlags.Shader);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool RaymarchingQualitiesOnCanRemove(ReorderableList list)
|
||||||
|
{
|
||||||
|
var qual = m_TargetConfig.GetRaymarchingQualityForIndex(list.index);
|
||||||
|
if (qual != null && qual.uniqueID == m_TargetConfig.defaultRaymarchingQualityUniqueID)
|
||||||
|
return false; // cannot remove default quality
|
||||||
|
|
||||||
|
return list.count > 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
void RaymarchingQualitiesDraw()
|
||||||
|
{
|
||||||
|
Debug.Assert(m_ListQualities != null);
|
||||||
|
m_ListQualities.DoLayoutList();
|
||||||
|
|
||||||
|
DrawRaymarchingQualitiesPopup(Config.Instance, defaultRaymarchingQualityUniqueID, EditorStrings.Config.HD.DefaultRaymarchingQuality);
|
||||||
|
|
||||||
|
#if VLB_DEBUG
|
||||||
|
for (int i = 0; i < m_TargetConfig.raymarchingQualitiesCount; ++i)
|
||||||
|
{
|
||||||
|
var qual = m_TargetConfig.GetRaymarchingQualityForIndex(i);
|
||||||
|
if (qual != null)
|
||||||
|
{
|
||||||
|
EditorGUILayout.LabelField(string.Format("#DEBUG# [{0}] {1} - {2} - {3}"
|
||||||
|
, i
|
||||||
|
, qual.uniqueID
|
||||||
|
, qual.name
|
||||||
|
, qual.stepCount
|
||||||
|
));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif // VLB_DEBUG
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void DrawRaymarchingQualitiesPopup(Config instance, SerializedProperty prop, GUIContent content)
|
||||||
|
{
|
||||||
|
Debug.Assert(instance != null);
|
||||||
|
|
||||||
|
int selectedIndex = -1;
|
||||||
|
var descriptions = new GUIContent[instance.raymarchingQualitiesCount];
|
||||||
|
|
||||||
|
for (int i = 0; i < instance.raymarchingQualitiesCount; ++i)
|
||||||
|
{
|
||||||
|
var qual = instance.GetRaymarchingQualityForIndex(i);
|
||||||
|
descriptions[i] = new GUIContent(string.Format("{0} ({1})", qual.name, qual.stepCount));
|
||||||
|
|
||||||
|
if (qual.uniqueID == prop.intValue)
|
||||||
|
selectedIndex = i;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (selectedIndex < 0)
|
||||||
|
{ // in case we couldn't find the serialized ID, fallback to 0
|
||||||
|
selectedIndex = 0;
|
||||||
|
|
||||||
|
var fallback = instance.GetRaymarchingQualityForIndex(selectedIndex);
|
||||||
|
Debug.LogErrorFormat("Failed to find default raymarching quality index in popup that fit with quality unique ID {0}.", prop.intValue);
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUI.showMixedValue = prop.hasMultipleDifferentValues;
|
||||||
|
{
|
||||||
|
selectedIndex = EditorGUILayout.Popup(content, selectedIndex, descriptions);
|
||||||
|
}
|
||||||
|
EditorGUI.showMixedValue = false;
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
var newQual = instance.GetRaymarchingQualityForIndex(selectedIndex);
|
||||||
|
prop.intValue = newQual.uniqueID;
|
||||||
|
}
|
||||||
|
|
||||||
|
#if VLB_DEBUG
|
||||||
|
{
|
||||||
|
var qual = instance.GetRaymarchingQualityForIndex(selectedIndex);
|
||||||
|
EditorGUILayout.LabelField(string.Format("#DEBUG# Serialized Unique ID: {0} | Found Unique ID: {1} / Steps: {2}", prop.intValue, qual.uniqueID, qual.stepCount));
|
||||||
|
}
|
||||||
|
#endif // VLB_DEBUG
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
|
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
base.OnInspectorGUI();
|
||||||
|
|
||||||
|
Debug.Assert(m_TargetConfig != null);
|
||||||
|
|
||||||
|
m_NeedToReloadNoise = false;
|
||||||
|
m_NeedToRefreshShader = false;
|
||||||
|
m_IsUsedInstance = m_TargetConfig.IsCurrentlyUsedInstance();
|
||||||
|
|
||||||
|
// Config per plaftorm
|
||||||
|
#if UNITY_2018_1_OR_NEWER
|
||||||
|
{
|
||||||
|
bool hasValidName = m_TargetConfig.HasValidAssetName();
|
||||||
|
bool isCurrentPlatformSuffix = m_TargetConfig.GetAssetSuffix() == PlatformHelper.GetCurrentPlatformSuffix();
|
||||||
|
|
||||||
|
var platformSuffix = m_TargetConfig.GetAssetSuffix();
|
||||||
|
string platformStr = "Default Config asset";
|
||||||
|
if(!string.IsNullOrEmpty(platformSuffix))
|
||||||
|
platformStr = string.Format("Config asset for platform '{0}'", m_TargetConfig.GetAssetSuffix());
|
||||||
|
if (!hasValidName)
|
||||||
|
platformStr += " (INVALID)";
|
||||||
|
EditorGUILayout.LabelField(platformStr, EditorStyles.boldLabel);
|
||||||
|
|
||||||
|
if (GUILayout.Button(EditorStrings.Beam.ButtonCreateOverridePerPlatform, EditorStyles.miniButton))
|
||||||
|
{
|
||||||
|
var menu = new GenericMenu();
|
||||||
|
foreach (var platform in System.Enum.GetValues(typeof(RuntimePlatform)))
|
||||||
|
menu.AddItem(new GUIContent(platform.ToString()), false, OnAddConfigPerPlatform, platform);
|
||||||
|
menu.ShowAsContext();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!hasValidName)
|
||||||
|
{
|
||||||
|
EditorGUILayout.Separator();
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Config.InvalidPlatformOverride, MessageType.Error);
|
||||||
|
ButtonOpenConfig();
|
||||||
|
}
|
||||||
|
else if (!m_IsUsedInstance)
|
||||||
|
{
|
||||||
|
EditorGUILayout.Separator();
|
||||||
|
|
||||||
|
if (isCurrentPlatformSuffix)
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Config.WrongAssetLocation, MessageType.Error);
|
||||||
|
else
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Config.NotCurrentAssetInUse, MessageType.Warning);
|
||||||
|
|
||||||
|
ButtonOpenConfig();
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorExtensions.DrawLineSeparator();
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HeaderBeamGeometry))
|
||||||
|
{
|
||||||
|
using (new EditorGUILayout.HorizontalScope())
|
||||||
|
{
|
||||||
|
geometryOverrideLayer.boolValue = EditorGUILayout.Toggle(EditorStrings.Config.GeometryOverrideLayer, geometryOverrideLayer.boolValue);
|
||||||
|
using (new EditorGUI.DisabledGroupScope(!geometryOverrideLayer.boolValue))
|
||||||
|
{
|
||||||
|
geometryLayerID.intValue = EditorGUILayout.LayerField(geometryLayerID.intValue);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
geometryTag.stringValue = EditorGUILayout.TagField(EditorStrings.Config.GeometryTag, geometryTag.stringValue);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HeaderRendering))
|
||||||
|
{
|
||||||
|
m_DrawerRenderQueue.Draw(EditorStrings.Config.GeometryRenderQueueSD);
|
||||||
|
m_DrawerRenderQueueHD.Draw(EditorStrings.Config.GeometryRenderQueueHD);
|
||||||
|
|
||||||
|
if (BeamGeometrySD.isCustomRenderPipelineSupported)
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
renderPipeline.CustomEnum<RenderPipeline>(EditorStrings.Config.GeometryRenderPipeline, EditorStrings.Config.GeometryRenderPipelineEnumDescriptions);
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
SetDirty(DirtyFlags.AllBeamGeom | DirtyFlags.Shader); // need to fully reset the BeamGeom to update the shader
|
||||||
|
SRPHelper.SetScriptingDefineSymbolsForRenderPipeline((RenderPipeline)renderPipeline.enumValueIndex);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_TargetConfig.hasRenderPipelineMismatch)
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Config.ErrorRenderPipelineMismatch, MessageType.Error);
|
||||||
|
|
||||||
|
#if VLB_DEBUG
|
||||||
|
EditorGUILayout.LabelField("#DEBUG# RP Scripting Define Symbol: " + SRPHelper.renderPipelineScriptingDefineSymbolAsString);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
RenderingModeGUIDraw(renderingMode, EditorStrings.Config.GeometryRenderingMode);
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
SetDirty(DirtyFlags.AllBeamGeom | DirtyFlags.GlobalMesh | DirtyFlags.Shader); // need to fully reset the BeamGeom to update the shader
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_TargetConfig.GetBeamShader(ShaderMode.SD) == null)
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Config.GetErrorInvalidShader(), MessageType.Error);
|
||||||
|
|
||||||
|
if (m_TargetConfig.GetBeamShader(ShaderMode.HD) == null)
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Config.GetErrorInvalidShader(), MessageType.Error);
|
||||||
|
|
||||||
|
if (ditheringFactor.FloatSlider(EditorStrings.Config.DitheringFactor, 0.0f, 1.0f))
|
||||||
|
{
|
||||||
|
SetDirty(DirtyFlags.Shader);
|
||||||
|
}
|
||||||
|
|
||||||
|
#if VLB_LIGHT_TEMPERATURE_SUPPORT
|
||||||
|
EditorGUILayout.PropertyField(useLightColorTemperature, EditorStrings.Config.UseLightColorTemperature);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
Utils._EditorSetAllMeshesDirty();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_TargetConfig.renderPipeline == RenderPipeline.URP)
|
||||||
|
{
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HeaderURPSpecific))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(urpDepthCameraScriptableRendererIndex, EditorStrings.Config.URPDepthCameraScriptableRendererIndex);
|
||||||
|
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HD.HDSpecific))
|
||||||
|
{
|
||||||
|
RaymarchingQualitiesDraw();
|
||||||
|
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
EditorGUILayout.PropertyField(hdBeamsCameraBlendingDistance, EditorStrings.Config.HD.CameraBlendingDistance);
|
||||||
|
if (EditorGUI.EndChangeCheck()) { SetDirty(DirtyFlags.Shader); }
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HeaderSharedMesh))
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
EditorGUILayout.PropertyField(sharedMeshSides, EditorStrings.Config.SharedMeshSides);
|
||||||
|
EditorGUILayout.PropertyField(sharedMeshSegments, EditorStrings.Config.SharedMeshSegments);
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
SetDirty(DirtyFlags.GlobalMesh | DirtyFlags.AllMeshes);
|
||||||
|
}
|
||||||
|
|
||||||
|
var meshInfo = "These properties will change the mesh tessellation of each Volumetric Light Beam with 'Shared' MeshType.\nAdjust them carefully since they could impact performance.";
|
||||||
|
meshInfo += string.Format("\nShared Mesh stats: {0} vertices, {1} triangles", MeshGenerator.GetSharedMeshVertexCount(), MeshGenerator.GetSharedMeshIndicesCount() / 3);
|
||||||
|
EditorGUILayout.HelpBox(meshInfo, MessageType.Info);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HeaderGlobal3DNoise))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(globalNoiseScale, EditorStrings.Config.GlobalNoiseScale);
|
||||||
|
EditorGUILayout.PropertyField(globalNoiseVelocity, EditorStrings.Config.GlobalNoiseVelocity);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HeaderFadeOutCamera))
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
fadeOutCameraTag.stringValue = EditorGUILayout.TagField(EditorStrings.Config.FadeOutCameraTag, fadeOutCameraTag.stringValue);
|
||||||
|
if (EditorGUI.EndChangeCheck() && Application.isPlaying)
|
||||||
|
m_TargetConfig.ForceUpdateFadeOutCamera();
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HeaderFeaturesEnabled))
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(featureEnabledColorGradient, EditorStrings.Config.FeatureEnabledColorGradient);
|
||||||
|
EditorGUILayout.PropertyField(featureEnabledNoise3D, EditorStrings.Config.FeatureEnabledNoise3D);
|
||||||
|
EditorGUILayout.PropertyField(featureEnabledDepthBlend, EditorStrings.Config.SD.FeatureEnabledDepthBlend);
|
||||||
|
EditorGUILayout.PropertyField(featureEnabledDynamicOcclusion, EditorStrings.Config.SD.FeatureEnabledDynamicOcclusion);
|
||||||
|
EditorGUILayout.PropertyField(featureEnabledMeshSkewing, EditorStrings.Config.SD.FeatureEnabledMeshSkewing);
|
||||||
|
EditorGUILayout.PropertyField(featureEnabledShaderAccuracyHigh, EditorStrings.Config.SD.FeatureEnabledShaderAccuracyHigh);
|
||||||
|
EditorGUILayout.PropertyField(featureEnabledShadow, EditorStrings.Config.HD.FeatureEnabledShadow);
|
||||||
|
EditorGUILayout.PropertyField(featureEnabledCookie, EditorStrings.Config.HD.FeatureEnabledCookie);
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
SetDirty(DirtyFlags.Shader | DirtyFlags.AllBeamGeom);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Config.HeaderInternalData))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(dustParticlesPrefab, EditorStrings.Config.DustParticlesPrefab);
|
||||||
|
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
EditorGUILayout.PropertyField(noiseTexture3D, EditorStrings.Config.NoiseTexture3D);
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
SetDirty(DirtyFlags.Noise);
|
||||||
|
|
||||||
|
if (Noise3D.isSupported && !Noise3D.isProperlyLoaded)
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Common.HelpNoiseLoadingFailed, MessageType.Error);
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
EditorGUILayout.PropertyField(ditheringNoiseTexture, EditorStrings.Config.DitheringNoiseTexture);
|
||||||
|
EditorGUILayout.PropertyField(jitteringNoiseTexture, EditorStrings.Config.HD.JitteringNoiseTexture);
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
SetDirty(DirtyFlags.Shader);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (GUILayout.Button(EditorStrings.Config.OpenDocumentation, EditorStyles.miniButton))
|
||||||
|
{
|
||||||
|
UnityEditor.Help.BrowseURL(Consts.Help.UrlConfig);
|
||||||
|
}
|
||||||
|
|
||||||
|
using (new EditorGUILayout.HorizontalScope())
|
||||||
|
{
|
||||||
|
if (GUILayout.Button(EditorStrings.Config.CopyDebugInfo, EditorStyles.miniButton))
|
||||||
|
{
|
||||||
|
var debugInfo = m_TargetConfig.GetDebugInfo();
|
||||||
|
GUIUtility.systemCopyBuffer = debugInfo;
|
||||||
|
Debug.Log("Copied to clipboard:\n" + debugInfo);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (GUILayout.Button(EditorStrings.Config.ClearAssetStoreCache, EditorStyles.miniButton))
|
||||||
|
{
|
||||||
|
ClearAssetStoreCache();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
using (new EditorGUILayout.HorizontalScope())
|
||||||
|
{
|
||||||
|
if (GUILayout.Button(EditorStrings.Config.ResetToDefaultButton, EditorStyles.miniButton))
|
||||||
|
{
|
||||||
|
UnityEditor.Undo.RecordObject(target, "Reset Config Properties");
|
||||||
|
m_TargetConfig.Reset();
|
||||||
|
SetDirty(DirtyFlags.Target | DirtyFlags.Noise);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (GUILayout.Button(EditorStrings.Config.ResetInternalDataButton, EditorStyles.miniButton))
|
||||||
|
{
|
||||||
|
UnityEditor.Undo.RecordObject(target, "Reset Internal Data");
|
||||||
|
m_TargetConfig.ResetInternalData();
|
||||||
|
SetDirty(DirtyFlags.Target | DirtyFlags.Noise);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
serializedObject.ApplyModifiedProperties();
|
||||||
|
|
||||||
|
if (m_NeedToRefreshShader)
|
||||||
|
m_TargetConfig.RefreshShaders(Config.RefreshShaderFlags.All); // need to be done AFTER ApplyModifiedProperties
|
||||||
|
|
||||||
|
if (m_NeedToReloadNoise)
|
||||||
|
Noise3D._EditorForceReloadData(); // Should be called AFTER ApplyModifiedProperties so the Config instance has the proper values when reloading data
|
||||||
|
}
|
||||||
|
|
||||||
|
static string GetAssetStoreCacheFolder()
|
||||||
|
{
|
||||||
|
switch (Application.platform)
|
||||||
|
{
|
||||||
|
case RuntimePlatform.WindowsEditor:
|
||||||
|
{
|
||||||
|
const string kAppData = "AppData";
|
||||||
|
var appDataPath = Application.persistentDataPath;
|
||||||
|
appDataPath = appDataPath.Substring(0, appDataPath.IndexOf(kAppData) + kAppData.Length);
|
||||||
|
return System.IO.Path.Combine(appDataPath, "Roaming/Unity/Asset Store-5.x/Tech Salad/");
|
||||||
|
}
|
||||||
|
|
||||||
|
case RuntimePlatform.OSXEditor:
|
||||||
|
return "~/Library/Unity/Asset Store-5.x/Tech Salad/";
|
||||||
|
|
||||||
|
case RuntimePlatform.LinuxEditor:
|
||||||
|
return "~/.local/share/unity3d/Asset Store-5.x/Tech Salad/";
|
||||||
|
|
||||||
|
default:
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void ClearAssetStoreCache()
|
||||||
|
{
|
||||||
|
string path = GetAssetStoreCacheFolder();
|
||||||
|
if (path == string.Empty)
|
||||||
|
{
|
||||||
|
EditorUtility.DisplayDialog("Clear Asset Store Cache"
|
||||||
|
, "Failed to compute Asset Store cache folder"
|
||||||
|
, "Ok");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(FileUtil.DeleteFileOrDirectory(path))
|
||||||
|
{
|
||||||
|
EditorUtility.DisplayDialog("Clear Asset Store Cache"
|
||||||
|
, string.Format("Folder '{0}' has been cleared successfully", path)
|
||||||
|
, "Ok");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
EditorUtility.DisplayDialog("Clear Asset Store Cache"
|
||||||
|
, string.Format("Failed to clear folder '{0}'", path)
|
||||||
|
, "Ok");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 11b7e89a4cae94542bcb6c9be7c2ee9b
|
||||||
|
timeCreated: 1508778801
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,74 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public abstract class Editor_EffectAbstractBase<T> : Editor_CommonSD where T : EffectAbstractBase
|
||||||
|
{
|
||||||
|
SerializedProperty componentsToChange = null;
|
||||||
|
SerializedProperty restoreIntensityOnDisable = null;
|
||||||
|
|
||||||
|
protected TargetList<T> m_Targets;
|
||||||
|
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
m_Targets = new TargetList<T>(targets);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected abstract void DisplayChildProperties();
|
||||||
|
|
||||||
|
public sealed override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
base.OnInspectorGUI();
|
||||||
|
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((T comp) => { return comp.GetComponent<UnityEngine.Light>() == null && comp.GetComponent<VolumetricLightBeamAbstractBase>() == null; }))
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Effects.HelpNoValidComponents, MessageType.Error);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((T comp) =>
|
||||||
|
{
|
||||||
|
if (comp.componentsToChange.HasFlag(EffectAbstractBase.ComponentsToChange.UnityLight))
|
||||||
|
{
|
||||||
|
var light = comp.GetComponent<UnityEngine.Light>();
|
||||||
|
#if UNITY_5_6_OR_NEWER
|
||||||
|
return (light && light.lightmapBakeType == UnityEngine.LightmapBakeType.Baked);
|
||||||
|
#else
|
||||||
|
return (light && light.lightmappingMode == UnityEngine.LightmappingMode.Baked);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}))
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Effects.HelpLightNotChangeable, MessageType.Warning);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((T comp) =>
|
||||||
|
{
|
||||||
|
if (comp.componentsToChange.HasFlag(EffectAbstractBase.ComponentsToChange.VolumetricLightBeam))
|
||||||
|
{
|
||||||
|
var beam = comp.GetComponent<VolumetricLightBeamSD>();
|
||||||
|
return (beam && !beam.trackChangesDuringPlaytime);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}))
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Effects.HelpBeamNotChangeable, MessageType.Warning);
|
||||||
|
}
|
||||||
|
|
||||||
|
DisplayChildProperties();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Effects.HeaderMisc))
|
||||||
|
{
|
||||||
|
componentsToChange.CustomMask<EffectAbstractBase.ComponentsToChange>(EditorStrings.Effects.ComponentsToChange);
|
||||||
|
EditorGUILayout.PropertyField(restoreIntensityOnDisable, EditorStrings.Effects.RestoreIntensityOnDisable);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
serializedObject.ApplyModifiedProperties();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 18e0ceec3655f144990c0deb0f6493bb
|
||||||
|
timeCreated: 1617647862
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,48 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(EffectFlicker))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_EffectFlicker : Editor_EffectAbstractBase<EffectFlicker>
|
||||||
|
{
|
||||||
|
SerializedProperty performPauses = null;
|
||||||
|
SerializedProperty flickeringDuration = null;
|
||||||
|
SerializedProperty pauseDuration = null;
|
||||||
|
SerializedProperty restoreIntensityOnPause = null;
|
||||||
|
SerializedProperty frequency = null;
|
||||||
|
SerializedProperty intensityAmplitude = null;
|
||||||
|
SerializedProperty smoothing = null;
|
||||||
|
|
||||||
|
protected override void DisplayChildProperties()
|
||||||
|
{
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Effects.HeaderTimings))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(frequency, EditorStrings.Effects.FrequencyFlicker);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Effects.HeaderPause))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(performPauses, EditorStrings.Effects.PerformPauses);
|
||||||
|
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((EffectFlicker comp) => { return comp.performPauses == true; }))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(flickeringDuration, EditorStrings.Effects.FlickeringDuration);
|
||||||
|
EditorGUILayout.PropertyField(pauseDuration, EditorStrings.Effects.PauseDuration);
|
||||||
|
EditorGUILayout.PropertyField(restoreIntensityOnPause, EditorStrings.Effects.RestoreIntensityOnPause);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Effects.HeaderVisual))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(intensityAmplitude, EditorStrings.Effects.IntensityAmplitude);
|
||||||
|
EditorGUILayout.PropertyField(smoothing, EditorStrings.Effects.Smoothing);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: acd24c9fc8968d74aa2ffe5a14630857
|
||||||
|
timeCreated: 1617383958
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,29 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(EffectPulse))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_EffectPulse : Editor_EffectAbstractBase<EffectPulse>
|
||||||
|
{
|
||||||
|
SerializedProperty frequency = null;
|
||||||
|
SerializedProperty intensityAmplitude = null;
|
||||||
|
|
||||||
|
protected override void DisplayChildProperties()
|
||||||
|
{
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Effects.HeaderTimings))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(frequency, EditorStrings.Effects.FrequencyPulse);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Effects.HeaderVisual))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(intensityAmplitude, EditorStrings.Effects.IntensityAmplitude);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e5ae0f0491b8ca743b77f3ffbaf703d1
|
||||||
|
timeCreated: 1617647714
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,46 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(TriggerZone))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_TriggerZone : Editor_CommonSD
|
||||||
|
{
|
||||||
|
SerializedProperty setIsTrigger = null;
|
||||||
|
SerializedProperty rangeMultiplier = null;
|
||||||
|
TargetList<VolumetricLightBeamAbstractBase> m_Targets;
|
||||||
|
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
m_Targets = new TargetList<VolumetricLightBeamAbstractBase>(targets);
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
base.OnInspectorGUI();
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(setIsTrigger, EditorStrings.TriggerZone.SetIsTrigger);
|
||||||
|
EditorGUILayout.PropertyField(rangeMultiplier, EditorStrings.TriggerZone.RangeMultiplier);
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.TriggerZone.HeaderInfos))
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(
|
||||||
|
UtilsBeamProps.GetDimensions(m_Targets.m_Targets[0]) == Dimensions.Dim3D ? EditorStrings.TriggerZone.HelpDescription3D : EditorStrings.TriggerZone.HelpDescription2D
|
||||||
|
, MessageType.Info);
|
||||||
|
|
||||||
|
if(m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamAbstractBase beam) => { return UtilsBeamProps.CanChangeDuringPlaytime(beam); }))
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.TriggerZone.HelpTrackChangesDuringPlaytimeEnabled, MessageType.Warning);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
serializedObject.ApplyModifiedProperties();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ded92402e19378c4a90ceb5ed4b418f9
|
||||||
|
timeCreated: 1531119204
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,94 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(VolumetricDustParticles))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_VolumetricDustParticles : Editor_CommonSD
|
||||||
|
{
|
||||||
|
SerializedProperty alpha = null;
|
||||||
|
SerializedProperty size = null;
|
||||||
|
SerializedProperty direction = null;
|
||||||
|
SerializedProperty velocity = null;
|
||||||
|
SerializedProperty density = null;
|
||||||
|
SerializedProperty spawnDistanceRange = null;
|
||||||
|
SerializedProperty cullingEnabled = null;
|
||||||
|
SerializedProperty cullingMaxDistance = null;
|
||||||
|
|
||||||
|
static bool AreParticlesInfosUpdated() { return Application.isPlaying; }
|
||||||
|
public override bool RequiresConstantRepaint() { return AreParticlesInfosUpdated(); }
|
||||||
|
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
base.OnInspectorGUI();
|
||||||
|
|
||||||
|
var particles = target as VolumetricDustParticles;
|
||||||
|
|
||||||
|
if (particles.gameObject.activeSelf && particles.enabled && !particles.particlesAreInstantiated)
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.DustParticles.HelpFailToInstantiate, MessageType.Error);
|
||||||
|
ButtonOpenConfig();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.DustParticles.HeaderRendering))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(alpha, EditorStrings.DustParticles.Alpha);
|
||||||
|
EditorGUILayout.PropertyField(size, EditorStrings.DustParticles.Size);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.DustParticles.HeaderDirectionAndVelocity))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(direction, EditorStrings.DustParticles.Direction);
|
||||||
|
|
||||||
|
if (particles.direction == ParticlesDirection.Random)
|
||||||
|
{
|
||||||
|
var vec = velocity.vector3Value;
|
||||||
|
vec.z = EditorGUILayout.FloatField(EditorStrings.DustParticles.Velocity, vec.z);
|
||||||
|
velocity.vector3Value = vec;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(velocity, EditorStrings.DustParticles.Velocity);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.DustParticles.HeaderCulling))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(cullingEnabled, EditorStrings.DustParticles.CullingEnabled);
|
||||||
|
if (cullingEnabled.boolValue)
|
||||||
|
EditorGUILayout.PropertyField(cullingMaxDistance, EditorStrings.DustParticles.CullingMaxDistance);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.DustParticles.HeaderSpawning))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(density, EditorStrings.DustParticles.Density);
|
||||||
|
EditorGUILayout.PropertyField(spawnDistanceRange, EditorStrings.DustParticles.SpawnDistanceRange);
|
||||||
|
|
||||||
|
{
|
||||||
|
var infos = "Current particles count: ";
|
||||||
|
if (AreParticlesInfosUpdated()) infos += particles.particlesCurrentCount;
|
||||||
|
else infos += "(playtime only)";
|
||||||
|
if (particles.isCulled)
|
||||||
|
infos += string.Format(" (culled by '{0}')", particles.mainCamera.name);
|
||||||
|
infos += string.Format("\nMax particles count: {0}", particles.particlesMaxCount);
|
||||||
|
EditorGUILayout.HelpBox(infos, MessageType.Info);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.DustParticles.HeaderInfos))
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.DustParticles.HelpRecommendation, MessageType.Info);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
serializedObject.ApplyModifiedProperties();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 264a06b7c9bbc6940bd66056f4a38291
|
||||||
|
timeCreated: 1510686811
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,341 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public abstract class Editor_VolumetricLightBeamAbstractBase : Editor_Common
|
||||||
|
{
|
||||||
|
TargetList<VolumetricLightBeamAbstractBase> m_Targets;
|
||||||
|
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
m_Targets = new TargetList<VolumetricLightBeamAbstractBase>(targets);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected string GetBatchingReport()
|
||||||
|
{
|
||||||
|
if (m_Targets.Count > 1)
|
||||||
|
{
|
||||||
|
string reasons = "";
|
||||||
|
for (int i = 1; i < m_Targets.Count; ++i)
|
||||||
|
{
|
||||||
|
if (!BatchingHelper.CanBeBatched(m_Targets[0], m_Targets[i], ref reasons))
|
||||||
|
{
|
||||||
|
return "Selected beams can't be batched together:\n" + reasons;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected void AddComponentToTargets<T>() where T : MonoBehaviour
|
||||||
|
{
|
||||||
|
foreach (var target in m_Targets) EditorExtensions.AddComponentFromEditor<T>(target);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void DrawEditInSceneButton()
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
bool editInScene = EditorPrefs.GetBool(EditorStrings.Beam.PrefEditInScene, false);
|
||||||
|
editInScene = GUILayout.Toggle(editInScene, EditorStrings.Beam.ButtonEditInScene, EditorStyles.miniButton);
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
EditorPrefs.SetBool(EditorStrings.Beam.PrefEditInScene, editInScene);
|
||||||
|
SceneView.RepaintAll();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
protected bool DrawFallOffSliderHandle(Transform beamTransf, Vector3 beamGlobalForward, Vector3 beamScale, float lineStartOffset, float lineAlpha, Handles.CapFunction capFunction, string recordName, System.Func<float> getValue, System.Action<float> setValue)
|
||||||
|
{
|
||||||
|
Debug.Assert(beamTransf != null);
|
||||||
|
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
var sliderPos = beamTransf.position + getValue() * beamScale.z * beamGlobalForward;
|
||||||
|
sliderPos = Handles.Slider(sliderPos, beamGlobalForward, HandleUtility.GetHandleSize(sliderPos) * 0.1f, capFunction, 0.5f);
|
||||||
|
|
||||||
|
Handles.Label(sliderPos, string.Format("{0} {1:0.0}", recordName, getValue()), labelStyle);
|
||||||
|
|
||||||
|
var savedCol = Handles.color;
|
||||||
|
{
|
||||||
|
var col = savedCol;
|
||||||
|
col.a = lineAlpha;
|
||||||
|
Handles.color = col;
|
||||||
|
Handles.DrawLine(beamTransf.position + beamGlobalForward * lineStartOffset, sliderPos);
|
||||||
|
Handles.color = savedCol;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
Undo.RecordObject(target, string.Format("Edit Beam '{0}'", recordName));
|
||||||
|
|
||||||
|
var sliderVec = (sliderPos - beamTransf.position);
|
||||||
|
var sliderLength = 0.0f;
|
||||||
|
if (Vector3.Dot(sliderVec, beamGlobalForward) > 0.0f)
|
||||||
|
sliderLength = sliderVec.magnitude;
|
||||||
|
|
||||||
|
sliderLength /= beamScale.z;
|
||||||
|
setValue(sliderLength);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected GUIStyle labelStyle
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
var style = new GUIStyle(GUI.skin.GetStyle("Label"));
|
||||||
|
style.normal.textColor = Handles.color;
|
||||||
|
style.alignment = TextAnchor.LowerCenter;
|
||||||
|
style.fixedWidth = 200.0f;
|
||||||
|
return style;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool DrawRadiusHandle(Transform beamTransf, Vector3 beamGlobalForward, Vector3 beamScale, Vector3 pos, string recordName, System.Func<float> getValue, System.Action<float> setValue)
|
||||||
|
{
|
||||||
|
Debug.Assert(beamTransf != null);
|
||||||
|
|
||||||
|
var rot = Quaternion.LookRotation(beamTransf.up, beamGlobalForward);
|
||||||
|
|
||||||
|
UnityEditor.IMGUI.Controls.ArcHandle hdl = null;
|
||||||
|
|
||||||
|
float maxScaleXY = Mathf.Max(beamScale.x, beamScale.y);
|
||||||
|
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
using (new Handles.DrawingScope(Matrix4x4.TRS(pos, rot * Quaternion.Euler(0.0f, 45.0f, 0.0f), Vector3.one)))
|
||||||
|
{
|
||||||
|
hdl = EditorExtensions.DrawHandleRadius(getValue() * maxScaleXY);
|
||||||
|
}
|
||||||
|
|
||||||
|
using (new Handles.DrawingScope(Matrix4x4.TRS(pos, rot, Vector3.one)))
|
||||||
|
{
|
||||||
|
Handles.Label(getValue() * maxScaleXY * Vector3.forward, string.Format("{0} {1:0.00}", recordName, getValue()), labelStyle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
Undo.RecordObject(target, string.Format("Edit Beam '{0}'", recordName));
|
||||||
|
setValue(hdl.radius / maxScaleXY);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool DrawSpotAngleHandle(Transform beamTransf, Vector3 beamGlobalForward, Vector3 pos, float handleRadius, string recordName, System.Func<float> getValue, System.Action<float> setValue)
|
||||||
|
{
|
||||||
|
Debug.Assert(beamTransf != null);
|
||||||
|
|
||||||
|
var left = Vector3.Cross(beamGlobalForward, beamTransf.up); // show angle handle properly with 2d beams
|
||||||
|
var rot = Quaternion.LookRotation(beamGlobalForward, left);
|
||||||
|
|
||||||
|
UnityEditor.IMGUI.Controls.ArcHandle hdl = null;
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
using (new Handles.DrawingScope(Matrix4x4.TRS(pos, rot * Quaternion.Euler(0.0f, -getValue() / 2, 0.0f), Vector3.one)))
|
||||||
|
{
|
||||||
|
hdl = EditorExtensions.DrawHandleSpotAngle(getValue(), handleRadius);
|
||||||
|
}
|
||||||
|
|
||||||
|
using (new Handles.DrawingScope(Matrix4x4.TRS(pos, rot, Vector3.one)))
|
||||||
|
{
|
||||||
|
Handles.Label(Vector3.forward * handleRadius, string.Format("{0} {1:0.0}", recordName, getValue()), labelStyle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
Undo.RecordObject(target, string.Format("Edit Beam '{0}'", recordName));
|
||||||
|
setValue(hdl.angle);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static Vector3 GetBeamGlobalForward(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.beamGlobalForward;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) return hd.beamGlobalForward;
|
||||||
|
return Vector3.forward;
|
||||||
|
}
|
||||||
|
|
||||||
|
static Vector3 GetBeamLossyScaleIfScalable(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam.IsScalable())
|
||||||
|
return beam.GetLossyScale();
|
||||||
|
return Vector3.one;
|
||||||
|
}
|
||||||
|
|
||||||
|
static float GetBeamConeRadiusStart(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.coneRadiusStart;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) return hd.coneRadiusStart;
|
||||||
|
return 0.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void SetBeamConeRadiusStart(VolumetricLightBeamAbstractBase beam, float radius)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) sd.coneRadiusStart = radius;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) hd.coneRadiusStart = radius;
|
||||||
|
}
|
||||||
|
|
||||||
|
static float GetBeamConeRadiusEnd(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.coneRadiusEnd;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) return hd.coneRadiusEnd;
|
||||||
|
return 1.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void SetBeamConeRadiusEnd(VolumetricLightBeamAbstractBase beam, float radius)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) sd.coneRadiusEnd = radius;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) hd.coneRadiusEnd = radius;
|
||||||
|
}
|
||||||
|
|
||||||
|
static float GetBeamSpotAngle(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.spotAngle;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) return hd.spotAngle;
|
||||||
|
return 1.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void SetBeamSpotAngle(VolumetricLightBeamAbstractBase beam, float radius)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) sd.spotAngle = radius;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) hd.spotAngle = radius;
|
||||||
|
}
|
||||||
|
|
||||||
|
static float GetBeamFallOffEnd(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.fallOffEnd;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) return hd.fallOffEnd;
|
||||||
|
return 1.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void SetBeamFallOffEnd(VolumetricLightBeamAbstractBase beam, float radius)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) sd.fallOffEnd = radius;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) hd.fallOffEnd = radius;
|
||||||
|
}
|
||||||
|
|
||||||
|
static float GetBeamFallOffStart(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.fallOffStart;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) return hd.fallOffStart;
|
||||||
|
return 1.0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool GetBeamHasMeshSkewing(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.hasMeshSkewing;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool GetBeamUseSpotAngleFromLight(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.spotAngleFromLight;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) return hd.useSpotAngleFromAttachedLightSpot;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool GetBeamUseFallOffEndFromLight(VolumetricLightBeamAbstractBase beam)
|
||||||
|
{
|
||||||
|
if (beam is VolumetricLightBeamSD sd) return sd.fallOffEndFromLight;
|
||||||
|
if (beam is VolumetricLightBeamHD hd) return hd.useFallOffEndFromAttachedLightSpot;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected virtual bool DrawEditInSceneHandles()
|
||||||
|
{
|
||||||
|
bool editInScene = EditorPrefs.GetBool(EditorStrings.Beam.PrefEditInScene, false);
|
||||||
|
if (!editInScene)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
var beam = target as VolumetricLightBeamAbstractBase;
|
||||||
|
Debug.Assert(beam != null);
|
||||||
|
|
||||||
|
bool update = false;
|
||||||
|
|
||||||
|
VolumetricLightBeamSD.AttachedLightType lightType;
|
||||||
|
var hasSpotLight = beam.GetLightSpotAttachedSlow(out lightType) != null;
|
||||||
|
|
||||||
|
Handles.color = beam.ComputeColorAtDepth(0.0f).ComputeComplementaryColor(true);
|
||||||
|
{
|
||||||
|
update |= DrawRadiusHandle(beam.transform, GetBeamGlobalForward(beam), GetBeamLossyScaleIfScalable(beam), beam.transform.position, "Source Radius", () => GetBeamConeRadiusStart(beam), (float v) => SetBeamConeRadiusStart(beam, v));
|
||||||
|
|
||||||
|
if (!hasSpotLight || !GetBeamUseSpotAngleFromLight(beam))
|
||||||
|
{
|
||||||
|
update |= DrawSpotAngleHandle(beam.transform, GetBeamGlobalForward(beam), beam.transform.position, GetBeamFallOffEnd(beam) / 2, "Spot Angle", () => GetBeamSpotAngle(beam), (float v) => SetBeamSpotAngle(beam, v));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!GetBeamHasMeshSkewing(beam))
|
||||||
|
{
|
||||||
|
Handles.color = beam.ComputeColorAtDepth(1.0f).ComputeComplementaryColor(true);
|
||||||
|
{
|
||||||
|
if (!hasSpotLight || !GetBeamUseFallOffEndFromLight(beam))
|
||||||
|
{
|
||||||
|
update |= DrawFallOffSliderHandle(beam.transform, GetBeamGlobalForward(beam), GetBeamLossyScaleIfScalable(beam), GetBeamFallOffStart(beam), 0.5f, Handles.CubeHandleCap, "Range Limit", () => GetBeamFallOffEnd(beam), (float v) => SetBeamFallOffEnd(beam, v));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!hasSpotLight || !GetBeamUseSpotAngleFromLight(beam))
|
||||||
|
{
|
||||||
|
var fallOffEndPos = beam.transform.TransformPoint(GetBeamGlobalForward(beam) * GetBeamFallOffEnd(beam));
|
||||||
|
update |= DrawRadiusHandle(beam.transform, GetBeamGlobalForward(beam), GetBeamLossyScaleIfScalable(beam), fallOffEndPos, "End Radius", () => GetBeamConeRadiusEnd(beam), (float v) => SetBeamConeRadiusEnd(beam, v));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return update;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
protected GUIStyle buttonAddComponentStyle { get => GUI.skin.button; }
|
||||||
|
|
||||||
|
protected void DrawButtonAddComponentDust()
|
||||||
|
{
|
||||||
|
bool showButtonDust = m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamAbstractBase beam) => { return beam.GetComponent<VolumetricDustParticles>() == null; });
|
||||||
|
|
||||||
|
if (showButtonDust && GUILayout.Button(EditorData.Instance.contentAddDustParticles, buttonAddComponentStyle))
|
||||||
|
AddComponentToTargets<VolumetricDustParticles>();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void DrawButtonAddComponentTriggerZone()
|
||||||
|
{
|
||||||
|
bool showButtonTriggerZone = m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamAbstractBase beam) => { return beam.GetComponent<TriggerZone>() == null; });
|
||||||
|
|
||||||
|
if (showButtonTriggerZone && GUILayout.Button(EditorData.Instance.contentAddTriggerZone, buttonAddComponentStyle))
|
||||||
|
AddComponentToTargets<TriggerZone>();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void DrawButtonAddComponentEffect()
|
||||||
|
{
|
||||||
|
bool showButtonEffect = m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamAbstractBase beam) => { return beam.GetComponent<EffectAbstractBase>() == null; });
|
||||||
|
|
||||||
|
if (showButtonEffect && GUILayout.Button(EditorData.Instance.contentAddEffect, buttonAddComponentStyle))
|
||||||
|
{
|
||||||
|
var menu = new GenericMenu();
|
||||||
|
menu.AddItem(new GUIContent(EditorStrings.Beam.ButtonAddEffectFlicker), false, AddComponentToTargets<EffectFlicker>);
|
||||||
|
menu.AddItem(new GUIContent(EditorStrings.Beam.ButtonAddEffectPulse), false, AddComponentToTargets<EffectPulse>);
|
||||||
|
menu.ShowAsContext();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void GetInfoTips(List<InfoTip> tips)
|
||||||
|
{
|
||||||
|
var gpuInstancingReport = GetBatchingReport();
|
||||||
|
if (!string.IsNullOrEmpty(gpuInstancingReport))
|
||||||
|
tips.Add(new InfoTip { type = MessageType.Warning, message = gpuInstancingReport });
|
||||||
|
|
||||||
|
base.GetInfoTips(tips);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif // UNITY_EDITOR
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 0a7989b7ed3b0b44985bf22d8b4059fe
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,77 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
#if UNITY_2019_1_OR_NEWER
|
||||||
|
#define UI_USE_FOLDOUT_HEADER_2019
|
||||||
|
#endif
|
||||||
|
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEngine;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public static class FoldableHeader
|
||||||
|
{
|
||||||
|
public static void OnEnable()
|
||||||
|
{
|
||||||
|
ms_CurrentFoldableHeader = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static bool Begin(UnityEngine.Object self, string label)
|
||||||
|
{
|
||||||
|
return Begin(self, new GUIContent(label));
|
||||||
|
}
|
||||||
|
|
||||||
|
public static bool Begin(UnityEngine.Object self, GUIContent label)
|
||||||
|
{
|
||||||
|
var uniqueString = label.text;
|
||||||
|
if(self) uniqueString = self.ToString() + uniqueString;
|
||||||
|
|
||||||
|
if (ms_StyleHeaderFoldable == null)
|
||||||
|
{
|
||||||
|
ms_StyleHeaderFoldable = new GUIStyle(EditorStyles.foldout);
|
||||||
|
ms_StyleHeaderFoldable.fontStyle = FontStyle.Bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
ms_CurrentFoldableHeader = uniqueString;
|
||||||
|
|
||||||
|
bool folded = IsFolded(uniqueString);
|
||||||
|
|
||||||
|
|
||||||
|
#if UI_USE_FOLDOUT_HEADER_2019
|
||||||
|
folded = !EditorGUILayout.BeginFoldoutHeaderGroup(!folded, label);
|
||||||
|
#else
|
||||||
|
folded = !EditorGUILayout.Foldout(!folded, label, toggleOnLabelClick: true, style: ms_StyleHeaderFoldable);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if (folded) ms_FoldedHeaders.Add(uniqueString);
|
||||||
|
else ms_FoldedHeaders.Remove(uniqueString);
|
||||||
|
|
||||||
|
return !folded;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void End()
|
||||||
|
{
|
||||||
|
Debug.Assert(ms_CurrentFoldableHeader != null, "Trying to call FoldableHeader.End() but there is no header opened");
|
||||||
|
bool isFolded = IsFolded(ms_CurrentFoldableHeader);
|
||||||
|
ms_CurrentFoldableHeader = null;
|
||||||
|
|
||||||
|
#if UI_USE_FOLDOUT_HEADER_2019
|
||||||
|
EditorGUILayout.EndFoldoutHeaderGroup();
|
||||||
|
#if UNITY_2019_3_OR_NEWER
|
||||||
|
if(!isFolded) EditorGUILayout.Separator();
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
EditorExtensions.DrawLineSeparator();
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool IsFolded(string uniqueString) { return ms_FoldedHeaders.Contains(uniqueString); }
|
||||||
|
|
||||||
|
static string ms_CurrentFoldableHeader = null;
|
||||||
|
static HashSet<String> ms_FoldedHeaders = new HashSet<String>();
|
||||||
|
static GUIStyle ms_StyleHeaderFoldable = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif // UNITY_EDITOR
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ccdd6181af634264e819236c461b2ac4
|
||||||
|
timeCreated: 1582578385
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 74f66c89e2b413640926a98f67110525
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,14 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public class Editor_CommonHD : Editor_Common
|
||||||
|
{
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
RetrieveSerializedProperties("m_");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif // UNITY_EDITOR
|
||||||
|
|
|
@ -0,0 +1,13 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ac1e2bfb8fc962941a00fa077e3cabf5
|
||||||
|
timeCreated: 1640627913
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,26 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(TrackRealtimeChangesOnLightHD))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_TrackRealtimeChangesOnLightHD : Editor_CommonHD
|
||||||
|
{
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
base.OnInspectorGUI();
|
||||||
|
DrawInfos();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void GetInfoTips(List<InfoTip> tips)
|
||||||
|
{
|
||||||
|
tips.Add(new InfoTip { type = MessageType.Info, message = EditorStrings.Beam.HD.TipTrackRealtimeChangesOnLight });
|
||||||
|
base.GetInfoTips(tips);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
|
@ -0,0 +1,11 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5771d378121df014ea4bf9be7db052b6
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,73 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(VolumetricCookieHD))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_VolumetricCookieHD : Editor_CommonHD
|
||||||
|
{
|
||||||
|
SerializedProperty m_Contribution = null, m_CookieTexture = null, m_Channel = null, m_Negative = null;
|
||||||
|
SerializedProperty m_Translation = null, m_Rotation = null, m_Scale = null;
|
||||||
|
protected TargetList<VolumetricCookieHD> m_Targets;
|
||||||
|
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
m_Targets = new TargetList<VolumetricCookieHD>(targets);
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
base.OnInspectorGUI();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Cookie.HeaderVisual))
|
||||||
|
{
|
||||||
|
EditorGUILayout.Slider(m_Contribution, Consts.Cookie.ContributionMin, Consts.Cookie.ContributionMax, EditorStrings.Cookie.Contribution);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Cookie.HeaderTexture))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_CookieTexture, EditorStrings.Cookie.CookieTexture);
|
||||||
|
EditorGUILayout.PropertyField(m_Channel, EditorStrings.Cookie.Channel);
|
||||||
|
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((VolumetricCookieHD comp) => { return comp.channel != CookieChannel.RGBA; }))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_Negative, EditorStrings.Cookie.Negative);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Cookie.HeaderTransform))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_Translation, EditorStrings.Cookie.Translation);
|
||||||
|
EditorGUILayout.PropertyField(m_Rotation, EditorStrings.Cookie.Rotation);
|
||||||
|
EditorGUILayout.PropertyField(m_Scale, EditorStrings.Cookie.Scale);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
DrawInfos();
|
||||||
|
|
||||||
|
serializedObject.ApplyModifiedProperties();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void GetInfoTips(List<InfoTip> tips)
|
||||||
|
{
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((VolumetricCookieHD comp) => {
|
||||||
|
if (comp.cookieTexture is Texture2D tex2D)
|
||||||
|
return tex2D.mipmapCount > 1;
|
||||||
|
return false;
|
||||||
|
}))
|
||||||
|
tips.Add(new InfoTip { type = MessageType.Warning, message = EditorStrings.Cookie.TipCookieMipMaps });
|
||||||
|
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((VolumetricCookieHD comp) => { return comp.GetComponent<VolumetricLightBeamHD>().jitteringFactor == 0.0f; }))
|
||||||
|
tips.Add(new InfoTip { type = MessageType.Info, message = EditorStrings.Beam.HD.TipJittering });
|
||||||
|
|
||||||
|
base.GetInfoTips(tips);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 9141d4662b9e5734b8d7facedcf6cb6c
|
||||||
|
timeCreated: 1614360514
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,314 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
#pragma warning disable 0429, 0162 // Unreachable expression code detected (because of Noise3D.isSupported on mobile)
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(VolumetricLightBeamHD))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_VolumetricLightBeamHD : Editor_VolumetricLightBeamAbstractBase
|
||||||
|
{
|
||||||
|
SerializedProperty m_ColorFromLight = null, m_ColorMode = null, m_ColorFlat = null, m_ColorGradient = null;
|
||||||
|
SerializedProperty m_Intensity = null, m_IntensityMultiplier = null;
|
||||||
|
SerializedProperty m_BlendingMode = null;
|
||||||
|
SerializedProperty m_SideSoftness = null;
|
||||||
|
SerializedProperty m_SpotAngle = null, m_SpotAngleMultiplier = null;
|
||||||
|
SerializedProperty m_ConeRadiusStart = null;
|
||||||
|
SerializedProperty m_Scalable = null;
|
||||||
|
SerializedProperty m_FallOffStart = null, m_FallOffEnd = null, m_FallOffEndMultiplier = null;
|
||||||
|
SerializedProperty m_AttenuationEquation = null;
|
||||||
|
SerializedProperty m_NoiseMode = null, m_NoiseIntensity = null, m_NoiseScaleUseGlobal = null, m_NoiseScaleLocal = null, m_NoiseVelocityUseGlobal = null, m_NoiseVelocityLocal = null;
|
||||||
|
SerializedProperty m_JitteringFactor = null, m_JitteringFrameRate = null, m_JitteringLerpRange = null, m_RaymarchingQualityID = null;
|
||||||
|
|
||||||
|
TargetList<VolumetricLightBeamHD> m_Targets;
|
||||||
|
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
RetrieveSerializedProperties("m_");
|
||||||
|
m_Targets = new TargetList<VolumetricLightBeamHD>(targets);
|
||||||
|
}
|
||||||
|
|
||||||
|
void DisplayDebugInfo(VolumetricLightBeamHD beam)
|
||||||
|
{
|
||||||
|
Debug.Assert(beam);
|
||||||
|
var geom = beam._EDITOR_GetBeamGeometry();
|
||||||
|
if(!geom)
|
||||||
|
{
|
||||||
|
EditorGUILayout.LabelField("No BeamGeometry");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
#if VLB_DEBUG
|
||||||
|
string matInfo = string.Format("Material: {0} | ID: {1} / {2}"
|
||||||
|
, geom._EDITOR_IsUsingCustomMaterial ? "CUSTOM" : "INSTANCED"
|
||||||
|
, geom._EDITOR_InstancedMaterialID
|
||||||
|
, MaterialManager.StaticPropertiesHD.staticPropertiesCount);
|
||||||
|
EditorGUILayout.LabelField(matInfo);
|
||||||
|
#endif // VLB_DEBUG
|
||||||
|
}
|
||||||
|
|
||||||
|
protected virtual void DrawProperties(bool hasLightSpot)
|
||||||
|
{
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Beam.HeaderBasic))
|
||||||
|
{
|
||||||
|
// Color
|
||||||
|
using (ButtonToggleScope.FromLight(m_ColorFromLight, hasLightSpot))
|
||||||
|
{
|
||||||
|
if (!hasLightSpot) EditorGUILayout.BeginHorizontal(); // mandatory to have the color picker on the same line (when the button "from light" is not here)
|
||||||
|
{
|
||||||
|
if (Config.Instance.featureEnabledColorGradient == FeatureEnabledColorGradient.Off)
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_ColorFlat, EditorStrings.Beam.ColorMode);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
using (new EditorExtensions.LabelWidth(65f))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_ColorMode, EditorStrings.Beam.ColorMode);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_ColorMode.enumValueIndex == (int)ColorMode.Gradient)
|
||||||
|
EditorGUILayout.PropertyField(m_ColorGradient, EditorStrings.Beam.ColorGradient);
|
||||||
|
else
|
||||||
|
EditorGUILayout.PropertyField(m_ColorFlat, EditorStrings.Beam.ColorFlat);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!hasLightSpot) EditorGUILayout.EndHorizontal();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Blending Mode
|
||||||
|
EditorGUILayout.PropertyField(m_BlendingMode, EditorStrings.Beam.BlendingMode);
|
||||||
|
|
||||||
|
// Intensity
|
||||||
|
using (var lightDisabledGrp = ButtonToggleScope.FromLight(m_IntensityMultiplier, hasLightSpot))
|
||||||
|
{
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamHD beam) => { return beam.useIntensityFromAttachedLightSpot; }))
|
||||||
|
{
|
||||||
|
using (new EditorExtensions.ShowMixedValue(m_Intensity))
|
||||||
|
{
|
||||||
|
// display grayed out Unity's light intensity
|
||||||
|
EditorGUILayout.FloatField(EditorStrings.Beam.HD.Intensity, SpotLightHelper.GetIntensity(m_Targets[0].lightSpotAttached));
|
||||||
|
}
|
||||||
|
|
||||||
|
lightDisabledGrp?.EndDisabledGroup(); // muliplier factor should be available
|
||||||
|
DrawMultiplierProperty(m_IntensityMultiplier, EditorStrings.Beam.IntensityMultiplier); // multiplier property
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_Intensity, EditorStrings.Beam.HD.Intensity);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.Slider(m_SideSoftness, Consts.Beam.HD.SideSoftnessMin, Consts.Beam.HD.SideSoftnessMax, EditorStrings.Beam.HD.SideSoftness);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Beam.HeaderShape))
|
||||||
|
{
|
||||||
|
// Fade End
|
||||||
|
using (var lightDisabledGrp = ButtonToggleScope.FromLight(m_FallOffEndMultiplier, hasLightSpot))
|
||||||
|
{
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamHD beam) => { return beam.useFallOffEndFromAttachedLightSpot; }))
|
||||||
|
{
|
||||||
|
using (new EditorExtensions.ShowMixedValue(m_FallOffEnd))
|
||||||
|
{
|
||||||
|
// display grayed out Unity's light range
|
||||||
|
EditorGUILayout.FloatField(EditorStrings.Beam.FallOffEnd, SpotLightHelper.GetFallOffEnd(m_Targets[0].lightSpotAttached));
|
||||||
|
}
|
||||||
|
|
||||||
|
lightDisabledGrp?.EndDisabledGroup(); // muliplier factor should be available
|
||||||
|
DrawMultiplierProperty(m_FallOffEndMultiplier, EditorStrings.Beam.FallOffEndMultiplier); // multiplier property
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_FallOffEnd, EditorStrings.Beam.FallOffEnd);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Spot Angle
|
||||||
|
using (var lightDisabledGrp = ButtonToggleScope.FromLight(m_SpotAngleMultiplier, hasLightSpot))
|
||||||
|
{
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamHD beam) => { return beam.useSpotAngleFromAttachedLightSpot; }))
|
||||||
|
{
|
||||||
|
using (new EditorExtensions.ShowMixedValue(m_SpotAngle))
|
||||||
|
{
|
||||||
|
// display grayed out Unity's light angle
|
||||||
|
EditorGUILayout.FloatField(EditorStrings.Beam.SpotAngle, SpotLightHelper.GetSpotAngle(m_Targets[0].lightSpotAttached));
|
||||||
|
}
|
||||||
|
|
||||||
|
lightDisabledGrp?.EndDisabledGroup(); // muliplier factor should be available
|
||||||
|
DrawMultiplierProperty(m_SpotAngleMultiplier, EditorStrings.Beam.SpotAngleMultiplier); // multiplier property
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
EditorGUILayout.Slider(m_SpotAngle, Consts.Beam.SpotAngleMin, Consts.Beam.SpotAngleMax, EditorStrings.Beam.SpotAngle);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(m_ConeRadiusStart, EditorStrings.Beam.ConeRadiusStart);
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(m_Scalable, EditorStrings.Beam.Scalable);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Beam.HD.HeaderRaymarching))
|
||||||
|
{
|
||||||
|
Editor_Config.DrawRaymarchingQualitiesPopup(Config.Instance, m_RaymarchingQualityID, EditorStrings.Beam.HD.RaymarchingQuality);
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(m_JitteringFactor, EditorStrings.Beam.HD.JitteringFactor);
|
||||||
|
|
||||||
|
if(m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamHD beam) => { return beam.jitteringFactor > 0.0f; }))
|
||||||
|
{
|
||||||
|
EditorGUILayout.IntSlider(m_JitteringFrameRate, Consts.Beam.HD.JitteringFrameRateMin, Consts.Beam.HD.JitteringFrameRateMax, EditorStrings.Beam.HD.JitteringFrameRate);
|
||||||
|
EditorGUILayout.PropertyField(m_JitteringLerpRange, EditorStrings.Beam.HD.JitteringLerpRange);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Beam.HeaderAttenuation))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_AttenuationEquation, EditorStrings.Beam.HD.AttenuationEquation);
|
||||||
|
|
||||||
|
if (m_FallOffEnd.hasMultipleDifferentValues)
|
||||||
|
EditorGUILayout.PropertyField(m_FallOffStart, EditorStrings.Beam.FallOffStart);
|
||||||
|
else
|
||||||
|
m_FallOffStart.FloatSlider(EditorStrings.Beam.FallOffStart, 0f, m_FallOffEnd.floatValue - Consts.Beam.FallOffDistancesMinThreshold);
|
||||||
|
|
||||||
|
EditorGUILayout.Separator();
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (Config.Instance.featureEnabledNoise3D)
|
||||||
|
{
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Beam.Header3DNoise))
|
||||||
|
{
|
||||||
|
m_NoiseMode.CustomEnum<NoiseMode>(EditorStrings.Beam.NoiseMode, EditorStrings.Beam.NoiseModeEnumDescriptions);
|
||||||
|
|
||||||
|
bool showNoiseProps = m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamHD beam) => { return beam.isNoiseEnabled; });
|
||||||
|
if (showNoiseProps)
|
||||||
|
{
|
||||||
|
EditorGUILayout.Slider(m_NoiseIntensity, Consts.Beam.NoiseIntensityMin, Consts.Beam.NoiseIntensityMax, EditorStrings.Beam.NoiseIntensity);
|
||||||
|
|
||||||
|
using (new EditorGUILayout.HorizontalScope())
|
||||||
|
{
|
||||||
|
using (new EditorGUI.DisabledGroupScope(m_NoiseScaleUseGlobal.boolValue))
|
||||||
|
{
|
||||||
|
EditorGUILayout.Slider(m_NoiseScaleLocal, Consts.Beam.NoiseScaleMin, Consts.Beam.NoiseScaleMax, EditorStrings.Beam.NoiseScale);
|
||||||
|
}
|
||||||
|
m_NoiseScaleUseGlobal.ToggleUseGlobalNoise();
|
||||||
|
}
|
||||||
|
|
||||||
|
using (new EditorGUILayout.HorizontalScope())
|
||||||
|
{
|
||||||
|
using (new EditorGUI.DisabledGroupScope(m_NoiseVelocityUseGlobal.boolValue))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_NoiseVelocityLocal, EditorStrings.Beam.NoiseVelocity);
|
||||||
|
}
|
||||||
|
m_NoiseVelocityUseGlobal.ToggleUseGlobalNoise();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (Noise3D.isSupported && !Noise3D.isProperlyLoaded)
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Common.HelpNoiseLoadingFailed, MessageType.Error);
|
||||||
|
|
||||||
|
if (!Noise3D.isSupported)
|
||||||
|
EditorGUILayout.HelpBox(Noise3D.isNotSupportedString, MessageType.Info);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public sealed override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
base.OnInspectorGUI();
|
||||||
|
Debug.Assert(m_Targets.Count > 0);
|
||||||
|
|
||||||
|
// Prevent from drawing inspector when editor props are dirty
|
||||||
|
// in Unity 2022, inspector is drawn BEFORE calling Update & GenerateGeometry which set a valid raymarching ID
|
||||||
|
// and that generates a error message in DrawRaymarchingQualitiesPopup
|
||||||
|
foreach (var target in m_Targets)
|
||||||
|
{
|
||||||
|
if(target.enabled // always display inspector for disabled component: when disabling a Beam, OnValidate is called which set EditorDirtyFlags.Props
|
||||||
|
&& target._EditorIsDirty())
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
DisplayDebugInfo(m_Targets[0]);
|
||||||
|
|
||||||
|
VolumetricLightBeamSD.AttachedLightType lightType;
|
||||||
|
bool hasLightSpot = m_Targets[0].GetLightSpotAttachedSlow(out lightType) != null;
|
||||||
|
if (lightType == VolumetricLightBeamSD.AttachedLightType.OtherLight)
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Beam.HelpNoSpotlight, MessageType.Warning);
|
||||||
|
}
|
||||||
|
|
||||||
|
DrawProperties(hasLightSpot);
|
||||||
|
|
||||||
|
DrawInfos();
|
||||||
|
DrawEditInSceneButton();
|
||||||
|
DrawCustomActionButtons();
|
||||||
|
DrawAdditionalFeatures();
|
||||||
|
|
||||||
|
serializedObject.ApplyModifiedProperties();
|
||||||
|
}
|
||||||
|
|
||||||
|
GUIContent AddEnabledStatusToContentText(GUIContent inContent, SerializedProperty prop)
|
||||||
|
{
|
||||||
|
Debug.Assert(prop.propertyType == SerializedPropertyType.Float);
|
||||||
|
|
||||||
|
var content = new GUIContent(inContent);
|
||||||
|
if (prop.hasMultipleDifferentValues)
|
||||||
|
content.text += " (-)";
|
||||||
|
else
|
||||||
|
content.text += prop.floatValue > 0.0 ? " (on)" : " (off)";
|
||||||
|
return content;
|
||||||
|
}
|
||||||
|
|
||||||
|
void DrawCustomActionButtons()
|
||||||
|
{
|
||||||
|
using (new EditorGUILayout.HorizontalScope())
|
||||||
|
{
|
||||||
|
if (GUILayout.Button(EditorStrings.Beam.ButtonResetProperties, EditorStyles.miniButton))
|
||||||
|
{
|
||||||
|
m_Targets.RecordUndoAction("Reset Light Beam Properties",
|
||||||
|
(VolumetricLightBeamHD beam) => { beam.Reset(); beam.GenerateGeometry(); } );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void DrawAdditionalFeatures()
|
||||||
|
{
|
||||||
|
if (Application.isPlaying) return; // do not support adding additional components at runtime
|
||||||
|
|
||||||
|
using (new EditorGUILayout.HorizontalScope())
|
||||||
|
{
|
||||||
|
DrawButtonAddComponentDust();
|
||||||
|
|
||||||
|
bool showButtonCookie = Config.Instance.featureEnabledCookie && m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamHD beam) => { return beam.GetComponent<VolumetricCookieHD>() == null; });
|
||||||
|
if (showButtonCookie && GUILayout.Button(EditorData.Instance.contentAddCookieHD, buttonAddComponentStyle))
|
||||||
|
AddComponentToTargets<VolumetricCookieHD>();
|
||||||
|
|
||||||
|
bool showButtonShadow = Config.Instance.featureEnabledShadow && m_Targets.HasAtLeastOneTargetWith((VolumetricLightBeamHD beam) => { return beam.GetComponent<VolumetricShadowHD>() == null; });
|
||||||
|
if (showButtonShadow && GUILayout.Button(EditorData.Instance.contentAddShadowHD, buttonAddComponentStyle))
|
||||||
|
AddComponentToTargets<VolumetricShadowHD>();
|
||||||
|
|
||||||
|
DrawButtonAddComponentEffect();
|
||||||
|
DrawButtonAddComponentTriggerZone();
|
||||||
|
|
||||||
|
bool showButtonTrackRealtime = m_Targets.HaveAll((VolumetricLightBeamHD beam) => { return beam.GetComponent<Light>() != null && beam.GetComponent<TrackRealtimeChangesOnLightHD>() == null; });
|
||||||
|
if (showButtonTrackRealtime && GUILayout.Button(EditorData.Instance.contentAddTrackRealtimeChangesOnLightHD, buttonAddComponentStyle))
|
||||||
|
AddComponentToTargets<TrackRealtimeChangesOnLightHD>();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
protected virtual void OnSceneGUI()
|
||||||
|
{
|
||||||
|
DrawEditInSceneHandles();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,11 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 55808f07a0c39974b9c12cfe0421e3e6
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,47 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Linq;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(VolumetricLightBeamHD2D))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_VolumetricLightBeamHD2D : Editor_VolumetricLightBeamHD
|
||||||
|
{
|
||||||
|
SerializedProperty m_SortingLayerID = null, m_SortingOrder = null;
|
||||||
|
string[] m_SortingLayerNames;
|
||||||
|
|
||||||
|
TargetList<VolumetricLightBeamHD2D> m_Targets;
|
||||||
|
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
m_Targets = new TargetList<VolumetricLightBeamHD2D>(targets);
|
||||||
|
m_SortingLayerNames = SortingLayer.layers.Select(l => l.name).ToArray();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void DrawProperties(bool hasLightSpot)
|
||||||
|
{
|
||||||
|
base.DrawProperties(hasLightSpot);
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Beam.Header2D))
|
||||||
|
{
|
||||||
|
DrawSortingLayerAndOrder();
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
}
|
||||||
|
|
||||||
|
void DrawSortingLayerAndOrder()
|
||||||
|
{
|
||||||
|
var updatedProperties = SortingLayerAndOrderDrawer.Draw(m_SortingLayerID, m_SortingOrder);
|
||||||
|
|
||||||
|
if (updatedProperties.HasFlag(SortingLayerAndOrderDrawer.UpdatedProperties.SortingLayerID))
|
||||||
|
m_Targets.RecordUndoAction("Edit Sorting Layer", (VolumetricLightBeamHD2D beam) => beam.sortingLayerID = m_SortingLayerID.intValue); // call setters
|
||||||
|
|
||||||
|
if (updatedProperties.HasFlag(SortingLayerAndOrderDrawer.UpdatedProperties.SortingOrder))
|
||||||
|
m_Targets.RecordUndoAction("Edit Sorting Order", (VolumetricLightBeamHD2D beam) => beam.sortingOrder = m_SortingOrder.intValue); // call setters
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 92675a6e6f8c5444291f530d44f8067d
|
||||||
|
timeCreated: 1504689328
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,104 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
[CustomEditor(typeof(VolumetricShadowHD))]
|
||||||
|
[CanEditMultipleObjects]
|
||||||
|
public class Editor_VolumetricShadowHD : Editor_CommonHD
|
||||||
|
{
|
||||||
|
SerializedProperty m_Strength = null;
|
||||||
|
SerializedProperty m_DepthMapResolution = null, m_LayerMask = null, m_UseOcclusionCulling = null;
|
||||||
|
SerializedProperty m_UpdateRate = null, m_WaitXFrames = null;
|
||||||
|
TargetList<VolumetricShadowHD> m_Targets;
|
||||||
|
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
m_Targets = new TargetList<VolumetricShadowHD>(targets);
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void OnInspectorGUI()
|
||||||
|
{
|
||||||
|
base.OnInspectorGUI();
|
||||||
|
bool shouldUpdateDepthCameraProperties = false;
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Shadow.HeaderVisual))
|
||||||
|
{
|
||||||
|
EditorGUILayout.Slider(m_Strength, Consts.Shadow.StrengthMin, Consts.Shadow.StrengthMax, EditorStrings.Shadow.Strength);
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Shadow.HeaderCamera))
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_LayerMask, EditorStrings.Shadow.LayerMask);
|
||||||
|
|
||||||
|
if (Config.Instance.geometryOverrideLayer == false)
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Shadow.HelpOverrideLayer, MessageType.Warning);
|
||||||
|
}
|
||||||
|
else if (m_Targets.HasAtLeastOneTargetWith((VolumetricShadowHD comp) => { return comp.HasLayerMaskIssues(); }))
|
||||||
|
{
|
||||||
|
EditorGUILayout.HelpBox(EditorStrings.Shadow.HelpLayerMaskIssues, MessageType.Warning);
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(m_UseOcclusionCulling, EditorStrings.Shadow.OcclusionCulling);
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
shouldUpdateDepthCameraProperties = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_DepthMapResolution, EditorStrings.Shadow.DepthMapResolution);
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
if (Application.isPlaying)
|
||||||
|
{
|
||||||
|
Debug.LogErrorFormat(Consts.Shadow.GetErrorChangeRuntimeDepthMapResolution(m_Targets[0]));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
if (FoldableHeader.Begin(this, EditorStrings.Shadow.HeaderUpdateRate))
|
||||||
|
{
|
||||||
|
m_UpdateRate.CustomEnum<ShadowUpdateRate>(EditorStrings.Shadow.UpdateRate, EditorStrings.Shadow.UpdateRateDescriptions);
|
||||||
|
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((VolumetricShadowHD comp) => { return comp.updateRate.HasFlag(ShadowUpdateRate.EveryXFrames); }))
|
||||||
|
{
|
||||||
|
EditorGUILayout.PropertyField(m_WaitXFrames, EditorStrings.Shadow.WaitXFrames);
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.HelpBox(
|
||||||
|
string.Format(EditorStrings.Shadow.GetUpdateRateAdvice<VolumetricShadowHD>(m_Targets[0].updateRate), m_Targets[0].waitXFrames),
|
||||||
|
MessageType.Info);
|
||||||
|
}
|
||||||
|
|
||||||
|
FoldableHeader.End();
|
||||||
|
|
||||||
|
DrawInfos();
|
||||||
|
|
||||||
|
serializedObject.ApplyModifiedProperties();
|
||||||
|
|
||||||
|
if (shouldUpdateDepthCameraProperties)
|
||||||
|
{
|
||||||
|
foreach (var target in m_Targets) target.UpdateDepthCameraProperties();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void GetInfoTips(List<InfoTip> tips)
|
||||||
|
{
|
||||||
|
if (m_Targets.HasAtLeastOneTargetWith((VolumetricShadowHD comp) => { return comp.GetComponent<VolumetricLightBeamHD>().jitteringFactor == 0.0f; }))
|
||||||
|
tips.Add(new InfoTip { type = MessageType.Info, message = EditorStrings.Beam.HD.TipJittering });
|
||||||
|
base.GetInfoTips(tips);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b011c09b423a06e49976d4d71ef5b553
|
||||||
|
timeCreated: 1614360514
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 9dedb0a098aa6d54ca26c9e18517d37c
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 1.5 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: c0b232bfb34a77a4a84fdc476cfedea4
|
||||||
|
timeCreated: 1617797074
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 0
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 2
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 11 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f4140fedf3f72d7448a4e55ea9db44ab
|
||||||
|
timeCreated: 1513615323
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: -1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: 2
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 1.6 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 1a5ba5df396106d4cafd5a96415ffb6c
|
||||||
|
timeCreated: 1617798010
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 0
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 2
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 12 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 6dfec383bc9ad504891027fdab8062b1
|
||||||
|
timeCreated: 1617798010
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: -1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 1
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 1.2 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 350d4bb70b7205342aefcb03e66a7dcb
|
||||||
|
timeCreated: 1617992244
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 0
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 2
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 8.7 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 96c382e4368041b4aad93aed0a833e2b
|
||||||
|
timeCreated: 1617808226
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: -1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 1
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 1.5 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: c7101e7dd11772c44b7977bcc3d30042
|
||||||
|
timeCreated: 1617796383
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 0
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 2
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 10 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 92cd5f0496b5c33418ef9b57bb0a7e7b
|
||||||
|
timeCreated: 1531459068
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: -1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: 2
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 1.5 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 3fcfb96a95b4b82439ae47f4f060137c
|
||||||
|
timeCreated: 1617796383
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 0
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 2
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 11 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 568401c2857b94943af27dc14afca0ae
|
||||||
|
timeCreated: 1531459068
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: -1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: 2
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 1.5 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: dbfd5683708f62f4a88afbd49cb649a4
|
||||||
|
timeCreated: 1617798010
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 0
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 2
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 11 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: cc27b1da0fcf63b40bfa30f6d7317bc1
|
||||||
|
timeCreated: 1617798010
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: -1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 1
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 1.4 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: eae0c95c9c12c4e40a87d028b6e5aaad
|
||||||
|
timeCreated: 1617781625
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 0
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: -1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 2
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 9.9 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 54d50eb83191723439a591eeeb0eab84
|
||||||
|
timeCreated: 1617781142
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: -1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: 2
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 28 KiB |
|
@ -0,0 +1,84 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 837747a8b63291a48838c340da834873
|
||||||
|
timeCreated: 1507401784
|
||||||
|
licenseType: Free
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
serializedVersion: 4
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: -1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
filterMode: 2
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -1
|
||||||
|
wrapMode: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
- buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
spritePackingTag:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 1.5 KiB |
|
@ -0,0 +1,110 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: efed7519f7ad1054aa787834f3c3344d
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 9
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 0
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapsPreserveCoverage: 0
|
||||||
|
alphaTestReferenceValue: 0.5
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
streamingMipmaps: 0
|
||||||
|
streamingMipmapsPriority: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: 1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
filterMode: -1
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -100
|
||||||
|
wrapU: 1
|
||||||
|
wrapV: 1
|
||||||
|
wrapW: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spriteGenerateFallbackPhysicsShape: 1
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 2
|
||||||
|
textureShape: 1
|
||||||
|
singleChannelComponent: 0
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- serializedVersion: 2
|
||||||
|
buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
- serializedVersion: 2
|
||||||
|
buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
- serializedVersion: 2
|
||||||
|
buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
bones: []
|
||||||
|
spriteID:
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
spritePackingTag:
|
||||||
|
pSDRemoveMatte: 0
|
||||||
|
pSDShowRemoveMatteOption: 0
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
After Width: | Height: | Size: 11 KiB |
|
@ -0,0 +1,110 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 88e1a1651b6b6994b8c93fb42aec5383
|
||||||
|
TextureImporter:
|
||||||
|
fileIDToRecycleName: {}
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 9
|
||||||
|
mipmaps:
|
||||||
|
mipMapMode: 0
|
||||||
|
enableMipMap: 1
|
||||||
|
sRGBTexture: 1
|
||||||
|
linearTexture: 0
|
||||||
|
fadeOut: 0
|
||||||
|
borderMipMap: 0
|
||||||
|
mipMapsPreserveCoverage: 0
|
||||||
|
alphaTestReferenceValue: 0.5
|
||||||
|
mipMapFadeDistanceStart: 1
|
||||||
|
mipMapFadeDistanceEnd: 3
|
||||||
|
bumpmap:
|
||||||
|
convertToNormalMap: 0
|
||||||
|
externalNormalMap: 0
|
||||||
|
heightScale: 0.25
|
||||||
|
normalMapFilter: 0
|
||||||
|
isReadable: 0
|
||||||
|
streamingMipmaps: 0
|
||||||
|
streamingMipmapsPriority: 0
|
||||||
|
grayScaleToAlpha: 0
|
||||||
|
generateCubemap: 6
|
||||||
|
cubemapConvolution: 0
|
||||||
|
seamlessCubemap: 0
|
||||||
|
textureFormat: -1
|
||||||
|
maxTextureSize: 2048
|
||||||
|
textureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
filterMode: 2
|
||||||
|
aniso: 1
|
||||||
|
mipBias: -100
|
||||||
|
wrapU: 1
|
||||||
|
wrapV: 1
|
||||||
|
wrapW: 1
|
||||||
|
nPOTScale: 0
|
||||||
|
lightmap: 0
|
||||||
|
compressionQuality: 50
|
||||||
|
spriteMode: 0
|
||||||
|
spriteExtrude: 1
|
||||||
|
spriteMeshType: 1
|
||||||
|
alignment: 0
|
||||||
|
spritePivot: {x: 0.5, y: 0.5}
|
||||||
|
spritePixelsToUnits: 100
|
||||||
|
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
spriteGenerateFallbackPhysicsShape: 1
|
||||||
|
alphaUsage: 1
|
||||||
|
alphaIsTransparency: 1
|
||||||
|
spriteTessellationDetail: -1
|
||||||
|
textureType: 0
|
||||||
|
textureShape: 1
|
||||||
|
singleChannelComponent: 0
|
||||||
|
maxTextureSizeSet: 0
|
||||||
|
compressionQualitySet: 0
|
||||||
|
textureFormatSet: 0
|
||||||
|
platformSettings:
|
||||||
|
- serializedVersion: 2
|
||||||
|
buildTarget: DefaultTexturePlatform
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
- serializedVersion: 2
|
||||||
|
buildTarget: Standalone
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
- serializedVersion: 2
|
||||||
|
buildTarget: Android
|
||||||
|
maxTextureSize: 2048
|
||||||
|
resizeAlgorithm: 0
|
||||||
|
textureFormat: -1
|
||||||
|
textureCompression: 1
|
||||||
|
compressionQuality: 50
|
||||||
|
crunchedCompression: 0
|
||||||
|
allowsAlphaSplitting: 0
|
||||||
|
overridden: 0
|
||||||
|
androidETC2FallbackOverride: 0
|
||||||
|
spriteSheet:
|
||||||
|
serializedVersion: 2
|
||||||
|
sprites: []
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
bones: []
|
||||||
|
spriteID:
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
|
spritePackingTag:
|
||||||
|
pSDRemoveMatte: 0
|
||||||
|
pSDShowRemoveMatteOption: 0
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,15 @@
|
||||||
|
#if UNITY_EDITOR && UNITY_2018_1_OR_NEWER
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEditor.Build;
|
||||||
|
using UnityEditor.Build.Reporting;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
class OnBuildPostprocess : IPostprocessBuildWithReport
|
||||||
|
{
|
||||||
|
public int callbackOrder { get { return 0; } }
|
||||||
|
public void OnPostprocessBuild(BuildReport report)
|
||||||
|
{
|
||||||
|
VLB.PlatformHelper.SetBuildTargetOverride(BuildTarget.NoTarget);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f6591152e52a89a4dba853ddca8c00f6
|
||||||
|
timeCreated: 1612121684
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,16 @@
|
||||||
|
#if UNITY_EDITOR && UNITY_2018_1_OR_NEWER
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEditor.Build;
|
||||||
|
using UnityEditor.Build.Reporting;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
class OnBuildPreprocess : IPreprocessBuildWithReport
|
||||||
|
{
|
||||||
|
public int callbackOrder { get { return 0; } }
|
||||||
|
public void OnPreprocessBuild(BuildReport report)
|
||||||
|
{
|
||||||
|
VLB.PlatformHelper.SetBuildTargetOverride(report.summary.platform);
|
||||||
|
VLB.Config.Instance.SetScriptingDefineSymbolsForCurrentRenderPipeline();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 9b7dc575bd0b12c449148d07bc32fe49
|
||||||
|
timeCreated: 1612121684
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,20 @@
|
||||||
|
#if UNITY_EDITOR && UNITY_2018_1_OR_NEWER
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEditor.Build;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public class ActiveBuildTargetListener : IActiveBuildTargetChanged
|
||||||
|
{
|
||||||
|
public int callbackOrder { get { return 0; } }
|
||||||
|
public void OnActiveBuildTargetChanged(BuildTarget previousTarget, BuildTarget newTarget)
|
||||||
|
{
|
||||||
|
Config.Instance.RefreshShaders(Config.RefreshShaderFlags.All);
|
||||||
|
Config.Instance.SetScriptingDefineSymbolsForCurrentRenderPipeline();
|
||||||
|
GlobalMeshSD.Destroy();
|
||||||
|
Utils._EditorSetAllMeshesDirty();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,12 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f54417ff4a50cfb4ba556d04b6689eab
|
||||||
|
timeCreated: 1612121684
|
||||||
|
licenseType: Free
|
||||||
|
MonoImporter:
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,67 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
class RenderQueueDrawer
|
||||||
|
{
|
||||||
|
bool isPropValueInEnumList
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
foreach (RenderQueue rq in System.Enum.GetValues(typeof(RenderQueue)))
|
||||||
|
{
|
||||||
|
if (rq != RenderQueue.Custom && m_Prop.intValue == (int)rq)
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public RenderQueueDrawer(SerializedProperty sprop)
|
||||||
|
{
|
||||||
|
Debug.Assert(sprop != null);
|
||||||
|
m_Prop = sprop;
|
||||||
|
m_IsRenderQueueCustom = !isPropValueInEnumList;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Draw(GUIContent label)
|
||||||
|
{
|
||||||
|
using (new EditorGUILayout.HorizontalScope())
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
{
|
||||||
|
EditorGUI.BeginChangeCheck();
|
||||||
|
|
||||||
|
if (!m_IsRenderQueueCustom && !isPropValueInEnumList)
|
||||||
|
m_IsRenderQueueCustom = true; // handle proper dropbox change to "custom" when resetting Config to default values
|
||||||
|
|
||||||
|
RenderQueue rq = m_IsRenderQueueCustom ? RenderQueue.Custom : (RenderQueue)m_Prop.intValue;
|
||||||
|
rq = (RenderQueue)EditorGUILayout.EnumPopup(label, rq);
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
m_IsRenderQueueCustom = (rq == RenderQueue.Custom);
|
||||||
|
|
||||||
|
if (!m_IsRenderQueueCustom)
|
||||||
|
m_Prop.intValue = (int)rq;
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUI.BeginDisabledGroup(!m_IsRenderQueueCustom);
|
||||||
|
{
|
||||||
|
m_Prop.intValue = EditorGUILayout.IntField(m_Prop.intValue, GUILayout.MaxWidth(65.0f));
|
||||||
|
}
|
||||||
|
EditorGUI.EndDisabledGroup();
|
||||||
|
}
|
||||||
|
if (EditorGUI.EndChangeCheck())
|
||||||
|
{
|
||||||
|
Utils._EditorSetAllBeamGeomDirty(); // TODO switch sd / hd ?
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
SerializedProperty m_Prop;
|
||||||
|
bool m_IsRenderQueueCustom = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,11 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e021c10e47c09b64e977dbc0de5bff22
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 47da327390025e44eaa9d73a65a256c7
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,26 @@
|
||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 0}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: f87284b87b8be7c4b9708f25ddb6669b, type: 3}
|
||||||
|
m_Name: VLBEditorData
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
buttonAddDustParticles: {fileID: 2800000, guid: eae0c95c9c12c4e40a87d028b6e5aaad,
|
||||||
|
type: 3}
|
||||||
|
buttonAddDynamicOcclusion: {fileID: 2800000, guid: c0b232bfb34a77a4a84fdc476cfedea4,
|
||||||
|
type: 3}
|
||||||
|
buttonAddTriggerZone: {fileID: 2800000, guid: 3fcfb96a95b4b82439ae47f4f060137c,
|
||||||
|
type: 3}
|
||||||
|
buttonAddEffect: {fileID: 2800000, guid: 1a5ba5df396106d4cafd5a96415ffb6c, type: 3}
|
||||||
|
buttonFromSpotLight: {fileID: 2800000, guid: 350d4bb70b7205342aefcb03e66a7dcb, type: 3}
|
||||||
|
buttonAddCookieHD: {fileID: 2800000, guid: dbfd5683708f62f4a88afbd49cb649a4, type: 3}
|
||||||
|
buttonAddShadowHD: {fileID: 2800000, guid: efed7519f7ad1054aa787834f3c3344d, type: 3}
|
||||||
|
buttonAddTrackRealtimeChangesOnLightHD: {fileID: 2800000, guid: c7101e7dd11772c44b7977bcc3d30042,
|
||||||
|
type: 3}
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 8979130d593fc654f8d175cfe9729e82
|
||||||
|
timeCreated: 1617863368
|
||||||
|
licenseType: Free
|
||||||
|
NativeFormatImporter:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 45a369b8973058c40817b12ec35060c9
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -0,0 +1,14 @@
|
||||||
|
#if UNITY_EDITOR
|
||||||
|
namespace VLB
|
||||||
|
{
|
||||||
|
public class Editor_CommonSD : Editor_Common
|
||||||
|
{
|
||||||
|
protected override void OnEnable()
|
||||||
|
{
|
||||||
|
base.OnEnable();
|
||||||
|
RetrieveSerializedProperties("_");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif // UNITY_EDITOR
|
||||||
|
|