<?xml version="1.0" encoding="utf-8"?>
<CheatTable CheatEngineTableVersion="46">
  <Files>
    <File Name="cemono.lua" Encoding="Ascii85">*md$C,cps1+A)av+f-8yA!)7-ID13gDqWkTLxCk7:3pBTWC1PFwoq9TL@]QAEWc/!a)73HqGTt[*[vGew6;4O/Gt}?JNA!^Kl+64DiW2I1*B;sQS}ZOt6IETpYo.frNWP{7V6DW?bJM7mr}TqSL;:-3+y,5s=LhJ7Y;f:x}#_S[/bc3B}n%Z!vOc=Wx^hNlX6uk7I#iMM4FFG+^tC;V0%n0L.:K_Sy^6z-V4pzaKzFQ:_(]p;523,6t[bHi58*zERLDh+}()aqEw9RBPxDf*kPy$/We-GjEN$JUGOh!^,gvC%O5[V*rSwPJ9)O)ltpQ@Vm]V/Ry,_QOLA{{+rd4168fxF$jaHw]6d+aF(q^]q;]zUO,l9xC^nN]hkw,f7CepEPa?A?N0F}tbGT%A[D-,[7=fx:KuKCq$fhgBWL6}TjZE5_Y$b)coaNw[at3Q$u[%gkc(;QOIG7EeQ7WdZx%OEF.a9$w6)@w9n0Zm8N{UtFrk#/deh?@F$A.Q=.-hbYaV#7[iDlgs,{PY:kOj1.cXSuJhup,qujoW]WKM8%M!e6YlD+6@X_E44DM:yH.[kUKiUyaH+8_6^(PK.*gEltaz[/f.dywN8g(ZwfGurnF$ZONhh[+IWhqx7VT0,WQ(axsUf_GKtO$}QUqReeD8tElEAFl=TJ==1-$#+(-nw5]qv:_Y/ADos/%bCHQO/T=P[5Hzn)%e1AzwNbN,KU4w@_H8*(JGzXn{wqc(=!-GuRw[]6@A@{r#yM+x57eWx!tVE5nR:=@4q,e@4uQt9oS8/gc#6jCW[aY$W!ZTQsz/:tEHy/(I$LmrO6j@3jqL(H6(nmkDggv0J8lGD_@ojP8hl%;KD%{Y(K%TM@/eOp2Hz^zoDIH7Zk@vn0Z$]Ux}_0uNM#P/Kx@_-MZ}K7fWIAd#B-w-ZomfM]#T?d;WQF6hWSzewm!.Jb_2?aYSY3Lbj5,zoUqGm!{iYT$c9SAHgR8CdQgG[/B_v,IMC7ZdIMTXCn[TT@PMK%#2OB,FY@W,V!+HDELhKV4EWQ=Pkd1D)CAHp%!HdOJ1rb+{M=xn=i{XsL38S9A2rT;#_P!T3MMf];LnbtF.m]]xVc7]t,$4Ga*F_d0_^-KJI--i2bf:h@3HRx{@%vkRBpNU:a(Gq!iEs$#WOnTJXW)iJ*b6kX#LUccP}Qp0^J=7I@;LkfS%0g[vyXi%gC3=7A0dH=)aKbrEEip_!Gz;Wc1TSx,tjC)_0K81#6VrnQiA!e:gT1Z^v0Skp(+qZj.71E?QpZ6)x)hgefe8n7E{0NoatBM3oCrw!Z,HXyc3KZMpwb)*=?y$-:q4gOZ8l-V;FsJXFfBdT.;$Jd5s6D[TUTY$LrU;{F=4aE0C.)rA._2aY#G^StmEf=;:CZ{h:3!PGtzs%dc)+HMx7OY2RW)oH}JGkuhMwO?+%koORuFK@u?ajw*9jyTY(Pw!^25:vKhj{q=b=0G%@{]E2Ppb.6*W8!:A{dU9uxpA%g=!3(5d}:x+s$b}.g9#:h5_42=mv4Wa5qg6/6C$Q3x=_vXOE$--PrQTV-IEV**?EZ?@HU1,D)DX$8t6GvoPBoQD(n#Q;@PrH;k.GNOkGLYy5f{kn1y(H_brl(n(w,$H8BUB8kV0H]qqKCPDL2i8C4])*s8j#B,j86=NcG;cd5bFrEsTII,uh(Kb$J*S9NUM)@YiFr0vtdi^e*pci/xJ@}=iR-t=:5MqJ,y4web;mPd@9D_GoL]1_#N3fG0#$L!sK!1q325n*OUDnZIllOrM,;%tONtH^uQ$h+iL.KF^h9MhW,@:bPSye#N[rY.e2w8[g]X4y!j#mo%#A0o,80j3{67E#NO2xv^h[qAJMxopb(BMsymN%8exJ%b{+JHZ8Bz5FC(UW3AsX;VSr;1rQs_g9;(?R0UEW}=%bH]iz.DMXYbeY+=Go^0?ea}w[+u1QP0**w.ynZQlw,v*[2*I_G:@ag=2@boU4=]#_b=^#a/mm4O5+0:L+*F?y.igBzcLp/E[$oxV1=,iS(UQAp_K+U/P7#0YezaUm!fbi9MoFB=V-LA0BunC=ud-nb6O5X3/$.IAj@Gayil6]tH!%hi3n;0NXdTok59P7}guK*eef,R!ce}+qreEh;wps2x(1MCR[F2m8D!t3vU-94/m]G{IEEDd@7_+c*51tJ_[!BsV@Ij8@b04{BThntu785Ow[ih:_,HjVsjC:EscAf0J+U;=SACFQT,HpGRk*b^x-EtP{CXdpxc?Oi5G6v+oBLMT-m@{x7SvLXYfL%#u-}9BeHFP!ROnom,8fhsA1!mQbCcRe_5a0M%b5hq}@TgS$zXs,yZ(*$dIXJKyLnC,KHHs2e0dWldTe5JHr?j15a]#W]-_)#(PVR@47n+gytmjTI@[yN:6%^[x.o9%pTBIf.,uVcN@F0Tc/}3(E]MDoNk9UWky+U5n0%r^+N{ab{1XGw1/tNmXI-AFsw_*_i4B*v+.XTIJ;84S2w3b@.q;?$y(i?@BdSYye;ABAMd@lVvRmt([C*d}45yT3rY%$LY5rGq*z[!*$$yFw/Ras=8R4u9)Rs7{GpO3!W-}ST</File>
  </Files>
  <CheatEntries>
    <CheatEntry>
      <ID>0</ID>
      <Description>"Enable"</Description>
      <Options moHideChildren="1" moDeactivateChildrenAsWell="1"/>
      <Color>008000</Color>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>[ENABLE]
{$lua}
if syntaxcheck then return end

local cev = getCEVersion()
local cevm = '\n(Your CE Version: '.. cev ..')'

if cev == nil or cev &lt; 7.1 then
  local msg = 'Please update!\nIts required to use at least Cheat Engine 7.1! '..cevm
  messageDialog(msg, mtError, mbOK)
  return --yeah, no going forward here!
else if cev &lt; 7.5 then
  local msg = 'Update recommended!\nTable checked to work on public Cheat Engine 7.5 &amp; 7.6!'..cevm
  messageDialog(msg, mtWarning, mbOK)
  -- getting latest online version is possible but I don't want to add online checks! Activate in CE settings or
  -- https://www.cheatengine.org/forum/viewtopic.php?t=610628 or check manually ... whatever floats your boat
end end

var = var or {}
--- you may change the next 4 variables as you see fit
var.pn1 = 'UiTC.exe' -- string - primary name of the exe to attach
var.pn2 = 'Unaware in The City.exe' -- string/nil - another possible name if provided
var.stopquery = true -- bool/nil - true to stop AAT after attaching / false continues ATT / nil queries
var.dbg = var.force or false -- bool - true for debug prints
--- dont change these lines or attaching/few functions wont work!
var.force = var.force or false --bool - true will preven value override
var.stopthread = false -- bool - true will stop autoAttachThread

