Skip to content
Snippets Groups Projects
Commit 2b97bac2 authored by John Schihada's avatar John Schihada
Browse files

Fixed TMP-Shader-issue AND Fixed Bug: Stopping Previews in ShinyThings on ToolModeChange

parent 7009201e
No related branches found
No related tags found
No related merge requests found
......@@ -157,6 +157,8 @@ public void OnToolModeChanged(ToolMode ActiveToolMode)
*/
break;
}
//Stop PreviewEvents in ShineThings on ToolModeChange
CommunicationEvents.StopPreviewsEvent.Invoke(null);
}
......
......@@ -63,6 +63,8 @@ public class ShinyEvent : UnityEvent<Fact> {
public static ShinyEvent StopLineDrawingEvent = new ShinyEvent();
public static ShinyEvent StartCurveDrawingEvent = new ShinyEvent();
public static ShinyEvent StopCurveDrawingEvent = new ShinyEvent();
//Event for stopping all previews -> Made When ToolMode is changed
public static ShinyEvent StopPreviewsEvent = new ShinyEvent();
......
......@@ -36,6 +36,7 @@ public void Start()
CommunicationEvents.StopLineDrawingEvent.AddListener(DeactivateLineDrawing);
CommunicationEvents.StartCurveDrawingEvent.AddListener(ActivateCurveDrawing);
CommunicationEvents.StopCurveDrawingEvent.AddListener(DeactivateCurveDrawing);
CommunicationEvents.StopPreviewsEvent.AddListener(StopPreviews);
}
// Update is called once per frame
......@@ -282,4 +283,11 @@ public void DeactivateCurveDrawing(Fact startFact)
this.linePositions = new List<Vector3>();
this.curveDrawingActivated = false;
}
public void StopPreviews(Fact startFact) {
if (lineDrawingActivated)
DeactivateLineDrawing(null);
if (curveDrawingActivated)
DeactivateCurveDrawing(null);
}
}
This diff is collapsed.
fileFormatVersion: 2
guid: 9e28c8e45ccafa24ab417dfac5293524
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 0
userData:
assetBundleName:
assetBundleVariant:
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: LiberationSans SDF
m_Shader: {fileID: 4800000, guid: e34db9d3f28517949bddb60fd4c0dbb9, type: 3}
m_ShaderKeywords:
m_LightmapFlags: 1
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _MainTex:
m_Texture: {fileID: 28684132378477856, guid: 8f586378b4e144a9851e7b34d9b748ee,
type: 2}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
- _ColorMask: 15
- _FaceDilate: 0
- _GradientScale: 10
- _MaskSoftnessX: 0
- _MaskSoftnessY: 0
- _OutlineSoftness: 0
- _OutlineWidth: 0
- _PerspectiveFilter: 0.875
- _ScaleRatioA: 0.9
- _ScaleRatioB: 1
- _ScaleRatioC: 0.73125
- _ScaleX: 1
- _ScaleY: 1
- _ShaderFlags: 0
- _Sharpness: 0
- _Stencil: 0
- _StencilComp: 8
- _StencilOp: 0
- _StencilReadMask: 255
- _StencilWriteMask: 255
- _TextureHeight: 1024
- _TextureWidth: 1024
- _UnderlayDilate: 0
- _UnderlayOffsetX: 0
- _UnderlayOffsetY: 0
- _UnderlaySoftness: 0
- _VertexOffsetX: 0
- _VertexOffsetY: 0
- _WeightBold: 0.75
- _WeightNormal: 0
m_Colors:
- _ClipRect: {r: -32767, g: -32767, b: 32767, a: 32767}
- _FaceColor: {r: 1, g: 1, b: 1, a: 1}
- _OutlineColor: {r: 0, g: 0, b: 0, a: 1}
- _UnderlayColor: {r: 0, g: 0, b: 0, a: 0.5}
fileFormatVersion: 2
guid: f6bea2473bdeaa2488a1fe2390bfbd88
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:
......@@ -319,7 +319,7 @@ GameObject:
m_Component:
- component: {fileID: 4650993679089994826}
m_Layer: 12
m_Name: Angle_Text_Front_Back
m_Name: Angle
m_TagString: Selectable
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
......@@ -475,7 +475,7 @@ MeshRenderer:
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
- {fileID: 2100000, guid: f6bea2473bdeaa2488a1fe2390bfbd88, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
......@@ -532,7 +532,7 @@ MonoBehaviour:
m_text: Test
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2100000, guid: f8a5ed9d842ae7948a988efa7b496b0b, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment