Automation helpers for the Revomon Android game running under BlueStacks, built on top of the Bluepyll automation framework.
Project description
RevomonAuto
A powerful automation framework for the Revomon Android game, built on top of the Bluepyll automation framework. RevomonAuto provides comprehensive UI automation, battle intelligence, and game data access for Revomon.
๐ฎ Features
Automation Capabilities
- Full App Lifecycle Management: Automated app opening, closing, and login sequences
- Menu Navigation: Navigate all main menus and submenus (Wardrobe, Bag, Friends, Settings, Revodex, Market, Discussion, Clan)
- PVP Queue Management: Enter and exit PVP queues automatically
- Battle Automation:
- OCR-based move extraction with PP tracking
- Health monitoring via pixel analysis
- Pluggable battle strategies (Random, Custom AI)
- Auto-run from battles (background thread)
- TV/PC Navigation: Search and select Revomon in storage
- Action Tracking: Full audit trail with state diffs for debugging
Battle Intelligence
- Real-time OCR: Extract mon names, levels, HP percentages, and moves
- Move Validation: Filter moves by PP availability
- Strategy Pattern: Extensible battle AI system
- Health Bar Analysis: Pixel-based HP calculation
Game Data Access
17+ specialized client libraries for querying game data:
- RevomonClient: Search by name, type, ability
- MovesClient: Physical, special, and status moves
- BattleMechanicsClient: Damage calculation, type effectiveness, team coverage analysis
- EvolutionClient: Evolution trees and optimal path finding
- WeatherClient: Weather synergy analysis
- StatusEffectsClient: Status condition strategy
- TypesClient, ItemsClient, NaturesClient, LocationsClient, and more
๐ Requirements
- Python: 3.13 or higher
- Operating System: Windows (BlueStacks integration)
- BlueStacks: Android emulator
- ADB: Android Debug Bridge (included with BlueStacks)
๐ Installation
We recommend using uv for package management.
Install as a dependency
uv add revomonauto
Development Setup
# Clone the repository
git clone https://github.com/IAmNo1Special/RevomonAuto.git
cd RevomonAuto
# Install dependencies with uv
uv sync
# Run the example
uv run examples/main.py
Using pip
# Clone the repository
git clone https://github.com/IAmNo1Special/RevomonAuto.git
cd RevomonAuto
# Create virtual environment
python -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
# Install dependencies
pip install -e .
# Run the example
python examples/main.py
๐ฏ Quick Start
Basic Automation
from bluepyll import BluePyllController
from revomonauto.models.revomon_app import RevomonApp
# Initialize
revomon_app = RevomonApp()
controller = BluePyllController(apps=[revomon_app])
# Start BlueStacks and open app
controller.bluestacks.open()
controller.revomon.open_revomon_app()
# Login sequence
controller.revomon.start_game()
controller.revomon.login()
# Navigate menus
controller.revomon.open_main_menu()
controller.revomon.open_menu_bag()
controller.revomon.close_menu_bag()
controller.revomon.close_main_menu()
# Enter PVP queue
controller.revomon.enter_pvp_queue()
Battle Automation
# Wait for battle to start, then automate
while True:
if controller.revomon.is_in_battle_scene():
# Open attacks menu
controller.revomon.open_attacks_menu()
# Choose a random move
controller.revomon.choose_move()
# Or use a custom strategy
from revomonauto.models.strategies import BattleStrategy
class AlwaysFirstMove(BattleStrategy):
def select_move(self, valid_move_names):
return valid_move_names[0]
controller.revomon.choose_move(strategy=AlwaysFirstMove())
Auto-Run from Battles
# Enable auto-run (runs from all battles automatically)
controller.revomon.toggle_auto_run()
# Your automation continues while battles are automatically escaped
# ...
# Disable when done
controller.revomon.toggle_auto_run()
Game Data Access
from revomonauto.data.gradex_clients import (
RevomonClient,
MovesClient,
BattleMechanicsClient,
EvolutionClient
)
# Initialize clients
revomon_client = RevomonClient()
moves_client = MovesClient()
battle_client = BattleMechanicsClient()
# Find Revomon by type
fire_types = revomon_client.get_revomon_by_type("fire")
print(f"Fire types: {[r['name'] for r in fire_types[:5]]}")
# Get all status moves
status_moves = moves_client.get_status_moves()
# Analyze team type coverage
team = [
revomon_client.get_revomon_by_name("gorcano"),
revomon_client.get_revomon_by_name("blizzora")
]
coverage = battle_client.analyze_type_coverage(team)
print(f"Type coverage: {coverage['overall_coverage']:.1%}")
# Find optimal evolution path
evolution_client = EvolutionClient()
paths = evolution_client.find_optimal_evolution_path(
target_stats={"spa": 1.0, "spe": 0.7},
max_evolutions=3
)
๐ Project Structure
RevomonAuto/
โโโ src/revomonauto/
โ โโโ models/
โ โ โโโ revomon_app.py # Main automation controller
โ โ โโโ states.py # GameState and BattleState enums
โ โ โโโ action.py # Action tracking system
โ โ โโโ strategies.py # Battle strategy implementations
โ โ โโโ revomon_ui/ # UI element definitions
โ โ โโโ assets/ # Image assets for UI matching
โ โ โโโ elements/ # UI element definitions
โ โ โโโ screens/ # Screen object models
โ โโโ data/
โ โโโ gradex_clients/ # Game data client libraries
โโโ examples/
โ โโโ main.py # Full automation workflow
โ โโโ example_client_usage.py # Data client examples
โโโ tests/ # Unit tests
โโโ pyproject.toml # Project configuration
โโโ README.md # This file
๐ง State Management
RevomonAuto uses a dual state machine system for robust automation:
GameState
NOT_STARTED,STARTED- Login flowOVERWORLD- Free roamingMAIN_MENU- Menu overlayMENU_BAG,WARDROBE,FRIENDS_LIST,SETTINGS,REVODEX,MARKET,DISCUSSION,CLAN- SubmenusPVP_QUEUE- Waiting for PVP matchBATTLE- In combatTV- PC/storage interface
BattleState (Sub-state when in BATTLE)
IDLE- Can attack, use bag, or runATTACKS_MENU_OPEN- Move selection visibleBAG_OPEN- Bag menu visibleWAITING_FOR_OPPONENT- Turn being processed
State validation is enforced via the @requires_state decorator:
@requires_state(GameState.BATTLE)
@action
def choose_move(self, strategy=None):
# Only executes if in BATTLE state
...
๐ฒ Creating Custom Battle Strategies
Extend the BattleStrategy abstract base class:
from revomonauto.models.strategies import BattleStrategy
from revomonauto.data.gradex_clients import MovesClient, TypesClient
class SuperEffectiveStrategy(BattleStrategy):
def __init__(self, opponent_type):
self.opponent_type = opponent_type
self.moves_client = MovesClient()
self.types_client = TypesClient()
def select_move(self, valid_move_names):
# Get move objects
moves = [self.moves_client.get_move_by_name(name)
for name in valid_move_names]
# Find super-effective moves
for move in moves:
effectiveness = self.types_client.get_effectiveness(
move['type'], self.opponent_type
)
```python
# Execute actions
controller.revomon.open_main_menu()
controller.revomon.enter_pvp_queue()
# Review action history
for action in controller.revomon.actions:
print(f"Action: {action['action_name']}")
print(f"Status: {action['status']}")
print(f"State changes: {action['state_diff']}")
Example output:
Action: open_main_menu
Status: True
State changes: {
'game_state': {'prev': 'OVERWORLD', 'new': 'MAIN_MENU'}
}
๐งช Testing
# Run tests with uv
uv run pytest
# Run specific test
uv run pytest tests/test_choose_move.py
# Run with coverage
uv run pytest --cov=src/revomonauto
๐ง Configuration
Create a .env file in the project root (not tracked by git):
# BlueStacks configuration
BLUESTACKS_PATH=C:\Program Files\BlueStacks_nxt\HD-Player.exe
ADB_PATH=C:\Program Files\BlueStacks_nxt\HD-Adb.exe
# Game credentials (optional, for auto-login)
REVOMON_USERNAME=your_username
REVOMON_PASSWORD=your_password
โ ๏ธ Important Notes
Game Terms of Service
- Use at your own risk: Automation may violate Revomon's Terms of Service
- Account safety: No guarantees against detection or bans
- Recommendation: Use on alternate accounts and add human-like delays
Limitations
- Scene detection: May require manual intervention in some scenarios
- OCR accuracy: ~95% accuracy, occasional errors in move/name detection
- State synchronization: Uses fixed delays (1 second) which may need adjustment
- Battle end detection: Manual input currently required to detect battle completion
๐บ๏ธ Roadmap
- Background scene detection thread
- Robust PVP queue state detection
- Battle end detection
- Error recovery and retry logic
- Comprehensive test suite
- CI/CD pipeline
- Performance optimization (reduce sleep delays)
- Docker support
๐ค Contributing
Contributions are welcome! Please follow these guidelines:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Follow existing code style and patterns
- Add tests for new functionality
- Update documentation as needed
- Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
Development Setup
# Clone your fork
git clone https://github.com/YOUR_USERNAME/RevomonAuto.git
cd RevomonAuto
# Install development dependencies
uv sync --all-extras
# Run tests
uv run pytest
# Run linter
uv run ruff check .
# Format code
uv run ruff format .
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐ Acknowledgments
- Bluepyll Framework: Core automation capabilities
- Revomon Community: Game data and mechanics information
- Contributors: All those who have contributed to this project
๐ Support
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Email: ivmno1special@gmail.com
โก Advanced Examples
Multi-Account Farming
accounts = [
{"username": "account1", "password": "pass1"},
{"username": "account2", "password": "pass2"}
]
for account in accounts:
# Login with different account
controller.revomon.login(account)
# Enable auto-run
controller.revomon.toggle_auto_run()
# Farm for 1 hour
time.sleep(3600)
# Logout
controller.revomon.quit_game()
Team Optimization
from revomonauto.data.gradex_clients import (
RevomonClient, EvolutionClient, BattleMechanicsClient
)
# Find Revomon with best special attack evolution path
evolution_client = EvolutionClient()
paths = evolution_client.find_optimal_evolution_path(
target_stats={"spa": 1.0, "spe": 0.8, "spd": 0.6},
max_evolutions=3
)
# Build a balanced team
battle_client = BattleMechanicsClient()
team = build_balanced_team(paths[:6])
# Analyze coverage
coverage = battle_client.analyze_type_coverage(team)
print(f"Team covers {coverage['covered_types']}/{coverage['total_types']} types")
Disclaimer: This project is not affiliated with or endorsed by Revomon. Use at your own risk.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file revomonauto-0.3.2.tar.gz.
File metadata
- Download URL: revomonauto-0.3.2.tar.gz
- Upload date:
- Size: 63.9 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
06f26d540cf065cf2d52bf49cbc1021f7224d5d385affa827a8ee7531eefdde8
|
|
| MD5 |
109d1d30910253f22100bad80a4acc5a
|
|
| BLAKE2b-256 |
4acaace0f93ef4c935e2386d44d850075bb85e79e289bf57842a37bee0fd24fe
|
File details
Details for the file revomonauto-0.3.2-py3-none-any.whl.
File metadata
- Download URL: revomonauto-0.3.2-py3-none-any.whl
- Upload date:
- Size: 63.9 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a4dd5733b22ec97cae2d07766e683c2af9ddfcaa4848e9f17348eab40f42e34b
|
|
| MD5 |
cf6cb10414ce6eeca496f06f92e6c7ed
|
|
| BLAKE2b-256 |
8a5347b0f45296cda57a26121b3fad901ee06844a52c03c4136fd43058e484d3
|