if var.dbg then print(cevm) end

local function getProcID() -- returns ID or nil for predefines names
  --local dtg = {'pn1','pn2','dbg'}
  --local pn1,pn2,dbg = getlocdef(dtg)
  local pn1,pn2,dbg = var.pn1,var.pn2,var.dbg
  if dbg then print("gPID - start - ",pn1,pn2,dbg) end
  if not pn1 then print('ProcessID - no process name given/defined') error("PID failed") return end

  local pn = pn1
  local pid = getProcessIDFromProcessName(pn)
    --- check if the process name matches, else try workarounds
  if not pid then
    if dbg then print("gPID - pid not found, trying workarounds") end
    if pn2 then
      pn = pn2
      pid = getProcessIDFromProcessName(pn)
      else pn2 = '' end
    if not pid then
      local pn1s = pn1:match("(%w+)") --get first word
      local pn2s = pn2:match("(%w+)")
      local sname = ''
      for _,v in pairs(getProcesslist()) do --go through process list, we just need values
        sname = v:match("(%w+)")
        if sname == pn1s or sname == pn2s then --check if name matches
          ---print('attaching to: ',v) --v still has full process name
          ---strings_add(getAutoAttachList(), v)
          pn = v
          break
      end end
      pid = getProcessIDFromProcessName(pn)
  end end
  if dbg then print("gPID - end") end
  return pid,pn
  --pn[0], pn[1] = process:match("(%w+)(.+)") --get first word (and the rest) or (\w+)$ for the last word
  --print(pn[0], pn[1], tostring(pn[0] ~= 'name1' and pn[0] ~= 'name1'))
end

local autoAttachThread = function(th)
  --th.freeOnTerminate(true)
  if not th then print('AutoAttachThead - error creating the thread') error("Thread failed") return end
  --local dbg = getlocdef({'dbg'})
  local dbg = var.dbg
  if dbg then print('aat - AutoAttachThead start',i,Interval) end
  local Interval = 1000
  local laststate = nil

  for i=1,36000 do -- start timed loop, always with conditions to stop!
    if th.Terminated then return end
    if var.stopthread then th.terminate() return end
    local openid = getOpenedProcessID() --get current IDs
    local pid,pn = getProcID()
    local attach = nil

    if pid == nil then -- process not running, speed up
      if laststate~=0 then
        unsetSaP() disableMono() detach()
        print('Waiting for the process to come up')
      end
      if dbg then print('aat - Still waiting',i,Interval) end
      Interval,laststate = 1000,0
    else
      if openid and openid == pid then -- opened process already the correct one
        if laststate ~=1 and laststate ~=2 then attach = true end
        Interval,laststate = 15000,1
      else
        if openid ~= pid then -- process is running, attach it
          openProcess(pid)
          if laststate ~=2 then attach = true end
          laststate = 2
        else
          print('aat - Cant be, you found a loop-hole!',openid,pid,tostring(laststate),tostring(attach))
      end end
      if dbg then print('aat - pn:',pn,'oid/pid:',openid,pid,'state:',laststate,'i/int:',i,Interval,'q:',tostring(attach)) end
      if attach then
        local conAtt = var.stopquery and 7
        local msg = pn.." attached."
        print(msg)
        if var.stopquery==nil then
          msg = msg.."\nDo you want auto-attaching to silently continue?"
          conAtt = messageDialog(msg,mtConfirmation, mbYes, mbNo)
        end
        -- inputQuery('Some caption','some prompt','y')
        checkmono()--synchronize()
        if conAtt == 7 then
          if dbg then print('aat - Stopping the attach function') end
          th.terminate()
          return
        else print("Continuing to watch and attach if game closes/crashes.\nNote: you may cancle with: var.stopthread = true")
      end end
      if dbg then print('aat - Still there',i,Interval,tostring(conAtt)) end
    end
    sleep(Interval)
  end
end
--https://forum.cheatengine.org/viewtopic.php?t=579133
--https://github.com/cheat-engine/cheat-engine/issues/1093
--closeRemoteHandle()

function checkmono()
  --local dbg = getlocdef({'dbg'}) --get debug value
  local dbg = var.dbg
  if dbg then print("cm - start") end

  --code to check proc name moved to autoAttachThread
  print('Checking if game is loaded/mono is working ...')
  local addr = getAddressSafe('PlayerTraits_UW:BuyTrait')
  while not addr and not var.stopthread do --repeat ----wait till game is loaded
    disableMono()
    local monoresult = LaunchMonoDataCollector()
    if monoresult == 0 then
      local msg = 'Process found, but mono could not be launched. Probably newer CE Version needed.'
      print(msg)
      switchActiveMR(0) error("Mono failed") return
    else
      if dbg then print("Mono:",monoresult) end
    end
    if switchActiveMR(0,true) then --"Enable" script,activate it - returns if it did neeed to activate
      local msg = "Seems game is yet not fully loaded but CE (mono bug?) did disable the script. Got you covered and 'll retry."
      print(msg)
      return
    end
    if not addr then sleep(1000) end --checkSynchronize(1000)
    addr = getAddressSafe('PlayerTraits_UW:BuyTrait') --GlobalObjects_UW:CheckIfExtended / GlobalObjects_UW:CheckVersionEXCHBA / monoSymbolList.FullyLoaded il2cpp
    if dbg then print('cm - Waiting for the game to fully load',tostring(addr)) end
  end --until (addr or var.stopthread)
  if dbg then print("cm - end") end
  addStructForOffsets()
end

function addStructForOffsets()
  local dbg = var.dbg
  if dbg then print("struct - start") end
  local s = findTableFile('cemono.lua').Stream
  local ls,le = load(readStringLocal(s.Memory,s.Size))
  if dbg then print(tostring(s),s.Memory,s.Size,tostring(ls),le) end
  --local ok, cem = pcall(ls)
  ls()

  -- clean Structures and Pointer
  if unsetSaP() then switchActiveMR(0) return end
  -- define the structures for offsets to get
  local funcs = {{'','EItems',true,2,0x1C,16}, -- NS/class/static fields/loop-start/start-offset/loop-offset
                 {'','EStats',true,1,0x1C,16}, -- static fields are needed for enums
                 {'','EReputations',true,2,0x1C,16},
                 {'','EBuffType',true,2,0x1C,16},
                 {'','ESexCount',true,2,0x1C,16},
                 {'','PlayerStats_UW',false},
                 {'','GameManager_UW',false},
                 {'','TimeSettings_UW',false},
                 {'','PlayerMain_UW',false},
                 {'','GlobalObjects_UW',true} }

  if dbg then print("struct - loading structures") end
  -- if anything fails reasonaibly stop here. We only need the value, not key
  for _,v in ipairs(funcs) do
    if synchronize(addMonoStructure,unpack(v)) then switchActiveMR(0) return end
  end
  --if AppendStructChilds('BaseItems','EItems_SF') then switchActiveMR(0) return end

  if dbg then print("struct - addded, trying to fetch global") end
  local gobj = monoStaticF('','GlobalObjects_UW') --this gets the important starting addr

  local shift=1
  if targetIs64Bit() then shift=33 end
  if not gobj or (gobj &gt;&gt; shift) &lt;= 0 then
    print('Error, could not get GlobalObjects. The table wont work!') switchActiveMR(0) return
  else
    --unregisterSymbol("pgobj")
    registerSymbol("pgobj", gobj, false)
  end

  if dbg then print("struct - end") end
  print('Done - you may start using the table now!')
end

function cycleFullCompact(sender,force)
	local state = not(compactmenuitem.Caption == 'Compact View Mode')
	if force~=nil then state = not force end
	compactmenuitem.Caption = state and 'Compact View Mode' or 'Full View Mode'
	getMainForm().Splitter1.Visible = state
	getMainForm().Panel4.Visible    = state
	getMainForm().Panel5.Visible    = state
end

