public void PlayMacro(List <DualShockState> sequence, int suspendDelay = 0) { MacroPlayer.Sequence = ScriptHostUtility.ConvertAPIToInterceptorSequence(sequence); MacroPlayer.Play(); if (suspendDelay > 0) { Suspend(suspendDelay); } }
public void OnReceiveData(ref PS4RemotePlayInterceptor.DualShockState state) { if (MacroPlayer.IsPlaying) { MacroPlayer.OnReceiveData(ref state); } else if (Script.CurrentState != null) { state = ScriptHostUtility.ConvertAPIToInterceptorState(Script.CurrentState); state.ReportTimeStamp = DateTime.Now; // Replace battery status state.Battery = 100; state.IsCharging = true; } }