add touch style UI elements and effects
games now support the ability to define two cursor colours if they need split screen touch inputs
This commit is contained in:
parent
14d53183c8
commit
8017f10aa3
|
|
@ -16,6 +16,7 @@ namespace Starpelly
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static Color Hex2RGB(this string hex)
|
public static Color Hex2RGB(this string hex)
|
||||||
{
|
{
|
||||||
|
if (hex is null or "") return Color.black;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
hex = hex.Replace("0x", "");//in case the string is formatted 0xFFFFFF
|
hex = hex.Replace("0x", "");//in case the string is formatted 0xFFFFFF
|
||||||
|
|
@ -25,7 +26,7 @@ namespace Starpelly
|
||||||
byte g = byte.Parse(hex.Substring(2, 2), System.Globalization.NumberStyles.HexNumber);
|
byte g = byte.Parse(hex.Substring(2, 2), System.Globalization.NumberStyles.HexNumber);
|
||||||
byte b = byte.Parse(hex.Substring(4, 2), System.Globalization.NumberStyles.HexNumber);
|
byte b = byte.Parse(hex.Substring(4, 2), System.Globalization.NumberStyles.HexNumber);
|
||||||
//Only use alpha if the string has enough characters
|
//Only use alpha if the string has enough characters
|
||||||
if (hex.Length == 8)
|
if (hex.Length >= 8)
|
||||||
{
|
{
|
||||||
a = byte.Parse(hex.Substring(6, 2), System.Globalization.NumberStyles.HexNumber);
|
a = byte.Parse(hex.Substring(6, 2), System.Globalization.NumberStyles.HexNumber);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2090,6 +2090,7 @@ RectTransform:
|
||||||
- {fileID: 3918594455571216808}
|
- {fileID: 3918594455571216808}
|
||||||
- {fileID: 3918594456177472909}
|
- {fileID: 3918594456177472909}
|
||||||
- {fileID: 3918594455700716071}
|
- {fileID: 3918594455700716071}
|
||||||
|
- {fileID: 8475765577213823739}
|
||||||
m_Father: {fileID: 9026175551012134334}
|
m_Father: {fileID: 9026175551012134334}
|
||||||
m_RootOrder: 2
|
m_RootOrder: 2
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
|
@ -3402,6 +3403,82 @@ MonoBehaviour:
|
||||||
m_StringArgument:
|
m_StringArgument:
|
||||||
m_BoolArgument: 0
|
m_BoolArgument: 0
|
||||||
m_CallState: 2
|
m_CallState: 2
|
||||||
|
--- !u!1 &3902585457234082832
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 8475765577213823739}
|
||||||
|
- component: {fileID: 4444702116040102111}
|
||||||
|
- component: {fileID: 888764958146106342}
|
||||||
|
m_Layer: 5
|
||||||
|
m_Name: Mouse
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 0
|
||||||
|
--- !u!224 &8475765577213823739
|
||||||
|
RectTransform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 3902585457234082832}
|
||||||
|
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: []
|
||||||
|
m_Father: {fileID: 4793950890431788211}
|
||||||
|
m_RootOrder: 7
|
||||||
|
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: 0, y: 0}
|
||||||
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!222 &4444702116040102111
|
||||||
|
CanvasRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 3902585457234082832}
|
||||||
|
m_CullTransparentMesh: 1
|
||||||
|
--- !u!114 &888764958146106342
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 3902585457234082832}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_Material: {fileID: 2100000, guid: 55b3a6672a0ec294d8f3edb9c1f94b36, type: 2}
|
||||||
|
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_RaycastTarget: 0
|
||||||
|
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_Maskable: 0
|
||||||
|
m_OnCullStateChanged:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
m_Sprite: {fileID: -974588141, guid: d44d97eed2a444b41be17f9737b43b5f, type: 3}
|
||||||
|
m_Type: 0
|
||||||
|
m_PreserveAspect: 1
|
||||||
|
m_FillCenter: 1
|
||||||
|
m_FillMethod: 4
|
||||||
|
m_FillAmount: 1
|
||||||
|
m_FillClockwise: 1
|
||||||
|
m_FillOrigin: 0
|
||||||
|
m_UseSpriteMesh: 0
|
||||||
|
m_PixelsPerUnitMultiplier: 1
|
||||||
--- !u!1 &3918594454379110542
|
--- !u!1 &3918594454379110542
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|
@ -3437,11 +3514,11 @@ RectTransform:
|
||||||
m_Father: {fileID: 3918594454557351925}
|
m_Father: {fileID: 3918594454557351925}
|
||||||
m_RootOrder: 0
|
m_RootOrder: 0
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 0, y: 0.5}
|
||||||
m_AnchoredPosition: {x: -229.1, y: -25}
|
m_AnchoredPosition: {x: 330, y: -0.0000000019699655}
|
||||||
m_SizeDelta: {x: 50, y: 50}
|
m_SizeDelta: {x: 50, y: 50}
|
||||||
m_Pivot: {x: 0.5, y: 0}
|
m_Pivot: {x: 0, y: 0.5}
|
||||||
--- !u!222 &3918594454379110530
|
--- !u!222 &3918594454379110530
|
||||||
CanvasRenderer:
|
CanvasRenderer:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|
@ -3664,8 +3741,8 @@ RectTransform:
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0, y: 1}
|
m_AnchorMin: {x: 0, y: 1}
|
||||||
m_AnchorMax: {x: 0, y: 1}
|
m_AnchorMax: {x: 0, y: 1}
|
||||||
m_AnchoredPosition: {x: 602.5, y: -243.97882}
|
m_AnchoredPosition: {x: 754, y: -307.9788}
|
||||||
m_SizeDelta: {x: 1165, y: 100}
|
m_SizeDelta: {x: 1468, y: 100}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &3918594454393827267
|
--- !u!114 &3918594454393827267
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
|
|
@ -3808,7 +3885,7 @@ MonoBehaviour:
|
||||||
m_linkedTextComponent: {fileID: 0}
|
m_linkedTextComponent: {fileID: 0}
|
||||||
parentLinkedComponent: {fileID: 0}
|
parentLinkedComponent: {fileID: 0}
|
||||||
m_enableKerning: 1
|
m_enableKerning: 1
|
||||||
m_ActiveFontFeatures: 00000000
|
m_ActiveFontFeatures: 6e72656b
|
||||||
m_enableExtraPadding: 0
|
m_enableExtraPadding: 0
|
||||||
checkPaddingRequired: 0
|
checkPaddingRequired: 0
|
||||||
m_isRichText: 1
|
m_isRichText: 1
|
||||||
|
|
@ -3947,7 +4024,7 @@ MonoBehaviour:
|
||||||
m_linkedTextComponent: {fileID: 0}
|
m_linkedTextComponent: {fileID: 0}
|
||||||
parentLinkedComponent: {fileID: 0}
|
parentLinkedComponent: {fileID: 0}
|
||||||
m_enableKerning: 1
|
m_enableKerning: 1
|
||||||
m_ActiveFontFeatures: 00000000
|
m_ActiveFontFeatures: 6e72656b
|
||||||
m_enableExtraPadding: 0
|
m_enableExtraPadding: 0
|
||||||
checkPaddingRequired: 0
|
checkPaddingRequired: 0
|
||||||
m_isRichText: 1
|
m_isRichText: 1
|
||||||
|
|
@ -4004,7 +4081,7 @@ RectTransform:
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
m_AnchoredPosition: {x: 0.000005722046, y: -0.000005722046}
|
m_AnchoredPosition: {x: 0, y: -0.000005722046}
|
||||||
m_SizeDelta: {x: 50, y: 50}
|
m_SizeDelta: {x: 50, y: 50}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &3918594454531700427
|
--- !u!222 &3918594454531700427
|
||||||
|
|
@ -4246,7 +4323,7 @@ RectTransform:
|
||||||
m_AnchorMin: {x: 0, y: 0}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 0, y: 0}
|
m_AnchorMax: {x: 0, y: 0}
|
||||||
m_AnchoredPosition: {x: 0, y: 0}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 1165, y: 64}
|
m_SizeDelta: {x: 0, y: 64}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &3918594454557351915
|
--- !u!222 &3918594454557351915
|
||||||
CanvasRenderer:
|
CanvasRenderer:
|
||||||
|
|
@ -4573,7 +4650,7 @@ MonoBehaviour:
|
||||||
m_Spacing: 0
|
m_Spacing: 0
|
||||||
m_ChildForceExpandWidth: 1
|
m_ChildForceExpandWidth: 1
|
||||||
m_ChildForceExpandHeight: 1
|
m_ChildForceExpandHeight: 1
|
||||||
m_ChildControlWidth: 0
|
m_ChildControlWidth: 1
|
||||||
m_ChildControlHeight: 0
|
m_ChildControlHeight: 0
|
||||||
m_ChildScaleWidth: 0
|
m_ChildScaleWidth: 0
|
||||||
m_ChildScaleHeight: 1
|
m_ChildScaleHeight: 1
|
||||||
|
|
@ -5749,7 +5826,7 @@ MonoBehaviour:
|
||||||
m_linkedTextComponent: {fileID: 0}
|
m_linkedTextComponent: {fileID: 0}
|
||||||
parentLinkedComponent: {fileID: 0}
|
parentLinkedComponent: {fileID: 0}
|
||||||
m_enableKerning: 1
|
m_enableKerning: 1
|
||||||
m_ActiveFontFeatures: 00000000
|
m_ActiveFontFeatures: 6e72656b
|
||||||
m_enableExtraPadding: 0
|
m_enableExtraPadding: 0
|
||||||
checkPaddingRequired: 0
|
checkPaddingRequired: 0
|
||||||
m_isRichText: 1
|
m_isRichText: 1
|
||||||
|
|
@ -5879,6 +5956,7 @@ MonoBehaviour:
|
||||||
- {fileID: 3918594455571216809}
|
- {fileID: 3918594455571216809}
|
||||||
- {fileID: 3918594456177472910}
|
- {fileID: 3918594456177472910}
|
||||||
- {fileID: 3918594455700716064}
|
- {fileID: 3918594455700716064}
|
||||||
|
- {fileID: 3902585457234082832}
|
||||||
controllerMat: {fileID: 2100000, guid: 55b3a6672a0ec294d8f3edb9c1f94b36, type: 2}
|
controllerMat: {fileID: 2100000, guid: 55b3a6672a0ec294d8f3edb9c1f94b36, type: 2}
|
||||||
PadBindingsMenus:
|
PadBindingsMenus:
|
||||||
- {fileID: 7023003282004720528}
|
- {fileID: 7023003282004720528}
|
||||||
|
|
@ -6987,7 +7065,7 @@ RectTransform:
|
||||||
m_AnchorMin: {x: 0, y: 0}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 0, y: 0}
|
m_AnchorMax: {x: 0, y: 0}
|
||||||
m_AnchoredPosition: {x: 0, y: 0}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 1165, y: 50}
|
m_SizeDelta: {x: 0, y: 50}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &3918594455809915006
|
--- !u!114 &3918594455809915006
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
|
|
@ -7538,7 +7616,7 @@ RectTransform:
|
||||||
m_AnchorMin: {x: 1, y: 0.5}
|
m_AnchorMin: {x: 1, y: 0.5}
|
||||||
m_AnchorMax: {x: 1, y: 0.5}
|
m_AnchorMax: {x: 1, y: 0.5}
|
||||||
m_AnchoredPosition: {x: 0, y: 0}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 786.6, y: 50}
|
m_SizeDelta: {x: 990, y: 50}
|
||||||
m_Pivot: {x: 1, y: 0.5}
|
m_Pivot: {x: 1, y: 0.5}
|
||||||
--- !u!222 &3918594455983756490
|
--- !u!222 &3918594455983756490
|
||||||
CanvasRenderer:
|
CanvasRenderer:
|
||||||
|
|
@ -7908,8 +7986,8 @@ RectTransform:
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0, y: 0}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 0, y: 0}
|
m_AnchorMax: {x: 0, y: 0}
|
||||||
m_AnchoredPosition: {x: 591, y: 0}
|
m_AnchoredPosition: {x: 754, y: 0}
|
||||||
m_SizeDelta: {x: 1142, y: 0}
|
m_SizeDelta: {x: 1468, y: 0}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &3918594456218978261
|
--- !u!222 &3918594456218978261
|
||||||
CanvasRenderer:
|
CanvasRenderer:
|
||||||
|
|
@ -8141,7 +8219,7 @@ MonoBehaviour:
|
||||||
m_linkedTextComponent: {fileID: 0}
|
m_linkedTextComponent: {fileID: 0}
|
||||||
parentLinkedComponent: {fileID: 0}
|
parentLinkedComponent: {fileID: 0}
|
||||||
m_enableKerning: 1
|
m_enableKerning: 1
|
||||||
m_ActiveFontFeatures: 00000000
|
m_ActiveFontFeatures: 6e72656b
|
||||||
m_enableExtraPadding: 0
|
m_enableExtraPadding: 0
|
||||||
checkPaddingRequired: 0
|
checkPaddingRequired: 0
|
||||||
m_isRichText: 1
|
m_isRichText: 1
|
||||||
|
|
@ -11326,7 +11404,7 @@ RectTransform:
|
||||||
m_AnchorMin: {x: 0, y: 0}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 0, y: 0}
|
m_AnchorMax: {x: 0, y: 0}
|
||||||
m_AnchoredPosition: {x: 0, y: 0}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 1165, y: 64}
|
m_SizeDelta: {x: 0, y: 64}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &5124755665249610764
|
--- !u!114 &5124755665249610764
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
|
|
|
||||||
|
|
@ -170,6 +170,120 @@ MonoBehaviour:
|
||||||
m_FillOrigin: 0
|
m_FillOrigin: 0
|
||||||
m_UseSpriteMesh: 0
|
m_UseSpriteMesh: 0
|
||||||
m_PixelsPerUnitMultiplier: 3
|
m_PixelsPerUnitMultiplier: 3
|
||||||
|
--- !u!1 &435555855710102188
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 7576197626345016079}
|
||||||
|
- component: {fileID: 1664206953461466981}
|
||||||
|
- component: {fileID: 7845231527756581285}
|
||||||
|
m_Layer: 31
|
||||||
|
m_Name: FlasherL
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!224 &7576197626345016079
|
||||||
|
RectTransform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 435555855710102188}
|
||||||
|
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: []
|
||||||
|
m_Father: {fileID: 8552962828543516429}
|
||||||
|
m_RootOrder: 0
|
||||||
|
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: 12}
|
||||||
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!222 &1664206953461466981
|
||||||
|
CanvasRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 435555855710102188}
|
||||||
|
m_CullTransparentMesh: 1
|
||||||
|
--- !u!114 &7845231527756581285
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 435555855710102188}
|
||||||
|
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: 0, b: 0, a: 0.1254902}
|
||||||
|
m_RaycastTarget: 1
|
||||||
|
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_Maskable: 0
|
||||||
|
m_OnCullStateChanged:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
m_Sprite: {fileID: 21300000, guid: 8be59c4bde4258c429ac39251f5f681b, type: 3}
|
||||||
|
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: 5
|
||||||
|
--- !u!1 &699803779871748277
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 8552962828543516429}
|
||||||
|
m_Layer: 31
|
||||||
|
m_Name: Flashers
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 0
|
||||||
|
--- !u!224 &8552962828543516429
|
||||||
|
RectTransform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 699803779871748277}
|
||||||
|
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: 7576197626345016079}
|
||||||
|
- {fileID: 8281773103246844715}
|
||||||
|
m_Father: {fileID: 2077856143944097172}
|
||||||
|
m_RootOrder: 3
|
||||||
|
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: 0, y: 0}
|
||||||
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!1 &2464883521749415129
|
--- !u!1 &2464883521749415129
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|
@ -693,6 +807,82 @@ Transform:
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_RootOrder: 0
|
m_RootOrder: 0
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!1 &6809880121875460609
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 8281773103246844715}
|
||||||
|
- component: {fileID: 7734333607666534753}
|
||||||
|
- component: {fileID: 2240635501115395630}
|
||||||
|
m_Layer: 31
|
||||||
|
m_Name: FlasherR
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!224 &8281773103246844715
|
||||||
|
RectTransform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 6809880121875460609}
|
||||||
|
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: []
|
||||||
|
m_Father: {fileID: 8552962828543516429}
|
||||||
|
m_RootOrder: 1
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
m_AnchorMin: {x: 1, y: 0}
|
||||||
|
m_AnchorMax: {x: 1, y: 1}
|
||||||
|
m_AnchoredPosition: {x: 0.0000009536743, y: 0}
|
||||||
|
m_SizeDelta: {x: 2, y: 12}
|
||||||
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!222 &7734333607666534753
|
||||||
|
CanvasRenderer:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 6809880121875460609}
|
||||||
|
m_CullTransparentMesh: 1
|
||||||
|
--- !u!114 &2240635501115395630
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 6809880121875460609}
|
||||||
|
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, g: 0, b: 1, a: 0.1254902}
|
||||||
|
m_RaycastTarget: 1
|
||||||
|
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_Maskable: 0
|
||||||
|
m_OnCullStateChanged:
|
||||||
|
m_PersistentCalls:
|
||||||
|
m_Calls: []
|
||||||
|
m_Sprite: {fileID: 21300000, guid: 8be59c4bde4258c429ac39251f5f681b, type: 3}
|
||||||
|
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: 5
|
||||||
--- !u!1 &7051539713125569525
|
--- !u!1 &7051539713125569525
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|
@ -894,6 +1084,7 @@ RectTransform:
|
||||||
- {fileID: 2769789585838315502}
|
- {fileID: 2769789585838315502}
|
||||||
- {fileID: 8925473620302868482}
|
- {fileID: 8925473620302868482}
|
||||||
- {fileID: 8512930684284350359}
|
- {fileID: 8512930684284350359}
|
||||||
|
- {fileID: 8552962828543516429}
|
||||||
m_Father: {fileID: 6052331674888157612}
|
m_Father: {fileID: 6052331674888157612}
|
||||||
m_RootOrder: 4
|
m_RootOrder: 4
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
|
|
||||||
|
|
@ -47,10 +47,12 @@ MonoBehaviour:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
follow: 1
|
follow: 1
|
||||||
mouseMoveSpeed: 249.1
|
mouseMoveSpeed: 249.1
|
||||||
|
sideChangeTrailTime: 0
|
||||||
DSGuy: {fileID: 0}
|
DSGuy: {fileID: 0}
|
||||||
DSGuyAnimator: {fileID: 0}
|
DSGuyAnimator: {fileID: 0}
|
||||||
flickCoeff: 0.35
|
flickCoeff: 0.35
|
||||||
flickInitMul: 1.5
|
flickInitMul: 1.5
|
||||||
|
splitTouchSnapEffect: {fileID: 0}
|
||||||
InnerCircle: {fileID: 0}
|
InnerCircle: {fileID: 0}
|
||||||
Circle: {fileID: 0}
|
Circle: {fileID: 0}
|
||||||
--- !u!50 &285182279131759466
|
--- !u!50 &285182279131759466
|
||||||
|
|
@ -84,6 +86,7 @@ GameObject:
|
||||||
m_Component:
|
m_Component:
|
||||||
- component: {fileID: 285182279137842937}
|
- component: {fileID: 285182279137842937}
|
||||||
- component: {fileID: 285182279137842938}
|
- component: {fileID: 285182279137842938}
|
||||||
|
- component: {fileID: 7664691932365309657}
|
||||||
m_Layer: 3
|
m_Layer: 3
|
||||||
m_Name: Actual
|
m_Name: Actual
|
||||||
m_TagString: Untagged
|
m_TagString: Untagged
|
||||||
|
|
@ -121,12 +124,122 @@ MonoBehaviour:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
follow: 0
|
follow: 0
|
||||||
mouseMoveSpeed: 0
|
mouseMoveSpeed: 0
|
||||||
|
sideChangeTrailTime: 0.05
|
||||||
DSGuy: {fileID: 285182280031512481}
|
DSGuy: {fileID: 285182280031512481}
|
||||||
DSGuyAnimator: {fileID: 4592128791974829295}
|
DSGuyAnimator: {fileID: 4592128791974829295}
|
||||||
flickCoeff: 12
|
flickCoeff: 12
|
||||||
flickInitMul: 64
|
flickInitMul: 64
|
||||||
|
splitTouchSnapEffect: {fileID: 7664691932365309657}
|
||||||
InnerCircle: {fileID: 285182279842109877}
|
InnerCircle: {fileID: 285182279842109877}
|
||||||
Circle: {fileID: 285182279897966106}
|
Circle: {fileID: 285182279897966106}
|
||||||
|
--- !u!96 &7664691932365309657
|
||||||
|
TrailRenderer:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 285182279137842936}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_CastShadows: 1
|
||||||
|
m_ReceiveShadows: 1
|
||||||
|
m_DynamicOccludee: 0
|
||||||
|
m_StaticShadowCaster: 0
|
||||||
|
m_MotionVectors: 0
|
||||||
|
m_LightProbeUsage: 0
|
||||||
|
m_ReflectionProbeUsage: 0
|
||||||
|
m_RayTracingMode: 0
|
||||||
|
m_RayTraceProcedural: 0
|
||||||
|
m_RenderingLayerMask: 1
|
||||||
|
m_RendererPriority: 0
|
||||||
|
m_Materials:
|
||||||
|
- {fileID: 10306, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
|
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: 20000
|
||||||
|
m_Time: 0.083333336
|
||||||
|
m_Parameters:
|
||||||
|
serializedVersion: 3
|
||||||
|
widthMultiplier: 0.15
|
||||||
|
widthCurve:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Curve:
|
||||||
|
- serializedVersion: 3
|
||||||
|
time: 0
|
||||||
|
value: 1
|
||||||
|
inSlope: 0
|
||||||
|
outSlope: -0.9
|
||||||
|
tangentMode: 69
|
||||||
|
weightedMode: 0
|
||||||
|
inWeight: 0.33333334
|
||||||
|
outWeight: 0.22058824
|
||||||
|
- serializedVersion: 3
|
||||||
|
time: 1
|
||||||
|
value: 0.1
|
||||||
|
inSlope: -0.9
|
||||||
|
outSlope: -2.2915363
|
||||||
|
tangentMode: 69
|
||||||
|
weightedMode: 0
|
||||||
|
inWeight: 0.16176468
|
||||||
|
outWeight: 0
|
||||||
|
m_PreInfinity: 2
|
||||||
|
m_PostInfinity: 2
|
||||||
|
m_RotationOrder: 4
|
||||||
|
colorGradient:
|
||||||
|
serializedVersion: 2
|
||||||
|
key0: {r: 1, g: 1, b: 1, a: 0.3137255}
|
||||||
|
key1: {r: 1, g: 1, b: 1, a: 0}
|
||||||
|
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_NumColorKeys: 2
|
||||||
|
m_NumAlphaKeys: 2
|
||||||
|
numCornerVertices: 0
|
||||||
|
numCapVertices: 4
|
||||||
|
alignment: 0
|
||||||
|
textureMode: 0
|
||||||
|
shadowBias: 0.5
|
||||||
|
generateLightingData: 0
|
||||||
|
m_MinVertexDistance: 0.25
|
||||||
|
m_Autodestruct: 0
|
||||||
|
m_Emitting: 1
|
||||||
--- !u!1 &285182279354310575
|
--- !u!1 &285182279354310575
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 434 KiB After Width: | Height: | Size: 465 KiB |
|
|
@ -272,6 +272,27 @@ TextureImporter:
|
||||||
indices:
|
indices:
|
||||||
edges: []
|
edges: []
|
||||||
weights: []
|
weights: []
|
||||||
|
- serializedVersion: 2
|
||||||
|
name: controllerSheet_0
|
||||||
|
rect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 347
|
||||||
|
y: 1067
|
||||||
|
width: 554
|
||||||
|
height: 902
|
||||||
|
alignment: 0
|
||||||
|
pivot: {x: 0, y: 0}
|
||||||
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
outline: []
|
||||||
|
physicsShape: []
|
||||||
|
tessellationDetail: 0
|
||||||
|
bones: []
|
||||||
|
spriteID: a781f3f6689516247a7cc092438330f7
|
||||||
|
internalID: -974588141
|
||||||
|
vertices: []
|
||||||
|
indices:
|
||||||
|
edges: []
|
||||||
|
weights: []
|
||||||
outline: []
|
outline: []
|
||||||
physicsShape: []
|
physicsShape: []
|
||||||
bones: []
|
bones: []
|
||||||
|
|
@ -283,6 +304,7 @@ TextureImporter:
|
||||||
weights: []
|
weights: []
|
||||||
secondaryTextures: []
|
secondaryTextures: []
|
||||||
nameFileIdTable:
|
nameFileIdTable:
|
||||||
|
controllerSheet_0: -974588141
|
||||||
nxJoyconL: 2557230542604182733
|
nxJoyconL: 2557230542604182733
|
||||||
nxJoyconPair: 8903944674802394384
|
nxJoyconPair: 8903944674802394384
|
||||||
nxJoyconR: 9166690998051772148
|
nxJoyconR: 9166690998051772148
|
||||||
|
|
|
||||||
|
|
@ -9,22 +9,38 @@ namespace HeavenStudio
|
||||||
{
|
{
|
||||||
public class CircleCursor : MonoBehaviour
|
public class CircleCursor : MonoBehaviour
|
||||||
{
|
{
|
||||||
|
static readonly GradientAlphaKey[] cursorAlphaKeys = new GradientAlphaKey[]
|
||||||
|
{
|
||||||
|
new GradientAlphaKey(0.5f, 0),
|
||||||
|
new GradientAlphaKey(0, 1)
|
||||||
|
};
|
||||||
|
|
||||||
[SerializeField] private bool follow = false;
|
[SerializeField] private bool follow = false;
|
||||||
[SerializeField] private float mouseMoveSpeed;
|
[SerializeField] private float mouseMoveSpeed;
|
||||||
|
[SerializeField] private float sideChangeTrailTime;
|
||||||
|
|
||||||
[Header("DSGuy")]
|
[Header("DSGuy")]
|
||||||
[SerializeField] private GameObject DSGuy;
|
[SerializeField] private GameObject DSGuy;
|
||||||
[SerializeField] private Animator DSGuyAnimator;
|
[SerializeField] private Animator DSGuyAnimator;
|
||||||
[SerializeField] private float flickCoeff = 0.35f;
|
[SerializeField] private float flickCoeff = 0.35f;
|
||||||
[SerializeField] private float flickInitMul = 1.5f;
|
[SerializeField] private float flickInitMul = 1.5f;
|
||||||
|
[SerializeField] private TrailRenderer splitTouchSnapEffect;
|
||||||
public GameObject InnerCircle;
|
public GameObject InnerCircle;
|
||||||
[SerializeField] private GameObject Circle;
|
[SerializeField] private GameObject Circle;
|
||||||
private bool isOpen;
|
private bool isOpen;
|
||||||
private Vector3 vel, flickStart, flickDeltaPos;
|
private Vector3 vel, flickStart, flickDeltaPos;
|
||||||
|
private Color colorMain, colorL, colorR;
|
||||||
|
private Gradient gradientL, gradientR;
|
||||||
|
private bool lastLeftRightState;
|
||||||
|
private float trailEnableTime;
|
||||||
|
|
||||||
|
private SpriteRenderer innerCircleRenderer;
|
||||||
|
|
||||||
private void Start()
|
private void Start()
|
||||||
{
|
{
|
||||||
// Cursor.visible = false;
|
// Cursor.visible = false;
|
||||||
|
splitTouchSnapEffect.emitting = false;
|
||||||
|
innerCircleRenderer = InnerCircle.GetComponent<SpriteRenderer>();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Open()
|
private void Open()
|
||||||
|
|
@ -64,6 +80,34 @@ namespace HeavenStudio
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
bool lrState = PlayerInput.GetInputController(1).GetPointerLeftRight();
|
||||||
|
if (PlayerInput.CurrentControlStyle == InputSystem.InputController.ControlStyles.Touch && (GameManager.instance?.GameHasSplitColours ?? false))
|
||||||
|
{
|
||||||
|
if (lrState != lastLeftRightState)
|
||||||
|
{
|
||||||
|
lastLeftRightState = lrState;
|
||||||
|
trailEnableTime = sideChangeTrailTime;
|
||||||
|
splitTouchSnapEffect.emitting = true;
|
||||||
|
|
||||||
|
innerCircleRenderer.color = lastLeftRightState ? colorR : colorL;
|
||||||
|
splitTouchSnapEffect.colorGradient = lastLeftRightState ? gradientR : gradientL;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (trailEnableTime <= 0)
|
||||||
|
{
|
||||||
|
trailEnableTime = 0;
|
||||||
|
splitTouchSnapEffect.emitting = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
trailEnableTime -= Time.deltaTime;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (splitTouchSnapEffect.emitting)
|
||||||
|
{
|
||||||
|
ClearTrail();
|
||||||
|
}
|
||||||
|
|
||||||
gameObject.transform.position = pos;
|
gameObject.transform.position = pos;
|
||||||
if (vel.magnitude > 0.05f)
|
if (vel.magnitude > 0.05f)
|
||||||
{
|
{
|
||||||
|
|
@ -89,11 +133,14 @@ namespace HeavenStudio
|
||||||
else if (PlayerInput.GetIsAction(Minigame.InputAction_FlickRelease))
|
else if (PlayerInput.GetIsAction(Minigame.InputAction_FlickRelease))
|
||||||
{
|
{
|
||||||
Flick(pos, deltaPos * flickInitMul);
|
Flick(pos, deltaPos * flickInitMul);
|
||||||
|
ClearTrail();
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((!PlayerInput.PlayerHasControl()) && isOpen)
|
if ((!PlayerInput.PlayerHasControl()) && isOpen)
|
||||||
{
|
{
|
||||||
Close();
|
Close();
|
||||||
|
ClearTrail();
|
||||||
|
splitTouchSnapEffect.emitting = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -101,6 +148,48 @@ namespace HeavenStudio
|
||||||
public void LockCursor(bool toggle)
|
public void LockCursor(bool toggle)
|
||||||
{
|
{
|
||||||
PlayerInput.GetInputController(1).TogglePointerLock(toggle);
|
PlayerInput.GetInputController(1).TogglePointerLock(toggle);
|
||||||
|
ClearTrail();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void ClearTrail()
|
||||||
|
{
|
||||||
|
splitTouchSnapEffect.Clear();
|
||||||
|
trailEnableTime = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void SetCursorColors(Color main, Color left, Color right)
|
||||||
|
{
|
||||||
|
if (innerCircleRenderer == null) innerCircleRenderer = InnerCircle.GetComponent<SpriteRenderer>();
|
||||||
|
|
||||||
|
colorMain = main;
|
||||||
|
colorL = left;
|
||||||
|
colorR = right;
|
||||||
|
if (PlayerInput.CurrentControlStyle == InputSystem.InputController.ControlStyles.Touch && (GameManager.instance?.GameHasSplitColours ?? false))
|
||||||
|
{
|
||||||
|
innerCircleRenderer.color = lastLeftRightState ? colorR : colorL;
|
||||||
|
gradientL = new Gradient()
|
||||||
|
{
|
||||||
|
colorKeys = new GradientColorKey[]
|
||||||
|
{
|
||||||
|
new GradientColorKey(colorL, 0),
|
||||||
|
new GradientColorKey(colorL, 1)
|
||||||
|
},
|
||||||
|
alphaKeys = cursorAlphaKeys
|
||||||
|
};
|
||||||
|
gradientR = new Gradient()
|
||||||
|
{
|
||||||
|
colorKeys = new GradientColorKey[]
|
||||||
|
{
|
||||||
|
new GradientColorKey(colorR, 0),
|
||||||
|
new GradientColorKey(colorR, 1)
|
||||||
|
},
|
||||||
|
alphaKeys = cursorAlphaKeys
|
||||||
|
};
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
innerCircleRenderer.color = colorMain;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -52,6 +52,16 @@ namespace HeavenStudio
|
||||||
[NonSerialized] public RiqEntity currentSection, nextSection;
|
[NonSerialized] public RiqEntity currentSection, nextSection;
|
||||||
public double sectionProgress { get; private set; }
|
public double sectionProgress { get; private set; }
|
||||||
|
|
||||||
|
public bool GameHasSplitColours
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
var inf = GetGameInfo(currentGame);
|
||||||
|
if (inf == null) return false;
|
||||||
|
return inf.splitColorL != null && inf.splitColorR != null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
bool AudioLoadDone;
|
bool AudioLoadDone;
|
||||||
bool ChartLoadError;
|
bool ChartLoadError;
|
||||||
|
|
||||||
|
|
@ -992,20 +1002,20 @@ namespace HeavenStudio
|
||||||
return eventCaller.minigames.Find(c => c.name == name);
|
return eventCaller.minigames.Find(c => c.name == name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Color colMain;
|
||||||
public void SetCurrentGame(string game, bool useMinigameColor = true)
|
public void SetCurrentGame(string game, bool useMinigameColor = true)
|
||||||
{
|
{
|
||||||
currentGame = game;
|
currentGame = game;
|
||||||
if (GetGameInfo(currentGame) != null)
|
if (GetGameInfo(currentGame) != null)
|
||||||
{
|
{
|
||||||
CircleCursor.InnerCircle.GetComponent<SpriteRenderer>().color = Colors.Hex2RGB(GetGameInfo(currentGame).color);
|
colMain = Colors.Hex2RGB(GetGameInfo(currentGame).color);
|
||||||
if (useMinigameColor) HeavenStudio.StaticCamera.instance.SetAmbientGlowColour(Colors.Hex2RGB(GetGameInfo(currentGame).color), true);
|
CircleCursor.SetCursorColors(colMain, Colors.Hex2RGB(GetGameInfo(currentGame).splitColorL), Colors.Hex2RGB(GetGameInfo(currentGame).splitColorR));
|
||||||
//else HeavenStudio.StaticCamera.instance.SetAmbientGlowColour(HeavenStudio.GameCamera.currentColor, false);
|
if (useMinigameColor) HeavenStudio.StaticCamera.instance.SetAmbientGlowColour(colMain, true);
|
||||||
else HeavenStudio.StaticCamera.instance.SetAmbientGlowColour(Color.black, false);
|
else HeavenStudio.StaticCamera.instance.SetAmbientGlowColour(Color.black, false);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
CircleCursor.InnerCircle.GetComponent<SpriteRenderer>().color = Color.white;
|
CircleCursor.SetCursorColors(Color.white, Color.white, Color.white);
|
||||||
//HeavenStudio.StaticCamera.instance.SetAmbientGlowColour(HeavenStudio.GameCamera.currentColor, false);
|
|
||||||
HeavenStudio.StaticCamera.instance.SetAmbientGlowColour(Color.black, false);
|
HeavenStudio.StaticCamera.instance.SetAmbientGlowColour(Color.black, false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ namespace HeavenStudio.Games.Loaders
|
||||||
{
|
{
|
||||||
public static Minigame AddGame(EventCaller eventCaller)
|
public static Minigame AddGame(EventCaller eventCaller)
|
||||||
{
|
{
|
||||||
return new Minigame("blueBear", "Blue Bear", "b4e6f6", false, false, new List<GameAction>()
|
return new Minigame("blueBear", "Blue Bear", "b4e6f6", "e7e7e7", "bf9d34", false, false, new List<GameAction>()
|
||||||
{
|
{
|
||||||
new GameAction("donut", "Donut")
|
new GameAction("donut", "Donut")
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ namespace HeavenStudio.Games.Loaders
|
||||||
// minigame menu items
|
// minigame menu items
|
||||||
public static Minigame AddGame(EventCaller eventCaller)
|
public static Minigame AddGame(EventCaller eventCaller)
|
||||||
{
|
{
|
||||||
return new Minigame("catchyTune", "Catchy Tune", "f2f2f2", false, false, new List<GameAction>()
|
return new Minigame("catchyTune", "Catchy Tune", "f2f2f2", "ff376c", "f2f2f2", false, false, new List<GameAction>()
|
||||||
{
|
{
|
||||||
new GameAction("orange", "Orange")
|
new GameAction("orange", "Orange")
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -51,7 +51,7 @@ namespace HeavenStudio.Games.Loaders
|
||||||
}
|
}
|
||||||
RiqBeatmap.OnUpdateEntity += MarchUpdater;
|
RiqBeatmap.OnUpdateEntity += MarchUpdater;
|
||||||
|
|
||||||
return new Minigame("marchingOrders", "Marching Orders", "ffb108", false, false, new List<GameAction>()
|
return new Minigame("marchingOrders", "Marching Orders", "ffb108", "ccc001", "f20016", false, false, new List<GameAction>()
|
||||||
{
|
{
|
||||||
new GameAction("bop", "Bop")
|
new GameAction("bop", "Bop")
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -437,6 +437,11 @@ namespace HeavenStudio.Games
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void ToggleSplitColoursDisplay(bool on)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
private void OnDestroy()
|
private void OnDestroy()
|
||||||
{
|
{
|
||||||
foreach (var evt in scheduledInputs)
|
foreach (var evt in scheduledInputs)
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ namespace HeavenStudio.Games.Loaders
|
||||||
{
|
{
|
||||||
public static Minigame AddGame(EventCaller eventCaller)
|
public static Minigame AddGame(EventCaller eventCaller)
|
||||||
{
|
{
|
||||||
return new Minigame("tramAndPauline", "Tram & Pauline", "adb5e7", false, false, new List<GameAction>()
|
return new Minigame("tramAndPauline", "Tram & Pauline", "adb5e7", "ca8b17", "c14fae", false, false, new List<GameAction>()
|
||||||
{
|
{
|
||||||
new GameAction("prepare", "Prepare")
|
new GameAction("prepare", "Prepare")
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1056,5 +1056,10 @@ namespace HeavenStudio.InputSystem
|
||||||
public override void RecentrePointer()
|
public override void RecentrePointer()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override bool GetPointerLeftRight()
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -318,5 +318,10 @@ namespace HeavenStudio.InputSystem
|
||||||
public override void RecentrePointer()
|
public override void RecentrePointer()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override bool GetPointerLeftRight()
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -432,5 +432,10 @@ namespace HeavenStudio.InputSystem
|
||||||
{
|
{
|
||||||
rawPointerPos = ScreenBounds * 0.5f;
|
rawPointerPos = ScreenBounds * 0.5f;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override bool GetPointerLeftRight()
|
||||||
|
{
|
||||||
|
return rawPointerPos.x > ScreenBounds.x * 0.5f;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -275,6 +275,7 @@ namespace HeavenStudio.InputSystem
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public abstract Vector2 GetPointer();
|
public abstract Vector2 GetPointer();
|
||||||
|
public abstract bool GetPointerLeftRight();
|
||||||
public abstract void TogglePointerLock(bool locked);
|
public abstract void TogglePointerLock(bool locked);
|
||||||
public abstract void RecentrePointer();
|
public abstract void RecentrePointer();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -284,7 +284,8 @@ namespace HeavenStudio
|
||||||
public string name;
|
public string name;
|
||||||
public string displayName;
|
public string displayName;
|
||||||
public string color;
|
public string color;
|
||||||
public GameObject holder;
|
public string splitColorL;
|
||||||
|
public string splitColorR;
|
||||||
public bool hidden;
|
public bool hidden;
|
||||||
public bool fxOnly;
|
public bool fxOnly;
|
||||||
public List<GameAction> actions = new List<GameAction>();
|
public List<GameAction> actions = new List<GameAction>();
|
||||||
|
|
@ -337,6 +338,28 @@ namespace HeavenStudio
|
||||||
this.defaultLocale = defaultLocale;
|
this.defaultLocale = defaultLocale;
|
||||||
this.supportedLocales = supportedLocales ?? new List<string>();
|
this.supportedLocales = supportedLocales ?? new List<string>();
|
||||||
this.inferred = inferred;
|
this.inferred = inferred;
|
||||||
|
|
||||||
|
this.splitColorL = null;
|
||||||
|
this.splitColorR = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Minigame(string name, string displayName, string color, string splitColorL, string splitColorR, bool hidden, bool fxOnly, List<GameAction> actions, List<string> tags = null, string assetBundle = "", string defaultLocale = "en", List<string> supportedLocales = null, bool inferred = false)
|
||||||
|
{
|
||||||
|
this.name = name;
|
||||||
|
this.displayName = displayName;
|
||||||
|
this.color = color;
|
||||||
|
this.actions = actions;
|
||||||
|
this.hidden = hidden;
|
||||||
|
this.fxOnly = fxOnly;
|
||||||
|
|
||||||
|
this.tags = tags ?? new List<string>();
|
||||||
|
this.wantAssetBundle = assetBundle;
|
||||||
|
this.defaultLocale = defaultLocale;
|
||||||
|
this.supportedLocales = supportedLocales ?? new List<string>();
|
||||||
|
this.inferred = inferred;
|
||||||
|
|
||||||
|
this.splitColorL = splitColorL;
|
||||||
|
this.splitColorR = splitColorR;
|
||||||
}
|
}
|
||||||
|
|
||||||
public AssetBundle GetLocalizedAssetBundle()
|
public AssetBundle GetLocalizedAssetBundle()
|
||||||
|
|
|
||||||
|
|
@ -2,14 +2,16 @@
|
||||||
%TAG !u! tag:unity3d.com,2011:
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
--- !u!21 &2100000
|
--- !u!21 &2100000
|
||||||
Material:
|
Material:
|
||||||
serializedVersion: 6
|
serializedVersion: 8
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
m_PrefabInstance: {fileID: 0}
|
m_PrefabInstance: {fileID: 0}
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_Name: Invert
|
m_Name: Invert
|
||||||
m_Shader: {fileID: 4800000, guid: 186aee7e6d6053f4f8f0cca0ed3d25ac, type: 3}
|
m_Shader: {fileID: 4800000, guid: 186aee7e6d6053f4f8f0cca0ed3d25ac, type: 3}
|
||||||
m_ShaderKeywords: ETC1_EXTERNAL_ALPHA
|
m_ValidKeywords: []
|
||||||
|
m_InvalidKeywords:
|
||||||
|
- ETC1_EXTERNAL_ALPHA
|
||||||
m_LightmapFlags: 4
|
m_LightmapFlags: 4
|
||||||
m_EnableInstancingVariants: 0
|
m_EnableInstancingVariants: 0
|
||||||
m_DoubleSidedGI: 0
|
m_DoubleSidedGI: 0
|
||||||
|
|
@ -55,6 +57,7 @@ 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}
|
||||||
|
m_Ints: []
|
||||||
m_Floats:
|
m_Floats:
|
||||||
- _BumpScale: 1
|
- _BumpScale: 1
|
||||||
- _Cutoff: 0.5
|
- _Cutoff: 0.5
|
||||||
|
|
@ -75,3 +78,4 @@ Material:
|
||||||
m_Colors:
|
m_Colors:
|
||||||
- _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}
|
||||||
|
m_BuildTextureStacks: []
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue