Openkore.com

OpenKore Forums
It is currently 25 Oct 2014, 03:13

All times are UTC - 5 hours [ DST ]





Post new topic Reply to topic  [ 16 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: DO Command on PM
PostPosted: 02 Nov 2008, 23:57 
Offline
Noob
Noob
User avatar

Joined: 27 Apr 2008, 20:23
Posts: 3
This macro was based on Do command from pm by windows98SE@thaikore on the old forums.

This macro will let a bot do a certain Do Command on a PM when the sender is on the list of allowed players.
This is useful in using bots while playing non-bots simultaneously.

Code:
##  DO Command at PM  ##

automacro DOonPM {
   console /\(From: (.*)\) : do (.*)/
   run-once 1
   call {
   #Multiple IF Statements can be added for flexibility
   # Player1 is an in-game name
   # Player2 is an in-game name
   if ("$.lastMatch1" == "Player1") goto ok
   if ("$.lastMatch1" == "Player2") goto ok
   do pm "$.lastMatch1" Asa... #any message to say rejection on request...
   release DOonPM
   stop
:ok
   release DOonPM
   do $.lastMatch2
   pause 2
   do pm "$.lastMatch1" done
   stop
   }
}


Example Situation 1 (Player1 is allowed):

Player1 PMs Bot: do openshop
Bot opens the shop
Bot PMs Player1: done

Example Situation 2 (Player2 is also allowed):

Player2 PMs Bot: do e heh
Bot uses emoticon heh
Bot PMs Player2: done

Example Situation 3 (Player3 is not allowed):

Player3 PMs Bot: do relog 9999999
Bot does nothing
Bot PMs Player3: Asa...

Example Situation 4 (Player1 is allowed):

Player1 PMs Bot: do relog 9999999
Bot relogs

This macro can be a part of a more complex macro... I'm using this to manually trade and chat... Hope this helps...

_________________
Proud Pinoy Botter!


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 28 Nov 2008, 16:54 
Offline
Been there done that!
Been there done that!
User avatar

Joined: 25 Oct 2008, 08:14
Posts: 144
Location: Spain, Madrid
I made a little tweak:

Code:
automacro doCommand {
   console /\(From: (.*)\) : do (.*)/
   call {
      $nick = $.lastMatch1
      $auth = @eval (defined $::overallAuth{"$nick"} ? $::overallAuth{"$nick"}:"None")
      if ($auth == 1) goto auth
      do pm $.lastMatch1 Pardon...?
      stop
   :auth   
      do $.lastMatch2
      pause
      do pm $.lastMatch1 All done.
   }
}

Basically I made it check your nick on the overallAuth.txt.
With that you don't need to change the macro, just add people to the file by console commands or char password.

_________________
ImageImageImage
ImageImageImage
ImageImageImage


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 21 Dec 2008, 21:36 
Offline
Noob
Noob
User avatar

Joined: 27 Apr 2008, 20:23
Posts: 3
Darki wrote:
Basically I made it check your nick on the overallAuth.txt.
With that you don't need to change the macro, just add people to the file by console commands or char password.


Nice that would make it a little easier and more functional. ^^,

_________________
Proud Pinoy Botter!


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 08 Jul 2009, 07:42 
Offline
Human
Human
User avatar

Joined: 05 Sep 2008, 08:45
Posts: 38
Location: Philippines
Is that posible that when I pm my bot the command exp, the bot will reply all the information shown in the console?

_________________
Image

Never interrupt your enemy when he's making a mistake.
Always go on PVP. /gg


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 08 Jul 2009, 13:18 
Offline
Perl Monk
Perl Monk
User avatar

Joined: 04 Apr 2008, 14:04
Posts: 427
Location: Brazil
You could try using adminpassword.

_________________
Quit.


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 08 Jul 2009, 20:54 
Offline
Human
Human
User avatar

Joined: 05 Sep 2008, 08:45
Posts: 38
Location: Philippines
How? May you explain it clearly? What do you mean about the admin password?

_________________
Image

Never interrupt your enemy when he's making a mistake.
Always go on PVP. /gg


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 12 Jul 2009, 08:03 
Offline
Been there done that!
Been there done that!
User avatar

Joined: 25 Oct 2008, 08:14
Posts: 144
Location: Spain, Madrid
You should make a different macro for that, one that evals the information and then pm's it.

_________________
ImageImageImage
ImageImageImage
ImageImageImage


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 12 Jul 2009, 20:19 
Offline
Human
Human
User avatar

Joined: 05 Sep 2008, 08:45
Posts: 38
Location: Philippines
I dont know how to make that macros, can you do that for me?

_________________
Image

Never interrupt your enemy when he's making a mistake.
Always go on PVP. /gg


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 12 Jul 2009, 20:35 
Offline
Testers Team
Testers Team

Joined: 04 Apr 2008, 21:53
Posts: 105
Location: Asia
Open overallAuth.txt
put your char name inside with flag 1.
example :
Code:
charName 1


try pm char using 'exp'.

Note : this already been implement on openkore, read openkore manual. Btw ths is share's macro topic.

_________________
Image
Image


Top
 Profile  
 
 Post subject: Re: DO Command on PM
PostPosted: 12 Jul 2009, 20:49 
Offline
Human
Human
User avatar

Joined: 05 Sep 2008, 08:45
Posts: 38
Location: Philippines
Thnx

_________________
Image

Never interrupt your enemy when he's making a mistake.
Always go on PVP. /gg


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 16 posts ]  Go to page 1, 2  Next

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


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
[ Time : 0.061s | 16 Queries | GZIP : On ]