Openkore.com

OpenKore Forums
It is currently 13 Nov 2019, 00:36

All times are UTC - 5 hours [ DST ]





Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Move to location and sit to recover (Ai Manual Fail?)
PostPosted: 24 Jul 2017, 09:13 
Offline
Noob
Noob

Joined: 17 Jul 2017, 04:01
Posts: 10
Hey guys,

I'm trying to create a combination of simple automacros to make my bot move to a specific location to sit and recover hp. For example if the bot is in toy factory 2 and it's hp drops below 30%, it should move to toy factory 1, sit down till it's hp is over 60%, stand up and continue with leveling in toy factory 2. I disable the sit to recover in the config file by setting sitAuto_hp_lower and sitAuto_hp_upper both to 100. I also disabled the autoMoveOnDeath. In my code I added a macro to sit in a specific spot in Aldebaran to recover hp.


Code:
automacro sitToRecoverInToyFactory1 {
   hp < 30%
   map xmas_dun02
   status not Sitting
   call {
      do ai manual
      do move xmas_dun01
      do sit
      do ai on
   }
   timeout 30
}

automacro sitToRecoverInAlde {
   hp < 60%
   map aldebaran
   status not Sitting
   call {
      do ai manual
      do move aldebaran 153 114
      do sit
      do ai on
   }
   timeout 30
}

automacro standAfterRecover {
   hp > 60%
   status Sitting
   call {
      do stand
   }
   timeout 30
}


Now to my problems: First of all, everything works fine with the script as long as the bot doesn't die. I had to add the "do ai manual" to prevent the bot from attacking mobs while moving to toy factory 1. (Quick Question: Is there another way to deactivate attacking via automacro?).
But here comes the problem with this: When my bot dies while moving to toy factory 1 (because it got attacked by a cruiser or stormy or whatever), it doesn't respawn most of the time. I guess the problem is, that do ai manual doesn't get revoked by do ai on, because the bot never reached toy factory 1 and sat down. This results in some other weird behaivors, because sometimes my bot does respawn, but then sits in aldebaran and does nothing at the spawn point. Or it does start the sitToRecoverInAlde macro, but doesn't walk back to lockmap xmas_dun02 after it stands up.

So maybe I need something else instead of do ai manual, to keep the bot from attacking while walking to toy factory 1. Or maybe I need a backup macro that checks if the bot did die and the ai is still on manual, to set it back to ai on.

Please let me know if you have any suggestions for my problem here :)

thank you and regards,

Krishna


Top
 Profile  
 
 Post subject: Re: Move to location and sit to recover (Ai Manual Fail?)
PostPosted: 24 Jul 2017, 18:04 
Offline
Plain Yogurt
Plain Yogurt

Joined: 16 Jun 2008, 08:41
Posts: 72
In macros commands line add
do conf attackauto 0
After that everything
do conf attackauto 2

Just sample , maybe some spelling error


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group