EDIT : at first I gave a lot of context for this question, explaining why I wanted to create a bot. I'm sorry it distracted people from my "actual" question.
My question is pretty simple : how does one create a bot for a game ? (Especially... on a mac, if it's possible -- though I can use a Linux virtual machine if needed).
Is it interfaced with the application, or just "watching" the screen and extracting information from it (as if it was taking pictures and analyzing them to get informations such as your HP, your position, etc.) ? Could I use python to code it, or are there specific languages ?
The forementioned context :
Since I started programming, I've wanted to try to create algorithms that would be able to "play" (or even "beat") video games. Many games require only logical choices, more and more complex as the difficulty grows, which seems perfect for algorithms.
I currently enjoy the game "Pixel Dungeon" a lot (see here), but it's not always nice to you (and you die. A lot.). A few researches on the internet show that a lot can be achieved just by following simple guidelines.
So I figured maybe this would be a good game to try and create bots to play it. In the long term, I would like to let bots play, extract data out of it, and modify my algorithms according to these data. I am really enthusiast about this, but also really novice.
(maybe this belongs more to https://stackoverflow.com/ ?)