Ikabot-Collective / ikabot

A Python-based bot designed for automating tasks in the game Ikariam
https://discord.com/invite/3hyxPRj
MIT License
100 stars 67 forks source link

Feature - queuing tasks using database/file #103

Open theWituch opened 2 years ago

theWituch commented 2 years ago

Adding queuing of tasks in the database (text file, H2 database or any other) from which data would be read by the crawler at certain intervals.

This would allow the queue to be stored permanently - even disabling the bot. The current TUI application would only require the relevant data - what operation, what cities, etc. and then a new entry would be added to the task queue.

From this database, the crawler (scheduler) would fetch the relevant task entries at specified intervals. Crawler would then check the conditions for completing a given task, e.g. in the case of a construction queue, whether the city has the right amount of resources - if so, he would start construction, if not, he would generate a telegram message, or send resources from other cities if the task was configured for this etc.

Then you would not have to worry about handling running processes and in case of an error it would not result in the loss of all queued tasks.

I am currently using the bot and I like how it works - it only lacks the mechanism I wrote about.

almir101 commented 1 year ago

Would be helpfull! Also I would like if they implemented research with crystal feature ^.^

susikaman commented 1 year ago

Would be helpfull! Also I would like if they implemented research with crystal feature ^.^

I've got good news for you. ;) https://github.com/physics-sec/ikabot/pull/118