function addCompactMenu()
	if compactmenualreadyexists then return end
	local parent = getMainForm().Menu.Items
	compactmenuitem = createMenuItem(parent)
	parent.add(compactmenuitem)
	compactmenuitem.Caption = 'Compact View Mode'
	compactmenuitem.OnClick = cycleFullCompact
	compactmenualreadyexists = 'yes'
end

function switchActiveMR(idn,enable) ---expects an ID or name / bool to activate the MR instead disable
  local mr = nil
  if type(idn)=="number" then
    mr = getAddressList().getMemoryRecordByID(idn)
  else if type(idn)=="string" then
    mr = getAddressList().getMemoryRecordByDescription(idn)
  end end
  if var.dbg then print("swtichActive: trying with mr "..idn) end
  if not mr then print('swtichActive: MR renamed or wrong ID?',idn) error("Wrong MR") else
    if enable then
      if  mr.Active == false then
        mr.Active = true
        return true
      end
    else
      mr.Active = false
  end end
  return nil --returns either true if activated or nil
end

function disableMono()
  if cev == 7.6 then print("With CE 7.6 I experienced freezes of mono. If so, restart CE.") else
    if type(monopipe)=='userdata'then
      if monopipe.OnTimeout then
        if var.dbg then print("mono - OnTimeout") end
        monopipe.OnTimeout()
      else
        if var.dbg then print("mono - Destroy") end
        monopipe=nil,monopipe.Destroy()
      end
    else if var.dbg then print('monotype: '..type(monopipe)) end end end
  print("mono - finished")
end

function unsetSaP()
  local gobj = getAddressSafe("pgobj")

  if delAllStructures then synchronize(delAllStructures) end
  --sr = removeMrChilds('BaseItems') --no need to if I can disable the script and the Populate * [DISABLE] parts takes care
  if gobj then
    unregisterSymbol("pgobj")
    gobj = nil
    if var.dbg then print("Structures and symbol removed") end
  end
  if var.dbg then print("unset-pgobj:",tostring(gobj)) end
end

function detach()
  synchronize(openProcess,"cheatengine*") --yeah if you rename CE, then you should be able to solve things yourself
  synchronize(function() MainForm.ProcessLabel.Caption=0 end)
  if var.dbg then print("detached process") end
end

var.aant = createThread(autoAttachThread)
--checkprocess()
--addStructForOffsets()
addCompactMenu()
cycleFullCompact(nil,true)


{$asm}
[DISABLE]
{$lua}
if syntaxcheck then return end

if var.dbg then print("disabling script (main incl subs)") end

cycleFullCompact(nil,false)

--if var.aant.Terminated==false then var.aant.terminate() end
var.stopthread = true

--ignore returns, just execute what's possible
unsetSaP()
disableMono()
detach()
</AssemblerScript>
      <CheatEntries>
        <CheatEntry>
          <ID>1</ID>
          <Description>"Change few options (groups enable all sub-options. use +/- to expand/collapse)"</Description>
          <Options moManualExpandCollapse="1" moDeactivateChildrenAsWell="1"/>
          <Color>C0C0C0</Color>
          <VariableType>Auto Assembler Script</VariableType>
          <AssemblerScript>{ Game   : Unaware in The City.exe
  Version: 1.0
  Date   : 2023-11-19
  Author : Nironan

  Change options, creates functions each subscript executes
}

[ENABLE]

{$lua}
if syntaxcheck then return end

function writeToStructEntries(struct,entry,sz,val)
  local offs=getAddressSafe(struct.."."..entry)
  if offs then
    local gobj = getAddressSafe("pgobj")
    if var.dbg then print("Opt: ",struct,entry,gobj+offs,sz,val) end
    if sz == vtByte then
      writeByte(gobj+offs,val)
    else if sz == vtDword then
      writeInteger(gobj+offs,val)
    else if sz == vtQword then
      writeQword(gobj+offs,val)
    else if sz == vtSingle then
      writeFloat(gobj+offs,val)
    else print("Opt: Unsupported type, plz check your input.",entry,sz)
    end end end end
  else if val&gt;0 then print("Couldn't get value",entry,"- likely removed/other version. Rest will work.") return nil end end
end

function setValuesOnStruct(entries,struct,ts,value) --loops for all entries if they do exist, passes them to write those
  if entries and type(entries)=="table" then
    if not struct then struct = "GlobalObjects_UW_SF" end
    for _, entry in ipairs(entries) do
      local sz,val=ts,value
      if ts and type(ts)=="table" and ts[entry] then
        local t=ts[entry]
        sz=t.size
        val=t.value
      else
        if not sz or (sz and not val) then sz,val=vtByte,01
      else
        if sz and val and not type(val)=="number" then
          print("Opt: Uh-Oh bad boy. No or wrong type of value given")
          goto continue
      end end end
      writeToStructEntries(struct,entry,sz,val)
      ::continue::
end end end

function scanAobRegion(bytestoscan,scanaddrstart,scanaddrend)
  if not bytestoscan then return end
  if not scanaddrstart then scanaddrstart=0 end
  if not scanaddrend then scanaddrend=0xffffffffffffffff end
  local addr = nil

  local scan = createMemScan(true)
  scan.setOnlyOneResult(false)
  --[[firstScan(scanoption, vartype, roundingtype, input1, input2 ,
  startAddress ,stopAddress ,protectionflags ,alignmenttype,
  "alignmentparam", isHexadecimalInput, isNotABinaryString, isunicodescan, iscasesensitive)]]--
  scan.firstScan(soExactValue,vtByteArray,rtRounded,bytestoscan,nil,
    scanaddrstart,scanaddrend,"*W*X-C",fsmNotAligned,nil,true,false,false,false)
  scan.waitTillDone()
  --Fetch result
  local FoundList=createFoundList(scan)
  FoundList.initialize()
  --Save addr
  if var.dbg then print("Opt: Scan Count: ",FoundList.Count) end
  if FoundList.Count == 1 then
    addr = FoundList.Address[0] -- Updated adresss storing the wanted function to hook
  end
  --Cleanup
  sleep(50)
  FoundList.deinitialize()
  FoundList.destroy()
  FoundList=nil
  scan.destroy()
  scan=nil
  return addr
end

function getVsStr()
  local gobj = getAddressSafe("pgobj")
  local offs = getAddressSafe("GlobalObjects_UW_SF.gameVersionStr")
  local pgvs = readPointer(gobj+offs)
  local leng = readInteger(pgvs+0x10)
  if leng &gt; 9 then leng = 7 end
  local flng = leng*2-4
  local str = readString(pgvs+0x14,leng*2, true)
  local addr = pgvs+0x14+flng
  if var.dbg then print(str,tohex(pgvs),leng,tohex(addr)) end
  return pgvs,addr --,flng
end

function ToInteger(number)
    return math.floor(tonumber(number) or print("Opt: Could not cast '" .. tostring(number) .. "' to number.'"))
end

print('Setting some values like EX/CH needs to be done from main menue. To force text-change open "Load Game" or "Credits" and go back.')

--[[
##Notes
## struct is now optional. Not that you can set another struct (ok, offset you could but no correct value) - I'd need to add the option to recursive read pointers
## Allowed values for size: vtByte,vtDword,vtQword, and vtSingle (for float entries)
## https://raw.githubusercontent.com/cheat-engine/cheat-engine/master/Cheat%20Engine/bin/defines.lua ~line 130

## you can now choose between solo entries - sets Byte=true
  setValuesOnStruct({"cheatsOn"})
## solos with direct values
  setValuesOnStruct({"cheatsOn"},nil,vtByte,0)
## or table entries - names without table.entries will act as solo; you can use nil on struct
  local tbl={}
  tbl.enc={size=vtDword,value}
  setValuesOnStruct({"isVersionExtended","enc"},nil,tbl)
## use vtSingle for float; you can give struct name
  local tbl={}
  tbl.npcDickSize={size=vtSingle,value=1.5}
  setValuesOnStruct("npcDickSize"},"GlobalObjects_UW_SF",tbl)


##old code:
aobscanregion(aobExt,GlobalObjects_UW:CheckVersionEXCHBA+e,GlobalObjects_UW:CheckVersionEXCHBA+16,48 63 00 83 F8 * 0F 84)
return getScriptWithStructOff("GlobalObjects_UW_SF",{"cheatsOn","isVersionExtended","isAllowAutoSave"})
return getScriptWithStructOff("GlobalObjects_UW_SF",{"showDevDebug","showInternalDebug","isDevBuild","isDebugMode","isSuperDebugging"})
return getScriptWithStructOff("GlobalObjects_UW_SF",{"accessAllClothes","maxLuck","dontCleanSperm","testAnimVals","allowFurries","allowFuta","npcDickSize"},tbl)
return getScriptWithStructOff("GlobalObjects_UW_SF",{"ignoreChoiceReqs","overpowerStars","showXRay","pregnancyInfoCheat"})]]
{$asm}

