Skip to content

Commit

Permalink
503 display breakers (#504)
Browse files Browse the repository at this point in the history
* Create breakers in front top left corner of racks

* fix Breakers creation

* Add button in right click menu to toggle breakers

* Auto breakers in config.toml & settings panel

* Add fr, pt & es translations

* Breaker takes color of related tag & respond to tag highlight (behaves like a children of the rack)

* Change breaker default color & prevent layers to catch breaker type

* Update build date & Version to 3.7.0
  • Loading branch information
Cedrok authored Aug 2, 2024
1 parent 207ecf9 commit 9a6585f
Show file tree
Hide file tree
Showing 18 changed files with 2,388 additions and 181 deletions.
8 changes: 8 additions & 0 deletions Assets/Localization/Texts Shared Data.asset
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,14 @@ MonoBehaviour:
m_Key: Save Object Position
m_Metadata:
m_Items: []
- m_Id: 52524171569664000
m_Key: Toggle breakers
m_Metadata:
m_Items: []
- m_Id: 52574482053206016
m_Key: Automatically enable Breakers
m_Metadata:
m_Items: []
m_Metadata:
m_Items: []
m_KeyGenerator:
Expand Down
8 changes: 8 additions & 0 deletions Assets/Localization/Texts_en.asset
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,14 @@ MonoBehaviour:
m_Localized: Save object position ?
m_Metadata:
m_Items: []
- m_Id: 52524171569664000
m_Localized: Breakers
m_Metadata:
m_Items: []
- m_Id: 52574482053206016
m_Localized: Automatically enable breakers
m_Metadata:
m_Items: []
references:
version: 2
RefIds:
Expand Down
8 changes: 8 additions & 0 deletions Assets/Localization/Texts_es.asset
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,14 @@ MonoBehaviour:
m_Localized: "Guardar la posici\xF3n del objeto?"
m_Metadata:
m_Items: []
- m_Id: 52524171569664000
m_Localized: Disyuntores
m_Metadata:
m_Items: []
- m_Id: 52574482053206016
m_Localized: "Activaci\xF3n autom\xE1tica de disyuntores"
m_Metadata:
m_Items: []
references:
version: 2
RefIds:
Expand Down
8 changes: 8 additions & 0 deletions Assets/Localization/Texts_fr.asset
Original file line number Diff line number Diff line change
Expand Up @@ -318,6 +318,14 @@ MonoBehaviour:
m_Localized: Sauvegarder la position de l'objet ?
m_Metadata:
m_Items: []
- m_Id: 52574482053206016
m_Localized: Activation automatique des disjoncteurs
m_Metadata:
m_Items: []
- m_Id: 52524171569664000
m_Localized: Disjoncteurs
m_Metadata:
m_Items: []
references:
version: 2
RefIds:
Expand Down
8 changes: 8 additions & 0 deletions Assets/Localization/Texts_pt.asset
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,14 @@ MonoBehaviour:
m_Localized: "Salvar a posi\xE7\xE3o do objeto?\r"
m_Metadata:
m_Items: []
- m_Id: 52524171569664000
m_Localized: Disjuntores
m_Metadata:
m_Items: []
- m_Id: 52574482053206016
m_Localized: "Ativa\xE7\xE3o autom\xE1tica de disjuntores"
m_Metadata:
m_Items: []
references:
version: 2
RefIds:
Expand Down
295 changes: 295 additions & 0 deletions Assets/Prefabs/Breaker.prefab
Original file line number Diff line number Diff line change
@@ -0,0 +1,295 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &4254767957273672101
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 4176928236324298618}
- component: {fileID: 2756453064248392137}
- component: {fileID: 2633159542549976067}
- component: {fileID: 280631025753518186}
m_Layer: 0
m_Name: Cube
m_TagString: Selectable
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &4176928236324298618
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4254767957273672101}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 0.08, y: 0.026, z: 0.018}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 8422964209624112029}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!33 &2756453064248392137
MeshFilter:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4254767957273672101}
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
--- !u!23 &2633159542549976067
MeshRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4254767957273672101}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_DynamicOccludee: 1
m_StaticShadowCaster: 0
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_RayTracingMode: 2
m_RayTraceProcedural: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 0142c1713e441b04ca9b28bdda0528b1, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_ReceiveGI: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_StitchLightmapSeams: 1
m_SelectedEditorRenderState: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_AdditionalVertexStreams: {fileID: 0}
--- !u!65 &280631025753518186
BoxCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4254767957273672101}
m_Material: {fileID: 0}
m_IncludeLayers:
serializedVersion: 2
m_Bits: 0
m_ExcludeLayers:
serializedVersion: 2
m_Bits: 0
m_LayerOverridePriority: 0
m_IsTrigger: 0
m_ProvidesContacts: 0
m_Enabled: 1
serializedVersion: 3
m_Size: {x: 1, y: 1, z: 1}
m_Center: {x: 0, y: 0, z: 0}
--- !u!1 &6010235731161253863
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 8422964209624112029}
- component: {fileID: 226685182499933010}
- component: {fileID: 530606338633814678}
- component: {fileID: 7641173002511634591}
- component: {fileID: 8887383438007595577}
- component: {fileID: 4357075341803950509}
m_Layer: 0
m_Name: Breaker
m_TagString: Selectable
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &8422964209624112029
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6010235731161253863}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 4176928236324298618}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &226685182499933010
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6010235731161253863}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4b42dd2f19759194496c13696d98ac2a, type: 3}
m_Name:
m_EditorClassIdentifier:
labelFront: {fileID: 0}
labelRear: {fileID: 0}
labelTop: {fileID: 0}
labelBottom: {fileID: 0}
labelLeft: {fileID: 0}
labelRight: {fileID: 0}
floatingLabel: {fileID: 0}
hasFloatingLabel: 0
usedLabels: []
attrToDisplay:
--- !u!205 &530606338633814678
LODGroup:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6010235731161253863}
serializedVersion: 2
m_LocalReferencePoint: {x: 0, y: 0, z: 0}
m_Size: 1
m_FadeMode: 0
m_AnimateCrossFading: 0
m_LastLODIsBillboard: 0
m_LODs:
- screenRelativeHeight: 0.10489535
fadeTransitionWidth: 0
renderers:
- renderer: {fileID: 0}
- renderer: {fileID: 0}
- renderer: {fileID: 0}
- renderer: {fileID: 0}
- renderer: {fileID: 0}
- renderer: {fileID: 0}
m_Enabled: 1
--- !u!54 &7641173002511634591
Rigidbody:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6010235731161253863}
serializedVersion: 4
m_Mass: 1
m_Drag: 0
m_AngularDrag: 0.05
m_CenterOfMass: {x: 0, y: 0, z: 0}
m_InertiaTensor: {x: 1, y: 1, z: 1}
m_InertiaRotation: {x: 0, y: 0, z: 0, w: 1}
m_IncludeLayers:
serializedVersion: 2
m_Bits: 0
m_ExcludeLayers:
serializedVersion: 2
m_Bits: 0
m_ImplicitCom: 1
m_ImplicitTensor: 1
m_UseGravity: 0
m_IsKinematic: 1
m_Interpolate: 0
m_Constraints: 0
m_CollisionDetection: 0
--- !u!114 &8887383438007595577
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6010235731161253863}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 33607cab658c03648afda9bfe3118223, type: 3}
m_Name:
m_EditorClassIdentifier:
name:
id:
parentId:
category: Breaker
description:
domain:
tags: []
currentLod: 0
originalLocalPosition: {x: -Infinity, y: -Infinity, z: -Infinity}
originalLocalRotation: {x: 0, y: 0, z: 0, w: 1}
originalLocalScale: {x: 1, y: 1, z: 1}
heatMap: {fileID: 0}
scatterPlot: 0
localCS: {fileID: 0}
isDoomed: 0
isLodLocked: 0
color: {r: 1, g: 1, b: 1, a: 1}
referent: {fileID: 0}
tempBar: {fileID: 0}
temperatureUnit:
hasSlotColor: 0
group: {fileID: 0}
clearanceHandler:
front:
length: 0
direction: {x: 0, y: 0, z: 0}
rear:
length: 0
direction: {x: 0, y: 0, z: 0}
left:
length: 0
direction: {x: 0, y: 0, z: 0}
right:
length: 0
direction: {x: 0, y: 0, z: 0}
top:
length: 0
direction: {x: 0, y: 0, z: 0}
bottom:
length: 0
direction: {x: 0, y: 0, z: 0}
clearedObject: {fileID: 0}
isToggled: 0
isInitialized: 0
clearanceWrapper: {fileID: 0}
clearances: []
isComponent: 1
primarySlot: {fileID: 0}
takenSlots: []
--- !u!114 &4357075341803950509
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 6010235731161253863}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 11599482bb3741f4b890d546eeba923f, type: 3}
m_Name:
m_EditorClassIdentifier:
isTemplate: 0
scatterPlotOfOneParent: 0
isHidden: 0
isHiddenInGroup: 0
isHighlighted: 0
7 changes: 7 additions & 0 deletions Assets/Prefabs/Breaker.prefab.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 9a6585f

Please sign in to comment.