mirror of
https://github.com/Ryubing/Ryujinx.git
synced 2026-02-20 14:06:51 -05:00
Move solution and projects to src
This commit is contained in:
33
src/Ryujinx.HLE/HOS/Tamper/AtmosphereProgram.cs
Normal file
33
src/Ryujinx.HLE/HOS/Tamper/AtmosphereProgram.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using Ryujinx.HLE.HOS.Services.Hid;
|
||||
using Ryujinx.HLE.HOS.Tamper.Operations;
|
||||
|
||||
namespace Ryujinx.HLE.HOS.Tamper
|
||||
{
|
||||
class AtmosphereProgram : ITamperProgram
|
||||
{
|
||||
private Parameter<long> _pressedKeys;
|
||||
private IOperation _entryPoint;
|
||||
|
||||
public string Name { get; }
|
||||
public bool TampersCodeMemory { get; set; } = false;
|
||||
public ITamperedProcess Process { get; }
|
||||
public bool IsEnabled { get; set; }
|
||||
|
||||
public AtmosphereProgram(string name, ITamperedProcess process, Parameter<long> pressedKeys, IOperation entryPoint)
|
||||
{
|
||||
Name = name;
|
||||
Process = process;
|
||||
_pressedKeys = pressedKeys;
|
||||
_entryPoint = entryPoint;
|
||||
}
|
||||
|
||||
public void Execute(ControllerKeys pressedKeys)
|
||||
{
|
||||
if (IsEnabled)
|
||||
{
|
||||
_pressedKeys.Value = (long)pressedKeys;
|
||||
_entryPoint.Execute();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user