|
|
|
|
|
|
internal SerializedProperty legacyBlendDistance; |
|
|
|
internal SerializedProperty boxSize; |
|
|
|
internal SerializedProperty boxOffset; |
|
|
|
internal SerializedProperty legacyMode; |
|
|
|
|
|
|
|
internal new HDAdditionalReflectionData target { get { return serializedObject.targetObject as HDAdditionalReflectionData; } } |
|
|
|
internal ReflectionProbe targetLegacy { get { return serializedLegacyObject.targetObject as ReflectionProbe; } } |
|
|
|
|
|
|
nearClip = legacyProbe.FindProperty("m_NearClip"); |
|
|
|
farClip = legacyProbe.FindProperty("m_FarClip"); |
|
|
|
legacyBlendDistance = legacyProbe.FindProperty("m_BlendDistance"); |
|
|
|
legacyMode = legacyProbe.FindProperty("m_Mode"); |
|
|
|
} |
|
|
|
|
|
|
|
internal override void Update() |
|
|
|
|
|
|
|
|
|
|
internal override void Apply() |
|
|
|
{ |
|
|
|
//sync size
|
|
|
|
switch(target.influenceVolume.shape) |
|
|
|
{ |
|
|
|
case InfluenceShape.Box: |
|
|
|
|
|
|
boxSize.vector3Value = Vector3.one * influenceVolume.sphereRadius.floatValue; |
|
|
|
break; |
|
|
|
} |
|
|
|
// Sync mode
|
|
|
|
legacyMode.intValue = mode.intValue; |
|
|
|
serializedLegacyObject.ApplyModifiedProperties(); |
|
|
|
serializedObject.ApplyModifiedProperties(); |
|
|
|
} |