Skip to content

SimplifiedAlliance

python
class SimplifiedAlliance(BaseModel):
    requestorID: PlayerID
    recipientID: PlayerID
    createdAt: Tick
    expiresAt: Tick

    def other(me: PlayerID) -> PlayerID
java
public class SimplifiedAlliance {
    @NotNull public PlayerID requestorID;
    @NotNull public PlayerID recipientID;
    @NotNull public Tick createdAt;
    @NotNull public Tick expiresAt;

    @NotNull
    public PlayerID other(@NotNull PlayerID me)
}

Encapsulates information about an alliance between two players in an ongoing game.

Attributes

AttributeTypeDescription
requestorIDPlayerIDThe unique identifier of the player who initiated the alliance.
recipientIDPlayerIDThe unique identifier of the player who accepted the alliance.
createdAtTickThe game tick at which the alliance was formed.
expiresAtTickThe game tick at which the alliance will expire, assuming it is not renewed or broken beforehand.

Methods

other

python
def other(me: PlayerID) -> PlayerID

Helper function for getting the ID of the other player in one of your alliances, given your own player ID.