DreamerRO Casino macro

Moderator: Moderators

Message
Author
mashiroiro
Noob
Noob
Posts: 2
Joined: 01 Dec 2014, 15:01
Noob?: Yes

Re: DreamerRO Casino macro

#11 Post by mashiroiro »

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 :
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" :
$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 : http://forums.openkore.com/viewtopic.ph ... 58#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: Select all

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: Select all

######################################################    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?

-Saint Seiya-
The Way Of Human
The Way Of Human
Posts: 178
Joined: 11 Apr 2008, 07:03

Re: DreamerRO Casino macro

#12 Post by -Saint Seiya- »

encounter this when opening macro. sorry is there any thing else which i need to add in or?

Code: Select all

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?

SkylorD
Moderators
Moderators
Posts: 1163
Joined: 16 Dec 2011, 02:53
Noob?: Yes
Location: Brazil

Re: DreamerRO Casino macro

#13 Post by SkylorD »

-Saint Seiya- wrote:encounter this when opening macro. sorry is there any thing else which i need to add in or?

Code: Select all

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.
Learn rules

iamjoelrivera
Noob
Noob
Posts: 1
Joined: 26 May 2015, 13:56
Noob?: Yes

Re: DreamerRO Casino macro

#14 Post by iamjoelrivera »

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

hueyyy
Noob
Noob
Posts: 1
Joined: 06 Feb 2016, 03:44
Noob?: Yes

Re: DreamerRO Casino macro

#15 Post by hueyyy »

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

SkylorD
Moderators
Moderators
Posts: 1163
Joined: 16 Dec 2011, 02:53
Noob?: Yes
Location: Brazil

Re: DreamerRO Casino macro

#16 Post by SkylorD »

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!
Learn rules

ivan243
Noob
Noob
Posts: 4
Joined: 22 Apr 2016, 01:20
Noob?: Yes

Re: DreamerRO Casino macro

#17 Post by ivan243 »

Sir can i ask ? what is the meaning of this "\d-\d\:\s.\s(.*)\s.+$/i" thanks!

allanon256
Developers
Developers
Posts: 19
Joined: 06 Mar 2010, 19:33
Noob?: No

Re: DreamerRO Casino macro

#18 Post by allanon256 »

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.

raven24
Noob
Noob
Posts: 5
Joined: 13 May 2016, 03:08
Noob?: Yes

Re: DreamerRO Casino macro

#19 Post by raven24 »

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
upon changing some recvpackets from internet
upon changing some recvpackets from internet
1.JPG (28.3 KiB) Viewed 4602 times
Capture.JPG

SkylorD
Moderators
Moderators
Posts: 1163
Joined: 16 Dec 2011, 02:53
Noob?: Yes
Location: Brazil

Re: DreamerRO Casino macro

#20 Post by SkylorD »

surely your serverType is wrong. you should search on forum about PEEK, follow the master tutorial of 4ept, read until the end.
Learn rules

Post Reply