Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

Moderator: Moderators

Message
Author
Pseudocode
Noob
Noob
Posts: 7
Joined: 02 Aug 2008, 23:43
Noob?: Yes

Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#1 Post by Pseudocode »

SERVER: MYRO
All of MYRO server, I would like to let you test my BETA VERSION of Automated Pharmacy "Yellow Potion". Feel free to use it.

Please reply me your feedback regarding on my simple macro.

Macro Step functionalities:
Modify your macro_timeout 2 to 1 on your timeout.txt before trying this.
Required Map: turbo_room

1. Baps first
2. Buy Yellow Herb to Pet Store npc(turbo_room)
3. Buy Medicine Bowl and Empty Potion Bottle to Creation npc(turbo_room)
4. Move on 4 randomly destination spot (Upper Left, Lower Left, Upper Right, Lower Right)
5. Do pharmacy(I fix it to 200 yellow for character weight purposes)
I do many fig.1 to minimize the looping timeout, and try to make pharmacy go fast.
fig 1.
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00

6. Sell Yellow Potion
7. Repeat: step 1 to 6


--------------------------------------------
Mac 2.0.2
--------------------------------------------
automacro Process {
inventory "Yellow Potion" = 0
call BuyItems
run-once 1
}

macro BuyItems {
$const = @invamount(Yellow Herb)
if ($const != 0) goto Uno
:Uno
$const = @invamount(Empty Potion Bottle)
if ($const != 0) goto Dos
:Dos
$const = @invamount(Medicine Bowl)
if ($const != 0) goto Pharmacy
$pot = @invamount(Yellow Potion)
if ($pot != 0) goto Sellme
do move 114 118
do talk @npc (110 122)
pause 1
do move 114 118
do talk @npc (112 118)
pause 1
$x = @invamount(Yellow Herb)
if ($x == 200) goto Creation
do move 89 120
do talk @npc (91 125)
do store
do buy @store(Yellow Herb) 200
:Creation
$y = @invamount(Empty Potion Bottle)
if ($y == 200) goto Y
do move 80 80
do talk @npc (86 86)
do store
do buy @store(Empty Potion Bottle) 200
:Y
$z = @invamount(Medicine Bowl)
if ($z == 200) goto Pharmacy
do move 80 80
do talk @npc (86 86)
do store
do buy @store(Medicine Bowl) 200
:Pharmacy
$p = @random ("1", "2", "3", "4")
log $p
if ($p == 1) goto UP
if ($p == 2) goto UL
if ($p == 3) goto LR
do move 53 70
goto ext
:UP
do move 144 155
goto ext
:UL
do move 56 157
goto ext
:LR
do move 145 71
goto ext
:ext

$crt = 0
while ($crt <= 20) as looping
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
$crt++
end looping
:Sellme
$a = @invamount(Yellow Potion)
do move 89 120
do talk @npc (91 125)
do sell
do sell @inventory(Yellow Potion) $a
do sell done

release all
}

fco2783
Plain Yogurt
Plain Yogurt
Posts: 95
Joined: 05 Apr 2008, 05:15
Noob?: Yes
Location: in place where you cant go
Contact:

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#2 Post by fco2783 »

@Pseudocode
nice code, but i think you post in the wrong section... secondly why do u need to make an yellow potion then sell it to NPC...

Code: Select all

$crt = 0
while ($crt <= 20) as looping
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
do ss 228 10
do send 8E 01 F7 01 00 00 00 00 00 00
$crt++
end looping
you dont you just make it to while ($crt <= 200) as looping than copy paste when you using loop...

sli
Perl Monk
Perl Monk
Posts: 810
Joined: 04 Apr 2008, 17:26
Noob?: No

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#3 Post by sli »

fco2783 wrote:you dont you just make it to while ($crt <= 200) as looping than copy paste when you using loop...
I was wondering that myself. :lol:
cs : ee : realist

Pseudocode
Noob
Noob
Posts: 7
Joined: 02 Aug 2008, 23:43
Noob?: Yes

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#4 Post by Pseudocode »

I create Yellow Potion because, I discover that the required item in creating yellow potion in my server is cheapter, maybe its a bug in the server. Well doing the Yellow Potion pharmacy could give you an unlimited Income in my server but actually I didn't know if other players in MYRO server knew this buggy. Although I might say that these kind of process is really really slow. Well in my case, I just did this because I have not enough time to hunt or gather quest items and sell them through vending. Because we all know that each one of us have its own respective responsibilities in life and also in our family too.

My main purpose of creating this macro is:
- to avoid putting in jail while you use bot for harvesting items.
- to save time and effort.
- to reduce the percentage of getting IP Ban in the server.
When you get IP Ban, it's a very very big deal to us players. Know why? Because you wasted, spended a lot of a golden times, effort and even money. So why should we be more practical, playing safe is a perfect term. Well that's only my perception and precaution.

