Posts: 41
Threads: 9
Joined: Nov 2016
Reputation:
0
Thank you for any help.
I created a cavebot, but the script can not follow the three Fullchek I created, just follow the first one that is the cap.
Many times my cap is full but the pot is running out and continues in the basement, how do I read all 3 fullchek?
I hosted the photo on a website, from the script, Link V
https://imgur.com/a/JIy4KeI
Desculpe por erros de digitação " Ingles "
Posts: 1,630
Threads: 103
Joined: Sep 2015
Reputation:
0
04-28-2019, 05:54 AM
(This post was last modified: 04-28-2019, 06:05 AM by Catar.)
Put all checks in single waypoint
https://wiki.bmega.net/doku.php?id=add_t...heck_label
here is random example from my scripts:
Code: FullCheck (32948 32686 6:Full BACK Else HUNT Code !BBot.ManaDrinker.Heavy.ItemID<!SMPb;!BBot.Healers.ItemHeavy.ItemID<!SHPb;cap<!capb;!BackThais>0)
Also its easier to put names on IDs in variables
while BBot.Healers.Items... are default names of variables that Healer function uses,
!SHPb / !SMPb / !capb are my own settings in variables,
makes it easier to adjust checks on the run
Posts: 41
Threads: 9
Joined: Nov 2016
Reputation:
0
04-28-2019, 05:04 PM
(This post was last modified: 04-29-2019, 03:25 AM by Freitas.)
Thanks
FullCheck (33638 31929 12:Full hunt Else city Code !BBot.ManaDrinker.Heavy.ItemID<200;!BBot.Healers.ItemHeavy.ItemID<200;cap<100)
Does it have to stay like this? I do not understand, sorry
Posts: 1,630
Threads: 103
Joined: Sep 2015
Reputation:
0
04-29-2019, 03:49 AM
(This post was last modified: 04-29-2019, 03:50 AM by Catar.)
You can make your own variables, I just used genetic ones because I liked to.
I just gave you example, all conditions on these full check have to be true for bot to do "full" label, and if even one of them isn't, it will do "else"
Posts: 41
Threads: 9
Joined: Nov 2016
Reputation:
0
FullCheck (33029 31161 2:Full city Else hunt Code cap<300)
FullCheck (33029 31161 2:Full city Else hunt Code cap<300;7643<200)
FullCheck (33029 31161 2:Full city Else hunt Code cap<300;268<400)
If I do this is the same thing? v
Fullcheck (33029 31161 2:Full city Else hunt code cap<300;cap<300;7643<200;<300;268<400)
?
Posts: 1,630
Threads: 103
Joined: Sep 2015
Reputation:
0
if any of these conditions is met it will do Full If all of these are false it will go else
Posts: 41
Threads: 9
Joined: Nov 2016
Reputation:
0
1 FullCheck (33638 31929 12:Full city Else hunt Code cap<=!minCap!;!SP!<=!minSP!;!SHP!<=!minSHP!)
##### Setup #####
# Leave Hunt #
minCap=100
minMP=200
minSHP=100
# Amount of Potions #
amountSHP=500
amountSP=600
# Price of Potions #
costSP=113
costSHP=458
!MyVariable!==3
2 Cap<100;Health Potion<10;3031>1500
Which one is right? or is it still wrong?
I want to learn from this my difficulty
Posts: 1,630
Threads: 103
Joined: Sep 2015
Reputation:
0
First thing, you copied from script that works, it should work, just analyze and use parts of working scripts, that's how I learned at first.
Using variables in full checks is always better
Posts: 41
Threads: 9
Joined: Nov 2016
Reputation:
0
05-01-2019, 05:00 PM
(This post was last modified: 05-03-2019, 01:52 AM by Freitas.)
I'm getting better, but I still have doubts.
(33637 31928 12:Full city Else hunt Code cap<=100;!ManaID!<=!ManaBack!) <- It works
(33637 31928 12:Full city Else hunt Code cap<=100;!ManaID!<=!ManaBack!<=!SpID!<=!SpBack!) <- Does not work because?
Variables
ManaID=237
ManaP=67800
ManaQT=600
ManaBack=40
SpID=23374
SpP=229000
SpQT=500
SpBack=100
23374 = Ultimate Spirit Potion
Posts: 41
Threads: 9
Joined: Nov 2016
Reputation:
0
Catar, there is no way you can record a video of 1 min, just to teach, there may be more people with difficulty too.
Posts: 1,630
Threads: 103
Joined: Sep 2015
Reputation:
0
05-06-2019, 07:39 PM
(This post was last modified: 05-06-2019, 07:40 PM by Catar.)
I have no tibia, nor any ots account and character I could test anything on.
Moved on from that game for now.
Posts: 41
Threads: 9
Joined: Nov 2016
Reputation:
0
I'll give you account support, Otservlist, Can be?
But you understood my doubt?
Scripting just reads, cap and mana. I needed one more
Posts: 1,630
Threads: 103
Joined: Sep 2015
Reputation:
0
05-07-2019, 03:07 PM
(This post was last modified: 05-07-2019, 03:09 PM by Catar.)
(33637 31928 12:Full city Else hunt Code cap<=100;!ManaID!<=!ManaBack!<=!SpID!<=!SpBack!)
its wrong,
u have to separate conditions with ;
(33637 31928 12:Full city Else hunt Code cap<=100;!ManaID<=!ManaBack;!SpID<=!SpBack)
also, no need for ! after variable name, use it only in front
Posts: 41
Threads: 9
Joined: Nov 2016
Reputation:
0
|