[DISABLE]

{
// ORIGINAL CODE - INJECTION POINT: GlobalObjects_UW:CheckIfExtended+e

1A0F4B28E60: 00 00                          - add [rax],al
1A0F4B28E62: 00 00                          - add [rax],al
1A0F4B28E64: 00 00                          - add [rax],al
1A0F4B28E66: 00 00                          - add [rax],al
1A0F4B28E68: 00 00                          - add [rax],al
1A0F4B28E6A: 00 00                          - add [rax],al
1A0F4B28E6C: 00 00                          - add [rax],al
1A0F4B28E6E: 00 00                          - add [rax],al
GlobalObjects_UW:CheckIfExtended: 48 83 EC 08                    - sub rsp,08
GlobalObjects_UW:CheckIfExtended+4: 48 B8 20 28 D0 F4 9E 01 00 00  - mov rax,0000019EF4D02820
// ---------- INJECTING HERE ----------
GlobalObjects_UW:CheckIfExtended+e: 48 63 00                       - movsxd  rax,dword ptr [rax]
GlobalObjects_UW:CheckIfExtended+11: 83 F8 4C                       - cmp eax,4C
// ---------- DONE INJECTING  ----------
GlobalObjects_UW:CheckIfExtended+14: 0F 84 B9 00 00 00              - je GlobalObjects_UW:CheckIfExtended+d3
GlobalObjects_UW:CheckIfExtended+1a: 48 B8 1C 28 D0 F4 9E 01 00 00  - mov rax,0000019EF4D0281C
GlobalObjects_UW:CheckIfExtended+24: C6 00 00                       - mov byte ptr [rax],00
GlobalObjects_UW:CheckIfExtended+27: 48 B8 1D 28 D0 F4 9E 01 00 00  - mov rax,0000019EF4D0281D
GlobalObjects_UW:CheckIfExtended+31: C6 00 00                       - mov byte ptr [rax],00
GlobalObjects_UW:CheckIfExtended+34: 48 B8 12 28 D0 F4 9E 01 00 00  - mov rax,0000019EF4D02812
GlobalObjects_UW:CheckIfExtended+3e: C6 00 00                       - mov byte ptr [rax],00
GlobalObjects_UW:CheckIfExtended+41: 48 B8 11 28 D0 F4 9E 01 00 00  - mov rax,0000019EF4D02811
GlobalObjects_UW:CheckIfExtended+4b: C6 00 00                       - mov byte ptr [rax],00
}
</AssemblerScript>
          <CheatEntries>
            <CheatEntry>
              <ID>11</ID>
              <Description>"Open Structure Dissect to check other values"</Description>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  createStructureForm("pgobj", nil, "GlobalObjects_UW_SF")
{$asm}

00000000:
nop
[DISABLE]
</AssemblerScript>
            </CheatEntry>
            <CheatEntry>
              <ID>12</ID>
              <Description>"Enable Ex,Ch,Save"</Description>
              <Options moManualExpandCollapse="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <GroupHeader>1</GroupHeader>
              <CheatEntries>
                <CheatEntry>
                  <ID>121</ID>
                  <Description>"Extended"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end
  local txt="EX"
  local val=76 --fallback version
  local cv=getAddressSafe("GlobalObjects_UW:CheckVersionEXCHBA")
  if not cv then cv=getAddressSafe("GlobalObjects_UW:CheckIfExtended") end
  if cv then
    local addr=scanAobRegion("48 63 00 83 F8 * 0F 84",cv+0xe,cv+0x16) --tonumber(-,16)
    if addr then
      local val2=readByte(addr..'+5')
      if val2 and val2&gt;0 then val=ToInteger(val2)--more futuresafe
      if var.dbg then print("Opt:",txt,tostring(cv),tostring(addr),val,val2) end
  end end end
  local tbl={}
  local vleng,vaddr=getVsStr()
  if var.dbg then print("Opt:",txt,tostring(cv),val,vaddr) end

[ENABLE]
  tbl.enc={size=vtDword,value=val}
  setValuesOnStruct({"isVersionExtended","enc"},nil,tbl)

  --print(readBytes(vleng+0x10, 8, false),tohex(vleng),tohex(vaddr))
  --writeInteger(vleng+0x10, 7)
  writeBytes(vaddr, 0x45, 0x00, 0x58) --EX it's rly just text info
  --[[local vpp = 'WellDonePeople123!'
  --local GetGameVersion = getAddressSafe("GetGameVersion_UW:Start")
  --https://forum.cheatengine.org/viewtopic.php?p=5784387]]
  switchActiveMR(124,true)

[DISABLE]
  tbl.isVersionExtended={size=vtByte,value=0}
  tbl.enc={size=vtDword,value=78} -- lets hope that will stay, at least reactivation wont break things, dont wanna alloc/read for that
  setValuesOnStruct({"isVersionExtended","enc"},nil,tbl)
  writeBytes(vaddr, 0x42, 0x00, 0x41) --BA
  switchActiveMR(124)


</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>122</ID>
                  <Description>"Cheats"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end
  local txt="CH"
  local val=77 --fallback version
  local cv=getAddressSafe("GlobalObjects_UW:CheckVersionEXCHBA")
  if not cv then cv=getAddressSafe("GlobalObjects_UW:CheckIfExtended") end
  if cv then
    local addr=scanAobRegion("48 63 00 83 F8 * 74",cv+0xc0,cv+0x131) --tonumber(-,16)
    if addr then
      local val2=readByte(addr..'+5')
      if val2 and val2&gt;0 then val=ToInteger(val2)--more futuresafe
      if var.dbg then print("Opt:",txt,tostring(cv),tostring(addr),val,val2) end
  end end end
  local vaddr=getVsStr()
  if var.dbg then print("Opt:",txt,tostring(cv),val,vaddr) end
  local mr = getAddressList().getMemoryRecordByDescription("Extended")

[ENABLE]
  if mr.Active then
    setValuesOnStruct({"isVersionCheats","cheatsOn"})
  else
    local tbl={}
    tbl.enc={size=vtDword,value=val}
    setValuesOnStruct({"isVersionCheats","cheatsOn","enc"},nil,tbl)
    writeBytes(vaddr, 0x43, 0x00, 0x48) --CH
    switchActiveMR(124,true)
  end
[DISABLE]
  if mr.Active then
    setValuesOnStruct({"isVersionCheats","cheatsOn"},nil,vtByte,0)
  else
    local tbl={}
    tbl.enc={size=vtDword,value=78}
    setValuesOnStruct({"isVersionCheats","cheatsOn","enc"},nil,tbl)
    writeBytes(vaddr, 0x42, 0x00, 0x41) --BA
    switchActiveMR(124)
  end
--{$asm}
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>124</ID>
                  <Description>"Not Steam (required for EX/CH)"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"isSteam"},nil,vtByte,0)

[DISABLE]
  setValuesOnStruct({"isSteam"},nil,vtByte,1)
  --[[ Note: Only the value gets changed, not the text because I dont wanna.
       Load a game back to main menue to show correct text]]
</AssemblerScript>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
            <CheatEntry>
              <ID>13</ID>
              <Description>"Enable other options"</Description>
              <Options moManualExpandCollapse="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <GroupHeader>1</GroupHeader>
              <CheatEntries>
                <CheatEntry>
                  <ID>131</ID>
                  <Description>"dontCleanSperm"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"dontCleanSperm"})