Here's to elaborate the scenario:
- You can buy Yellow herb = 40z w/Discount = 30z at NPC
- You can buy Medicine bowl = 8z w/Discount = 6z at NPC
- You can buy Empty potion bottle = 10z w/Discount = 7z at NPC

Then add all the discounted value: 30+6+7 = 42z. That's all you need to produce 1 Yellow Potion. You could sell it at the cost of 341z w/ overcharge at npc. Then create as many as you like...
Pseudocode wrote:you dont you just make it to while ($crt <= 200) as looping than copy paste when you using loop...


Okey, I didn't do it like this "while ($crt <= 200)" it's because, the looping execution takes more time to read itself. So I just make it simpler yet concise.

Precaution using this block of code:
A. Assign->Compare-> action ->increment - In these situation you will gonna do
Assign 200x-Compare 200x-action 200x-increment 200x. Do you get the point.
Method: Step-by-Step

read(1)line -> $crt = 0
read(2)line -> while ($crt <= 200) as looping
read(3)line -> do ss 228 10
read(4)line -> do send 8E 01 F7 01 00 00 00 00 00 00
read(5)line -> $crt++
read(6)line -> end looping

Precaution using this block of code:
B. Assign->Compare-> action ->increment - In these situation you will gonna do
Assign 20x-Compare 20x-action 10x-increment 20x. Do you get the point.
Method: Shortest-Job-First

read(1)line -> $crt = 0
read(2)line -> while ($crt <= 20) as looping
read(3)line -> do ss 228 10----(10x)
read(4)line -> do send 8E 01 F7 01 00 00 00 00 00 00---(10x)
read(5)line -> $crt++
read(6)line -> end looping

Conclusion: A and B are both the same in function. However (A) takes the longest path while (B) takes the shortest path. That's all I could explain. Opinion and suggestion is kindly accepted.

sli
Perl Monk
Perl Monk
Posts: 810
Joined: 04 Apr 2008, 17:26
Noob?: No

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#5 Post by sli »

That's actually probably Perl's fault. Comparisons are a measly one line of machine code.

Code: Select all

test eax, ebx
Well, technically three.

Code: Select all

mov incVar, eax
mov compVar, ebx
text, eax, ebx
You get the idea. Not a whole lot is going on there. Just wanted to clear that up so there's no confusion that comparisons are slower than large while blocks.
cs : ee : realist

neomoves
Noob
Noob
Posts: 4
Joined: 01 Jun 2008, 19:38
Noob?: Yes

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#6 Post by neomoves »

my bot won't buy the recipes in making the yellow potion.. maybe i did something wrong

fco2783
Plain Yogurt
Plain Yogurt
Posts: 95
Joined: 05 Apr 2008, 05:15
Noob?: Yes
Location: in place where you cant go
Contact:

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#7 Post by fco2783 »

when im using Pharmacy macro working i dont use whole macro on it...

i use mix of OK and macro... like the storageAuto, buyAuto and sellAuto...
dont forget about the items_control.txt so that your item wont mix up on you cart...

Pseudocode
Noob
Noob
Posts: 7
Joined: 02 Aug 2008, 23:43
Noob?: Yes

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#8 Post by Pseudocode »

@sli - I'm technically I agree with you, I'm just starting to learn perl and writing plugins.
@fcp2783 - You have an idea. I almost forgot the OK to minimize the macro task. Thanks for reminding me, I shouldn't depend it all in macro.
fco2783 wrote:dont forget about the items_control.txt so that your item wont mix up on you cart...
Sorry, I didn't mention it on my post that change the items_control.txt to all 0, so the items won't be added into cart and since the macro is fix and the routine is buy and sell only that's why cart is actually not necessary and also autostorage.

@neomoves - you could place you're SS(Screen Shot) here to minimize the discussion. the OK version and your Mac version.

Thank you guys......

Cozzie
Spam Generator
Spam Generator
Posts: 499
Joined: 04 Apr 2008, 09:30
Noob?: No
Location: Melbourne, City of beer and awful sushis

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#9 Post by Cozzie »

err isnt macros plugin should be in well.. err macros section?
Make Openkore Awesome. Join the team.

RockwellRyan
Noob
Noob
Posts: 5
Joined: 09 Oct 2008, 06:27
Noob?: Yes
Location: Ortigas, Pasig City

Re: Automated Pharmacy "Yellow Potion" |OK 2.0.5.1 Mac 2.0.2|

#10 Post by RockwellRyan »

Guys wait, is Macro the only way for the skill Pharmacy to work? Honestly I don't know how to use Macros but I do configs well, I just really don't know this Macro thing. Is there a way? :roll:
Always be a blessing to anybody and always try to see good in everyone.

Post Reply