com.tunnelsnakes.audiosystem 1.1.3 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,20 +1,28 @@
|
|
|
1
|
+
//#undef MOREMOUNTAINS_NICEVIBRATIONS_INSTALLED
|
|
2
|
+
//#define MOREMOUNTAINS_NICEVIBRATIONS
|
|
1
3
|
using System.Collections;
|
|
2
4
|
using System.Collections.Generic;
|
|
3
5
|
using UnityEngine;
|
|
4
|
-
#if
|
|
6
|
+
#if MOREMOUNTAINS_NICEVIBRATIONS_INSTALLED
|
|
7
|
+
using Lofelt.NiceVibrations;
|
|
8
|
+
#elif MOREMOUNTAINS_NICEVIBRATIONS
|
|
5
9
|
using MoreMountains.NiceVibrations;
|
|
6
10
|
#endif
|
|
7
11
|
|
|
8
|
-
[CreateAssetMenu(fileName = nameof(
|
|
9
|
-
public class
|
|
12
|
+
[CreateAssetMenu(fileName = nameof(HapticPresetVibration), menuName = MENU_FOLDER + nameof(HapticPresetVibration))]
|
|
13
|
+
public class HapticPresetVibration : Vibration {
|
|
10
14
|
|
|
11
|
-
#if
|
|
15
|
+
#if MOREMOUNTAINS_NICEVIBRATIONS_INSTALLED
|
|
16
|
+
[SerializeField] private HapticPatterns.PresetType _type = HapticPatterns.PresetType.None;
|
|
17
|
+
#elif MOREMOUNTAINS_NICEVIBRATIONS
|
|
12
18
|
[SerializeField] private HapticTypes _type = HapticTypes.None;
|
|
13
19
|
#endif
|
|
14
20
|
|
|
15
21
|
public override void Vibrate() {
|
|
16
22
|
if (CanVibrate) {
|
|
17
|
-
#if
|
|
23
|
+
#if MOREMOUNTAINS_NICEVIBRATIONS_INSTALLED
|
|
24
|
+
HapticPatterns.PlayPreset(_type);
|
|
25
|
+
#elif MOREMOUNTAINS_NICEVIBRATIONS
|
|
18
26
|
MMVibrationManager.Haptic(_type, false, true, null);
|
|
19
27
|
#else
|
|
20
28
|
#if UNITY_EDITOR
|
|
@@ -1,18 +1,20 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "com.tunnelsnakes.audiosystem.Runtime",
|
|
3
|
-
"
|
|
4
|
-
|
|
5
|
-
"GUID:
|
|
6
|
-
"GUID:
|
|
7
|
-
"GUID:
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"
|
|
1
|
+
{
|
|
2
|
+
"name": "com.tunnelsnakes.audiosystem.Runtime",
|
|
3
|
+
"rootNamespace": "",
|
|
4
|
+
"references": [
|
|
5
|
+
"GUID:ec99747e8eb95ee488f6cfa3a8e647b9",
|
|
6
|
+
"GUID:041029188fa88c54f9efffc039b6a1c9",
|
|
7
|
+
"GUID:865b414a121ed594e91db2e09f65d38c",
|
|
8
|
+
"GUID:c5c32a628b9233446bcce7f67a49d1f4",
|
|
9
|
+
"GUID:57a0b9bc628ab4740af4b6f1f0b2e134"
|
|
10
|
+
],
|
|
11
|
+
"includePlatforms": [],
|
|
12
|
+
"excludePlatforms": [],
|
|
13
|
+
"allowUnsafeCode": false,
|
|
14
|
+
"overrideReferences": false,
|
|
15
|
+
"precompiledReferences": [],
|
|
16
|
+
"autoReferenced": true,
|
|
17
|
+
"defineConstraints": [],
|
|
18
|
+
"versionDefines": [],
|
|
19
|
+
"noEngineReferences": false
|
|
18
20
|
}
|