Jump to content

value reset problem


Bunny2001
 Share

Recommended Posts

2 hours ago, nok1a said:

Thanks. Try now @alien420, @Khadimulislam:

  On 2/14/2024 at 12:44 AM, nok1a said:
If your using 64 Bit download this script, should work:

function class_Pointer()
  local range = gg.getRangesList("global-metadata.dat")
  -- get dll pointer UserProfile
  gg.setRanges(gg.REGION_OTHER)
  gg.searchNumber("h00 55 73 65 72 50 72 6F 66 69 6C 65 2E 49 6E 66 72 61 73 74 72 75 63 74 75 72 65 2E 64 6C 6C 00", gg.TYPE_BYTE, nil, nil, range[1].start, range[1]["end"]) -- UserProfile.Infrastructure.dll
  local char_UserProfile = gg.getResults(2)
  gg.setRanges(gg.REGION_ANONYMOUS)
  gg.clearResults()
  gg.searchNumber(char_UserProfile[2].address, gg.TYPE_QWORD)
  local pointerCheck = gg.getResults(1)
  gg.clearResults()
  -- get class pointer JourneyProgress
  gg.setRanges(gg.REGION_OTHER)
  gg.searchNumber("h00 4A 6F 75 72 6E 65 79 50 72 6F 67 72 65 73 73 00", gg.TYPE_BYTE, nil, nil, range[1].start, range[1]["end"]) -- JourneyProgress
  local char_Journey = gg.getResults(2)
  gg.clearResults()
  gg.setRanges(gg.REGION_ANONYMOUS)
  gg.searchNumber(char_Journey[2].address, gg.TYPE_QWORD)
  local t = gg.getResults(gg.getResultsCount())
  for i, v in ipairs(t) do
    v.address = v.address - 0x10
  end
  t = gg.getValues(t)
  local class_Pointer_JourneyProcess = {}
  for i, v in ipairs(t) do
    if v.value == pointerCheck[1].address then
      class_Pointer_JourneyProcess[i] = v.address
    end
  end
  gg.clearResults()
  return class_Pointer_JourneyProcess
end
local class_Pointer_JourneyProcess = class_Pointer()

function field_numberOfCompletedJourney(input)
  local Level = input
  gg.searchNumber(class_Pointer_JourneyProcess[1], gg.TYPE_QWORD)
  local t = gg.getResults(gg.getResultsCount())
  for i, v in ipairs(t) do
    v.address = v.address + 0x190
    v.flags = gg.TYPE_DWORD
  end
  t = gg.getValues(t)
  local numberOfCompletedJourney = {}
  for i, v in ipairs(t) do
    if v.value == (tonumber(Level[1]) - 1) then
      numberOfCompletedJourney[#numberOfCompletedJourney + 1] = t[i]
    end
  end
  if #numberOfCompletedJourney == 0 then
    gg.toast("Level not found, did you input correct level?")
    gg.sleep(100)
  else
    local LevelSet = gg.prompt(
      {'Input desired Level to edit to'},
      {[1]=''},
      {[1]='number'}
    )
    for i, v in ipairs(numberOfCompletedJourney) do
      v.value = tonumber(LevelSet[1]) - 1
    end
    gg.setValues(numberOfCompletedJourney)
    gg.toast("Level set, go in game and back to lobby for apply the change visually")
  end
  gg.clearResults()
end


function start()
  local Level = gg.prompt(
    {'Input your current Level'},
    {[1]=''},
    {[1]='number'}
  )
  if Level == nil then
    gg.toast("No input")
  else
    local nonNumb = 0
    for i in string.gmatch(Level[1], "%U") do
      local char = string.byte(i)
      if char < 0x30 or char > 0x39 then
        nonNumb = nonNumb + 1
      end
      if nonNumb ~= 0 then
        gg.toast("This is not a number")
      else
        field_numberOfCompletedJourney(Level)
        break
      end
    end
  end
end

while (true) do
  if gg.isVisible() then
    gg.setVisible(false)
    start()
  end
  gg.sleep(100) 
end

 

Showing this error

Screenshot_2024-04-14-18-03-39-327_games.burny.playdoku.block.puzzle.jpg

Link to comment
Share on other sites

1 hour ago, Khadimulislam said:

Showing this error

Screenshot_2024-04-14-18-03-39-327_games.burny.playdoku.block.puzzle.jpg

Can you try this:
 

function class_Pointer()
  local range = gg.getRangesList("global-metadata.dat")
  -- get dll pointer UserProfile
  gg.setRanges(gg.REGION_OTHER)
  gg.searchNumber("h00 55 73 65 72 50 72 6F 66 69 6C 65 2E 49 6E 66 72 61 73 74 72 75 63 74 75 72 65 2E 64 6C 6C 00", gg.TYPE_BYTE, nil, nil, range[1].start, range[1]["end"]) -- UserProfile.Infrastructure.dll
  local char_UserProfile = gg.getResults(2)
  gg.setRanges(gg.REGION_ANONYMOUS)
  gg.clearResults()
  gg.searchNumber(char_UserProfile[2].address, gg.TYPE_QWORD)
  local pointerCheck = gg.getResults(1)
  gg.clearResults()
  -- get class pointer JourneyProgress
  gg.setRanges(gg.REGION_OTHER)
  gg.searchNumber("h00 4A 6F 75 72 6E 65 79 50 72 6F 67 72 65 73 73 00", gg.TYPE_BYTE, nil, nil, range[1].start, range[1]["end"]) -- JourneyProgress
  local char_Journey = gg.getResults(2)
  gg.clearResults()
  gg.setRanges(gg.REGION_ANONYMOUS)
  gg.searchNumber(char_Journey[2].address, gg.TYPE_QWORD)
  local t = gg.getResults(gg.getResultsCount())
  for i, v in ipairs(t) do
    v.address = v.address - 0x10
  end
  t = gg.getValues(t)
  local class_Pointer_JourneyProcess = {}
  for i, v in ipairs(t) do
    if v.value == pointerCheck[1].address then
      class_Pointer_JourneyProcess[#class_Pointer_JourneyProcess + 1] = v.address
    end
  end
  gg.clearResults()
  return class_Pointer_JourneyProcess
end
local class_Pointer_JourneyProcess = class_Pointer()

function field_numberOfCompletedJourney(input)
  local Level = input
  gg.searchNumber(class_Pointer_JourneyProcess[1], gg.TYPE_QWORD)
  local t = gg.getResults(gg.getResultsCount())
  for i, v in ipairs(t) do
    v.address = v.address + 0x190
    v.flags = gg.TYPE_DWORD
  end
  t = gg.getValues(t)
  local numberOfCompletedJourney = {}
  for i, v in ipairs(t) do
    if v.value == (tonumber(Level[1]) - 1) then
      numberOfCompletedJourney[#numberOfCompletedJourney + 1] = t[i]
    end
  end
  if #numberOfCompletedJourney == 0 then
    gg.toast("Level not found, did you input correct level?")
    gg.sleep(100)
  else
    local LevelSet = gg.prompt(
      {'Input desired Level to edit to'},
      {[1]=''},
      {[1]='number'}
    )
    for i, v in ipairs(numberOfCompletedJourney) do
      v.value = tonumber(LevelSet[1]) - 1
    end
    gg.setValues(numberOfCompletedJourney)
    gg.toast("Level set, go in game and back to lobby for apply the change visually")
  end
  gg.clearResults()
end
function start()
  local Level = gg.prompt(
    {'Input your current Level'},
    {[1]=''},
    {[1]='number'}
  )
  if Level == nil then
    gg.toast("No input")
  else
    local nonNumb = 0
    for i in string.gmatch(Level[1], "%U") do
      local char = string.byte(i)
      if char < 0x30 or char > 0x39 then
        nonNumb = nonNumb + 1
      end
      if nonNumb ~= 0 then
        gg.toast("This is not a number")
      else
        field_numberOfCompletedJourney(Level)
        break
      end
    end
  end
end
while (true) do
  if gg.isVisible() then
    gg.setVisible(false)
    start()
  end
  gg.sleep(100) 
end

 

Link to comment
Share on other sites

5 hours ago, nok1a said:

Can you try this:
 

function class_Pointer()
  local range = gg.getRangesList("global-metadata.dat")
  -- get dll pointer UserProfile
  gg.setRanges(gg.REGION_OTHER)
  gg.searchNumber("h00 55 73 65 72 50 72 6F 66 69 6C 65 2E 49 6E 66 72 61 73 74 72 75 63 74 75 72 65 2E 64 6C 6C 00", gg.TYPE_BYTE, nil, nil, range[1].start, range[1]["end"]) -- UserProfile.Infrastructure.dll
  local char_UserProfile = gg.getResults(2)
  gg.setRanges(gg.REGION_ANONYMOUS)
  gg.clearResults()
  gg.searchNumber(char_UserProfile[2].address, gg.TYPE_QWORD)
  local pointerCheck = gg.getResults(1)
  gg.clearResults()
  -- get class pointer JourneyProgress
  gg.setRanges(gg.REGION_OTHER)
  gg.searchNumber("h00 4A 6F 75 72 6E 65 79 50 72 6F 67 72 65 73 73 00", gg.TYPE_BYTE, nil, nil, range[1].start, range[1]["end"]) -- JourneyProgress
  local char_Journey = gg.getResults(2)
  gg.clearResults()
  gg.setRanges(gg.REGION_ANONYMOUS)
  gg.searchNumber(char_Journey[2].address, gg.TYPE_QWORD)
  local t = gg.getResults(gg.getResultsCount())
  for i, v in ipairs(t) do
    v.address = v.address - 0x10
  end
  t = gg.getValues(t)
  local class_Pointer_JourneyProcess = {}
  for i, v in ipairs(t) do
    if v.value == pointerCheck[1].address then
      class_Pointer_JourneyProcess[#class_Pointer_JourneyProcess + 1] = v.address
    end
  end
  gg.clearResults()
  return class_Pointer_JourneyProcess
end
local class_Pointer_JourneyProcess = class_Pointer()

function field_numberOfCompletedJourney(input)
  local Level = input
  gg.searchNumber(class_Pointer_JourneyProcess[1], gg.TYPE_QWORD)
  local t = gg.getResults(gg.getResultsCount())
  for i, v in ipairs(t) do
    v.address = v.address + 0x190
    v.flags = gg.TYPE_DWORD
  end
  t = gg.getValues(t)
  local numberOfCompletedJourney = {}
  for i, v in ipairs(t) do
    if v.value == (tonumber(Level[1]) - 1) then
      numberOfCompletedJourney[#numberOfCompletedJourney + 1] = t[i]
    end
  end
  if #numberOfCompletedJourney == 0 then
    gg.toast("Level not found, did you input correct level?")
    gg.sleep(100)
  else
    local LevelSet = gg.prompt(
      {'Input desired Level to edit to'},
      {[1]=''},
      {[1]='number'}
    )
    for i, v in ipairs(numberOfCompletedJourney) do
      v.value = tonumber(LevelSet[1]) - 1
    end
    gg.setValues(numberOfCompletedJourney)
    gg.toast("Level set, go in game and back to lobby for apply the change visually")
  end
  gg.clearResults()
end
function start()
  local Level = gg.prompt(
    {'Input your current Level'},
    {[1]=''},
    {[1]='number'}
  )
  if Level == nil then
    gg.toast("No input")
  else
    local nonNumb = 0
    for i in string.gmatch(Level[1], "%U") do
      local char = string.byte(i)
      if char < 0x30 or char > 0x39 then
        nonNumb = nonNumb + 1
      end
      if nonNumb ~= 0 then
        gg.toast("This is not a number")
      else
        field_numberOfCompletedJourney(Level)
        break
      end
    end
  end
end
while (true) do
  if gg.isVisible() then
    gg.setVisible(false)
    start()
  end
  gg.sleep(100) 
end

 

Awesome Brother. 
Now this Code Working
Your are very Good Coder 
How can i learn coding like you?

Link to comment
Share on other sites

On 4/15/2024 at 12:41 AM, Khadimulislam said:

Awesome Brother. 
Now this Code Working
Your are very Good Coder 
How can i learn coding like you?

I don't know, I would pick a game and do something simple like look for ammo value and change it with GG manually. Then try to make a Lua script for it. Download a simple Lua script from the forum and try to understand how it is making changes to the game. There is some nice documentation we use: https://gameguardian.net/help/classgg.html

 

Link to comment
Share on other sites

  • 2 weeks later...
On 4/16/2024 at 5:15 PM, nok1a said:

I don't know, I would pick a game and do something simple like look for ammo value and change it with GG manually. Then try to make a Lua script for it. Download a simple Lua script from the forum and try to understand how it is making changes to the game. There is some nice documentation we use: https://gameguardian.net/help/classgg.html

 

Brother again updated 😴

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.