private void Read(DebuggerProcess OwningProcess, Patch PatchItem)
        {
            int Size = PatchSize(ref PatchItem);

            if (Size > 0)
            {
                byte[] Current = OwningProcess.ReadMemoryBlock(new IntPtr(PatchItem.Offset), (uint)Size);
                PatchItem.Original = Current;
            }
        }
Beispiel #2
0
        public string Read(DebuggerProcess OwningProcess, Patch PatchItem)
        {
            int Size = PatchSize(PatchItem);

            if (Size == 0)
            {
                return("");
            }

            byte[] Current = OwningProcess.ReadMemoryBlock(new IntPtr(PatchItem.Offset), (uint)Size);
            return(Format(PatchItem.DisplayAs, Current));
        }
 private void Setup(DebuggerProcess OwningProcess, Patch PatchItem)
 {
     if (PatchItem.Original == null)
     {
         int Size = PatchSize(ref PatchItem);
         if (Size > 0)
         {
             byte[] Current = OwningProcess.ReadMemoryBlock(new IntPtr(PatchItem.Offset), (uint)Size);
             if (Current != null)
             {
                 PatchItem.Original = Current;
                 Apply(OwningProcess, PatchItem);
             }
         }
     }
 }