Implement a new Java bot that applies multi-player game theory: in N>2 games, always direct all units toward the current score leader rather than the nearest enemy. This creates a natural kingmaker dynamic that prevents any single bot from running away with the game. Strategy: - Identify all visible opponents and their scores (cores count as proxy) - Pick primary target: opponent with highest inferred score (tiebreak: nearest) - Send all bots toward primary target's centroid (mean of visible bots + cores) - Exception: if own core is under threat (enemy bot within 6 tiles), detach 2 bots to defend - In 2-player games: fall back to straight aggressor strategy Novelty: No current bot does multi-player score-aware target selection. Most bots target nearest enemy, which lets a distant leader accumulate score unmolested. Leader-targeter explicitly models the N-player problem. Co-Authored-By: Claude <noreply@anthropic.com>
75 lines
2.9 KiB
XML
75 lines
2.9 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
|
<modelVersion>4.0.0</modelVersion>
|
|
|
|
<groupId>com.acb</groupId>
|
|
<artifactId>leader-targeter-bot</artifactId>
|
|
<version>1.0.0</version>
|
|
<packaging>jar</packaging>
|
|
|
|
<name>LeaderTargeterBot</name>
|
|
<description>Multi-player score leader targeting bot for AI Code Battle</description>
|
|
|
|
<properties>
|
|
<maven.compiler.source>21</maven.compiler.source>
|
|
<maven.compiler.target>21</maven.compiler.target>
|
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
|
<javalin.version>6.3.0</javalin.version>
|
|
<jackson.version>2.17.0</jackson.version>
|
|
</properties>
|
|
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>io.javalin</groupId>
|
|
<artifactId>javalin</artifactId>
|
|
<version>${javalin.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.fasterxml.jackson.core</groupId>
|
|
<artifactId>jackson-databind</artifactId>
|
|
<version>${jackson.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.slf4j</groupId>
|
|
<artifactId>slf4j-simple</artifactId>
|
|
<version>2.0.12</version>
|
|
</dependency>
|
|
</dependencies>
|
|
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-shade-plugin</artifactId>
|
|
<version>3.5.2</version>
|
|
<executions>
|
|
<execution>
|
|
<phase>package</phase>
|
|
<goals>
|
|
<goal>shade</goal>
|
|
</goals>
|
|
<configuration>
|
|
<transformers>
|
|
<transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
|
|
<mainClass>com.acb.targeter.App</mainClass>
|
|
</transformer>
|
|
</transformers>
|
|
<filters>
|
|
<filter>
|
|
<artifact>*:*</artifact>
|
|
<excludes>
|
|
<exclude>META-INF/*.SF</exclude>
|
|
<exclude>META-INF/*.DSA</exclude>
|
|
<exclude>META-INF/*.RSA</exclude>
|
|
</excludes>
|
|
</filter>
|
|
</filters>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</project>
|