Skip to main content

Seamaster is a package which helps users write and submit code to participate in the Seawars game.

Project description

Seamaster Bot Programming – User Guide

Note: This library is still under development, and the contents of this README might change in the future.

Seamaster is a strategy-based bot programming platform where you design autonomous bots that explore, harvest, fight, and survive in a grid-based world.

Key Mindset You do not control bots every turn. You define strategies, and bots follow them autonomously for their entire lifetime.

Core Philosophy

A bot is born with a strategy. It lives with that strategy. It dies with that strategy.

  • You define how a bot behaves
  • The engine decides when that behavior runs
  • You never micromanage bots after spawning

Architecture Overview

Layer Responsibility
User (user.py) Strategy logic only
BotContext Gives you methods to define your custom bot
Helpers Create actions (move, attack, etc.)

You only write user.py.


Bots = Strategies

Each bot type is a Python class.

class Forager(BotController):
    def act(self):
        ...

Define your complete bot strategy here and execute!

Some Examples:

Adding extra abilities while spawning bots and using botcontext

    def play(api: GameAPI):
    actions = []

    if api.view.bot_count < api.view.max_bots:
        abilities = [
            Ability.HARVEST.value,
            Ability.SCOUT.value,
            Ability.SPEED.value,          # EXTRA ability
            Ability.SELF_DESTRUCT.value,  # EXTRA ability
        ]

        if can_afford(api, abilities):
            actions.append(
                spawn("HeatSeeker", abilities)
            )

    return actions

OR like this:

actions.append(
    spawn(
        "CustomBot",
        [
            Ability.HARVEST.value,
            Ability.SCOUT.value,
            Ability.SPEED.value,
        ]
    )
)

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

seamaster-0.0.5.tar.gz (553.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

seamaster-0.0.5-py3-none-any.whl (607.2 kB view details)

Uploaded Python 3

File details

Details for the file seamaster-0.0.5.tar.gz.

File metadata

  • Download URL: seamaster-0.0.5.tar.gz
  • Upload date:
  • Size: 553.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for seamaster-0.0.5.tar.gz
Algorithm Hash digest
SHA256 ad86fec5f00b0e2704c0f3c64fed2d479c2f6d86b15cc0b34984513d893ec32d
MD5 1d52e248fc0c552acaafaf83c59c2d05
BLAKE2b-256 1b1aa425a0063d629898b0a22a27047a71ffe44f316f2419c827292b9ed5cd2e

See more details on using hashes here.

File details

Details for the file seamaster-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: seamaster-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 607.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for seamaster-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 e6d163c851ec953a75981780bd3e2bf9dfbf462151cdc1d519ea6c67483b81cd
MD5 fd5448cb3d4f99a962aef3afd306b32a
BLAKE2b-256 26d21f386b4585471579d5d30ea4dd20e06c3cfb85465bc32503f8d5ff453520

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page