Jump to content
Sign in to follow this  

Using the OCR in Our MODS

Recommended Posts

I am looking for help on How To Use The OCR. If I am not mistaken the OCR is used for reading text and I wish to write some code that reads some text that the bot does not currently support reading.

As it stands right now, I am un-aware how the OCR uses those .xml files to search for the words and could use some explanation so that I may utilize the OCR for my MODs. 


Thank you! :)

Edited by Chilly-Chill
Removed top-line title.

Share this post

Link to post
Share on other sites

From what I have read:

If the text you want to read is not same size, color, and font type as one of the existing font sets supported by existing XML files, you will not be able to use existing getOcr.au3 code.  Fundamental problem is the XML files are encrypted closed source?


Not sure this is best solution, but will share regardless:

Prior to V5 MyBot used a different text OCR method that was customizable by users.  Can search GitHub archive for V5 and prior versions in the "Read Text" folder for the obsoleted programs.  There also used to be thread archived that explained how the code worked.   It was developed back in 2014/2015 for earliest released versions (called COCGameBot on different web site back then) by one of the original bot developers. 

Reading text used to be one of the 'slow' areas of MBR performance as features expanded and more screen data needed to be incorporated into game play decisions.  Development of faster multi-threaded image recognition code in DLL and XML pixel maps was huge improvement..  If you only to read a few characters, the old code was simple and fast enough to get job done.  Recognizing entire English and foreign character sets brought image detection performance to a crawl, and was abandoned.


Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...