[DISABLE]
  setValuesOnStruct({"dontCleanSperm"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>132</ID>
                  <Description>"testAnimVals"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"testAnimVals"})

[DISABLE]
  setValuesOnStruct({"testAnimVals"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>133</ID>
                  <Description>"npcDickSize"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end
  local tbl={}

[ENABLE]
  tbl.npcDickSize={size=vtSingle,value=1.5}
  setValuesOnStruct({"npcDickSize"},nil,tbl)

[DISABLE]
  tbl.npcDickSize={size=vtSingle,value=1.0}
  setValuesOnStruct({"npcDickSize"},nil,tbl)
</AssemblerScript>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
            <CheatEntry>
              <ID>14</ID>
              <Description>"Enable minor options"</Description>
              <Options moManualExpandCollapse="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <GroupHeader>1</GroupHeader>
              <CheatEntries>
                <CheatEntry>
                  <ID>141</ID>
                  <Description>"XRay"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"showXRay","allowXRay","showCutInsXRay"})

[DISABLE]
  --setValuesOnStruct({"showXRay","allowXRay","showCutInsXRay"},nil,vtByte,0) --its default
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>142</ID>
                  <Description>"pregnancyInfoCheat"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"pregnancyInfoCheat"})

[DISABLE]
  setValuesOnStruct({"pregnancyInfoCheat"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>143</ID>
                  <Description>"disableScreenFade"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"disableScreenFade"})

[DISABLE]
  setValuesOnStruct({"disableScreenFade"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>144</ID>
                  <Description>"eyesOverHairs"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"eyesOverHairs"})

[DISABLE]
  setValuesOnStruct({"eyesOverHairs"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>145</ID>
                  <Description>"pregnantBelly (En/Disable to remove)"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"pregnantBelly"})

[DISABLE]
  setValuesOnStruct({"pregnantBelly"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>146</ID>
                  <Description>"hidePregnantBelly"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"hidePregnantBelly"})

[DISABLE]
  setValuesOnStruct({"hidePregnantBelly"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>147</ID>
                  <Description>"boobBouncingPower"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"boobBouncingPower"},nil,vtDword,10)

[DISABLE]
  setValuesOnStruct({"boobBouncingPower"},nil,vtDword,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>148</ID>
                  <Description>"forceNudity"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"forceNudity"},nil,vtDword,1)

[DISABLE]
  setValuesOnStruct({"forceNudity"},nil,vtDword,0)
</AssemblerScript>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
            <CheatEntry>
              <ID>15</ID>
              <Description>"Enable debug options"</Description>
              <Options moManualExpandCollapse="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <GroupHeader>1</GroupHeader>
              <CheatEntries>
                <CheatEntry>
                  <ID>151</ID>
                  <Description>"showInternalDebug"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"showInternalDebug"})

[DISABLE]
  setValuesOnStruct({"showInternalDebug"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>152</ID>
                  <Description>"isDevBuild"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"isDevBuild"})

[DISABLE]
  setValuesOnStruct({"isDevBuild"},nil,vtByte,0)

--[[ I could add " Dev" to gameVersionStr here too but its unnessecary pain.
Cause you can't directly write, a syscall is need for new space as it's not gonna fit]]
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>153</ID>
                  <Description>"isDebugMode"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"isDebugMode"})

[DISABLE]
  setValuesOnStruct({"isDebugMode"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>154</ID>
                  <Description>"isSuperDebugging"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"isSuperDebugging"})

[DISABLE]
  setValuesOnStruct({"isSuperDebugging"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
            <CheatEntry>
              <ID>16</ID>
              <Description>"stopTimeFlow (only 1 min when changing scenes except train)"</Description>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"stopTimeFlow"})

[DISABLE]
  setValuesOnStruct({"stopTimeFlow"},nil,vtByte,0)
</AssemblerScript>
            </CheatEntry>
            <CheatEntry>
              <ID>17</ID>
              <Description>"Old options (wont work on gameversion table is written on but older versions)"</Description>
              <Options moManualExpandCollapse="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  print("\nI've left some vars if someone does play an old version or some come back again (and for reference).")
  print("You can click 'Open Structure Dissect', check there are any new/renamed ones, double click any script to edit and CTR+R replace.")
[DISABLE]

</AssemblerScript>
              <CheatEntries>
                <CheatEntry>
                  <ID>170</ID>
                  <Description>"showDevDebug"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"showDevDebug"})

[DISABLE]
  setValuesOnStruct({"showDevDebug"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>171</ID>
                  <Description>"accessAllClothes"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"accessAllClothes"})

[DISABLE]
  setValuesOnStruct({"accessAllClothes"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>172</ID>
                  <Description>"maxLuck"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"maxLuck"})

[DISABLE]
  setValuesOnStruct({"maxLuck"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>173</ID>
                  <Description>"ignoreChoiceReqs"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"ignoreChoiceReqs"})

[DISABLE]
  setValuesOnStruct({"ignoreChoiceReqs"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>174</ID>
                  <Description>"overpowerStars"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"overpowerStars"})

[DISABLE]
  setValuesOnStruct({"overpowerStars"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>175</ID>
                  <Description>"AllowAutoSave"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"isAllowAutoSave"})

[DISABLE]
  setValuesOnStruct({"isAllowAutoSave"},nil,vtByte,0)

</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>176</ID>
                  <Description>"MemoryCleaning"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"memoryCleaning"})

[DISABLE]
  setValuesOnStruct({"memoryCleaning"},nil,vtByte,0)

</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>177</ID>
                  <Description>"AutoSaveType (Buggy)"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"autoSaveType"},nil,vtDword,1) -- 2:Always 1:Often 0:Off

[DISABLE]
  setValuesOnStruct({"autoSaveType"},nil,vtByte,0)

</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>178</ID>
                  <Description>"allowFurries"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"allowFurries"})

