Back to search:Freelance Develop / Indonesia
We are seeking a skilled developer to create a robust and reliable script capable of autonomously playing a web-based Snake game. The primary objective is to develop an intelligent bot that can take full control of the snake's movement, aiming to keep it alive as long as possible while maximizing the score without any manual intervention.Core Requirements:* Real-time game state detection: The script must accurately identify the current direction of the snake, the precise location of food, and assess potential collision risks within the game environment.* Intelligent movement generation: Develop an algorithm to intelligently steer the snake by generating and sending the necessary keyboard events to the game.* Unattended operation: The bot should run autonomously until the game round concludes, then report the final score. This report can be displayed in the console or saved to a log file.Technical Notes:* The solution should offer a headless mode for efficient execution, but it is crucial that the bot also functions in a visible browser mode to allow for observation and debugging during testing.* Acceptable technologies include JavaScript with Puppeteer, or a lightweight Python solution utilizing tools like Selenium with a webdriver, Playwright, or direct JavaScript injection. The choice should prioritize stable and consistent control over the web-based game.* The final code must be self-contained, requiring only one command to install all dependencies and one command to initiate the bot's execution.Acceptance Criteria:1. Upon a fresh clone and installation, the script must launch and demonstrate autonomous snake movement.2. The bot's performance should consistently surpass that of a randomly moving snake, ideally lasting at least twice as long as an average manual play session.3. The solution must be entirely open-source and redistributable, with no reliance on external paid APIs or compiled binaries.4. The project deliverables include clean, well-commented code, accompanied by a concise README file detailing setup instructions, usage guidelines, and any configurable parameters.This project is complete once the script successfully meets all the outlined requirements and acceptance criteria.