public VirtualTimer(PspEmulatorContext PspEmulatorContext, string Name) { PspEmulatorContext.InjectDependencesTo(this); this.Timer = PspRtc.CreateVirtualTimer(Handler); this.Name = Name; this.Timer.Enabled = false; this.PspSharedInfoMemoryPartition = MemoryManager.GetPartition(HleMemoryManager.Partitions.Kernel0).Allocate( sizeof(PspSharedInfoStruct), Name: "VTimer.PspSharedInfoStruct" ); this.PspSharedInfo = (PspSharedInfoStruct*)CpuProcessor.Memory.PspAddressToPointerSafe(this.PspSharedInfoMemoryPartition.Low); }
public VirtualTimer(InjectContext InjectContext, string Name) { InjectContext.InjectDependencesTo(this); this.Timer = PspRtc.CreateVirtualTimer(Handler); this.Name = Name; this.Timer.Enabled = false; this.PspSharedInfoMemoryPartition = MemoryManager.GetPartition(MemoryPartitions.Kernel0).Allocate( sizeof(PspSharedInfoStruct), Name: "VTimer.PspSharedInfoStruct" ); this.PspSharedInfo = (PspSharedInfoStruct *)CpuProcessor.Memory.PspAddressToPointerSafe( this.PspSharedInfoMemoryPartition.Low); }