[DISABLE]
  setValuesOnStruct({"allowFurries"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>179</ID>
                  <Description>"allowFuta"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>{$lua}
  if syntaxcheck then return end

[ENABLE]
  setValuesOnStruct({"allowFuta"})

[DISABLE]
  setValuesOnStruct({"allowFuta"},nil,vtByte,0)
</AssemblerScript>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
          </CheatEntries>
        </CheatEntry>
        <CheatEntry>
          <ID>2</ID>
          <Description>"Ignore negative TP (New user &amp; Hostpital)"</Description>
          <Color>8000FF</Color>
          <VariableType>Auto Assembler Script</VariableType>
          <AssemblerScript>{ Game   : UiTC_v33b_EX_Win_64_Bit.exe / UiTC.exe
  Version: 1.0 / 1.1
  Date   : 2024-02-05 / 2025-07.08
  Author : Nironan

  Character traits - TP decrease - Creation/ Hospital
}

[ENABLE]

// 75 C9 48 * * * * * * * * * * * * * * * * * * * * * * * * * * *
//aobscan(aobDisableTPDec,75 C9 48 C7 85 58 FF FF FF 00 00 00 00)
aobscanregion(aobDisableTPDec,CharacterChanger_Traits_Comp_UW:UpdateTraitPoints,CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+150,75 * 48 C7)
registersymbol(aobDisableTPDec)

// 75 * 49 8B CF 48 8B D7 45 * * 48
//aobscan(aobBuyTraitNoCostCheck,75 22 49 8B CF 48 8B)
aobscanregion(aobBuyTraitNoCostCheck,PlayerTraits_UW:BuyTrait,PlayerTraits_UW:BuyTrait+FF,75 * 49 8B CF 48 8B)
registersymbol(aobBuyTraitNoCostCheck)

//aobscan(aobChangeCharNoTPCheck,0F 8D 5D 00 00 00 48 B8)
aobscanregion(aobChangeCharNoTPCheck,CharacterChanger_UW:ChangeCharacter_Accept,CharacterChanger_UW:ChangeCharacter_Accept+FF,0F 8D * * * * 48 B8)
registersymbol(aobChangeCharNoTPCheck)

alloc(tpmem,$4,aobDisableTPDec)
registersymbol(tpmem)

tpmem:
  readmem(aobDisableTPDec,2)
  readmem(aobBuyTraitNoCostCheck,2)

aobDisableTPDec:
  nop 2


aobBuyTraitNoCostCheck:
  nop 2

aobChangeCharNoTPCheck:
// nop, jmp
db 90 E9

[DISABLE]

aobDisableTPDec:
  //db 75 C9
  readmem(tpmem,2)

aobBuyTraitNoCostCheck:
  //db 75 22
  readmem(tpmem+2,2)

aobChangeCharNoTPCheck:
//  jnl CharacterChanger_UW:ChangeCharacter_Accept+a8
  db 0F 8D 5D 00 00 00

dealloc(tpmem)
unregistersymbol(tpmem)
unregistersymbol(aobDisableTPDec)
unregistersymbol(aobBuyTraitNoCostCheck)
unregistersymbol(aobChangeCharNoTPCheck)
{
// ORIGINAL CODE - INJECTION POINT: CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+9d

CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+68: 48 8B BD 70 FF FF FF              - mov rdi,[rbp-00000090]
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+6f: 48 63 47 34                       - movsxd  rax,dword ptr [rdi+34]
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+73: 44 03 F0                          - add r14d,eax
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+76: 48 8B CD                          - mov rcx,rbp
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+79: 48 81 C1 60 FF FF FF              - add rcx,FFFFFFFFFFFFFF60
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+80: 49 BA 40 4A 63 38 2E 02 00 00     - mov r10,0000022E38634A40
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+8a: 48 8D 6D 00                       - lea rbp,[rbp+00]
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+8e: 49 BB 30 DC 77 E0 2B 02 00 00     - mov r11,System.Collections.Generic.List`1+Enumerator[T_REF]:MoveNext
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+98: 41 FF D3                          - call r11
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+9b: 85 C0                             - test eax,eax
// ---------- INJECTING HERE ----------
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+9d: 75 C9                             - jne CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+68
// ---------- DONE INJECTING  ----------
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+9f: 48 C7 85 58 FF FF FF 00 00 00 00  - mov qword ptr [rbp-000000A8],00000000
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+aa: 48 83 EC 08                       - sub rsp,08
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+ae: E8 22 00 00 00                    - call CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+d5
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+b3: 48 83 C4 08                       - add rsp,08
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+b7: 48 8B 85 58 FF FF FF              - mov rax,[rbp-000000A8]
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+be: 48 85 C0                          - test rax,rax
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+c1: 74 10                             - je CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+d3
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+c3: 66 66 90                          - nop 3
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+c6: 49 BB 8B 5C 77 E0 2B 02 00 00     - mov r11,0000022BE0775C8B
CharacterChanger_Traits_Comp_UW:UpdateTraitPoints+d0: 41 FF D3                          - call r11
}

{
// ORIGINAL CODE - INJECTION POINT: PlayerTraits_UW:BuyTrait+54

PlayerTraits_UW:BuyTrait+2b: 85 C0                          - test eax,eax
PlayerTraits_UW:BuyTrait+2d: 0F 85 C2 00 00 00              - jne PlayerTraits_UW:BuyTrait+f5
PlayerTraits_UW:BuyTrait+33: 49 8B CF                       - mov rcx,r15
PlayerTraits_UW:BuyTrait+36: 48 8B D7                       - mov rdx,rdi
PlayerTraits_UW:BuyTrait+39: 48 8D 64 24 00                 - lea rsp,[rsp+00]
PlayerTraits_UW:BuyTrait+3e: 49 BB 20 D7 C8 65 03 02 00 00  - mov r11,PlayerTraits_UW:GetTraitData
PlayerTraits_UW:BuyTrait+48: 41 FF D3                       - call r11
PlayerTraits_UW:BuyTrait+4b: 4C 8B F0                       - mov r14,rax
PlayerTraits_UW:BuyTrait+4e: 0F B6 45 E0                    - movzx eax,byte ptr [rbp-20]
PlayerTraits_UW:BuyTrait+52: 85 C0                          - test eax,eax
// ---------- INJECTING HERE ----------
PlayerTraits_UW:BuyTrait+54: 75 22                          - jne PlayerTraits_UW:BuyTrait+78
// ---------- DONE INJECTING  ----------
PlayerTraits_UW:BuyTrait+56: 49 8B CF                       - mov rcx,r15
PlayerTraits_UW:BuyTrait+59: 48 8B D7                       - mov rdx,rdi
PlayerTraits_UW:BuyTrait+5c: 45 33 C0                       - xor r8d,r8d
PlayerTraits_UW:BuyTrait+5f: 48 8D AD 00 00 00 00           - lea rbp,[rbp+00000000]
PlayerTraits_UW:BuyTrait+66: 49 BB F0 53 04 65 03 02 00 00  - mov r11,PlayerTraits_UW:UnlockTrait
PlayerTraits_UW:BuyTrait+70: 41 FF D3                       - call r11
PlayerTraits_UW:BuyTrait+73: E9 9B 00 00 00                 - jmp PlayerTraits_UW:BuyTrait+113
PlayerTraits_UW:BuyTrait+78: 48 B8 40 29 48 11 03 02 00 00  - mov rax,0000020311482940
PlayerTraits_UW:BuyTrait+82: 48 8B 00                       - mov rax,[rax]
PlayerTraits_UW:BuyTrait+85: 48 8B 40 40                    - mov rax,[rax+40]
}

{
// ORIGINAL CODE - INJECTION POINT: CharacterChanger_UW:ChangeCharacter_Accept+45

CharacterChanger_UW:ChangeCharacter_Accept+1a: 33 C0                          - xor eax,eax
CharacterChanger_UW:ChangeCharacter_Accept+1c: 48 89 45 A0                    - mov [rbp-60],rax
CharacterChanger_UW:ChangeCharacter_Accept+20: 48 89 45 A8                    - mov [rbp-58],rax
CharacterChanger_UW:ChangeCharacter_Accept+24: 48 89 45 B0                    - mov [rbp-50],rax
CharacterChanger_UW:ChangeCharacter_Accept+28: 48 63 86 F8 01 00 00           - movsxd  rax,dword ptr [rsi+000001F8]
CharacterChanger_UW:ChangeCharacter_Accept+2f: 83 F8 05                       - cmp eax,05
CharacterChanger_UW:ChangeCharacter_Accept+32: 0F 85 E0 02 00 00              - jne CharacterChanger_UW:ChangeCharacter_Accept+318
CharacterChanger_UW:ChangeCharacter_Accept+38: 48 8B 46 30                    - mov rax,[rsi+30]
CharacterChanger_UW:ChangeCharacter_Accept+3c: 48 63 80 D4 00 00 00           - movsxd  rax,dword ptr [rax+000000D4]
CharacterChanger_UW:ChangeCharacter_Accept+43: 85 C0                          - test eax,eax
// ---------- INJECTING HERE ----------
CharacterChanger_UW:ChangeCharacter_Accept+45: 0F 8D 5D 00 00 00              - jnl CharacterChanger_UW:ChangeCharacter_Accept+a8
// ---------- DONE INJECTING  ----------
CharacterChanger_UW:ChangeCharacter_Accept+4b: 48 B8 60 29 26 10 85 02 00 00  - mov rax,0000028510262960
CharacterChanger_UW:ChangeCharacter_Accept+55: 48 8B 00                       - mov rax,[rax]
CharacterChanger_UW:ChangeCharacter_Accept+58: 48 8B 40 60                    - mov rax,[rax+60]
CharacterChanger_UW:ChangeCharacter_Accept+5c: 48 B9 60 29 26 10 85 02 00 00  - mov rcx,0000028510262960
CharacterChanger_UW:ChangeCharacter_Accept+66: 48 8B 09                       - mov rcx,[rcx]
CharacterChanger_UW:ChangeCharacter_Accept+69: 48 8B 49 60                    - mov rcx,[rcx+60]
CharacterChanger_UW:ChangeCharacter_Accept+6d: 48 8B 51 38                    - mov rdx,[rcx+38]
CharacterChanger_UW:ChangeCharacter_Accept+71: 48 B9 80 29 26 10 85 02 00 00  - mov rcx,0000028510262980
CharacterChanger_UW:ChangeCharacter_Accept+7b: F3 0F 10 01                    - movss xmm0,[rcx]
CharacterChanger_UW:ChangeCharacter_Accept+7f: F3 0F 5A C0                    - cvtss2sd xmm0,xmm0
}
</AssemblerScript>
        </CheatEntry>
        <CheatEntry>
          <ID>3</ID>
          <Description>"Fix Structures/Records (needs a new game/or save already loaded)"</Description>
          <Color>FF8000</Color>
          <VariableType>Auto Assembler Script</VariableType>
          <AssemblerScript>[ENABLE]
{$lua}
if syntaxcheck then return end

function adeptStructOffsets(addr,strname)
  if addr and type(addr)=='number' and strname and type(strname)=='string' then
    local struct = getStructureByName(strname) --need struct cause reading at +18 is too high
    local count = struct.Count-1

    if count &lt; 15 or count &gt; 200 then print("Struct-Sort: Error - may got the wrong the wrong table?",addr,strname,count) error("Struct-Sort") return end

    if var.dbg then print("Struct-Sort:",strname,addr,type(addr),count) end
    local tbl,t={},{}

    --get the table
    for i=0,count do
      tbl[i+1] = {
        ["id"]=readInteger(addr+i*16), --id we will later sort on
        ["val"]=readInteger(addr+i*16+12), --value just for prints
        ["off"]=32+12+i*16 -- +32d/20h and +12d/0Ch means we start at 2C
      }
      t[i+1]=struct.Element[i]
      --print("Struct-Sort: i:",i,tbl.id[i+1],tbl.val[i+1])
    end

    --sort the table
    table.sort(tbl, function(t1,t2) return t1.id &lt; t2.id end)

    --change structure to adapt to the sorting
    for i=count,0,-1 do
      local el = t[i+1]
      local soff = el.Offset-4 --the original (s)tructure offset
      local toff = tbl[i+1].off --the calculated new offset in the (t)able
      if var.dbg then print("Struct-Sort: i:",i,"ID:",tbl[i+1].id,"VAL:",tbl[i+1].val,"OFF:",soff,tohex(soff),"str",el.Name) end
      el.Offset=toff
      if var.dbg then print("Struct-Sort: i:",i,"ID:",tbl[i+1].id,"VAL:",tbl[i+1].val,"OFF:",toff,tohex(toff),"str",el.Name) end
    end

    for i=2,1,-1 do
      if t[i].Name=="NONE" or t[i].Name=="value___NS" then if var.dbg then print(t[i].Name,"destroyed") end t[i].Destroy() end
    end

    local t=(strname:match("(%w+)")):sub(2)
    print("Struct-Sort: Sorted the offsets on:",count+1,"values for:",t)
  else print("Sure you wanna do that? I know I wont - see ya. (Prob. because no addr:",addr,type(addr),") Struct:",strname,type(strname))
end end

local addr = getAddressSafe("[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.items]+18]+18]+20")
local struct = "EItems_SF"
adeptStructOffsets(addr, struct)
  addr = getAddressSafe("[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]+PlayerStats_UW.allStats]+18]+20")
  struct = "EStats_SF"
adeptStructOffsets(addr, struct)
  addr = getAddressSafe("[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]+PlayerStats_UW.allReps]+18]+20")
  struct = "EReputations_SF"
adeptStructOffsets(addr, struct)
  addr = getAddressSafe("[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]+PlayerStats_UW.allBuffs]+18]+20")
  struct = "EBuffType_SF"
adeptStructOffsets(addr, struct)
  addr = getAddressSafe("[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]+PlayerStats_UW.allCounts]+18]+20")
  struct = "ESexCount_SF"
adeptStructOffsets(addr, struct)

--[[
Progress:
first made staticFixStats() to fix Stats-Structure, didnt like it, sortTableOnAddress() to fix game data but it of course messing with IDs in memory the game uses breaks things
Reverted back to staticFixStats(). In the meantime I tried to look into C# with regression, possible. Also thought about manually writing indexes but problematic with game updates.
But then it hit me - just need to pass the sorting.

try to fix sorting of table entries
local pitems = "[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.items]+18]+18]+20"
local stritems = "EItems_SF"
sortTableOnAddress(pitems, stritems)
local pstats = getAddressSafe("[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]+PlayerStats_UW.allStats]+18]+20")
local strstats = "EStats_SF"
sortTableOnAddress(pstats, strstats)
staticFixStats()

function sortTableOnAddress(addr,strname)
  if addr and type(addr)=='number' and strname and type(strname)=='string' then
    local struct = getStructureByName(strname) --need struct cause reading at +18 is too high
    local count = struct.Count-1

    if var.dbg then print("Table-Sort:",addr,type(addr),count) end
    local tbl={}

    --get the table
    for i=0,count do
      tbl[i+1] = {
        ["id"]=readInteger(addr+i*16),
        ["val"]=readInteger(addr+i*16+12)
      }
      --print(tbl.id[i+1],tbl.val[i+1])
    end

    --sort the table
    table.sort(tbl, function(t1,t2) return t1.id &lt; t2.id end)

    --write the sorted table
    for i=0,count do
      writeInteger(addr+i*16,tbl[i+1].id)
      writeInteger(addr+i*16+8,tbl[i+1].id)
      writeInteger(addr+i*16+12,tbl[i+1].val)
      print(tbl[i+1].id,tbl[i+1].val)
    end
    --tbl.Destroy()
    if strname=="EStats_SF" then
      struct.Element[1].Destroy()
      struct.Element[0].Destroy()
    end
    --return tbl
end end

-- but its prone to not work in game updates so ... rly ... I do need the index data of EStats
function staticFixStats()
  local pmain = getAddressSafe("[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]+PlayerStats_UW.allStats]+18]+20")
  if pmain then
    local val = readInteger(pmain)
    if val==211 then
      -- no need to check here - addStructForOffsets ensures this exists
      local struct = getStructureByName("EStats_SF")
      local startPreg = struct.Count
      for i=0,struct.Count-1 do
        --print(i,struct.Element[i].Name,struct.Element[i].Offset,(i+2)*16)
        if struct.Element[i].Name=="OTHER_PREGNANT" then
          struct.Element[i].Offset=32
          startPreg=i
        end
        if i &gt; startPreg then
          struct.Element[i].Offset=(i+1)*16
        end
      end
      struct.Element[2].Destroy()
      struct.Element[0].Destroy()
      print("Fixed the table for ya")
    else
      print("No can do man")
    end
  end
end]]

{$asm}

00000000:
nop

[DISABLE]

</AssemblerScript>
        </CheatEntry>
        <CheatEntry>
          <ID>4</ID>
          <Description>"Open Structures"</Description>
          <Options moHideChildren="1"/>
          <GroupHeader>1</GroupHeader>
          <CheatEntries>
            <CheatEntry>
              <ID>41</ID>
              <Description>"Open Items"</Description>
              <Color>0000FF</Color>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  local addr = "[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.items]+18]+18]"
  local strname = "EItems_SF"
  createStructureForm(addr, nil, strname)
{$asm}

00000000:
nop
[DISABLE]
</AssemblerScript>
            </CheatEntry>
            <CheatEntry>
              <ID>42</ID>
              <Description>"Open Stats"</Description>
              <Color>0080FF</Color>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  local addr = "[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]+PlayerStats_UW.allStats]+18]"
  local strname = "EStats_SF"
  createStructureForm(addr, nil, strname)
{$asm}

00000000:
nop
[DISABLE]
</AssemblerScript>
            </CheatEntry>
            <CheatEntry>
              <ID>43</ID>
              <Description>"Open Reputations"</Description>
              <Color>008000</Color>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  local addr = "[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]++PlayerStats_UW.allReps]+18]"
  local strname = "EReputations_SF"
  --SignedStructCheck(strname,addr)
  createStructureForm(addr, nil, strname)
{$asm}

00000000:
nop
[DISABLE]
</AssemblerScript>
            </CheatEntry>
            <CheatEntry>
              <ID>44</ID>
              <Description>"Open Buffs"</Description>
              <Color>A5DADA</Color>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  local addr = "[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]++PlayerStats_UW.allBuffs]+18]"
  local strname = "EBuffType_SF"
  --SignedStructCheck(strname,addr)
  createStructureForm(addr, nil, strname)
{$asm}

00000000:
nop
[DISABLE]
</AssemblerScript>
            </CheatEntry>
            <CheatEntry>
              <ID>45</ID>
              <Description>"Additional Structures (only)"</Description>
              <GroupHeader>1</GroupHeader>
              <CheatEntries>
                <CheatEntry>
                  <ID>451</ID>
                  <Description>"Open Counts (unused?)"</Description>
                  <Color>E798E7</Color>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>[ENABLE]
{$lua}
  local addr = "[[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.stats]++PlayerStats_UW.allCounts]+18]"
  local strname = "ESexCount_SF"
  createStructureForm(addr, nil, strname)
{$asm}

00000000:
nop
[DISABLE]
</AssemblerScript>
                </CheatEntry>
                <CheatEntry>
                  <ID>461</ID>
                  <Description>"Open timeSettings"</Description>
                  <VariableType>Auto Assembler Script</VariableType>
                  <AssemblerScript>[ENABLE]
{$lua}
  local addr = "[[[pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField]+PlayerMain_UW.gameManager]+GameManager_UW.timeSettings]"
  local strname = "TimeSettings_UW"
  createStructureForm(addr, nil, strname)
{$asm}

00000000:
nop
[DISABLE]
</AssemblerScript>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
          </CheatEntries>
        </CheatEntry>
        <CheatEntry>
          <ID>5</ID>
          <Description>"Generate Records to be able to freeze"</Description>
          <Options moHideChildren="1" moDeactivateChildrenAsWell="1"/>
          <GroupHeader>1</GroupHeader>
          <CheatEntries>
            <CheatEntry>
              <ID>51</ID>
              <Description>"Populate Items"</Description>
              <Options moHideChildren="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <Color>0000FF</Color>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  removeMrChilds('BaseItems')
  AppendStructChilds('BaseItems','EItems_SF')
{$asm}

[DISABLE]

{$lua}
  removeMrChilds('BaseItems')
{$asm}
</AssemblerScript>
              <CheatEntries>
                <CheatEntry>
                  <ID>511</ID>
                  <Description>"BaseItems"</Description>
                  <Options moHideChildren="1"/>
                  <ShowAsSigned>0</ShowAsSigned>
                  <GroupHeader>1</GroupHeader>
                  <Address>pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField</Address>
                  <Offsets>
                    <Offset>+0</Offset>
                    <Offset>+18</Offset>
                    <Offset>+18</Offset>
                    <Offset>PlayerMain_UW.items</Offset>
                  </Offsets>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
            <CheatEntry>
              <ID>52</ID>
              <Description>"Populate Stats"</Description>
              <Options moHideChildren="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <Color>0080FF</Color>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  removeMrChilds('BaseStats')
  AppendStructChilds('BaseStats','EStats_SF')
{$asm}

[DISABLE]

{$lua}
  removeMrChilds('BaseStats')
{$asm}
</AssemblerScript>
              <CheatEntries>
                <CheatEntry>
                  <ID>521</ID>
                  <Description>"BaseStats"</Description>
                  <Options moHideChildren="1"/>
                  <ShowAsSigned>0</ShowAsSigned>
                  <GroupHeader>1</GroupHeader>
                  <Address>pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField</Address>
                  <Offsets>
                    <Offset>0</Offset>
                    <Offset>+18</Offset>
                    <Offset>PlayerStats_UW.allStats</Offset>
                    <Offset>PlayerMain_UW.stats</Offset>
                  </Offsets>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
            <CheatEntry>
              <ID>53</ID>
              <Description>"Populate Reputation"</Description>
              <Options moHideChildren="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <Color>008000</Color>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  removeMrChilds('BaseReputation')
  AppendStructChilds('BaseReputation','EReputations_SF')
{$asm}

[DISABLE]

{$lua}
  removeMrChilds('BaseReputation')
{$asm}
</AssemblerScript>
              <CheatEntries>
                <CheatEntry>
                  <ID>531</ID>
                  <Description>"BaseReputation"</Description>
                  <Options moHideChildren="1"/>
                  <ShowAsSigned>0</ShowAsSigned>
                  <GroupHeader>1</GroupHeader>
                  <Address>pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField</Address>
                  <Offsets>
                    <Offset>0</Offset>
                    <Offset>+18</Offset>
                    <Offset>PlayerStats_UW.allReps</Offset>
                    <Offset>PlayerMain_UW.stats</Offset>
                  </Offsets>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
            <CheatEntry>
              <ID>54</ID>
              <Description>"Populate Buffs"</Description>
              <Options moHideChildren="1" moActivateChildrenAsWell="1" moDeactivateChildrenAsWell="1"/>
              <Color>A5DADA</Color>
              <VariableType>Auto Assembler Script</VariableType>
              <AssemblerScript>[ENABLE]
{$lua}
  removeMrChilds('BaseBuffs')
  AppendStructChilds('BaseBuffs','EBuffType_SF')
{$asm}

[DISABLE]

{$lua}
  removeMrChilds('BaseBuffs')
{$asm}
</AssemblerScript>
              <CheatEntries>
                <CheatEntry>
                  <ID>541</ID>
                  <Description>"BaseBuffs"</Description>
                  <Options moHideChildren="1"/>
                  <ShowAsSigned>0</ShowAsSigned>
                  <GroupHeader>1</GroupHeader>
                  <Address>pgobj+GlobalObjects_UW_SF.&lt;playerMain&gt;k__BackingField</Address>
                  <Offsets>
                    <Offset>0</Offset>
                    <Offset>+18</Offset>
                    <Offset>PlayerStats_UW.allBuffs</Offset>
                    <Offset>PlayerMain_UW.stats</Offset>
                  </Offsets>
                </CheatEntry>
              </CheatEntries>
            </CheatEntry>
          </CheatEntries>
        </CheatEntry>
        <CheatEntry>
          <ID>6</ID>
          <Description>"Show Comment (not possible in compact view)"</Description>
          <VariableType>Auto Assembler Script</VariableType>
          <AssemblerScript>[ENABLE]
{$lua}
if not syntaxcheck then
  getMainForm().CommentButton.doClick()
end
{$asm}

00000000:
nop

[DISABLE]

</AssemblerScript>
        </CheatEntry>
      </CheatEntries>
    </CheatEntry>
    <CheatEntry>
      <ID>7</ID>
      <Description>"Print debug infos to report (on errors)"</Description>
      <VariableType>Auto Assembler Script</VariableType>
      <AssemblerScript>[ENABLE]
{$lua}
if syntaxcheck then return end

if not var then
  print("Try enable first please")
  error("No var")
  return
else
  local pgobj = tostring(getAddressSafe("pgobj") or nil)
  local bExtend = tostring(getAddressSafe("bExtend") or nil)
  local monopt
  if monopipe then monopt = tostring(monopipe.OnTimeout) else monopt='nil' end
  print(getCEVersion(),process,' p/m:',pgobj,monopt,' e:',bExtend)

  var.force = true
  switchActiveMR(0)
  switchActiveMR(0,true)
end

{$asm}

[DISABLE]
{$lua}
var.force = false
switchActiveMR(0)
</AssemblerScript>
    </CheatEntry>
  </CheatEntries>
  <UserdefinedSymbols/>
  <Comments>You can add notes here how you like. F.e.
Money &lt; 999999
Condoms,Dildo,Golden_Spoon,Old_Shoe,Metro_VIP max 1
</Comments>
</CheatTable>
