Vend bot with multiple items help!
Posted: 02 Sep 2017, 11:44
Hello guys..
I botte quite on and off and have come back to the game now.
I have a vend bot that i want to sell items and rebuy them once they are empty, but i doesnt seem to rebuy them.
Here is the code
[code#######################################
##### Vending in Payon #####
#######################################
#################################
##### Open Shop at location #####
#################################
automacro vend {
location payon
cart "Red Potion" > 25,cart "Orange Potion" > 25,cart "Awakening Potion" > 10,cart "Concentration Potion" > 10,cart "Fly Wing" > 25
call open_shop
timeout 10
}
macro open_shop {
do move 170 61
}
automacro open_shop_now {
run-once 1
location payon 170 61
call open_my_shop
}
macro open_my_shop {
do move 170 62
pause 1
do openshop
release open_shop_now
}
##########################################################################
####################
##### Buy Item #####
####################
automacro get_red {
location payon 170 62
shop "Red Potion" < 26
exclusive 1
call go_buyred
}
macro go_buyred {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 2 250
pause 3
do cart add Red Potion
pause 3
do move payon_in01 16 51
do move payon 170 62
}
automacro get_orange {
location payon 170 62
shop "Orange Potion" < 26
exclusive 1
call go_buyorange
}
macro go_buyorange {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 3 250
pause 3
do cart add Orange Potion
pause 3
do move payon_in01 16 51
do move payon 170 62
}
automacro get_Awak {
location payon 170 62
shop "Awakening Potion" < 11
exclusive 1
call go_buyawak
}
macro go_buyawak {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 8 30
pause 3
do cart add Awakening Potion
pause 3
do move payon_in01 16 51
do move payon 170 62
}
automacro get_conc {
location payon 170 62
shop "Concentration Potion" < 11
exclusive 1
call go_buyconc
}
macro go_buyconc {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 7 30
pause 3
do cart add Concentration Potion
pause 3
do move payon_in01 16 51
do move payon 170 62
}
automacro get_fly {
location payon 170 62
shop "Fly Wing" < 26
exclusive 1
call go_buyfly
}
macro go_buyfly {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 9 200
pause 3
do cart add Fly Wing
pause 3
do move payon_in01 16 51
do move payon 170 62
}
[/code]
As you can see i want the bot to buy Red Pot and Orange Pot when they are below 26 and open shop when they are above 25.. and so on
The Shop will have a total of 5 items, Red Potion, Orange Potion, Fy Wing, Awak and Conc..
I found this script for White Potion online and tried to modify it for my needs but because i have multiple items i cant seem to get it to work..
Basically I want the bot to go Buy whenever 1 item becomes too low.
I botte quite on and off and have come back to the game now.
I have a vend bot that i want to sell items and rebuy them once they are empty, but i doesnt seem to rebuy them.
Here is the code
[code#######################################
##### Vending in Payon #####
#######################################
#################################
##### Open Shop at location #####
#################################
automacro vend {
location payon
cart "Red Potion" > 25,cart "Orange Potion" > 25,cart "Awakening Potion" > 10,cart "Concentration Potion" > 10,cart "Fly Wing" > 25
call open_shop
timeout 10
}
macro open_shop {
do move 170 61
}
automacro open_shop_now {
run-once 1
location payon 170 61
call open_my_shop
}
macro open_my_shop {
do move 170 62
pause 1
do openshop
release open_shop_now
}
##########################################################################
####################
##### Buy Item #####
####################
automacro get_red {
location payon 170 62
shop "Red Potion" < 26
exclusive 1
call go_buyred
}
macro go_buyred {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 2 250
pause 3
do cart add Red Potion
pause 3
do move payon_in01 16 51
do move payon 170 62
}
automacro get_orange {
location payon 170 62
shop "Orange Potion" < 26
exclusive 1
call go_buyorange
}
macro go_buyorange {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 3 250
pause 3
do cart add Orange Potion
pause 3
do move payon_in01 16 51
do move payon 170 62
}
automacro get_Awak {
location payon 170 62
shop "Awakening Potion" < 11
exclusive 1
call go_buyawak
}
macro go_buyawak {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 8 30
pause 3
do cart add Awakening Potion
pause 3
do move payon_in01 16 51
do move payon 170 62
}
automacro get_conc {
location payon 170 62
shop "Concentration Potion" < 11
exclusive 1
call go_buyconc
}
macro go_buyconc {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 7 30
pause 3
do cart add Concentration Potion
pause 3
do move payon_in01 16 51
do move payon 170 62
}
automacro get_fly {
location payon 170 62
shop "Fly Wing" < 26
exclusive 1
call go_buyfly
}
macro go_buyfly {
do closeshop
pause 3
do move payon 141 85
do move payon_in01 11 49
do talk @npc (5 49)
do store
pause 3
do buy 9 200
pause 3
do cart add Fly Wing
pause 3
do move payon_in01 16 51
do move payon 170 62
}
[/code]
As you can see i want the bot to buy Red Pot and Orange Pot when they are below 26 and open shop when they are above 25.. and so on
The Shop will have a total of 5 items, Red Potion, Orange Potion, Fy Wing, Awak and Conc..
I found this script for White Potion online and tried to modify it for my needs but because i have multiple items i cant seem to get it to work..
Basically I want the bot to go Buy whenever 1 item becomes too low.