userfunction score

Additional botting resources. Addons may be either for the game itself or for the RoM bot.
Forum rules
Only post additional bot resources here. Please do not ask unrelated questions.
Post Reply
Message
Author
User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

userfunction score

#1 Post by BlubBlab » Wed Jul 01, 2015 10:41 pm

It is not finished but there are a lot of opinions I need.
So I need beta testers.

What it can do? Until now it can score equip.

This userfunctions main purpose is to clean the bag and equip characters when they level through quests. Therefore it scores and filter every equip in your bag and equip it if it is better than what is already equipped (or nil). But it can also used to compare items

Code: Select all

-- First function give you an gearscore as a number
getItemScore( item )
@item item object

-- secound function give you an gearscore as a number
getEquipScore( item )
@item item object

-- the other is the 'main' function of the userfunction

 clearAndEquipChar(erase, rarity, safeswitch)

@erase a boolean which say if all other stuff should should thrown out
@ rarity the max rarity until stuff will thrown out  1 -white, 2 -green, 3 -blue and so on (if nil 2 is default)
@safeswitch a string which activate the function behind level 50 "I know what I'm doing"
all other things will result in nothing and the userfunction stops function after level 50 

What I need to know are errors and suggestion on the stat rating and what weapons some classes can wield which I possible I had forgotten ?
(Basically those big lists on top of the file)

V0.9e :add a new function and a few bug fixes, added sanity check for + level addresse
V1.0 fix weapon values, add auto check if wearing a two handed weapons when try to equip shield or talisman, fix bug with arrows for scout
V1.0b fixed all know bugs , starting to implement scoring for quest items
V1.0d turned off debug messages
Attachments
userfunction_score.lua
V.1.0d
(54.66 KiB) Downloaded 195 times
Last edited by BlubBlab on Mon Jul 20, 2015 7:08 am, edited 7 times in total.
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: userfunction score

#2 Post by BlubBlab » Fri Jul 03, 2015 6:04 am

The scoring of weapons works now.
I also tested it in wander modus yesterday I let the bot run for hours to let him equip itself when it find new (crap)stuff.
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

User avatar
beanybabe
Posts: 647
Joined: Wed Mar 06, 2013 1:27 am

Re: userfunction score

#3 Post by beanybabe » Fri Jul 03, 2015 7:03 am

I would worry about swaping weapons to repair them. also if you had a tiered weapon you were using that it not get destroy if weapon swap failed and it got left in bag. I think your plain is to use this for 0 to 50 but someone might want to use for other things.

it seems to me that either the elf wp chain or the logar one would auto equip better inventory. I never checked if that is what you are trying to do.

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: userfunction score

#4 Post by BlubBlab » Fri Jul 03, 2015 8:09 am

You can also turn off the cleaning of the bag if you want that, what I wanted todo was for large quest chains automatically find the best equip for the char. It isn't built for high-end chars so it turns it off if the player level is higher than level 50. This was planned as helper function for my path recorder. You can also use it to find better quip in low level zones if you party bot with a high char you can get your lower char through the Abtei(?) or so, a few hours later the char stay fully equipped there.
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: userfunction score

#5 Post by rock5 » Fri Jul 03, 2015 11:37 am

I thought of the possibility that the stat effects and the plus effects use different offsets but hadn't tested it yet. To me it looks like the stat effects offset of 0xB8 is correct and works properly. I thought 0x98 worked for 1 of my items but the amounts were off, and it didn't work at all for my other weapon. So it looks like the plussing still doesn't work properly for me.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: userfunction score

#6 Post by BlubBlab » Fri Jul 03, 2015 9:14 pm

Okay than I must test it more with other weapons. It could be that it depends on the item or the game version @. @
EDIT: I added a sanity check for which offset addresses will be used. I'm not sure why with the 'new' addresses I got always 4 dmg more than it should be
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: userfunction score

#7 Post by BlubBlab » Sat Jul 04, 2015 8:37 pm

Committed a new version.
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: userfunction score

#8 Post by BlubBlab » Thu Jul 09, 2015 1:35 am

