Macro's

Ask, answer and discuss any and all topics about the hows, whys, wheres and whens of playing Haven & Hearth.

Re: Macro's

Postby DigDog » Wed Nov 03, 2010 5:40 pm

serpentyngallery wrote:
Dusk wrote:Jorb and Loftar don't ban people for using macro's. Otherwise the population of haven and hearth would decrease significantly!


I'd actually be interested to see that, I somehow doubt the population would decrease as much as you think.

It would actually be positive since it reduces serverload caused by the macroers.
burgingham wrote:You call that beer?
User avatar
DigDog
 
Posts: 711
Joined: Mon Jul 19, 2010 1:52 am
Location: Germany

Re: Macro's

Postby DatOneGuy » Wed Nov 03, 2010 6:26 pm

More than half the significant people would be gone, just about everyone worth their weight in salt used macros at some point.


Also, there can be very different macros, there can be for example macros to unload smelters, there could also however be macros to grind LP.

It's a lot better to edit these into the game client as part of it, but it's also significantly harder to learn Java than it is to learn AutoHotKey. If I knew how to set something like an empty smelters button in a client I'd try my hardest to do it, but I'm stuck with a crappy AHK script instead.
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . .Hi. . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
User avatar
DatOneGuy
 
Posts: 5553
Joined: Sun Apr 18, 2010 7:50 am
Location: I'm in Miami, trick.

Re: Macro's

Postby ElGato » Wed Nov 03, 2010 7:12 pm

Code: Select all
    $LAlt::
    while GetKeyState("LAlt", "P")
    {
        Click
        sleep, 4000
    }
    return


    $RAlt::
    while GetKeyState("RAlt", "P")
    {
        Click Right
        sleep, 1200
    }
    return

here you go :lol:
burgingham wrote:We are all Gato, and Gato is Delamore of course. Goons blablabla...

Caradon wrote:Gato, the anti-ghandi

Sabinati wrote:yeah we're gonna kill you gato!!!
User avatar
ElGato
 
Posts: 1945
Joined: Tue Nov 10, 2009 2:10 am

Re: Macro's

Postby Granger » Thu Nov 04, 2010 12:30 am

Sorry guys, AutoHotkey is nice when you want to code a MACRO, but it sucks when it comes to create a ROBOT (which does the really cool stuff by itself)..
⁎ Mon Mar 22, 2010 ✝ Thu Jan 23, 2020
User avatar
Granger
 
Posts: 9254
Joined: Mon Mar 22, 2010 2:00 pm

Re: Macro's

Postby BoobyJo » Thu Nov 04, 2010 1:41 am

Granger wrote:Sorry guys, AutoHotkey is nice when you want to code a MACRO, but it sucks when it comes to create a ROBOT (which does the really cool stuff by itself)..


Like... silk?
"Nothing is too early nor too late, which is in due time for thee, O Universe."
User avatar
BoobyJo
 
Posts: 43
Joined: Sat Jul 24, 2010 4:32 am

Re: Macro's

Postby sabinati » Thu Nov 04, 2010 1:46 am

yeah but this thread is about macro's [sic]
User avatar
sabinati
 
Posts: 15513
Joined: Mon Jul 13, 2009 4:25 am
Location: View active topics

Re: Macro's

Postby notalbanian » Thu Nov 04, 2010 2:09 am

DatOneGuy wrote:More than half the significant people would be gone, just about everyone worth their weight in salt used macros at some point.


Also, there can be very different macros, there can be for example macros to unload smelters, there could also however be macros to grind LP.

It's a lot better to edit these into the game client as part of it, but it's also significantly harder to learn Java than it is to learn AutoHotKey. If I knew how to set something like an empty smelters button in a client I'd try my hardest to do it, but I'm stuck with a crappy AHK script instead.

It would be nice if there was a bulk load/unload container option in the game.
aso11 wrote:
NaoWhut wrote:Our grasslands will block out the sun.

Wait... grassland doesn't fly. Dude, you've been playing too much Minecraft.
notalbanian
 
Posts: 95
Joined: Wed Aug 18, 2010 3:25 pm

Re: Macro's

Postby ewlol » Thu Nov 04, 2010 2:11 am

notalbanian wrote:
DatOneGuy wrote:More than half the significant people would be gone, just about everyone worth their weight in salt used macros at some point.


Also, there can be very different macros, there can be for example macros to unload smelters, there could also however be macros to grind LP.

