Difference between revisions of "Tutorials:Auto Assembler:Setup test table"

From Cheat Engine
Jump to navigation Jump to search
(Created page with '<!-- http://pinetools.com/syntax-highlighter --> <!-- x86asm --> <!-- Monokai Sublime --> == Setup auto assembler test table == Let's setup an auto assembler test table. Open t…')
 
Line 1: Line 1:
 
<!-- http://pinetools.com/syntax-highlighter -->
 
<!-- http://pinetools.com/syntax-highlighter -->
 
<!-- x86asm -->
 
<!-- x86asm -->
 +
<!-- XML -->
 
<!-- Monokai Sublime -->
 
<!-- Monokai Sublime -->
 
== Setup auto assembler test table ==
 
== Setup auto assembler test table ==
Line 12: Line 13:
 
Let's '''add so code to allocate some global memory for test assembling and value storing'''.
 
Let's '''add so code to allocate some global memory for test assembling and value storing'''.
  
<pre>//// --------------------  Main Section  ---------------------
+
<!-- <pre>//// --------------------  Main Section  ---------------------
 
globalAlloc(TestVals, 0x40) //// Globally allocates memory, same as 'alloc' with 'registerSymbol'
 
globalAlloc(TestVals, 0x40) //// Globally allocates memory, same as 'alloc' with 'registerSymbol'
 
globalAlloc(memTest, 0x200)
 
globalAlloc(memTest, 0x200)
Line 18: Line 19:
 
//// --------------------  Enable Section  ---------------------
 
//// --------------------  Enable Section  ---------------------
 
memTest: //// Start assembling as this address (memTest)
 
memTest: //// Start assembling as this address (memTest)
  // START: Test code
+
    // START: Test code
  
  // END: Test code
+
    // END: Test code
  ret //// return, needed for ending the threads
+
    ret //// return, needed for ending the threads
 
[DISABLE]
 
[DISABLE]
 
//// --------------------  Disable Section  --------------------
 
//// --------------------  Disable Section  --------------------
 
//// Reset memTest and TestVals
 
//// Reset memTest and TestVals
 
memTest:
 
memTest:
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  // 0x100
+
    // 0x100
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
  db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 C3 //// An extra ret just in case
+
    db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 C3 //// An extra ret just in case
  // 0x200
+
    // 0x200
 
TestVals:
 
TestVals:
  db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+
    db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+
    db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+
    db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
+
    db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
</pre>
+
</pre> -->
 +
<p style="white-space:pre;font-family:'Lucida Console';display: block; overflow-x: auto; padding: 0.5em; background: rgb(35, 36, 31); color: rgb(248, 248, 242);"><span style="color: rgb(117, 113, 94);">//// --------------------  Main Section  ---------------------</span>
 +
globalAlloc(TestVals, <span style="color: rgb(174, 129, 255);">0x40</span>) <span style="color: rgb(117, 113, 94);">//// Globally allocates memory, same as 'alloc' with 'registerSymbol'</span>
 +
globalAlloc(memTest, <span style="color: rgb(174, 129, 255);">0x200</span>)
 +
<span style="color:pink;font-weight:bold;">[ENABLE]</span>
 +
<span style="color: rgb(117, 113, 94);">//// --------------------  Enable Section  ---------------------</span>
 +
<span style="color: rgb(102, 217, 239);">memTest:</span> <span style="color: rgb(117, 113, 94);">//// Start assembling as this address (memTest)</span>
 +
    <span style="color: rgb(117, 113, 94);">// START: Test code</span>
  
 +
    <span style="color: rgb(117, 113, 94);">// END: Test code</span>
 +
    <span style="color: rgb(249, 38, 114);">ret</span> <span style="color: rgb(117, 113, 94);">//// return, needed for ending the threads</span>
 +
<span style="color:pink;font-weight:bold;">[DISABLE]</span>
 +
<span style="color: rgb(117, 113, 94);">//// --------------------  Disable Section  --------------------</span>
 +
<span style="color: rgb(117, 113, 94);">//// Reset memTest and TestVals</span>
 +
<span style="color: rgb(102, 217, 239);">memTest:</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(117, 113, 94);">// 0x100</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 C3</span> <span style="color: rgb(117, 113, 94);">//// An extra ret just in case</span>
 +
    <span style="color: rgb(117, 113, 94);">// 0x200</span>
 +
 +
<span style="color: rgb(102, 217, 239);">TestVals:</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00</span>
 +
    <span style="color: rgb(230, 219, 116);">db</span> <span style="color: rgb(174, 129, 255);">00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00</span>
 +
</p>
  
 
Now '''add that to the table''', and set it's description to 'Test Script'
 
Now '''add that to the table''', and set it's description to 'Test Script'
 
:If you are unsure how to do that check here: [[Tutorials:AddScriptToTable|How to add script to table]]
 
:If you are unsure how to do that check here: [[Tutorials:AddScriptToTable|How to add script to table]]
 +
  
 
Now we need a script to start a new thread in the test memory we will be using.
 
Now we need a script to start a new thread in the test memory we will be using.
<pre>[ENABLE]
+
<!-- <pre>[ENABLE]
 
createThread(memTest)
 
createThread(memTest)
 
[DISABLE]
 
[DISABLE]
</pre>
+
</pre> -->
 +
<p style="white-space:pre;font-family:'Lucida Console';display: block; overflow-x: auto; padding: 0.5em; background: rgb(35, 36, 31); color: rgb(248, 248, 242);"><span style="color: rgb(117, 113, 94);">//// --------------------  Main Section  ---------------------</span>
 +
<span style="color:pink;font-weight:bold;">[ENABLE]</span>
 +
<span style="color: rgb(117, 113, 94);">//// --------------------  Enable Section  ---------------------</span>
 +
createThread(memTest) <span style="color: rgb(117, 113, 94);">//// Create and start thread</span>
 +
<span style="color:pink;font-weight:bold;">[DISABLE]</span>
 +
<span style="color: rgb(117, 113, 94);">//// --------------------  Disable Section  --------------------</span>
 +
</p>
  
 
Now '''add that to the table''', set it's description to 'Create Thread', and make it a child of the first script.
 
Now '''add that to the table''', set it's description to 'Create Thread', and make it a child of the first script.
Line 120: Line 183:
 
#* Type: Double
 
#* Type: Double
  
<pre><?xml version="1.0" encoding="utf-8"?>
+
<!-- <pre><?xml version="1.0" encoding="utf-8"?>
 
<CheatTable>
 
<CheatTable>
 
   <CheatEntries>
 
   <CheatEntries>
    <CheatEntry>
+
    <CheatEntry>
      <ID>0</ID>
+
        <ID>0</ID>
      <Description>"memTest"</Description>
+
        <Description>"memTest"</Description>
      <LastState Value="" RealAddress="00000000"/>
+
        <LastState Value="" RealAddress="00000000"/>
      <ShowAsHex>1</ShowAsHex>
+
        <ShowAsHex>1</ShowAsHex>
      <VariableType>Array of byte</VariableType>
+
        <VariableType>Array of byte</VariableType>
      <ByteLength>0</ByteLength>
+
        <ByteLength>0</ByteLength>
      <Address>memTest</Address>
+
        <Address>memTest</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>1</ID>
+
        <ID>1</ID>
      <Description>"TestVals"</Description>
+
        <Description>"TestVals"</Description>
      <LastState Value="" RealAddress="00000000"/>
+
        <LastState Value="" RealAddress="00000000"/>
      <VariableType>Array of byte</VariableType>
+
        <VariableType>Array of byte</VariableType>
      <ByteLength>0</ByteLength>
+
        <ByteLength>0</ByteLength>
      <Address>TestVals</Address>
+
        <Address>TestVals</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>2</ID>
+
        <ID>2</ID>
      <Description>"TestVals+0"</Description>
+
        <Description>"TestVals+0"</Description>
      <VariableType>4 Bytes</VariableType>
+
        <VariableType>4 Bytes</VariableType>
      <Address>TestVals+0</Address>
+
        <Address>TestVals+0</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>3</ID>
+
        <ID>3</ID>
      <Description>"TestVals+4"</Description>
+
        <Description>"TestVals+4"</Description>
      <VariableType>4 Bytes</VariableType>
+
        <VariableType>4 Bytes</VariableType>
      <Address>TestVals+4</Address>
+
        <Address>TestVals+4</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>4</ID>
+
        <ID>4</ID>
      <Description>"TestVals+8"</Description>
+
        <Description>"TestVals+8"</Description>
      <VariableType>4 Bytes</VariableType>
+
        <VariableType>4 Bytes</VariableType>
      <Address>TestVals+8</Address>
+
        <Address>TestVals+8</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>5</ID>
+
        <ID>5</ID>
      <Description>"TestVals+C"</Description>
+
        <Description>"TestVals+C"</Description>
      <VariableType>4 Bytes</VariableType>
+
        <VariableType>4 Bytes</VariableType>
      <Address>TestVals+C</Address>
+
        <Address>TestVals+C</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>6</ID>
+
        <ID>6</ID>
      <Description>"TestVals+0"</Description>
+
        <Description>"TestVals+0"</Description>
      <VariableType>8 Bytes</VariableType>
+
        <VariableType>8 Bytes</VariableType>
      <Address>TestVals+0</Address>
+
        <Address>TestVals+0</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>7</ID>
+
        <ID>7</ID>
      <Description>"TestVals+8"</Description>
+
        <Description>"TestVals+8"</Description>
      <VariableType>8 Bytes</VariableType>
+
        <VariableType>8 Bytes</VariableType>
      <Address>TestVals+8</Address>
+
        <Address>TestVals+8</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>8</ID>
+
        <ID>8</ID>
      <Description>"TestVals+0"</Description>
+
        <Description>"TestVals+0"</Description>
      <VariableType>Float</VariableType>
+
        <VariableType>Float</VariableType>
      <Address>TestVals+0</Address>
+
        <Address>TestVals+0</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>9</ID>
+
        <ID>9</ID>
      <Description>"TestVals+4"</Description>
+
        <Description>"TestVals+4"</Description>
      <VariableType>Float</VariableType>
+
        <VariableType>Float</VariableType>
      <Address>TestVals+4</Address>
+
        <Address>TestVals+4</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>10</ID>
+
        <ID>10</ID>
      <Description>"TestVals+8"</Description>
+
        <Description>"TestVals+8"</Description>
      <VariableType>Float</VariableType>
+
        <VariableType>Float</VariableType>
      <Address>TestVals+8</Address>
+
        <Address>TestVals+8</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>11</ID>
+
        <ID>11</ID>
      <Description>"TestVals+C"</Description>
+
        <Description>"TestVals+C"</Description>
      <VariableType>Float</VariableType>
+
        <VariableType>Float</VariableType>
      <Address>TestVals+C</Address>
+
        <Address>TestVals+C</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>12</ID>
+
        <ID>12</ID>
      <Description>"TestVals+0"</Description>
+
        <Description>"TestVals+0"</Description>
      <VariableType>Double</VariableType>
+
        <VariableType>Double</VariableType>
      <Address>TestVals+0</Address>
+
        <Address>TestVals+0</Address>
    </CheatEntry>
+
    </CheatEntry>
    <CheatEntry>
+
    <CheatEntry>
      <ID>13</ID>
+
        <ID>13</ID>
      <Description>"TestVals+8"</Description>
+
        <Description>"TestVals+8"</Description>
      <VariableType>Double</VariableType>
+
        <VariableType>Double</VariableType>
      <Address>TestVals+8</Address>
+
        <Address>TestVals+8</Address>
    </CheatEntry>
+
    </CheatEntry>
 
   </CheatEntries>
 
   </CheatEntries>
 
</CheatTable>
 
</CheatTable>
</pre>
+
</pre> -->
 +
<p style="white-space:pre;font-family:'Lucida Console';display: block; overflow-x: auto; padding: 0.5em; background: rgb(35, 36, 31); color: rgb(248, 248, 242);"><span class="php"><span style="color: rgb(117, 113, 94);">&lt;?</span>xml version=<span style="color: rgb(230, 219, 116);">"1.0"</span> encoding=<span style="color: rgb(230, 219, 116);">"utf-8"</span><span style="color: rgb(117, 113, 94);">?&gt;</span></span>
 +
<span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatTable</span>&gt;</span>
 +
  <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntries</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>0<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"memTest"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">LastState</span> <span style="color: rgb(249, 38, 114);">Value</span>=<span style="color: rgb(230, 219, 116);">""</span> <span style="color: rgb(249, 38, 114);">RealAddress</span>=<span style="color: rgb(230, 219, 116);">"00000000"</span>/&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ShowAsHex</span>&gt;</span>1<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ShowAsHex</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>Array of byte<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ByteLength</span>&gt;</span>0<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ByteLength</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>memTest<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>1<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">LastState</span> <span style="color: rgb(249, 38, 114);">Value</span>=<span style="color: rgb(230, 219, 116);">""</span> <span style="color: rgb(249, 38, 114);">RealAddress</span>=<span style="color: rgb(230, 219, 116);">"00000000"</span>/&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>Array of byte<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ByteLength</span>&gt;</span>0<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ByteLength</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>2<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+0"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>4 Bytes<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+0<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>3<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+4"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>4 Bytes<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+4<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>4<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+8"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>4 Bytes<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+8<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>5<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+C"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>4 Bytes<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+C<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>6<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+0"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>8 Bytes<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+0<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>7<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+8"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>8 Bytes<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+8<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>8<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+0"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>Float<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+0<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>9<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+4"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>Float<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+4<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>10<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+8"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>Float<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+8<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>11<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+C"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>Float<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+C<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>12<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+0"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>Double<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+0<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>13<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">ID</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>"TestVals+8"<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Description</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>Double<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">VariableType</span>&gt;</span>
 +
        <span style="color: rgb(248, 248, 242);">&lt;<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>TestVals+8<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">Address</span>&gt;</span>
 +
    <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntry</span>&gt;</span>
 +
  <span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatEntries</span>&gt;</span>
 +
<span style="color: rgb(248, 248, 242);">&lt;/<span style="color: rgb(249, 38, 114);">CheatTable</span>&gt;</span></p>
  
  
Line 243: Line 400:
 
== Example scripts ==
 
== Example scripts ==
 
'''Testing [[Assembler:Commands:MUL|MUL]]''':
 
'''Testing [[Assembler:Commands:MUL|MUL]]''':
<pre>...
+
<!-- <pre>...
  // START: Test code
+
    // START: Test code
  mov eax,2
+
    mov eax,2
  mox ecx,3
+
    mov ecx,3
  mul ecx
+
    mul ecx
  mov [TestVals+0],edx
+
    mov [TestVals+0],edx
  mov [TestVals+4],eax
+
    mov [TestVals+4],eax
  mov [TestVals+8],ecx
+
    mov [TestVals+8],ecx
  // END: Test code
+
    // END: Test code
 
...
 
...
</pre>
+
</pre> -->
 +
<p style="white-space:pre;font-family:'Lucida Console';display: block; overflow-x: auto; padding: 0.5em; background: rgb(35, 36, 31); color: rgb(248, 248, 242);"><span style="color: rgb(117, 113, 94);">...</span>
 +
    <span style="color: rgb(117, 113, 94);">// START: Test code</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> <span style="color: rgb(230, 219, 116);">eax</span>,<span style="color: rgb(174, 129, 255);">2</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> <span style="color: rgb(230, 219, 116);">ecx</span>,<span style="color: rgb(174, 129, 255);">3</span>
 +
    <span style="color: rgb(249, 38, 114);">mul</span> <span style="color: rgb(230, 219, 116);">ecx</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">0</span>],<span style="color: rgb(230, 219, 116);">edx</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">4</span>],<span style="color: rgb(230, 219, 116);">eax</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">8</span>],<span style="color: rgb(230, 219, 116);">ecx</span>
 +
    <span style="color: rgb(117, 113, 94);">// END: Test code</span>
 +
<span style="color: rgb(117, 113, 94);">...</span>
 +
</p>
  
  
Line 259: Line 427:
  
 
Testing one operand:
 
Testing one operand:
<pre>...
+
<!-- <pre>...
  // START: Test code
+
    // START: Test code
  mov eax,2
+
    mov eax,2
  mox ecx,3
+
    mov ecx,3
  imul ecx
+
    imul ecx
  mov [TestVals+0],edx
+
    mov [TestVals+0],edx
  mov [TestVals+4],eax
+
    mov [TestVals+4],eax
  mov [TestVals+8],ecx
+
    mov [TestVals+8],ecx
  // END: Test code
+
    // END: Test code
 
...
 
...
</pre>
+
</pre> -->
 +
<p style="white-space:pre;font-family:'Lucida Console';display: block; overflow-x: auto; padding: 0.5em; background: rgb(35, 36, 31); color: rgb(248, 248, 242);"><span style="color: rgb(117, 113, 94);">...</span>
 +
    <span style="color: rgb(117, 113, 94);">// START: Test code</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> <span style="color: rgb(230, 219, 116);">eax</span>,<span style="color: rgb(174, 129, 255);">2</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> <span style="color: rgb(230, 219, 116);">ecx</span>,<span style="color: rgb(174, 129, 255);">3</span>
 +
    <span style="color: rgb(249, 38, 114);">imul</span> <span style="color: rgb(230, 219, 116);">ecx</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">0</span>],<span style="color: rgb(230, 219, 116);">edx</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">4</span>],<span style="color: rgb(230, 219, 116);">eax</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">8</span>],<span style="color: rgb(230, 219, 116);">ecx</span>
 +
    <span style="color: rgb(117, 113, 94);">// END: Test code</span>
 +
<span style="color: rgb(117, 113, 94);">...</span>
 +
</p>
 
Testing two operands:
 
Testing two operands:
<pre>...
+
<!-- <pre>...
  // START: Test code
+
    // START: Test code
  mov eax,3
+
    mov eax,3
  imul eax,2
+
    imul eax,2
  mov [TestVals+0],eax
+
    mov [TestVals+0],eax
  // END: Test code
+
    // END: Test code
 
...
 
...
</pre>
+
</pre> -->
 +
<p style="white-space:pre;font-family:'Lucida Console';display: block; overflow-x: auto; padding: 0.5em; background: rgb(35, 36, 31); color: rgb(248, 248, 242);"><span style="color: rgb(117, 113, 94);">...</span>
 +
    <span style="color: rgb(117, 113, 94);">// START: Test code</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> <span style="color: rgb(230, 219, 116);">eax</span>,<span style="color: rgb(174, 129, 255);">3</span>
 +
    <span style="color: rgb(249, 38, 114);">imul</span> <span style="color: rgb(230, 219, 116);">eax</span>,<span style="color: rgb(174, 129, 255);">2</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">0</span>],<span style="color: rgb(230, 219, 116);">eax</span>
 +
    <span style="color: rgb(117, 113, 94);">// END: Test code</span>
 +
<span style="color: rgb(117, 113, 94);">...</span>
 +
</p>
 
Testing three operands:
 
Testing three operands:
<pre>...
+
<!-- <pre>...
  // START: Test code
+
    // START: Test code
  mov eax,0
+
    mov eax,0
  mov ecx,3
+
    mov ecx,3
  imul eax,ecx,2
+
    imul eax,ecx,2
  mov [TestVals+0],eax
+
    mov [TestVals+0],eax
  mov [TestVals+4],ecx
+
    mov [TestVals+4],ecx
  // END: Test code
+
    // END: Test code
 
...
 
...
</pre>
+
</pre> -->
 +
<p style="white-space:pre;font-family:'Lucida Console';display: block; overflow-x: auto; padding: 0.5em; background: rgb(35, 36, 31); color: rgb(248, 248, 242);"><span style="color: rgb(117, 113, 94);">...</span>
 +
    <span style="color: rgb(117, 113, 94);">// START: Test code</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> <span style="color: rgb(230, 219, 116);">eax</span>,<span style="color: rgb(174, 129, 255);">0</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> <span style="color: rgb(230, 219, 116);">ecx</span>,<span style="color: rgb(174, 129, 255);">3</span>
 +
    <span style="color: rgb(249, 38, 114);">imul</span> <span style="color: rgb(230, 219, 116);">eax</span>,<span style="color: rgb(230, 219, 116);">ecx</span>,<span style="color: rgb(174, 129, 255);">2</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">0</span>],<span style="color: rgb(230, 219, 116);">eax</span>
 +
    <span style="color: rgb(249, 38, 114);">mov</span> [TestVals+<span style="color: rgb(174, 129, 255);">4</span>],<span style="color: rgb(230, 219, 116);">ecx</span>
 +
    <span style="color: rgb(117, 113, 94);">// END: Test code</span>
 +
<span style="color: rgb(117, 113, 94);">...</span>
 +
</p>
  
  
Line 298: Line 495:
 
== See also ==
 
== See also ==
 
* [[Tutorials]]
 
* [[Tutorials]]
 +
 +
==== Syntax Highlighter ====
 +
* [http://pinetools.com/syntax-highlighter pinetools.com/syntax-highlighter]

Revision as of 04:49, 16 March 2017

Setup auto assembler test table

Let's setup an auto assembler test table.

Open the Cheat Engine Tutorial and attach to the process, you can pick the 32 bit or the 64 bit depending on what you are testing.

So now on the Cheat Engine main form press Crtl+Alt+A to open an auto assemble form.

Let's add so code to allocate some global memory for test assembling and value storing.

//// -------------------- Main Section --------------------- globalAlloc(TestVals, 0x40) //// Globally allocates memory, same as 'alloc' with 'registerSymbol' globalAlloc(memTest, 0x200) [ENABLE] //// -------------------- Enable Section --------------------- memTest: //// Start assembling as this address (memTest) // START: Test code // END: Test code ret //// return, needed for ending the threads [DISABLE] //// -------------------- Disable Section -------------------- //// Reset memTest and TestVals memTest: db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 // 0x100 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 db 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 C3 //// An extra ret just in case // 0x200 TestVals: db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 db 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

Now add that to the table, and set it's description to 'Test Script'

If you are unsure how to do that check here: How to add script to table


Now we need a script to start a new thread in the test memory we will be using.

//// -------------------- Main Section --------------------- [ENABLE] //// -------------------- Enable Section --------------------- createThread(memTest) //// Create and start thread [DISABLE] //// -------------------- Disable Section --------------------

Now add that to the table, set it's description to 'Create Thread', and make it a child of the first script.


Now add some addresses to the table, and make them a child of the first script.

If you are unsure how to do that check here: How to add addresses to the address list
You can just copy the XML code below, then paste on the cheat table address list.
Note: Cheat Engine uses XML when cutting or pasting memory records, and will automaticlly asign new IDs when pasting memory records from other tables.
  1. Address
    • Address: memTest
    • Type: Array Of Bytes
      • Lenght: 0
    • Address: TestVals
    • Type: Array Of Bytes
      • Lenght: 0
     
  2. Address
    • Address: TestVals+0
    • Type: 4 Bytes
  3. Address
    • Address: TestVals+4
    • Type: 4 Bytes
  4. Address
    • Address: TestVals+8
    • Type: 4 Bytes
  5. Address
    • Address: TestVals+C
    • Type: 4 Bytes
     
  6. Address
    • Address: TestVals+0
    • Type: 8 Bytes
  7. Address
    • Address: TestVals+8
    • Type: 8 Bytes
     
  8. Address
    • Address: TestVals+0
    • Type: Float
  9. Address
    • Address: TestVals+4
    • Type: Float
  10. Address
    • Address: TestVals+8
    • Type: Float
  11. Address
    • Address: TestVals+C
    • Type: Float
     
  12. Address
    • Address: TestVals+0
    • Type: Double
  13. Address
    • Address: TestVals+8
    • Type: Double

<?xml version="1.0" encoding="utf-8"?> <CheatTable> <CheatEntries> <CheatEntry> <ID>0</ID> <Description>"memTest"</Description> <LastState Value="" RealAddress="00000000"/> <ShowAsHex>1</ShowAsHex> <VariableType>Array of byte</VariableType> <ByteLength>0</ByteLength> <Address>memTest</Address> </CheatEntry> <CheatEntry> <ID>1</ID> <Description>"TestVals"</Description> <LastState Value="" RealAddress="00000000"/> <VariableType>Array of byte</VariableType> <ByteLength>0</ByteLength> <Address>TestVals</Address> </CheatEntry> <CheatEntry> <ID>2</ID> <Description>"TestVals+0"</Description> <VariableType>4 Bytes</VariableType> <Address>TestVals+0</Address> </CheatEntry> <CheatEntry> <ID>3</ID> <Description>"TestVals+4"</Description> <VariableType>4 Bytes</VariableType> <Address>TestVals+4</Address> </CheatEntry> <CheatEntry> <ID>4</ID> <Description>"TestVals+8"</Description> <VariableType>4 Bytes</VariableType> <Address>TestVals+8</Address> </CheatEntry> <CheatEntry> <ID>5</ID> <Description>"TestVals+C"</Description> <VariableType>4 Bytes</VariableType> <Address>TestVals+C</Address> </CheatEntry> <CheatEntry> <ID>6</ID> <Description>"TestVals+0"</Description> <VariableType>8 Bytes</VariableType> <Address>TestVals+0</Address> </CheatEntry> <CheatEntry> <ID>7</ID> <Description>"TestVals+8"</Description> <VariableType>8 Bytes</VariableType> <Address>TestVals+8</Address> </CheatEntry> <CheatEntry> <ID>8</ID> <Description>"TestVals+0"</Description> <VariableType>Float</VariableType> <Address>TestVals+0</Address> </CheatEntry> <CheatEntry> <ID>9</ID> <Description>"TestVals+4"</Description> <VariableType>Float</VariableType> <Address>TestVals+4</Address> </CheatEntry> <CheatEntry> <ID>10</ID> <Description>"TestVals+8"</Description> <VariableType>Float</VariableType> <Address>TestVals+8</Address> </CheatEntry> <CheatEntry> <ID>11</ID> <Description>"TestVals+C"</Description> <VariableType>Float</VariableType> <Address>TestVals+C</Address> </CheatEntry> <CheatEntry> <ID>12</ID> <Description>"TestVals+0"</Description> <VariableType>Double</VariableType> <Address>TestVals+0</Address> </CheatEntry> <CheatEntry> <ID>13</ID> <Description>"TestVals+8"</Description> <VariableType>Double</VariableType> <Address>TestVals+8</Address> </CheatEntry> </CheatEntries> </CheatTable>


At this point you should have a cheat table that looks like this.

CreateTestTable.01.png


Now set the main script to disable child memory records, right click the address and selecting group config then selecting deactivating this entry deactivates it's children.

CreateTestTable.02.png


Now set the main script to hide child memory records when deactivated, right click the address and selecting group config then selecting hide children when deactivated.

CreateTestTable.03.png


So now you can write some test scripts, run a thread to test the code, with a clean registory, independend of any game to just test the code in the Cheat Engine Auto Assembler.

The TestVals is for storing values to see the registory at different points, you can also break and trace the code to see what is going on.


When testing just add your code then assemble (enable Test Script), then create the thread (enable Create Thread). After running thread remember to check that the process is still running.


Example scripts

Testing MUL:

... // START: Test code mov eax,2 mov ecx,3 mul ecx mov [TestVals+0],edx mov [TestVals+4],eax mov [TestVals+8],ecx // END: Test code ...


Testing IMUL:

Testing one operand:

... // START: Test code mov eax,2 mov ecx,3 imul ecx mov [TestVals+0],edx mov [TestVals+4],eax mov [TestVals+8],ecx // END: Test code ...

Testing two operands:

... // START: Test code mov eax,3 imul eax,2 mov [TestVals+0],eax // END: Test code ...

Testing three operands:

... // START: Test code mov eax,0 mov ecx,3 imul eax,ecx,2 mov [TestVals+0],eax mov [TestVals+4],ecx // END: Test code ...


Going further


See also

Syntax Highlighter