I wrote a new version I actually fixed a lot of bugs which I found so I don't remember all of them there were some update missing and some checks.
I'm nearly finished with the quest item scoring it is not an easy task because you need to scan the item IDs of ROM a lot it can take nearly an hour to do so. So it makes only sense to use it in corporation with another userfuction which write than your AcceptQuest with corresponding item choice number.
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

User avatar
beanybabe
Posts: 647
Joined: Wed Mar 06, 2013 1:27 am

Re: userfunction score

#9 Post by beanybabe » Thu Jul 09, 2015 2:06 am

I looked back in the old messages and found this you all worked on years ago it may be useless now.
http://www.solarstrike.net/phpBB3/viewt ... ear#p32369

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: userfunction score

#10 Post by rock5 » Thu Jul 09, 2015 2:32 am

Yeah that's the topic that lead to my rater function. I even posted it there.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: userfunction score

#11 Post by BlubBlab » Thu Jul 09, 2015 6:02 am

I noticed that earlier but than it was already too late most of the function was finished.
It kinda funny my record userfunction based also on a work of MiesterMan. Main difference between my version(score) and his is that I don't need to install an add-on in rom.

I suspect MiesterMan was also aiming for something similar like I do with both userfunctions. The problem is both userfunction are highly complex in score the problem is all the exceptions like off-hand daggers that you have 2 spots for the rings and earrings and also the shields and talismans which need to put aside when wearing a two-hand weapon. In the record userfunction it was a lot of maths to filter out all the unnecessary waypoint and keep track of all the quests which are accepted or completed(which seems still not working when things are done outside the Quest ID order)
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

Celesteria
Posts: 36
Joined: Mon Jun 01, 2015 7:44 am

Re: userfunction score

#12 Post by Celesteria » Mon Jul 20, 2015 6:01 am

hi blubblab

this userfunction is not really working as expected. there are some points i figured out using it for a level 1 farming char.

1. there is no level check (or it is not working correctly) for the items
2. there is no check if the player (rouge) can allready equip a second weapon
3. it ALLWAYS spam this output: "You must specify a valid location to move the item to. You cannot use "all"
4. it seams to me the priority of then durability of an item is too high. an item with "ausdauer II" and dura of 76 is handled as better then the same item with "ausdauer I" and dura of 98.
5. it would be fine if you could separat the functions for erasing and equipping. i will equip better items, but i also want to sell the other stuff and let the addon LootIt! erase unneeded items
6. sometimes i get this output from your function:

Code: Select all

Kampf beendet. 65 Jungbär getötet. (Kampf #65 / Laufzeit 14 Minuten)
Lösche Ziel.
Unknown type for this class: 21
Unknown type for this class: 19
Unknown type for this class: 1039747284
Unknown type for this class: 1057046329
Unknown type for this class: 1063739784
Unknown type for this class: 1036128736
Unknown type for this class: 1039747279
Unknown type for this class: 1039747275
Unknown type for this class: 1057128630
Unknown type for this class: 1043089456
Unknown type for this class: 1065187062
Unknown type for this class: 1056626248
Unknown type for this class: 1035411120
Unknown type for this class: 1054964972
Unknown type for this class: 1040296545
Unknown type for this class: 1063403790
Unknown type for this class: 1060258732
Unknown type for this class: 1063740204
Unknown type for this class: 1015776536
Unknown type for this class: 1065187892
Unknown type for this class: 1039747285
Unknown type for this class: 1060254730
Unknown type for this class: 1065104761
Unknown type for this class: 1010311744
Unknown type for this class: 1054999235
Unknown type for this class: 1050293640
Unknown type for this class: 1063486092
Unknown type for this class: 1057145962
Unknown type for this class: 1057046328
öffne/anziehen Gegenstand: Magische ├£berhose
 because it gearscore is: 1168.600000 which is better than the old 0.000000You must specify a valid location to move the item to. You cannot use "all".
Lösche Ziel.
7. sometimes it can not equip an item for some reason. so it should be nice if you could save this item and dont check again every time

hope it helps finding some bugs :)


