mirror of
https://gitgud.io/AbstractConcept/rimworld-animation-studio.git
synced 2024-08-15 00:43:27 +00:00
Improvements to timeline
This commit is contained in:
parent
d2ca61c61c
commit
591b176924
99 changed files with 460 additions and 359 deletions
|
@ -71,7 +71,7 @@ RectTransform:
|
|||
m_AnchorMin: {x: 0, y: 0.5}
|
||||
m_AnchorMax: {x: 1, y: 0.5}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 20}
|
||||
m_SizeDelta: {x: -16, y: 20}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &3581489635090573721
|
||||
MonoBehaviour:
|
||||
|
|
|
@ -107,7 +107,7 @@ RectTransform:
|
|||
m_AnchorMin: {x: 0, y: 0.5}
|
||||
m_AnchorMax: {x: 1, y: 0.5}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: -10, y: 20}
|
||||
m_SizeDelta: {x: -16, y: 20}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &7758949423219383195
|
||||
MonoBehaviour:
|
||||
|
@ -163,7 +163,7 @@ MonoBehaviour:
|
|||
ghostSliders: {fileID: 2175275438354546744}
|
||||
ghostSliderPrefab: {fileID: 3581489635090573721, guid: 890d76c226858de4fa96adfe7cc85383,
|
||||
type: 3}
|
||||
maxGhosts: 0
|
||||
maxGhosts: 4
|
||||
actorID: 0
|
||||
keyframeID: 0
|
||||
--- !u!1 &8359461402257861397
|
||||
|
@ -177,6 +177,8 @@ GameObject:
|
|||
- component: {fileID: 5757681650493455882}
|
||||
- component: {fileID: 4736752906210224906}
|
||||
- component: {fileID: 1135382459109805448}
|
||||
- component: {fileID: 6141625215454872087}
|
||||
- component: {fileID: 1036971081672004212}
|
||||
m_Layer: 5
|
||||
m_Name: Handle
|
||||
m_TagString: Untagged
|
||||
|
@ -240,3 +242,41 @@ MonoBehaviour:
|
|||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!223 &6141625215454872087
|
||||
Canvas:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8359461402257861397}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 3
|
||||
m_RenderMode: 2
|
||||
m_Camera: {fileID: 0}
|
||||
m_PlaneDistance: 100
|
||||
m_PixelPerfect: 0
|
||||
m_ReceivesEvents: 1
|
||||
m_OverrideSorting: 1
|
||||
m_OverridePixelPerfect: 0
|
||||
m_SortingBucketNormalizedSize: 0
|
||||
m_AdditionalShaderChannelsFlag: 0
|
||||
m_SortingLayerID: 0
|
||||
m_SortingOrder: 20
|
||||
m_TargetDisplay: 0
|
||||
--- !u!114 &1036971081672004212
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8359461402257861397}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_IgnoreReversedGraphics: 1
|
||||
m_BlockingObjects: 0
|
||||
m_BlockingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
|
|
|
@ -322,7 +322,7 @@ RectTransform:
|
|||
- {fileID: 1302075273}
|
||||
- {fileID: 1849536740}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 23
|
||||
m_RootOrder: 22
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
@ -1066,6 +1066,81 @@ CanvasRenderer:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 134868802}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!1 &138865803
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 138865804}
|
||||
- component: {fileID: 138865806}
|
||||
- component: {fileID: 138865805}
|
||||
m_Layer: 5
|
||||
m_Name: Background
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &138865804
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 138865803}
|
||||
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_Children:
|
||||
- {fileID: 1289465654}
|
||||
m_Father: {fileID: 219230438}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 1200, y: 15}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &138865805
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 138865803}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 0.75, g: 0.75, b: 0.75, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 10911, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_Type: 1
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &138865806
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 138865803}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!1 &143158138
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -1301,7 +1376,7 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 44343587}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 16
|
||||
m_RootOrder: 15
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -1429,8 +1504,9 @@ RectTransform:
|
|||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 591894605}
|
||||
- {fileID: 138865804}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 18
|
||||
m_RootOrder: 17
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0}
|
||||
m_AnchorMax: {x: 0.5, y: 0}
|
||||
|
@ -1664,7 +1740,7 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 1397551272}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 12
|
||||
m_RootOrder: 11
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -2537,7 +2613,7 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 239634964}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 9
|
||||
m_RootOrder: 8
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 1, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 0}
|
||||
|
@ -3117,7 +3193,7 @@ RectTransform:
|
|||
- {fileID: 2041360447}
|
||||
- {fileID: 1377952650}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 7
|
||||
m_RootOrder: 6
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 1, y: 1}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
@ -3255,7 +3331,7 @@ RectTransform:
|
|||
- {fileID: 749354207}
|
||||
- {fileID: 1153227823}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 20
|
||||
m_RootOrder: 19
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -3818,7 +3894,7 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 1514381832}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 11
|
||||
m_RootOrder: 9
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -4030,7 +4106,7 @@ RectTransform:
|
|||
- {fileID: 567758162}
|
||||
- {fileID: 1676585154}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 5
|
||||
m_RootOrder: 4
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0}
|
||||
m_AnchorMax: {x: 0.5, y: 0}
|
||||
|
@ -4749,13 +4825,15 @@ GameObject:
|
|||
- component: {fileID: 591894608}
|
||||
- component: {fileID: 591894607}
|
||||
- component: {fileID: 591894606}
|
||||
- component: {fileID: 591894609}
|
||||
- component: {fileID: 591894610}
|
||||
m_Layer: 5
|
||||
m_Name: Image
|
||||
m_Name: Chaser
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &591894605
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -4772,8 +4850,8 @@ RectTransform:
|
|||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 2, y: 0}
|
||||
m_AnchoredPosition: {x: 8, y: -2.5}
|
||||
m_SizeDelta: {x: 4, y: -15}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &591894606
|
||||
MonoBehaviour:
|
||||
|
@ -4808,7 +4886,7 @@ MonoBehaviour:
|
|||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 0, b: 0, a: 1}
|
||||
m_Color: {r: 1, g: 0.5, b: 0.5, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
|
@ -4832,6 +4910,42 @@ CanvasRenderer:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 591894604}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!223 &591894609
|
||||
Canvas:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 591894604}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 3
|
||||
m_RenderMode: 2
|
||||
m_Camera: {fileID: 0}
|
||||
m_PlaneDistance: 100
|
||||
m_PixelPerfect: 0
|
||||
m_ReceivesEvents: 1
|
||||
m_OverrideSorting: 1
|
||||
m_OverridePixelPerfect: 0
|
||||
m_SortingBucketNormalizedSize: 0
|
||||
m_AdditionalShaderChannelsFlag: 0
|
||||
m_SortingLayerID: 0
|
||||
m_SortingOrder: 10
|
||||
m_TargetDisplay: 0
|
||||
--- !u!114 &591894610
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 591894604}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 9584d659e560b88409843604ae04229b, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
target: {fileID: 1437263270}
|
||||
chaseAlongX: 1
|
||||
chaseAlongY: 0
|
||||
--- !u!1 &592018739
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -4995,7 +5109,7 @@ RectTransform:
|
|||
- {fileID: 1960844026}
|
||||
- {fileID: 1463915053}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 17
|
||||
m_RootOrder: 16
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -5117,7 +5231,7 @@ RectTransform:
|
|||
- {fileID: 783530509}
|
||||
- {fileID: 725162531}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 19
|
||||
m_RootOrder: 18
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -5520,7 +5634,7 @@ RectTransform:
|
|||
- {fileID: 371198550}
|
||||
- {fileID: 77649836}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 25
|
||||
m_RootOrder: 24
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
@ -5731,80 +5845,6 @@ CanvasRenderer:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 698711480}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!1 &723601102
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 723601103}
|
||||
- component: {fileID: 723601105}
|
||||
- component: {fileID: 723601104}
|
||||
m_Layer: 5
|
||||
m_Name: Fill
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &723601103
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 723601102}
|
||||
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_Children: []
|
||||
m_Father: {fileID: 1811965325}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 10, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &723601104
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 723601102}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_Type: 1
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &723601105
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 723601102}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!1 &725162530
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -6028,9 +6068,9 @@ RectTransform:
|
|||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: -17, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0, y: 1}
|
||||
--- !u!114 &749354208
|
||||
MonoBehaviour:
|
||||
|
@ -6467,7 +6507,7 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 415722554}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 8
|
||||
m_RootOrder: 7
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
|
@ -7000,7 +7040,7 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 395375412}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 14
|
||||
m_RootOrder: 13
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -8094,7 +8134,7 @@ RectTransform:
|
|||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 6
|
||||
m_RootOrder: 5
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 1, y: 1}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
@ -8306,7 +8346,7 @@ RectTransform:
|
|||
- {fileID: 347034222}
|
||||
- {fileID: 932977622}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 26
|
||||
m_RootOrder: 25
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
@ -8399,7 +8439,7 @@ RectTransform:
|
|||
- {fileID: 1898380637}
|
||||
- {fileID: 1966925531}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 28
|
||||
m_RootOrder: 27
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
@ -8490,7 +8530,7 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 1321044693}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 15
|
||||
m_RootOrder: 14
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -8588,80 +8628,6 @@ CanvasRenderer:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1136677496}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!1 &1142371456
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1142371457}
|
||||
- component: {fileID: 1142371459}
|
||||
- component: {fileID: 1142371458}
|
||||
m_Layer: 5
|
||||
m_Name: Background
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &1142371457
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1142371456}
|
||||
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_Children: []
|
||||
m_Father: {fileID: 1289465654}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0.25}
|
||||
m_AnchorMax: {x: 1, y: 0.75}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &1142371458
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1142371456}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_Type: 1
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!222 &1142371459
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1142371456}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!1 &1149068017
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -8821,7 +8787,7 @@ MonoBehaviour:
|
|||
m_TargetGraphic: {fileID: 922060210}
|
||||
m_HandleRect: {fileID: 922060209}
|
||||
m_Direction: 2
|
||||
m_Value: 1
|
||||
m_Value: 0
|
||||
m_Size: 1
|
||||
m_NumberOfSteps: 0
|
||||
m_OnValueChanged:
|
||||
|
@ -9577,20 +9543,18 @@ RectTransform:
|
|||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1289465653}
|
||||
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: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 1142371457}
|
||||
- {fileID: 1811965325}
|
||||
- {fileID: 1628817485}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 4
|
||||
m_Father: {fileID: 138865804}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0}
|
||||
m_AnchorMax: {x: 0.5, y: 0}
|
||||
m_AnchoredPosition: {x: 0, y: 88}
|
||||
m_SizeDelta: {x: 1200, y: 20}
|
||||
m_AnchorMin: {x: 0, y: 0.5}
|
||||
m_AnchorMax: {x: 1, y: 0.5}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: -16, y: 20}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!114 &1289465655
|
||||
MonoBehaviour:
|
||||
|
@ -9632,11 +9596,11 @@ MonoBehaviour:
|
|||
m_DisabledTrigger: Disabled
|
||||
m_Interactable: 1
|
||||
m_TargetGraphic: {fileID: 1437263272}
|
||||
m_FillRect: {fileID: 723601103}
|
||||
m_FillRect: {fileID: 0}
|
||||
m_HandleRect: {fileID: 1437263271}
|
||||
m_Direction: 0
|
||||
m_MinValue: 1
|
||||
m_MaxValue: 1
|
||||
m_MaxValue: 100
|
||||
m_WholeNumbers: 1
|
||||
m_Value: 1
|
||||
m_OnValueChanged:
|
||||
|
@ -10036,14 +10000,13 @@ RectTransform:
|
|||
- {fileID: 134868803}
|
||||
- {fileID: 502634721}
|
||||
- {fileID: 585946794}
|
||||
- {fileID: 1289465654}
|
||||
- {fileID: 539052777}
|
||||
- {fileID: 1083597498}
|
||||
- {fileID: 429161117}
|
||||
- {fileID: 842870043}
|
||||
- {fileID: 364433430}
|
||||
- {fileID: 972501617}
|
||||
- {fileID: 527085934}
|
||||
- {fileID: 972501617}
|
||||
- {fileID: 257242826}
|
||||
- {fileID: 1572887942}
|
||||
- {fileID: 899286715}
|
||||
|
@ -11265,6 +11228,8 @@ GameObject:
|
|||
- component: {fileID: 1437263271}
|
||||
- component: {fileID: 1437263273}
|
||||
- component: {fileID: 1437263272}
|
||||
- component: {fileID: 1437263274}
|
||||
- component: {fileID: 1437263275}
|
||||
m_Layer: 5
|
||||
m_Name: Handle
|
||||
m_TagString: Untagged
|
||||
|
@ -11304,7 +11269,7 @@ MonoBehaviour:
|
|||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_Color: {r: 1, g: 0.5, b: 0.5, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_Maskable: 1
|
||||
m_OnCullStateChanged:
|
||||
|
@ -11328,6 +11293,44 @@ CanvasRenderer:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1437263270}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!223 &1437263274
|
||||
Canvas:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1437263270}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 3
|
||||
m_RenderMode: 2
|
||||
m_Camera: {fileID: 0}
|
||||
m_PlaneDistance: 100
|
||||
m_PixelPerfect: 0
|
||||
m_ReceivesEvents: 1
|
||||
m_OverrideSorting: 1
|
||||
m_OverridePixelPerfect: 0
|
||||
m_SortingBucketNormalizedSize: 0
|
||||
m_AdditionalShaderChannelsFlag: 0
|
||||
m_SortingLayerID: 0
|
||||
m_SortingOrder: 20
|
||||
m_TargetDisplay: 0
|
||||
--- !u!114 &1437263275
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1437263270}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_IgnoreReversedGraphics: 1
|
||||
m_BlockingObjects: 0
|
||||
m_BlockingMask:
|
||||
serializedVersion: 2
|
||||
m_Bits: 4294967295
|
||||
--- !u!1 &1441706102
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -13237,7 +13240,7 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 1741478633}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 13
|
||||
m_RootOrder: 12
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
|
@ -13446,7 +13449,7 @@ RectTransform:
|
|||
- {fileID: 1395818346}
|
||||
- {fileID: 1798757604}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 22
|
||||
m_RootOrder: 21
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
@ -13542,7 +13545,7 @@ RectTransform:
|
|||
- {fileID: 1092312354}
|
||||
- {fileID: 891468915}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 21
|
||||
m_RootOrder: 20
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
|
@ -13630,12 +13633,12 @@ RectTransform:
|
|||
m_Children:
|
||||
- {fileID: 1437263271}
|
||||
m_Father: {fileID: 1289465654}
|
||||
m_RootOrder: 2
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: -20, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!1 &1632534165
|
||||
GameObject:
|
||||
|
@ -14879,42 +14882,6 @@ CanvasRenderer:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1811133721}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!1 &1811965324
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 1811965325}
|
||||
m_Layer: 5
|
||||
m_Name: Fill Area
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &1811965325
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 1811965324}
|
||||
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_Children:
|
||||
- {fileID: 723601103}
|
||||
m_Father: {fileID: 1289465654}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0.25}
|
||||
m_AnchorMax: {x: 1, y: 0.75}
|
||||
m_AnchoredPosition: {x: -5, y: 0}
|
||||
m_SizeDelta: {x: -20, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!1 &1813469519
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -15837,7 +15804,7 @@ RectTransform:
|
|||
- {fileID: 1543793723}
|
||||
- {fileID: 1344070788}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 27
|
||||
m_RootOrder: 26
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
@ -16138,7 +16105,7 @@ RectTransform:
|
|||
- {fileID: 1481521047}
|
||||
- {fileID: 1261535758}
|
||||
m_Father: {fileID: 1335076903}
|
||||
m_RootOrder: 24
|
||||
m_RootOrder: 23
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
|
|
24
Assets/Scripts/Chaser.cs
Normal file
24
Assets/Scripts/Chaser.cs
Normal file
|
@ -0,0 +1,24 @@
|
|||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
namespace RimWorldAnimationStudio
|
||||
{
|
||||
public class Chaser : MonoBehaviour
|
||||
{
|
||||
public GameObject target;
|
||||
public bool chaseAlongX = true;
|
||||
public bool chaseAlongY = false;
|
||||
|
||||
void Update()
|
||||
{
|
||||
if (target == null)
|
||||
{ return; }
|
||||
|
||||
float x = chaseAlongX ? target.transform.position.x : transform.position.x;
|
||||
float y = chaseAlongY ? target.transform.position.y : transform.position.y;
|
||||
|
||||
transform.position = new Vector3(x, y, 0f);
|
||||
}
|
||||
}
|
||||
}
|
11
Assets/Scripts/Chaser.cs.meta
Normal file
11
Assets/Scripts/Chaser.cs.meta
Normal file
|
@ -0,0 +1,11 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 9584d659e560b88409843604ae04229b
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -72,12 +72,12 @@ namespace RimWorldAnimationStudio
|
|||
if (actorBody == this)
|
||||
{ continue; }
|
||||
|
||||
actorBody.bodyRenderer.color = new Color(1f, 1f, 1f);
|
||||
actorBody.headRenderer.color = new Color(1f, 1f, 1f);
|
||||
actorBody.bodyRenderer.color = Constants.ColorWhite;
|
||||
actorBody.headRenderer.color = Constants.ColorWhite;
|
||||
}
|
||||
|
||||
bodyRenderer.color = new Color(0f, 1f, 0f);
|
||||
headRenderer.color = new Color(0f, 1f, 0f);
|
||||
bodyRenderer.color = Constants.ColorGreen;
|
||||
headRenderer.color = Constants.ColorGreen;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -23,26 +23,29 @@ namespace RimWorldAnimationStudio
|
|||
{
|
||||
Activate();
|
||||
|
||||
PawnKeyframe keyframe = Workspace.Instance.GetCurrentPawnKeyframe();
|
||||
|
||||
if (Workspace.Instance.GetCurrentPawnKeyframe() == null)
|
||||
{ Debug.LogWarning("Cannot alter actor - no keyframe data available"); return; }
|
||||
|
||||
Vector3 mousePosition = Camera.main.ScreenToWorldPoint(Input.mousePosition);
|
||||
PawnKeyframe keyframe = Workspace.animationDef.animationStages[Workspace.stageID].animationClips[parent.actorID].keyframes.FirstOrDefault(x => x.keyframeID == Workspace.keyframeID);
|
||||
|
||||
if (Workspace.actorManipulationMode == ActorManipulationMode.Pan)
|
||||
{
|
||||
float distance = ((Vector2)mousePosition - (Vector2)transform.position).y;
|
||||
|
||||
Vector3 headOffset = new Vector3(0f, 0.34f, 0f);
|
||||
headOffset = Quaternion.Euler(0, 0, keyframe.bodyAngle) * headOffset;
|
||||
|
||||
distance = Vector2.Dot(parent.transform.up, (Vector2)(mousePosition - parent.transform.position - headOffset));
|
||||
|
||||
Debug.Log(headOffset.ToString());
|
||||
|
||||
Workspace.animationDef.animationStages[Workspace.stageID].animationClips[parent.actorID].keyframes.FirstOrDefault(x => x.keyframeID == Workspace.keyframeID).headBob = distance;
|
||||
keyframe.headBob = distance;
|
||||
}
|
||||
|
||||
else if (Workspace.actorManipulationMode == ActorManipulationMode.Rotate)
|
||||
{
|
||||
float angle = Vector2.SignedAngle(Vector2.down, (Vector2)mousePosition - (Vector2)transform.position);
|
||||
Workspace.animationDef.animationStages[Workspace.stageID].animationClips[parent.actorID].keyframes.FirstOrDefault(x => x.keyframeID == Workspace.keyframeID).headAngle = angle;
|
||||
keyframe.headAngle = angle;
|
||||
}
|
||||
|
||||
else if (Workspace.actorManipulationMode == ActorManipulationMode.Face)
|
||||
|
@ -51,9 +54,7 @@ namespace RimWorldAnimationStudio
|
|||
int facing = -Mathf.RoundToInt(angle / 90f);
|
||||
facing = facing < 0 ? facing + 4 : facing;
|
||||
|
||||
Debug.Log(facing.ToString());
|
||||
|
||||
Workspace.animationDef.animationStages[Workspace.stageID].animationClips[parent.actorID].keyframes.FirstOrDefault(x => x.keyframeID == Workspace.keyframeID).headFacing = facing;
|
||||
keyframe.headFacing = facing;
|
||||
}
|
||||
|
||||
PawnAnimationClip clip = Workspace.Instance.GetPawnAnimationClip(parent.actorID);
|
||||
|
@ -66,11 +67,11 @@ namespace RimWorldAnimationStudio
|
|||
|
||||
foreach (ActorBody actorBody in AnimationController.Instance.GetComponentsInChildren<ActorBody>())
|
||||
{
|
||||
actorBody.bodyRenderer.color = new Color(1f, 1f, 1f);
|
||||
actorBody.headRenderer.color = new Color(1f, 1f, 1f);
|
||||
actorBody.bodyRenderer.color = Constants.ColorWhite;
|
||||
actorBody.headRenderer.color = Constants.ColorWhite;
|
||||
}
|
||||
|
||||
bodyPartRenderer.color = new Color(0f, 1f, 0f);
|
||||
bodyPartRenderer.color = Constants.ColorGreen;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -66,12 +66,10 @@ namespace RimWorldAnimationStudio
|
|||
if (ghostSliders.childCount <= i)
|
||||
{ Instantiate(ghostSliderPrefab, ghostSliders); }
|
||||
|
||||
GameObject ghostSliderObject = ghostSliders.GetChild(i).gameObject;
|
||||
Debug.Log(ghostSliderObject);
|
||||
GameObject ghostSliderObject = ghostSliders.GetChild(i).gameObject;
|
||||
ghostSliderObject.SetActive(true);
|
||||
|
||||
Slider ghostSlider = ghostSliderObject.GetComponent<Slider>();
|
||||
Debug.Log(ghostSlider);
|
||||
ghostSlider.value = (int)((i + 1) * clip.duration + keyframe.atTick);
|
||||
|
||||
float mult = 1f - Mathf.Pow((float)i / maxGhosts, 2);
|
||||
|
@ -96,12 +94,20 @@ namespace RimWorldAnimationStudio
|
|||
|
||||
public void OnPointerClick(PointerEventData eventData)
|
||||
{
|
||||
Activate();
|
||||
Workspace.actorID = actorID;
|
||||
Workspace.keyframeID = keyframeID;
|
||||
|
||||
if (eventData.clickCount >= 2)
|
||||
{
|
||||
AnimationController.Instance.stageTick = keyframe.atTick.Value;
|
||||
}
|
||||
}
|
||||
|
||||
public void OnBeginDrag(PointerEventData eventData)
|
||||
{
|
||||
Activate();
|
||||
AnimationController.Instance.stageTick = keyframe.atTick.Value;
|
||||
Workspace.actorID = actorID;
|
||||
Workspace.keyframeID = keyframeID;
|
||||
|
||||
if (keyframe.atTick == 1)
|
||||
{ return; }
|
||||
|
@ -113,7 +119,8 @@ namespace RimWorldAnimationStudio
|
|||
{
|
||||
base.OnDrag(eventData);
|
||||
|
||||
Activate();
|
||||
AnimationController.Instance.stageTick = keyframe.atTick.Value;
|
||||
Workspace.actorID = actorID;
|
||||
}
|
||||
|
||||
public void OnEndDrag(PointerEventData eventData)
|
||||
|
@ -121,23 +128,21 @@ namespace RimWorldAnimationStudio
|
|||
interactable = false;
|
||||
}
|
||||
|
||||
public void Activate()
|
||||
protected override void Update()
|
||||
{
|
||||
AnimationController.Instance.stageTick = keyframe.atTick.Value;
|
||||
base.Update();
|
||||
|
||||
Workspace.keyframeID = keyframeID;
|
||||
if (Workspace.keyframeID == keyframeID && AnimationController.Instance.stageTick == keyframe.atTick.Value)
|
||||
{ transform.FindDeepChild("Handle").GetComponent<Image>().color = Constants.ColorPurple; }
|
||||
|
||||
foreach (AnimationTimeline _timeline in AnimationController.Instance.animationTimelines.GetComponentsInChildren<AnimationTimeline>())
|
||||
{
|
||||
foreach (KeyframeSlider keyframeSlider in _timeline.GetComponentsInChildren<KeyframeSlider>())
|
||||
{
|
||||
if (keyframeSlider.keyframe.atTick.Value == keyframe.atTick.Value)
|
||||
{ keyframeSlider.transform.FindDeepChild("Handle").GetComponent<Image>().color = new Color(0f, 1f, 0f); }
|
||||
else if (Workspace.keyframeID == keyframeID)
|
||||
{ transform.FindDeepChild("Handle").GetComponent<Image>().color = Constants.ColorCyan; }
|
||||
|
||||
else
|
||||
{ keyframeSlider.transform.FindDeepChild("Handle").GetComponent<Image>().color = new Color(1f, 1f, 1f); }
|
||||
}
|
||||
}
|
||||
else if (AnimationController.Instance.stageTick == keyframe.atTick.Value)
|
||||
{ transform.FindDeepChild("Handle").GetComponent<Image>().color = Constants.ColorPink; }
|
||||
|
||||
else
|
||||
{ transform.FindDeepChild("Handle").GetComponent<Image>().color = Constants.ColorWhite; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -60,8 +60,8 @@ namespace RimWorldAnimationStudio
|
|||
|
||||
Workspace.stageID = transform.GetSiblingIndex();
|
||||
|
||||
AnimationController.Instance.ResetAnimationTimeline();
|
||||
AnimationController.Instance.InitializeAnimationTimeline();
|
||||
//AnimationController.Instance.ResetAnimationTimeline();
|
||||
//AnimationController.Instance.InitializeAnimationTimeline();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -31,6 +31,7 @@ namespace RimWorldAnimationStudio
|
|||
public AnimationTimeline animationTimelinePrefab;
|
||||
|
||||
// Private timing variables
|
||||
private int lastStageTick = 1;
|
||||
private float timeSinceLastUpdate = 0;
|
||||
private int cycleIndex = 0;
|
||||
|
||||
|
@ -54,9 +55,6 @@ namespace RimWorldAnimationStudio
|
|||
timeSinceLastUpdate -= 1f / 60f;
|
||||
stageTick += 1;
|
||||
|
||||
stageTimelineSlider.value = stageTick;
|
||||
animationClipTimeField.text = stageTick.ToString();
|
||||
|
||||
if (stageTick > Workspace.StageWindowSize)
|
||||
{
|
||||
if (stageLoopDropdown.value == 1)
|
||||
|
@ -73,8 +71,8 @@ namespace RimWorldAnimationStudio
|
|||
++Workspace.stageID;
|
||||
cycleIndex = 0;
|
||||
|
||||
ResetAnimationTimeline();
|
||||
InitializeAnimationTimeline();
|
||||
//ResetAnimationTimeline();
|
||||
//InitializeAnimationTimeline();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -84,15 +82,29 @@ namespace RimWorldAnimationStudio
|
|||
}
|
||||
|
||||
// Update stage timeline
|
||||
animationClipTimeField.interactable = isAnimating == false;
|
||||
animationClipTimeField.interactable = isAnimating == false;
|
||||
animationClipLengthField.interactable = isAnimating == false;
|
||||
|
||||
if (lastStageTick != stageTick)
|
||||
{
|
||||
stageTimelineSlider.value = stageTick;
|
||||
animationClipTimeField.text = stageTick.ToString();
|
||||
|
||||
lastStageTick = stageTick;
|
||||
}
|
||||
|
||||
// Update animation
|
||||
UpdateAnimation();
|
||||
}
|
||||
|
||||
public void UpdateAnimation()
|
||||
{
|
||||
if (Workspace.Instance.AnimationTimelinesNeedUpdate())
|
||||
{
|
||||
ResetAnimationTimeline();
|
||||
InitializeAnimationTimeline();
|
||||
}
|
||||
|
||||
List<ActorBody> actorBodies = GetComponentsInChildren<ActorBody>().ToList();
|
||||
|
||||
for (int actorID = 0; actorID < actorBodies.Count; actorID++)
|
||||
|
@ -177,21 +189,20 @@ namespace RimWorldAnimationStudio
|
|||
public void Reset()
|
||||
{
|
||||
Workspace.stageID = 0;
|
||||
|
||||
isAnimating = false;
|
||||
ResetAnimationTimeline();
|
||||
StageCardManager.Instance.Reset();
|
||||
}
|
||||
|
||||
public void ResetAnimationTimeline()
|
||||
{
|
||||
isAnimating = false;
|
||||
{
|
||||
timeSinceLastUpdate = 0;
|
||||
cycleIndex = 0;
|
||||
|
||||
foreach (ActorBody actorBody in GetComponentsInChildren<ActorBody>())
|
||||
{ Destroy(actorBody.gameObject); }
|
||||
|
||||
foreach (Transform animationTimeline in animationTimelines)
|
||||
foreach (AnimationTimeline animationTimeline in animationTimelines.GetComponentsInChildren<AnimationTimeline>())
|
||||
{ Destroy(animationTimeline.gameObject); }
|
||||
}
|
||||
|
||||
|
@ -299,7 +310,7 @@ namespace RimWorldAnimationStudio
|
|||
|
||||
clip.BuildSimpleCurves();
|
||||
|
||||
animationTimelines.GetChild(Workspace.actorID).GetComponent<AnimationTimeline>().AddPawnKeyFrame(keyframe.keyframeID);
|
||||
animationTimelines.GetComponentsInChildren<AnimationTimeline>()[Workspace.actorID].AddPawnKeyFrame(keyframe.keyframeID);
|
||||
}
|
||||
|
||||
public void RemovePawnKeyframe()
|
||||
|
@ -311,12 +322,12 @@ namespace RimWorldAnimationStudio
|
|||
{
|
||||
PawnKeyframe keyframe = Workspace.Instance.GetPawnKeyframe(actorID, keyframeID);
|
||||
|
||||
if (keyframe.atTick == 1)
|
||||
if (keyframe != null && keyframe.atTick == 1)
|
||||
{ Debug.LogWarning("Cannot delete key frame - the first key frame of an animation cannot be deleted"); return; }
|
||||
|
||||
if (keyframe != null)
|
||||
{
|
||||
animationTimelines.GetChild(actorID).GetComponent<AnimationTimeline>().RemovePawnKeyFrame(keyframe.keyframeID);
|
||||
animationTimelines.GetComponentsInChildren<AnimationTimeline>()[Workspace.actorID].RemovePawnKeyFrame(keyframe.keyframeID);
|
||||
|
||||
PawnAnimationClip clip = Workspace.animationDef.animationStages[Workspace.stageID].animationClips[actorID];
|
||||
clip.keyframes.Remove(keyframe);
|
||||
|
@ -383,8 +394,8 @@ namespace RimWorldAnimationStudio
|
|||
animationClipLengthField.text = newstageWindowSize.ToString();
|
||||
Workspace.animationDef.animationStages[Workspace.stageID].stageWindowSize = newstageWindowSize;
|
||||
|
||||
ResetAnimationTimeline();
|
||||
InitializeAnimationTimeline();
|
||||
//ResetAnimationTimeline();
|
||||
//InitializeAnimationTimeline();
|
||||
}
|
||||
|
||||
public void OnCycleNormalFieldChange()
|
||||
|
|
|
@ -13,5 +13,10 @@ namespace RimWorldAnimationStudio
|
|||
public static Color ColorGoldYellow = new Color(1f, 0.85f, 0f);
|
||||
public static Color ColorGrey = new Color(0.5f, 0.5f, 0.5f);
|
||||
public static Color ColorDarkGrey = new Color(0.2f, 0.2f, 0.2f);
|
||||
public static Color ColorPink = new Color(1.0f, 0.5f, 0.5f);
|
||||
public static Color ColorOrange = new Color(1.0f, 0.7f, 0.0f);
|
||||
public static Color ColorRichOrange = new Color(1.0f, 0.4f, 0.1f);
|
||||
public static Color ColorCyan = new Color(0.0f, 1.0f, 1.0f);
|
||||
public static Color ColorPurple = new Color(0.85f, 0.0f, 1.0f);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -41,12 +41,12 @@ namespace RimWorldAnimationStudio
|
|||
}
|
||||
}
|
||||
|
||||
public PawnKeyframe GetCurrentPawnKeyframe(bool makeNewIfNull = true)
|
||||
public PawnKeyframe GetCurrentPawnKeyframe()
|
||||
{
|
||||
int stageTick = AnimationController.Instance.stageTick;
|
||||
PawnKeyframe keyframe = animationDef?.animationStages[stageID]?.animationClips[actorID]?.keyframes.FirstOrDefault(x => x.atTick == stageTick);
|
||||
|
||||
if (keyframe != null || makeNewIfNull == false)
|
||||
if (keyframe != null)
|
||||
{ return keyframe; }
|
||||
|
||||
AnimationController.Instance.AddPawnKeyframe();
|
||||
|
@ -105,5 +105,41 @@ namespace RimWorldAnimationStudio
|
|||
|
||||
// All other data
|
||||
}
|
||||
|
||||
private int lastactorCount = 0;
|
||||
private int lastStageID = 0;
|
||||
private int lastStageCount = 0;
|
||||
private int lastStageWindowSize = 0;
|
||||
|
||||
public bool AnimationTimelinesNeedUpdate()
|
||||
{
|
||||
if (animationDef == null) return false;
|
||||
|
||||
bool update = false;
|
||||
|
||||
if (lastStageID != stageID)
|
||||
{ update = true; }
|
||||
|
||||
if (lastStageCount != animationDef.animationStages.Count)
|
||||
{ update = true; }
|
||||
|
||||
if (lastactorCount != animationDef.actors.Count)
|
||||
{ update = true; }
|
||||
|
||||
if (lastStageWindowSize != StageWindowSize)
|
||||
{ update = true; }
|
||||
|
||||
if (update)
|
||||
{
|
||||
lastStageID = stageID;
|
||||
lastStageCount = animationDef.animationStages.Count;
|
||||
lastactorCount = animationDef.actors.Count;
|
||||
lastStageWindowSize = StageWindowSize;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue