Simple game display menu

User Tag List

Results 1 to 15 of 15
  1. #1
    allahupish's Avatar Member
    Reputation
    3
    Join Date
    Jan 2016
    Posts
    28
    Thanks G/R
    1/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Simple game display

    so I'm making a simple health/energy shield display in visual basic program and I need a bit of help, I can get the address but I need to scan it every time i restart the game. I would like to get it from offsets but I don't know how

    Here is example code:


    HTML Code:
    Imports System.Runtime.InteropServices
    Imports System
    Imports System.Text
    
    Private Declare Function ReadProcessMemory Lib "kernel32" (
                ByVal hProcess As Integer,
                ByVal lpBaseAddress As Integer,
                ByRef lpBuffer As Integer,
                ByVal nSize As Integer,
                ByRef lpNumberOfBytesWritten As Integer
            ) As Integer
    
    Private Sub Timer1_Tick(sender As Object, e As EventArgs) Handles Timer1.Tick
            Dim address As Integer
            address = &H28A75994&
            Dim floatvalueinmemory As Single = 0
            Dim proc As Process = Process.GetCurrentProcess
            For Each proc In Process.GetProcesses
                If proc.MainWindowTitle = "Path of Exile" Then
                    If ReadProcessMemory(proc.Handle.ToInt32(), address, floatvalueinmemory, 4, 0) = 0 Then
                        MsgBox("Not Working")
                    Else
                        Label1.Text = CInt(floatvalueinmemory)
                    End If
                End If
            Next
        End Sub
    I don't know how to put base address and offsets in for lets say, energy shield or HP. If someone can help me please, Visual Basic 2015.

    Simple game display
  2. Thanks toadskin (1 members gave Thanks to allahupish for this useful post)
  3. #2
    Sharps's Avatar Contributor CoreCoins Purchaser
    Reputation
    117
    Join Date
    Apr 2012
    Posts
    138
    Thanks G/R
    31/70
    Trade Feedback
    8 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Dim addr1 As Int32 = Memory.ReadInt(0xbaseaddress) + offset1
    Dim addr2 As Int32 = Memory.ReadInt(addr1) + offset2
    Dim finalAddress As Int32 = Memory.ReadInt(addr2)

    I guess you're looking for something like that for a multi level pointer?

  4. Thanks toadskin (1 members gave Thanks to Sharps for this useful post)
  5. #3
    allahupish's Avatar Member
    Reputation
    3
    Join Date
    Jan 2016
    Posts
    28
    Thanks G/R
    1/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'd really need some help, I'm looking around the internet and trying everything, specifically off cheatengine site, it's not working

  6. #4
    allahupish's Avatar Member
    Reputation
    3
    Join Date
    Jan 2016
    Posts
    28
    Thanks G/R
    1/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    can someone at least help me setup some sort of Health energy shield flask reader with autoscript ?

  7. #5
    dlr5668's Avatar Contributor
    Reputation
    279
    Join Date
    May 2012
    Posts
    543
    Thanks G/R
    129/226
    Trade Feedback
    0 (0%)
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by allahupish View Post
    can someone at least help me setup some sort of Health energy shield flask reader with autoscript ?
    No, but here is working x86 flask script PoE Autoflask & AutoScript, Improvements and updates. (PoE Autoflask & AutoScript, Improvements and updates.) .
    You can start from here
    github.com/vadash/EZVendor

  8. #6
    allahupish's Avatar Member
    Reputation
    3
    Join Date
    Jan 2016
    Posts
    28
    Thanks G/R
    1/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    can someone help me to get this working:

    Path Of Exile reading pointers example - Gaming Scripts - AutoHotkey Community

    I don't know where to input the new offset addresses.

  9. #7
    Treasure_Box's Avatar Contributor
    Reputation
    155
    Join Date
    Sep 2014
    Posts
    189
    Thanks G/R
    63/130
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Based on my own personal experience, I would say you are better off looking else were, rather than this sub-forum if you are seeking help with learning how to find pointer offsets, programing in C#, ect.

    It really boils down to this: Most of the people here are just users, no real desire to learn how to code or put in the effort, they just want to consume and complain if something doesn't work for them. The majority can' t even be bothered to read a few pages back to often times find a solution to their problem(s).

    Then you have the few that know how things work and how to put stuff together, but be it because of time constraints, lack of interest, or because they view it as a loss of profits they are not going to be the people that you can seek help from if you are just getting started or lack the same level of experience that they feel they have.

    I've been dumping a ton of time into educational videos, and books trying to teach myself C#, and its going at a snails pace, so i understand the frustration that some may have.
    As much as this may be a disappointment, honestly this isn't unfair, this is just the reality of things.
    Last edited by Treasure_Box; 01-09-2017 at 03:25 AM.

  10. Thanks toadskin (1 members gave Thanks to Treasure_Box for this useful post)
  11. #8
    milkbananas's Avatar Member
    Reputation
    2
    Join Date
    Oct 2013
    Posts
    10
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by allahupish View Post
    I need to scan it every time i restart the game.
    You can find the pointers with cheat engine. Once you find the health address right click it and select "Pointer scan for this address".
    Default setup should be good. Once it's done restart your game and reattach cheat engine. Then in the pointer scan window select "pointer scanner" -> "Rescan memory".
    Repeat the operation a few times to make sure the pointers you choose is good.

  12. Thanks toadskin (1 members gave Thanks to milkbananas for this useful post)
  13. #9
    rtoqwo's Avatar Private
    Reputation
    6
    Join Date
    Nov 2016
    Posts
    2
    Thanks G/R
    0/5
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    using GitHub - Kalamity/classMemory: An AHK memory reading/writing class with pattern scans. you'll get a working DX11/64bits auto flasker in a few lines of code :
    Code:
    #SingleInstance force
    ;https://github.com/Kalamity/classMemory : memory reading library
    #Include classMemory.ahk
    SetFormat, Integer, hex
    
    ;=================startup load the frameBase (IngameState)===============
    
    ;https://github.com/TehCheat/PoEHUD/tree/x64/src/Poe/Offsets.cs:        private static readonly Pattern basePtrPattern = new Pattern(new byte[]
    basePtrPattern:=[0x40, 0x53, 0x48, 0x83, 0xEC, 0x50, 0x48, 0xC7, 0x44, 0x24, 0x20, 0xFE, 0xFF, 0xFF, 0xFF, 0xC7, 0x44, 0x24, 0x60, 0x00, 0x00, 0x00, 0x00, 0x48, 0x8b, 0x05]
    
    cliexe:="PathOfExile_x64.exe"
    
    while WinID!=1
    {
    	;waiting for the game
    	WinGet, WinID, List, ahk_exe %cliexe%
    	Sleep, 1000
    }
    
    global poe := new _ClassMemory("ahk_exe " . cliexe, "", hProcessCopy)
    PatternIsAt:=poe.modulePatternScan(cliexe, basePtrPattern*)-poe.BaseAddress
    
    ;https://github.com/TehCheat/PoEHUD/tree/x64/src/Poe/Offsets.cs :        Base = m.ReadInt(m.AddressOfProcess + array[0] + 0x1A) + array[0] + 0x1E;
    baseMgrPtr:=poe.read(poe.BaseAddress+PatternIsAt+0x1A, "UInt")+PatternIsAt+0x1E
    
    ;https://github.com/TehCheat/PoEHUD/tree/x64/src/Poe/RemoteMemoryObjects/TheGame.cs :       Address = m.ReadLong(Offsets.Base + m.AddressOfProcess, 0x8, 0xf8);
    ;https://github.com/TehCheat/PoEHUD/tree/x64/src/Poe/RemoteMemoryObjects/TheGame.cs :       public IngameState IngameState => ReadObject<IngameState>(Address + 0x38);
    global frameBase:=poe.read(poe.BaseAddress+baseMgrPtr, "Int64", 0x8, 0xf8, 0x38)
    global IngameState:=frameBase
    
    ;=======================retrieve current data============================
    
    readPlayerStats(byRef PlayerStats){
    	
    	;https://github.com/TehCheat/PoEHUD/tree/x64/src/Poe/RemoteMemoryObjects/IngameState.cs :       public IngameData Data => ReadObject<IngameData>(Address + 0x160 + Offsets.IgsOffset);
    	InGameData:=poe.read(IngameState+0x160, "Int64")
    	
    	PlayerStats.isInGame:=False
    	if(InGameData>0xffff){
    		PlayerStats.isInGame:=True
    		
    		;https://github.com/TehCheat/PoEHUD/tree/x64/src/Poe/RemoteMemoryObjects/IngameData.cs :        public Entity LocalPlayer => ReadObject<Entity>(Address + 0x180);
    		LocalPlayer:=poe.read(InGameData+0x180, "Int64")
    		
    		;https://github.com/badplayerr/beta-autopot/blob/master/Autopot.ahk :         PlayerMain:=ReadMemUInt(pH,PlayerBase+4)       PlayerStatsOffset:=ReadMemUInt(pH,PlayerMain+0xC)
    		LPLifeComponent:=poe.read(LocalPlayer+0x8, "Int64", 0x18)
    		
    		;https://github.com/TehCheat/PoEHUD/tree/x64/src/Poe/Components/Life.cs :      public int CurHP => Address != 0 ? M.ReadInt(Address + 0x54) : 1;   public int CurMana => Address != 0 ? M.ReadInt(Address + 0x84) : 1;
    		poe.readRaw(LPLifeComponent, LifeStructure, 0xB8)
    		curHP:=NumGet(LifeStructure, 0x54, "UInt")
    		maxHP:=NumGet(LifeStructure, 0x50, "UInt")
    		
    		if(maxHP>0 and curHP>0){
    			PlayerStats.hp:=(curHP*1.0)/(maxHP*1.0)
    		}else{
    			PlayerStats.hp:=0.0
    		}
    	}
    }
    
    ;==========================main program loop===============================
    
    lastPopo:=A_TickCount
    PlayerStats:=Object()
    loop
    {
    	readPlayerStats(PlayerStats)
    	if(PlayerStats.isInGame=True){
    		if(PlayerStats.hp>0.0){
    			now:=A_TickCount
    			if((PlayerStats.hp<0.8 and now-lastPopo>5000) or (PlayerStats.hp<0.4 and now-lastPopo>1000)){
    				lastPopo:=now
    				Send, {1 Down}
    				Sleep, 30
    				Send, {1 Up}
    			}
    		}
    	}
    	Sleep, 30
    }
    
    ;============================================================================
    
    SC029 & NumpadSub::
    	ExitApp
    Return
    
    SC029 & NumpadAdd::
    	reload
    Return
    You'll need to install/reinstall the 64 bits autoHotKey_L to test it. It'll pop the flask in your slot 1 whenever you're health drops under 80%/40% if this works. Also note that most useful information for your bots can be very easily fetched starting from the frameBase (IngameState) in PoE. So that's the important pointer to find for reference or dumb scanning, before the health/mana/.. data.

  14. Thanks TehCheat, dlr5668, toadskin, Treasure_Box, Xcesiuss (5 members gave Thanks to rtoqwo for this useful post)
  15. #10
    allahupish's Avatar Member
    Reputation
    3
    Join Date
    Jan 2016
    Posts
    28
    Thanks G/R
    1/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I can see in cheat engine, flask charges, skills timers, buffs, everything, I need a little help in how to setup in VB so I can read them and display in my little program. I don't need another stupid health pot program, I'm making something different. So far I manually have to input every adress witch is a pain in the ass, I wish I could code in the primary address and offsets (just update them every time game patches)

  16. #11
    Treasure_Box's Avatar Contributor
    Reputation
    155
    Join Date
    Sep 2014
    Posts
    189
    Thanks G/R
    63/130
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by allahupish View Post
    I can see in cheat engine, flask charges, skills timers, buffs, everything, I need a little help in how to setup in VB so I can read them and display in my little program. I don't need another stupid health pot program, I'm making something different. So far I manually have to input every adress witch is a pain in the ass, I wish I could code in the primary address and offsets (just update them every time game patches)
    Not sure that is possible, as even with Guruds AHK AutoPot program uses an additional script to preform a AOB scan of the address shifts "AutoHotkeyMemoryLib.ahk"
    Last edited by Treasure_Box; 01-10-2017 at 03:01 AM.

  17. #12
    GameHelper's Avatar ★ Elder ★ CoreCoins Purchaser
    Reputation
    2455
    Join Date
    Jun 2015
    Posts
    3,049
    Thanks G/R
    455/2200
    Trade Feedback
    0 (0%)
    Mentioned
    65 Post(s)
    Tagged
    1 Thread(s)
    [CODE]Signature Scanning


    just a guess, does this helps?
    If I did not reply to you, it mean the question you are asking is stupid.

  18. #13
    TehCheat's Avatar ★ Elder ★
    Reputation
    2560
    Join Date
    Oct 2013
    Posts
    1,898
    Thanks G/R
    347/2262
    Trade Feedback
    5 (100%)
    Mentioned
    32 Post(s)
    Tagged
    1 Thread(s)
    Originally Posted by allahupish View Post
    I can see in cheat engine, flask charges, skills timers, buffs, everything, I need a little help in how to setup in VB so I can read them and display in my little program. I don't need another stupid health pot program, I'm making something different. So far I manually have to input every adress witch is a pain in the ass, I wish I could code in the primary address and offsets (just update them every time game patches)
    First of all, I don't know if you're trying to do this in x86 or x64 so it's hard for me to hold your hand enough to get you through it.

    Secondly, these flask programs show you *exactly* how to do what you're hoping to do. In fact the very first memory reading program I did in PoE, I looked over an ahk flask script to find everything I needed (a base pattern to find a base offset and offsets from there to other structures that I needed) and wrote what has evolved into my private auto flasker in c#. So I'd strongly suggest looking over these ahk scripts. Even if you don't understand the syntax, it's pretty easy to get what you need out of it. There's a pattern to scan for (you can certainly find a visual basic function to find patterns, just google it). There are offsets from the base pattern. Just follow what they do.

  19. #14
    allahupish's Avatar Member
    Reputation
    3
    Join Date
    Jan 2016
    Posts
    28
    Thanks G/R
    1/2
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Visual Basic 2015 for poe x32, I wan't to do it all inside VB. C+ and autohotkey work almost similarly. Reason why I use VB is because i know VB, I need 3 months to learn C+. If I could just have the code solved on how to work the offsets and how to find them in cheat engine, just that small thing. I tried array pattern searching it failed, I looked over 40 youtube tutorials for searching offets and I cant find out does it work from playerbase, healthbase. I'm writing these adresses in hex like this: &H28A75994& when they start in different format like 0x0054 I get confused.

  20. #15
    TehCheat's Avatar ★ Elder ★
    Reputation
    2560
    Join Date
    Oct 2013
    Posts
    1,898
    Thanks G/R
    347/2262
    Trade Feedback
    5 (100%)
    Mentioned
    32 Post(s)
    Tagged
    1 Thread(s)
    Originally Posted by allahupish View Post
    Visual Basic 2015 for poe x32, I wan't to do it all inside VB. C+ and autohotkey work almost similarly. Reason why I use VB is because i know VB, I need 3 months to learn C+. If I could just have the code solved on how to work the offsets and how to find them in cheat engine, just that small thing. I tried array pattern searching it failed, I looked over 40 youtube tutorials for searching offets and I cant find out does it work from playerbase, healthbase. I'm writing these adresses in hex like this: &H28A75994& when they start in different format like 0x0054 I get confused.
    So for x86 you'd search for these bytes in memory:
    Code:
        0x50, 0x64, 0x89, 0x25, 0x00, 0x00, 0x00, 0x00, 0x83, 0xEC, 0x20, 0xC7, 0x45, 0xF0, 0x00, 0x00, 0x00, 0x00, 0xA1
    So we're looking for a pointer (4 bytes, because x86) that follows directly after this pattern. So to read where that pointer points to, we need to add 19 (or 0x13) to where we found the pattern (the pattern is 19 bytes long, which is where that number is coming from).

    So if you read the 4 byte int value at that found pattern + 0x13, you'll be pointed to a new object. HUD sort of calls this base, but it doesn't really have an object for it, it just uses an int to store the offset. From there it reads the first 4 bytes of the 'base' object and gets pointed to a new object (HUD actually doesn't use an object here, it uses a multi-level pointer to get to where it wants to, I'd suggest looking this up if you are unfamiliar, rather than worrying about naming every structure you can skip through several structures at once and only worry about naming the important ones). Then in this object it reads the pointer at offset 4 and gets a new object. Then in this new object, it reads the pointer at offset 0xFC. Then in this new object it reads the object at offset 0x1C and this is what HUD calls InGameState.

    Inside of InGameState you can read a pointer at offset 0x138 and get what HUD calls InGameData. Inside InGameData you can read the offset at 0x144 and this is your local player's entity. Inside the local player entity, you can read the pointer at localplayer + 0x4 and get a component list (the ahk script calls this player main, I think). This component list is a list of pointers, to get the Life component (ahk script calls this playerstats), you'd read the 4th pointer, which is at offset 0xC. So now you have the life component. Inside the life component you can read values at the following offsets:
    Code:
    0x2C - MaxHP 
    0x30 - CurrentHP
    0x38 - ReservedHP
    0x50 - MaxMana
    0x54 - CurrentMana
    0x5C - ReservedMana
    0x74 - MaxES
    0x78 - CurrentES

  21. Thanks GameHelper, OO42O (2 members gave Thanks to TehCheat for this useful post)

Similar Threads

  1. [Guide] Simple Way To Find Display ID - Without Programs
    By Sajakain in forum WoW EMU Guides & Tutorials
    Replies: 6
    Last Post: 10-15-2008, 01:50 PM
  2. [Release] Game Object Display Patch
    By Matis02 in forum World of Warcraft Emulator Servers
    Replies: 40
    Last Post: 07-21-2008, 08:14 PM
  3. simple, the confidence game
    By aazz in forum WoW Scam Prevention
    Replies: 11
    Last Post: 04-17-2008, 12:33 PM
  4. May someone give a simple analogy about Ascent Game Object Adding?
    By tyman2006 in forum World of Warcraft Emulator Servers
    Replies: 4
    Last Post: 12-16-2007, 02:13 PM
  5. simple, but funny game
    By ayadew in forum Community Chat
    Replies: 3
    Last Post: 06-07-2007, 07:10 PM
All times are GMT -5. The time now is 08:15 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search