It's a lot better to edit these into the game client as part of it, but it's also significantly harder to learn Java than it is to learn AutoHotKey. If I knew how to set something like an empty smelters button in a client I'd try my hardest to do it, but I'm stuck with a crappy AHK script instead.

It would be nice if there was a bulk load/unload container option in the game.



Shift + mouse-scroll (to take/out dump extremely fast)

Shift + ctrl + mouse-scroll (to dump/take out by ql)
User avatar
ewlol
 
Posts: 775
Joined: Mon Mar 29, 2010 2:40 pm

Re: Macro's

Postby Sarchi » Thu Nov 04, 2010 2:21 am

Well, it's easy to create a simple macro, but the good ones are hard to make.

Of course, I don't use macros anyway. Those are for cheaters.
User avatar
Sarchi
 
Posts: 2517
Joined: Sat Jun 12, 2010 1:14 am
Location: 109, -37

Re: Macro's

Postby DatOneGuy » Thu Nov 04, 2010 2:29 am

ewlol wrote:
notalbanian wrote:
DatOneGuy wrote:More than half the significant people would be gone, just about everyone worth their weight in salt used macros at some point.


Also, there can be very different macros, there can be for example macros to unload smelters, there could also however be macros to grind LP.

It's a lot better to edit these into the game client as part of it, but it's also significantly harder to learn Java than it is to learn AutoHotKey. If I knew how to set something like an empty smelters button in a client I'd try my hardest to do it, but I'm stuck with a crappy AHK script instead.

It would be nice if there was a bulk load/unload container option in the game.



Shift + mouse-scroll (to take/out dump extremely fast)

Shift + ctrl + mouse-scroll (to dump/take out by ql)

That's to dump to inventory, not to floor. The idea is to take out the bars and then dump the stones. My current method uses image correction (to ensure that they are all dumped without a problem), it relies on images and the code is ugly and bloated, but:
Code: Select all
#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.


F3::SetTimer, Sendit, -500

^#z::SetTimer, Sendit, off

sendit:
WinWait, Haven and Hearth,
IfWinNotActive, Haven and Hearth, , WinActivate, Haven and Hearth,
WinWaitActive, Haven and Hearth,

ImageSearch, SmeltX, SmeltY, 0,0,%A_ScreenWidth%, %A_ScreenHeight%, *40 *TransWhite images\Smeltertext.png
if ErrorLevel = 1
 Msgbox No open Smelter
if ErrorLevel = 0
  {
   SmeltX1:= SmeltX - 60
   SmeltX2:= SmeltX + 110
   SmeltY1:= SmeltY + 10
   SmeltY2:= SmeltY + 190

 Loop
   {
   ImageSearch, FoundX, FoundY, %SmeltX1%, %SmeltY1%, %SmeltX2%, %SmeltY2%, *40 *Transff00c0 images\Cast.png
    if ErrorLevel = 1
   break
    if ErrorLevel = 0
       {
       FoundX+=16
       FoundY+=16
       Send, {Shiftdown}
       Sleep, 50
       MouseClick, left, %FoundX%, %FoundY%
       Sleep, 50
       Send, {Shiftup}
       MouseMove,200,30,,R
       }
   }

  Loop
   {
    ImageSearch, StoneX, StoneY, %SmeltX1%, %SmeltY1%, %SmeltX2%, %SmeltY2%, *40 *Transff00c0 images\Stone.png
    if ErrorLevel = 1
   break
    if ErrorLevel = 0
       {
       StoneX+=9
       StoneY+=5
       Send, {Ctrldown}
       Sleep, 50
       MouseClick, left, %StoneX%, %StoneY%
       Sleep, 50
       Send, {Ctrlup}
       MouseMove,200,30,,R
       } 
   }
   
  }
return

#^a::Pause


As Granger said though bots (I guess you can call them robots, but I always just call them bots) are best done in Java, you really just `can't` make them in AHK, it won't work, it'll be way too big, AHK is best for small scripts at most a 'stupid macro', for example easily repetition, very light decision making, never factoring into account more than one thing. Bad for long amounts of time too.
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . .Hi. . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
User avatar
DatOneGuy
 
Posts: 5553
Joined: Sun Apr 18, 2010 7:50 am
Location: I'm in Miami, trick.

Previous

Return to How do I?

Who is online

Users browsing this forum: Claude [Bot], PetalBot [Bot] and 0 guests