Openkore.com

OpenKore Forums
It is currently 16 Nov 2018, 11:39

All times are UTC - 5 hours [ DST ]





Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2, 3  Next
Author Message
 Post subject: Re: DreamerRO Casino macro
PostPosted: 03 Dec 2014, 09:11 
Offline
Noob
Noob

Joined: 01 Dec 2014, 15:01
Posts: 2
SkylorD wrote:
"The game consists of score 3 consecutive letters."

Last update :
Changed "automacro zenys" eval condition to check if your inventory is not full before you change your zenys for bags.
Reason : I lost some billions. The last condition was 'eval !%talk'. If you want to change it.

1 - Set in your config :

Quote:
casino_machinenumber <Machine ID> - Here you need to set the slot machine name . Just one. If you don't set this option, you will play in a random machine.


I want to play in "Slot machine #slot3-4" :

casino_machinenumber 3-4


You can set the amount to bet in "automacro insertzeny" :

Quote:
$casinoamount = 2000000


You could see this macro above :

#Note : items.txt => 20062#1Billion Money Bag# as default now is "1B", and not "1 B". sry.

#PS (2014/10/03) :
Updated macro : viewtopic.php?f=33&t=196765&p=269158#p269098 (Your char must be inside casino map)

You can use the macro above (The link to the updated macro) or the macro below (Oudated) :

Code:
automacro casinoroute {
exclusive 1
location caspen
zeny < 1990000000
hook AI_pre
call {
$billionbag = @inventory(1Billion Money Bag)
$billamount = @invamount(1Billion Money Bag)
if ($billionbag != -1) {
do c @storage
pause 1
$billionbag = @inventory(1Billion Money Bag)
do storage add $billionbag
pause 1
do storage close
pause 1
} else {
pause 2
$x = @rand (183, 187)
$y = @rand (104, 106)
$x2 = @rand (182, 191)
$y2 = @rand (98, 99)
$randompos = @random ("$x $y", "$x2 $y2")
do c @warp cmd_in02 $randompos
pause 1
#$x = @rand (151, 159)
#$y =  @rand (203, 209)
#do move caspen $x $y
#Dreamer RO Helper coords : 155 210
#do talknpc 155 210 c r3 c r3 c r1
}
}
}


automacro movetomachine {
exclusive 1
location cmd_in02
location not cmd_in02 182 106 191 99
zeny < 1990000000
call {
$x = @rand (183, 187)
$y = @rand (104, 106)
$x2 = @rand (182, 191)
$y2 = @rand (98, 99)
$randompos = @random ("$x $y", "$x2 $y2")
do move $randompos
}
}

