OutdatedTrove AutoHotkey Scripts

Posts 61–75 of 122 · Page 5 of 9
Quote Originally Posted by reeferuk1 View Post
Yeah ok, I bet its not even complicated.
It is. search on Youtube "how to find pointers in cheat engine" so you can have a small idea of what are we talking about.
Quote Originally Posted by reeferuk1 View Post
Yeah ok, I bet its not even complicated.
It is.. I tried years ago when I was into coding, finding a base address is pretty difficult
Yeah i see now, i guess if you've already found it before, makes things much easier.
Auto-fishing is not pulling the fish back!
Quote Originally Posted by nagenick View Post
Auto-fishing is not pulling the fish back!
Everyone knows mate, waiting for someone to find/post the new address for popped lures.
you can edit the code simply by deleting the 'numpad' part, then the hotkeys would be only the numbers
Ugh, looks like I won't be botting tonight
Quote Originally Posted by Xaymar View Post
  1. Start Trove.
  2. Wait for login to be complete.
  3. Find a body of fishable liquid (water, lava, choco). (For me, that's in the Club World)
  4. Launch the script file needed.
  5. Aim so that you don't hit ground or walls.
  6. Press Ctrl + Numpad / and enjoy automatic fishing.
  7. Occasionally check Inventory for boots while script is active and drop them.

That's all I do.
I do the exact same thing, strange.
Win 7 32 or 64?
AHK Verson number?
Which installation?
32, 64 or ansi?
Quote Originally Posted by Crassmaker View Post
I do the exact same thing, strange.
Win 7 32 or 64?
AHK Verson number?
Which installation?
32, 64 or ansi?
Its because the patch just came out.
Nah, I also tested the script with the new offsets, so that has nothing to do with the patch, otherwise I wouldn't post dude


[EDIT]
I switched to Fullscreen Windowed, now it works like a charme.
Windowed didn't work for me o.O
Quote Originally Posted by Crassmaker View Post
Nah, I also tested the script with the new offsets, so that has nothing to do with the patch, otherwise I wouldn't post dude


[EDIT]
I switched to Fullscreen Windowed, now it works like a charme.
Windowed didn't work for me o.O
What new offsets?
hzt posted 8 hours ago:
water "trove.exe"+00964208 +144 + e4 + 70
lava "trove.exe"+00964208 +144 + e4 +514
choco "trove.exe"+00964208 +144 + e4 +2c0

So I edited this line:
Code:
;- Pointers
    Base := getProcessBaseAddress(HWND)
    WaterAddress := GetAddressWater(PID, Base, 0x009570DC) 
    LavaAddress := GetAddressLava(PID, Base, 0x009570DC) 
    ChocoAddress := GetAddressChoco(PID, Base, 0x009570DC)
to this:
Code:
;- Pointers
    Base := getProcessBaseAddress(HWND)
    WaterAddress := GetAddressWater(PID, Base, 0x00964208) 
    LavaAddress := GetAddressLava(PID, Base, 0x00964208) 
    ChocoAddress := GetAddressChoco(PID, Base, 0x00964208)
I am like... really new to using these, I don't understand what I am opening up... like, can someone tell me how to actually open it?
Quote Originally Posted by xSTANDBYxKING View Post
I am like... really new to using these, I don't understand what I am opening up... like, can someone tell me how to actually open it?
for me too pls. i open it right step by step and it dont work. Anyone know what i can do ?
To stay with the source of the Thread owner:

Download AutoHotKey, search on google, then save the following code as "Trove.ahk"
Code:
AntiAFK_Code(Index, Key, ByRef RunningVar, ByRef StopVar)
{
    ;- Check if the HotKey is already running.
    if RunningVar
    {
        ; Let's signal the running thread it to stop.
        StopVar := true
        return
    }
    
    ;- Make sure that we actually have a Trove window targeted.
    if not WinActive("Trove")
        return
    
    ;- Signal that we have officially been able to start.
    RunningVar := true
    
    ;- If it's not running, we'll start by grabbing information about the games window.
    WinGet, PID, PID, A
    WinGet, HWND, ID, A
    
    ; Show a tooltip at the windows position.
    CoordMode, ToolTip, Screen
    WinGetPos, winX, winY, winW, winH, ahk_pid %PID%
        
    ;- The actual loop that does our work.
    Timer := 0
    Time_Start := A_TickCount
    Loop
    {
        ; Avoiding AFK is as simple as opening up the Character menu.
        ControlSend, , {c down}, ahk_pid %PID%
        Sleep, 86
        ControlSend, , {c up}, ahk_pid %PID%

        ; Sleep in order to not look like a spammer.
        Random, SleepTime, 5, 50
        Loop %SleepTime%
        {
            ; Check if we should stop.
            if StopVar
                break 2
            
            ; Display AFK time.
            CoordMode, ToolTip, Screen
            WinGetPos, winX, winY, winW, winH, ahk_pid %PID%
            Time := A_TickCount - Time_Start
            ToolTipText =
(
Anti-AFK Bot %Index% is running, press %Key% to stop it.
    Total Time: %Time% ms.
)
            ToolTip, %ToolTipText%, %winX%, %winY%
            
            Random, SleepTime, 86, 111
            Sleep, %SleepTime%
            Timer := Timer + 1
        }
    }
    
    ; Reset state for re-use.
    RunningVar := false
    StopVar := false
    ToolTip, , , , 1
}

AutoFishing_Code(Index, Key, ByRef RunningVar, ByRef StopVar)
{
    ;- Check if the HotKey is already running.
    if RunningVar
    {
        ; Let's signal the running thread it to stop.
        StopVar := true
        return
    }
    
    ;- Make sure that we actually have a Trove window targeted.
    if not WinActive("Trove")
        return
    
    ;- Signal that we're running now.
    RunningVar := true
    
    ;- If it's not running, we'll start by grabbing information about the games window.
    WinGet, PID, PID, A
    WinGet, HWND, ID, A
    
    ;- Pointers
    Base := getProcessBaseAddress(HWND)
    WaterAddress := GetAddressWater(PID, Base, 0x00964208) 
    LavaAddress := GetAddressLava(PID, Base, 0x00964208) 
    ChocoAddress := GetAddressChoco(PID, Base, 0x00964208)
    
    ;- Statistics
    Time_Start := A_TickCount
    Time := 0
    Fishing_Start := A_TickCount
    Fishing := 0
    Fish := 0
    
    HumanPressButton(b, ahk_pid %PID%)
    
    
    ; The main loop based on a State-Machine.
    State=0
    Loop
    {
        ; Show a tooltip at the windows position.
        CoordMode, ToolTip, Screen
        WinGetPos, winX, winY, winW, winH, ahk_pid %PID%
        Time := A_TickCount - Time_Start
        ToolTipText=
(
Auto-Fishing Bot %Index% is running, press %Key% to stop it.
    Total Time: %Time% ms
    Total Fish Caught: %Fish%
    Fishing Time: %Fishing% ms
    State: %State%/%StateNext%
)
        ToolTip, %ToolTipText%, %winX%, %winY%, 1s
        
        ;- State-Machine
        If IsLabel("AutoFishing-" . State)
        {
            Loop 1 {
                Goto AutoFishing-%State%
                
                ; State: Anti-AFK
                AutoFishing-0:
                AutoFishing-AntiAFK-Init:
                    ControlSend, , {c down}, ahk_pid %PID%
                    
                    ; Advance
                    State=AntiAFK
                    StateTimer=0
                    Break
                AutoFishing-AntiAFK:
                    ControlSend, , {c up}, ahk_pid %PID%
                    
                    ; Advance
                    State=AntiDetection-Init
                    StateNext=ThrowHook-Init
                    StateTimer=0
                    Break
                
                ; State: Throw Hook
                AutoFishing-2:
                AutoFishing-ThrowHook-Init:
                    ControlSend, , {f down}, ahk_pid %PID%
                    
                    ; Advance
                    State=ThrowHook
                    StateTimer=0
                    Random, StateMaxTimer, 2, 15
                    Break
                AutoFishing-ThrowHook:
                    ControlSend, , {f up}, ahk_pid %PID%
                    
                    ; Time Display
                    Fishing_Start := A_TickCount
                    
                    ; Advance
                    State=AntiDetection-Init
                    StateNext=Prepare
                    Break
                
                ; State: Prepare for Check
                AutoFishing-Prepare:
                    ; Update Statistics
                    Fishing := A_TickCount - Fishing_Start
                    
                    ; Read memory to determine if we're in the pool of things (it's 1 until it hits the surface).
                    CaughtWater := ReadMemory(PID, WaterAddress)
                    CaughtLava := ReadMemory(PID, LavaAddress)
                    CaughtChoco := ReadMemory(PID, ChocoAddress)
                    
                    if !(CaughtWater || CaughtLava || CaughtChoco)
                    {
                        State=Check
                    }
                    else {
                        ; If 5 seconds have passed, assume we hit the ground and reset.
                        If (Fishing > 5000)
                            State=0
                    }
                    
                    Break
                
                ; State: Check for Fish
                AutoFishing-Check:
                    ; Update Statistics
                    Fishing := A_TickCount - Fishing_Start
                    
                    ; Read memory to determine if we have something hooked or not.
                    ; (Can we do this without reading memory? This is easily detectable, we'd have to mask it like a virus scanner.)
                    CaughtWater := ReadMemory(PID, WaterAddress)
                    CaughtLava := ReadMemory(PID, LavaAddress)
                    CaughtChoco := ReadMemory(PID, ChocoAddress)
                    
                    if (CaughtWater || CaughtLava || CaughtChoco)
                    {
                        Fish := Fish + 1
                        
                        State=AntiDetection-Init
                        StateNext=ReelIn-Init
                    }
                    else 
                    {
                        ; If 45 seconds have passed, we're bugged so reset.
                        if (Fishing > 45000)
                        {
                            State=AntiDetection-Init
                            StateNext=ReelIn-Init
                        }
                    }
                    Break
                    
                ; State: Reel In Hook
                AutoFishing-ReelIn-Init:
                    ControlSend, , {f down}, ahk_pid %PID%
                    
                    State=ReelIn
                    Break
                AutoFishing-ReelIn:
                    ControlSend, , {f up}, ahk_pid %PID%
                    
                    State=CompleteCycle
                    StateNext=Reset
                    Break
                
                ; State: Complete Cycle
                AutoFishing-CompleteCycle-Init:
                    Random, StateMaxTimer, 8, 16
                    
                    State=CompleteCycle
                    StateTimer=0
                    Break
                AutoFishing-CompleteCycle:
                    StateTimer := StateTimer + 1
                    if (StateTimer > StateMaxTimer)
                    {
                        State=AntiDetection-Init
                        StateNext=Reset
                    }
                    Break
                
                ; Reset State
                AutoFishing-Reset:
                    State=0
                    StateNext=
                    StateTimer=0
                    StateMaxTimer=0
                    Break
                
                ; Utility State: Anti-Detection (wait humane amount of time)
                AutoFishing-AntiDetection-Init:
                    Random, StateMaxTimer, 8, 16
                    
                    State=AntiDetection
                    StateTimer=0
                    Break
                AutoFishing-AntiDetection:
                    StateTimer := StateTimer + 1
                    if (StateTimer > StateMaxTimer)
                    {
                        State=%StateNext%
                        StateNext=
                        StateTimer=0
                    }
                    Break
            }
        }
        
        ; Check if we should stop.
        if StopVar
            break
        
        HumanLikeSleep()
    }
    HumanPressButton(b, ahk_pid %PID%)
    
    ; Reset state for re-use.
    RunningVar := false
    StopVar := false
    ToolTip, , , , 1
}

HumanPressButton(Button, To)
{
    ControlSend, , {%Button% down}, %To%
    HumanLikeSleep()
    ControlSend, , {%Button% up}, %To%
}

HumanLikeSleep()
{
    Random, SleepTime, 66, 122
    Sleep, %SleepTime%
}

;- Helpers & Utility
GetAddressWater(PID, Base, Address)
{
    pointerBase := base + Address
    y1 := ReadMemory(PID, pointerBase)
    y2 := ReadMemory(PID, y1 + 0x144)
    y3 := ReadMemory(PID, y2 + 0xe4)
    Return WaterAddress := (y3 + 0x70)   
}

GetAddressLava(PID, Base, Address)
{
    pointerBase := base + Address
    y1 := ReadMemory(PID, pointerBase)
    y2 := ReadMemory(PID, y1 + 0x144)
    y3 := ReadMemory(PID, y2 + 0xe4)
    Return LavaAddress := (y3 + 0x514) 
}

GetAddressChoco(PID, Base, Address)
{
    pointerBase := base + Address
    y1 := ReadMemory(PID, pointerBase)
    y2 := ReadMemory(PID, y1 + 0x144)
    y3 := ReadMemory(PID, y2 + 0xe4)
    Return ChocoAddress := (y3 + 0x2c0) 
}

getProcessBaseAddress(HWND)
{
    return DllCall( A_PtrSize = 4
                        ? "GetWindowLong"
                        : "GetWindowLongPtr"
                    , "Ptr", HWND
                    , "Int", -6
                    , "Int64") ; Use Int64 to prevent negative overflow when AHK is 32 bit and target process is 64bit
    ; If DLL call fails, returned value will = 0
}   

ReadMemory(PID, MADDRESS)
{
    VarSetCapacity(MVALUE,4,0)
    ProcessHandle := DllCall("OpenProcess", "Int", 24, "Char", 0, "UInt", PID, "UInt")
    ;DllCall("ReadProcessMemory","UInt",ProcessHandle,"UInt",MADDRESS,"Str",MVALUE,"UInt",4,"UInt *",0)
    DllCall("ReadProcessMemory", "UInt", ProcessHandle, "Ptr", MADDRESS, "Ptr", &MVALUE, "Uint",4)
    Loop 4
        result += *(&MVALUE + A_Index-1) << 8*(A_Index-1)
    return, result
}
Then save this example with keybindings as name whatever you want e.g. "activate.ahk"
Code:
#Persistent
#MaxThreadsPerHotKey 3
#WinActivateForce

; Client 1: Hotkeys
^Numpad6::
    AntiAFK_Code(1, "Numpad6", Running, Stop)
return

^Numpad7::
    AutoFishing_Code(1, "Numpad7", Running, Stop)
return

#Include Trove.ahk
Then start Trove in Windowed Fullscreen or Fullscreen mode, search some place to fish, e.g. HUB World in front of water, aim like you do when you fish, double click the "activate.ahk" and then press "STRG + Numpad 6" for anti-Afk or "Strg + Numpad 7" for Auto fishing.
And dont forget the lures


"Trove.ahk" and "activate.ahk" must be in the same directory of course
Posts 61–75 of 122 · Page 5 of 9

Post a Reply

Similar Threads

Tags for this Thread

Talk with us