greetings
Celesteria
I am a botter, but no cheater. So none of my scripts ever use any of the hacks like swimhack, speedhack, wallhack...
I hope you can understand my english. Its not my native language and it has been a long time since I used it the last time :)

User avatar
beanybabe
Posts: 647
Joined: Wed Mar 06, 2013 1:27 am

Re: userfunction score

#13 Post by beanybabe » Mon Jul 20, 2015 6:10 am

I find from level 1 to 5 or so you can just use the same weapon and armor so no really need to check gear below there.

User avatar
BlubBlab
Posts: 948
Joined: Fri Nov 30, 2012 11:33 pm
Location: My little Pony cafe

Re: userfunction score

#14 Post by BlubBlab » Mon Jul 20, 2015 7:02 am

Celesteria wrote:hi blubblab

this userfunction is not really working as expected. there are some points i figured out using it for a level 1 farming char.

1. there is no level check (or it is not working correctly) for the items
2. there is no check if the player (rouge) can allready equip a second weapon
3. it ALLWAYS spam this output: "You must specify a valid location to move the item to. You cannot use "all"
4. it seams to me the priority of then durability of an item is too high. an item with "ausdauer II" and dura of 76 is handled as better then the same item with "ausdauer I" and dura of 98.
5. it would be fine if you could separat the functions for erasing and equipping. i will equip better items, but i also want to sell the other stuff and let the addon LootIt! erase unneeded items
6. sometimes i get this output from your function:

Code: Select all

Kampf beendet. 65 Jungbär getötet. (Kampf #65 / Laufzeit 14 Minuten)
Lösche Ziel.
Unknown type for this class: 21
Unknown type for this class: 19
Unknown type for this class: 1039747284
Unknown type for this class: 1057046329
Unknown type for this class: 1063739784
Unknown type for this class: 1036128736
Unknown type for this class: 1039747279
Unknown type for this class: 1039747275
Unknown type for this class: 1057128630
Unknown type for this class: 1043089456
Unknown type for this class: 1065187062
Unknown type for this class: 1056626248
Unknown type for this class: 1035411120
Unknown type for this class: 1054964972
Unknown type for this class: 1040296545
Unknown type for this class: 1063403790
Unknown type for this class: 1060258732
Unknown type for this class: 1063740204
Unknown type for this class: 1015776536
Unknown type for this class: 1065187892
Unknown type for this class: 1039747285
Unknown type for this class: 1060254730
Unknown type for this class: 1065104761
Unknown type for this class: 1010311744
Unknown type for this class: 1054999235
Unknown type for this class: 1050293640
Unknown type for this class: 1063486092
Unknown type for this class: 1057145962
Unknown type for this class: 1057046328
öffne/anziehen Gegenstand: Magische ├£berhose
 because it gearscore is: 1168.600000 which is better than the old 0.000000You must specify a valid location to move the item to. You cannot use "all".
Lösche Ziel.
7. sometimes it can not equip an item for some reason. so it should be nice if you could save this item and dont check again every time

hope it helps finding some bugs :)


greetings
Celesteria
To 1 Okay yeah I forgot that
2.)I implemented that hm? When you start you can't wear a secound dagger in the off hand I will test it again.
3.) I fixed that maybe it is an old version and I should re upload it.
4.) The priority for the attributes for the classes can be found in local CLASS_SCORE, dura isn't one of them
5.) internally it is a separate function you can turn it of with clearAndEquipChar(false)
6.) That are only test outputs which put outs unknown types of attributes maybe I should turn it off so that people aren't irritated by it

Okay I will make some changes and than reupload

EDIT: The level checke was also there in the last version maybe the upload didn't work properly because I had some errors the last time.
Jack-of-all-trades, but master-of-only of a few :D

My Reps:
https://github.com/BlubBlab/Micromacro-with-OpenCV (My version of MM2 with OpenCV and for MS Visual Studio)
https://github.com/BlubBlab/rom-bot (rombot with no stop WP and advanced human emulation mode and some other extensions)
https://github.com/BlubBlab/Micromacro-2-Bot-Framework ( A work in progress )
My Tools : viewtopic.php?f=10&t=6226

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests