wangguan
2020-12-29 452c75675679c44cc39b04bdb7d330d7c5c14d5c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
 
namespace MoreMountains.NiceVibrations
{
    /// <summary>
    /// A class used to store android waveform values, used to trigger haptics with varying intensity
    /// </summary>
    [System.Serializable]
    public class MMNVRumbleWaveForm
    {
        public long[] Pattern;
        public int[] LowFrequencyAmplitudes;
        public int[] HighFrequencyAmplitudes;
    }
    
    /// <summary>
    /// A scriptable object used to store waveform values
    /// </summary>
    [CreateAssetMenu(fileName = "RumbleWaveFormAsset", menuName = "MoreMountains/NiceVibrations/RumbleWaveFormAsset")]
    public class MMNVRumbleWaveFormAsset : ScriptableObject
    {
        [Header("Properties")]
        public MMNVRumbleWaveForm WaveForm;
 
        [Header("AHAP")]
        public TextAsset AHAPFile;
        public float IntensityMultiplier = 1f;
        public float SharpnessMultiplier = 1f;
    }
}