diff --git a/Assets/Plugins/Essgee.Unity/Configuration.cs b/Assets/Plugins/Essgee.Unity/Configuration.cs index 959f804..342ce17 100644 --- a/Assets/Plugins/Essgee.Unity/Configuration.cs +++ b/Assets/Plugins/Essgee.Unity/Configuration.cs @@ -1,7 +1,4 @@ using Essgee.Emulation.Configuration; -using Essgee.Utilities; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; using System.Collections.Generic; using System.Drawing; diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Audio/CGBAudio.cs b/Assets/Plugins/Essgee.Unity/Emulation/Audio/CGBAudio.cs index 4d9144d..cfd2495 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Audio/CGBAudio.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Audio/CGBAudio.cs @@ -1,6 +1,4 @@ -using System.Collections.Generic; - -namespace Essgee.Emulation.Audio +namespace Essgee.Emulation.Audio { public partial class CGBAudio : DMGAudio, IAudio { diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Audio/DMGAudio.cs b/Assets/Plugins/Essgee.Unity/Emulation/Audio/DMGAudio.cs index 7801b62..1974e9f 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Audio/DMGAudio.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Audio/DMGAudio.cs @@ -2,10 +2,7 @@ using Essgee.Exceptions; using Essgee.Utilities; using System; -using System.Collections.Generic; -using System.Linq; using System.Runtime.InteropServices; -using Unity.VisualScripting.Dependencies.Sqlite; namespace Essgee.Emulation.Audio { diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Audio/SN76489.cs b/Assets/Plugins/Essgee.Unity/Emulation/Audio/SN76489.cs index 6541aad..16b4ea9 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Audio/SN76489.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Audio/SN76489.cs @@ -2,12 +2,9 @@ using Essgee.Exceptions; using Essgee.Utilities; using System; -using System.Collections.Generic; using System.Linq; using System.Runtime.InteropServices; -using UnityEngine.Playables; using static Essgee.Emulation.Utilities; -using static UnityEditor.Experimental.AssetDatabaseExperimental.AssetDatabaseCounters; namespace Essgee.Emulation.Audio { @@ -188,7 +185,7 @@ namespace Essgee.Emulation.Audio data.MemberData[nameof(channelCounters)] = channelCounters.ToByteArray(); data.MemberData[nameof(channelOutput)] = channelOutput.ToByteArray(); - data.MemberData[nameof(latchedChannel)] = BitConverter.GetBytes( latchedChannel); + data.MemberData[nameof(latchedChannel)] = BitConverter.GetBytes(latchedChannel); data.MemberData[nameof(latchedType)] = BitConverter.GetBytes(latchedType); data.MemberData[nameof(noiseLfsr)] = BitConverter.GetBytes(noiseLfsr); diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Audio/SegaSMSPSG.cs b/Assets/Plugins/Essgee.Unity/Emulation/Audio/SegaSMSPSG.cs index c6861ea..f624ddd 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Audio/SegaSMSPSG.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Audio/SegaSMSPSG.cs @@ -1,7 +1,4 @@ -using static UnityEditor.Experimental.AssetDatabaseExperimental.AssetDatabaseCounters; -using System; - -namespace Essgee.Emulation.Audio +namespace Essgee.Emulation.Audio { public class SegaSMSPSG : SN76489 { diff --git a/Assets/Plugins/Essgee.Unity/Emulation/CPU/ICPU.cs b/Assets/Plugins/Essgee.Unity/Emulation/CPU/ICPU.cs index cb099bd..0964cc3 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/CPU/ICPU.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/CPU/ICPU.cs @@ -1,6 +1,6 @@ namespace Essgee.Emulation.CPU { - interface ICPU: IAxiStatus + interface ICPU : IAxiStatus { void Startup(); void Shutdown(); diff --git a/Assets/Plugins/Essgee.Unity/Emulation/CPU/SM83.cs b/Assets/Plugins/Essgee.Unity/Emulation/CPU/SM83.cs index e522b7c..ac13172 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/CPU/SM83.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/CPU/SM83.cs @@ -2,7 +2,6 @@ using Essgee.Utilities; using System; using System.Linq; -using Unity.VisualScripting; using static Essgee.Emulation.Utilities; namespace Essgee.Emulation.CPU diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/ICartridge.cs b/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/ICartridge.cs index afc1357..3926b7d 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/ICartridge.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/ICartridge.cs @@ -1,6 +1,6 @@ namespace Essgee.Emulation.Cartridges { - internal interface ICartridge :IAxiStatus + internal interface ICartridge : IAxiStatus { void LoadRom(byte[] data); void LoadRam(byte[] data); diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/CodemastersCartridge.cs b/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/CodemastersCartridge.cs index 9a06c89..83ed6be 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/CodemastersCartridge.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/CodemastersCartridge.cs @@ -29,7 +29,7 @@ namespace Essgee.Emulation.Cartridges.Sega ramData = data.MemberData[nameof(ramData)]; pagingRegisters = data.MemberData[nameof(pagingRegisters)]; bankMask = data.MemberData[nameof(bankMask)].First(); - isRamEnabled = BitConverter.ToBoolean( data.MemberData[nameof(isRamEnabled)]); + isRamEnabled = BitConverter.ToBoolean(data.MemberData[nameof(isRamEnabled)]); } public AxiEssgssStatusData SaveAxiStatus() diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/Multicart4PakAllActionCartridge.cs b/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/Multicart4PakAllActionCartridge.cs index 244f33f..696f8e0 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/Multicart4PakAllActionCartridge.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/Multicart4PakAllActionCartridge.cs @@ -1,7 +1,6 @@ using Essgee.Exceptions; using Essgee.Utilities; using System; -using UnityEngine.Playables; namespace Essgee.Emulation.Cartridges.Sega { diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/SegaSGCartridge.cs b/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/SegaSGCartridge.cs index 3eb12cd..7ae290d 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/SegaSGCartridge.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Cartridges/Sega/SegaSGCartridge.cs @@ -1,7 +1,6 @@ using Essgee.Utilities; using System; using System.Linq; -using UnityEngine.Playables; namespace Essgee.Emulation.Cartridges.Sega { diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/ColecoVision.cs b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/ColecoVision.cs index 761ae47..adf3eb4 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/ColecoVision.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/ColecoVision.cs @@ -1,6 +1,4 @@ using Essgee.Utilities; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; namespace Essgee.Emulation.Configuration { diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameBoy.cs b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameBoy.cs index a0a6691..7f548ff 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameBoy.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameBoy.cs @@ -2,7 +2,6 @@ using Essgee.Emulation.ExtDevices.Nintendo; using Essgee.Utilities; using Newtonsoft.Json; -using Newtonsoft.Json.Converters; using System; namespace Essgee.Emulation.Configuration diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameBoyColor.cs b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameBoyColor.cs index 83e929f..6c9ec40 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameBoyColor.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameBoyColor.cs @@ -2,7 +2,6 @@ using Essgee.Emulation.ExtDevices.Nintendo; using Essgee.Utilities; using Newtonsoft.Json; -using Newtonsoft.Json.Converters; using System; namespace Essgee.Emulation.Configuration diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameGear.cs b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameGear.cs index 9297077..3218d10 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameGear.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/GameGear.cs @@ -1,6 +1,4 @@ using Essgee.Utilities; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; namespace Essgee.Emulation.Configuration { diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/MasterSystem.cs b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/MasterSystem.cs index b6fc569..6ba97dc 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/MasterSystem.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/MasterSystem.cs @@ -1,6 +1,4 @@ using Essgee.Utilities; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; namespace Essgee.Emulation.Configuration { diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/SC3000.cs b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/SC3000.cs index 6c82e4a..36a31ac 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/SC3000.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/SC3000.cs @@ -1,7 +1,4 @@ -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; - -namespace Essgee.Emulation.Configuration +namespace Essgee.Emulation.Configuration { //todo Unity [ElementPriority(1)] public class SC3000 : IConfiguration diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/SG1000.cs b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/SG1000.cs index 3a8eca4..112d811 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Configuration/SG1000.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Configuration/SG1000.cs @@ -1,7 +1,4 @@ -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; - -namespace Essgee.Emulation.Configuration +namespace Essgee.Emulation.Configuration { //todo Unity [ElementPriority(0)] public class SG1000 : IConfiguration diff --git a/Assets/Plugins/Essgee.Unity/Emulation/EmulatorHandler.cs b/Assets/Plugins/Essgee.Unity/Emulation/EmulatorHandler.cs index 2db6fe3..a4bbc62 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/EmulatorHandler.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/EmulatorHandler.cs @@ -5,7 +5,6 @@ using Essgee.Metadata; using Essgee.Utilities; using System; using System.Collections.Generic; -using System.Diagnostics; using System.IO; using System.Threading; diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Machines/ColecoVision.cs b/Assets/Plugins/Essgee.Unity/Emulation/Machines/ColecoVision.cs index def33c1..fab8dd1 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Machines/ColecoVision.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Machines/ColecoVision.cs @@ -263,7 +263,7 @@ namespace Essgee.Emulation.Machines vdp.LoadAxiStatus(data.ClassData[nameof(vdp)]); psg.LoadAxiStatus(data.ClassData[nameof(psg)]); - portControls1 = BitConverter.ToUInt16( data.MemberData[nameof(portControls1)]); + portControls1 = BitConverter.ToUInt16(data.MemberData[nameof(portControls1)]); portControls2 = BitConverter.ToUInt16(data.MemberData[nameof(portControls2)]); controlsReadMode = data.MemberData[nameof(controlsReadMode)].First(); isNmi = BitConverter.ToBoolean(data.MemberData[nameof(isNmi)]); diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Machines/GameGear.cs b/Assets/Plugins/Essgee.Unity/Emulation/Machines/GameGear.cs index 2e5e1d6..d218db4 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Machines/GameGear.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Machines/GameGear.cs @@ -326,14 +326,14 @@ namespace Essgee.Emulation.Machines { AxiEssgssStatusData data = new AxiEssgssStatusData(); data.MemberData[nameof(configuration.Region)] = configuration.Region.ToByteArray(); - + data.ClassData[nameof(bootstrap)] = bootstrap.SaveAxiStatus(); data.ClassData[nameof(cartridge)] = cartridge.SaveAxiStatus(); data.MemberData[nameof(wram)] = wram; data.ClassData[nameof(cpu)] = cpu.SaveAxiStatus(); data.ClassData[nameof(vdp)] = vdp.SaveAxiStatus(); data.ClassData[nameof(psg)] = psg.SaveAxiStatus(); - + data.MemberData[nameof(portMemoryControl)] = BitConverter.GetBytes(portMemoryControl); data.MemberData[nameof(portIoControl)] = BitConverter.GetBytes(portIoControl); data.MemberData[nameof(hCounterLatched)] = BitConverter.GetBytes(hCounterLatched); diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Machines/IMachine.cs b/Assets/Plugins/Essgee.Unity/Emulation/Machines/IMachine.cs index e4450e9..287915c 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Machines/IMachine.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Machines/IMachine.cs @@ -5,7 +5,7 @@ using System.Collections.Generic; namespace Essgee.Emulation.Machines { - public interface IMachine:IAxiStatus + public interface IMachine : IAxiStatus { event EventHandler SendLogMessage; event EventHandler EmulationReset; diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Machines/MasterSystem.cs b/Assets/Plugins/Essgee.Unity/Emulation/Machines/MasterSystem.cs index b5d8ef4..6b4725f 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Machines/MasterSystem.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Machines/MasterSystem.cs @@ -340,9 +340,9 @@ namespace Essgee.Emulation.Machines { AxiEssgssStatusData data = new AxiEssgssStatusData(); data.MemberData[nameof(configuration.TVStandard)] = configuration.TVStandard.ToByteArray(); - data.MemberData[nameof(configuration.Region)] = configuration.Region.ToByteArray(); + data.MemberData[nameof(configuration.Region)] = configuration.Region.ToByteArray(); - if(bootstrap != null) + if (bootstrap != null) data.ClassData[nameof(bootstrap)] = bootstrap.SaveAxiStatus(); data.ClassData[nameof(cartridge)] = cartridge.SaveAxiStatus(); diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaGGVDP.cs b/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaGGVDP.cs index bea4985..3986fab 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaGGVDP.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaGGVDP.cs @@ -1,7 +1,6 @@ using Essgee.EventArguments; using Essgee.Utilities; using System; -using System.Runtime.InteropServices; using static Essgee.Emulation.Utilities; namespace Essgee.Emulation.Video diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaSMSVDP.cs b/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaSMSVDP.cs index d99e900..f856c14 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaSMSVDP.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaSMSVDP.cs @@ -4,8 +4,6 @@ using System; using System.Diagnostics; using System.Linq; using System.Runtime.InteropServices; -using Unity.Mathematics; -using Unity.VisualScripting; using static Essgee.Emulation.Utilities; namespace Essgee.Emulation.Video diff --git a/Assets/Plugins/Essgee.Unity/Emulation/Video/TMS99xxA.cs b/Assets/Plugins/Essgee.Unity/Emulation/Video/TMS99xxA.cs index c0983bd..46edd5f 100644 --- a/Assets/Plugins/Essgee.Unity/Emulation/Video/TMS99xxA.cs +++ b/Assets/Plugins/Essgee.Unity/Emulation/Video/TMS99xxA.cs @@ -5,7 +5,6 @@ using System.Diagnostics; using System.Linq; using System.Runtime.InteropServices; using static Essgee.Emulation.Utilities; -using static UnityEditor.Experimental.AssetDatabaseExperimental.AssetDatabaseCounters; namespace Essgee.Emulation.Video { diff --git a/Assets/Plugins/Essgee.Unity/EventArguments/EnqueueSamplesEventArgs.cs b/Assets/Plugins/Essgee.Unity/EventArguments/EnqueueSamplesEventArgs.cs index 5f4e193..181c663 100644 --- a/Assets/Plugins/Essgee.Unity/EventArguments/EnqueueSamplesEventArgs.cs +++ b/Assets/Plugins/Essgee.Unity/EventArguments/EnqueueSamplesEventArgs.cs @@ -20,7 +20,7 @@ namespace Essgee.EventArguments //} //public static EnqueueSamplesEventArgs Create(int numChannels, short[][] channelSamples, bool[] isMuted, short[] mixedSamples) - public static EnqueueSamplesEventArgs Create(int numChannels, short*[] channelSamples, bool[] isMuted, short* mixedSamples,int mixedSamplesLength) + public static EnqueueSamplesEventArgs Create(int numChannels, short*[] channelSamples, bool[] isMuted, short* mixedSamples, int mixedSamplesLength) { var eventArgs = ObjectPoolAuto.Acquire(); eventArgs.NumChannels = numChannels; diff --git a/Assets/Plugins/Essgee.Unity/IAxiStatus.cs b/Assets/Plugins/Essgee.Unity/IAxiStatus.cs index a683da8..64c9382 100644 --- a/Assets/Plugins/Essgee.Unity/IAxiStatus.cs +++ b/Assets/Plugins/Essgee.Unity/IAxiStatus.cs @@ -1,10 +1,8 @@ -using Essgee.Utilities; using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Runtime.Serialization.Formatters.Binary; -using System.Text; [Serializable] public class AxiEssgssStatusData diff --git a/Assets/Plugins/Essgee.Unity/Metadata/GameMetadataHandler.cs b/Assets/Plugins/Essgee.Unity/Metadata/GameMetadataHandler.cs index 7fce547..3eba71b 100644 --- a/Assets/Plugins/Essgee.Unity/Metadata/GameMetadataHandler.cs +++ b/Assets/Plugins/Essgee.Unity/Metadata/GameMetadataHandler.cs @@ -18,7 +18,7 @@ namespace Essgee.Metadata public interface IGameMetaReources { public bool GetCartMetadataDatabase(out string loadedData); - public bool GetDatBytes(string DatName,out byte[] loadedData); + public bool GetDatBytes(string DatName, out byte[] loadedData); } public class GameMetadataHandler @@ -37,7 +37,7 @@ namespace Essgee.Metadata { gameMetaReources = metaresources; - if(!gameMetaReources.GetCartMetadataDatabase(out string loadedData)) + if (!gameMetaReources.GetCartMetadataDatabase(out string loadedData)) throw new HandlerException("CartMetadataDatabase file not found"); cartMetadataDatabase = JsonConvert.DeserializeObject>(loadedData);