automacro talknpc {
location cmd_in02 182 106 191 99
eval !%talk
timeout 3
hook AI_pre
call {
$talkcont = @config(autoTalkCont)
$machinenumber = @config(casino_machinenumber)
if ($talkcont == "0") {
do conf autoTalkCont 1
}
$npcid = @npc(/Slot Machine\#slot$machinenumber/i)
while ($npcid == -1) as loop
$x = @rand(1, 10)
$y = @rand(1, 10)
$npcid = @npc(/Slot Machine\#slot$x\-$y/i)
end loop
do talk $npcid
}
}

automacro selectplay {
console /(.*)?\d+\s+Play(.*)?/i
call {
do talk resp 0
}
}

automacro insertzeny {
console /.+Insert zeny to bet.+/i
call {
pause @rand(1, 2, 3)
$casinoamount = 2000000
do talk num $casinoamount
}
}

automacro antibot {
console /Slot Machine\#slot\d-\d\:\s.\s(.*)\s.+$/i
call {
do talk text $.lastMatch1
}
}

automacro zenys {
eval $char->inventory->size < 100
zeny >= 1990000000
exclusive 1
call {
pause 1
$y = @rand(186, 196)
do c @go 0
do move 180 $y
do talknpc 185 193 r3 r2 r2
pause 1
do c @storage
pause 1
$billionbag = @inventory(1Billion Money Bag)
do storage add $billionbag
pause 1
do storage close
pause 1
$x = @rand (183, 187)
$y = @rand (104, 106)
$x2 = @rand (182, 191)
$y2 = @rand (98, 99)
$randompos = @random ("$x $y", "$x2 $y2")
do c @warp cmd_in02 $randompos
pause 1
}
}

(Your character need to be inside casino map or in caspen)


#Not needed but : #
It prints the match result :

Code:
######################################################    CASINO RESULTS    ######################################################
sub machineresult {
my ($a, $b, $c) = @_;
my %casinoresponses;
my $p = 0;
$p = 1 if ($a eq $b && $b eq $c && $c eq $a);
$casinoresponses{$a} = $a if (!$casinoresponses{$a} && $p ne 1);
$casinoresponses{$b} = $b if (!$casinoresponses{$b} && $p ne 1);
$casinoresponses{$c} = $c if (!$casinoresponses{$c} && $p ne 1);
my $total = keys %casinoresponses;
if ($total eq 3) {
$losses += 1;
warning "Losses +1 . now is $losses\n";
}
elsif ($total eq 2) {
$draw += 1;
warning "Draw +1 . now is $draw\n";
}
elsif ($total eq 1) {
$draw += 1;
warning "Draws +1 . now is $draw\n";
}
elsif ($total eq 0) {
$won += 1;
warning "Wins +1 . now is $won\n";
}
}   

automacro won {
console /Slot Machine#slot\d-\d\:(\s+)?.\s+(\w)\s+.\s+(\w)\s+.\s+(\w)\s+\s+.(.+)?/i
varvar draw unset
varvar won unset
varvar losses unset
varvar totallosses unset
call {
do eval machineresult($.lastMatch2, $.lastMatch3, $.lastMatch4);
}
}

Working good.

Image


Machine result :

Image



what if i want my bot to just stay still? what should i put?


Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 06 Dec 2014, 00:55 
Offline
The Way Of Human
The Way Of Human

Joined: 11 Apr 2008, 07:03
Posts: 175
encounter this when opening macro. sorry is there any thing else which i need to add in or?

Code:
control\macros.txt: ignoring '}' (munch, munch, strange food)
control\macros.txt: ignoring '$npcid = @npc(/Slot Machine\#slot$machinenumber/i)' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring 'while ($npcid == -1) as loop' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring '$x = @rand(1, 10)' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring '$y = @rand(1, 10)' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring '$npcid = @npc(/Slot Machine\#slot$x\-$y/i)' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring 'end loop' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring 'do talk $npcid' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring '}' (munch, munch, strange food)


does this affect anything?


Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 17 May 2015, 02:52 
Offline
Moderators
Moderators
User avatar

Joined: 16 Dec 2011, 02:53
Posts: 1212
Location: Brazil
-Saint Seiya- wrote:
encounter this when opening macro. sorry is there any thing else which i need to add in or?

Code:
control\macros.txt: ignoring '}' (munch, munch, strange food)
control\macros.txt: ignoring '$npcid = @npc(/Slot Machine\#slot$machinenumber/i)' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring 'while ($npcid == -1) as loop' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring '$x = @rand(1, 10)' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring '$y = @rand(1, 10)' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring '$npcid = @npc(/Slot Machine\#slot$x\-$y/i)' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring 'end loop' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring 'do talk $npcid' (munch, munch, unknown automacro keyword)
control\macros.txt: ignoring '}' (munch, munch, strange food)


does this affect anything?


Surely. 40%.

What've you did? Try copying the macro again. If does not work post your code here. I can't reproduce this. It's still working here.

_________________
"'There are three things all wise men fear: the sea in storm, a night with no moon, and the anger of a gentle man.'" :P

viewtopic.php?f=10&t=16117

Thanks for this Eternal! =D <3<3


Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 26 May 2015, 14:07 
Offline
Noob
Noob

Joined: 26 May 2015, 13:56
Posts: 1
sir can you please teach me how to bot in dreamerro ! with black jack npc please :( i want to make zenny there i hope i wil lget response


Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 06 Feb 2016, 04:55 
Offline
Noob
Noob

Joined: 06 Feb 2016, 03:44
Posts: 1
sir how do i get a macro? and how to configure this? because i have here openkore only. and dont know how to configure it to casino macro please help me


Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 11 Mar 2016, 21:05 
Offline
Moderators
Moderators
User avatar

Joined: 16 Dec 2011, 02:53
Posts: 1212
Location: Brazil
hueyyy wrote:
sir how do i get a macro? and how to configure this? because i have here openkore only. and dont know how to configure it to casino macro please help me


http://openkore.com/index.php/Macro_plugin

1 - Download Macro Plugin
2 - Extract only the Macro folder and the macro.pl file, in other words, don't extract the trunk file inside the rar file.
3 - Create a folder called plugins in your openkore folder and then paste that files there.
4 - Now open your notepad, paste the macro, save it in anywhere and change the format to UTF-8, save the filename as 'macros'
5 - Move this to your openkore/control folder.

Run normally and success!

_________________
"'There are three things all wise men fear: the sea in storm, a night with no moon, and the anger of a gentle man.'" :P

viewtopic.php?f=10&t=16117

Thanks for this Eternal! =D <3<3


Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 22 Apr 2016, 01:42 
Offline
Noob
Noob

Joined: 22 Apr 2016, 01:20
Posts: 4
Sir can i ask ? what is the meaning of this "\d-\d\:\s.\s(.*)\s.+$/i" thanks!


Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 27 Apr 2016, 16:11 
Offline
Developers
Developers

Joined: 06 Mar 2010, 19:33
Posts: 19
ivan243 wrote:
Sir can i ask ? what is the meaning of this "\d-\d\:\s.\s(.*)\s.+$/i" thanks!


That is a regular expression, which translates to: a number, then a dash, then a number, then a colon, then a space, then one character (anything!), then a space, then any sequence of characters, then a space, then any sequence of at least one character.

For example, it would match "0-0: ! (anything goes here!) at_least_one_character_here".

The parentheses in the regular expression capture the "(anything goes here!)" part of my example.

Google finds some great resources on regular expressions. They can be very complicated sometimes - this one is pretty simple.


Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 13 May 2016, 03:16 
Offline
Noob
Noob

Joined: 13 May 2016, 03:08
Posts: 5
i dont know what did i do wrong but these came up send help .. thanks did try all the packets extractor and didnt work at all please skylord help


Attachments:
3.JPG
3.JPG [ 15.96 KiB | Viewed 3278 times ]
File comment: upon changing some recvpackets from internet
1.JPG
1.JPG [ 28.3 KiB | Viewed 3282 times ]
Capture.JPG
Capture.JPG [ 37.64 KiB | Viewed 3295 times ]
Top
 Profile  
 
 Post subject: Re: DreamerRO Casino macro
PostPosted: 15 May 2016, 15:50 
Offline
Moderators
Moderators
User avatar

Joined: 16 Dec 2011, 02:53
Posts: 1212
Location: Brazil
surely your serverType is wrong. you should search on forum about PEEK, follow the master tutorial of 4ept, read until the end.

_________________
"'There are three things all wise men fear: the sea in storm, a night with no moon, and the anger of a gentle man.'" :P

viewtopic.php?f=10&t=16117

Thanks for this Eternal! =D <3<3


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2, 3  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