Add city gameplay, snapshot migrations, administration and Compose operations
This commit is contained in:
1 parent
3b1fcd996a
commit
85df37c26e
24 files changed
+1042
-55
No files matched your search
+147
-15
@@ -10,7 +10,7 @@ import type { Message } from "@bufbuild/protobuf";
|
||||
* Describes the file city.proto.
|
||||
*/
|
||||
export const file_city: GenFile = /*@__PURE__*/
|
||||
fileDesc("CgpjaXR5LnByb3RvEgRjaXR5IkIKBFJlY3QSDQoFbWluX3gYASABKBESDQoFbWluX3kYAiABKBESDQoFbWF4X3gYAyABKBESDQoFbWF4X3kYBCABKBEiPgoESm9pbhIMCgRyb29tGAEgASgJEhYKDmNsaWVudF92ZXJzaW9uGAIgASgNEhAKCG5pY2tuYW1lGAMgASgJIjIKCVN1YnNjcmliZRIYCgRyZWN0GAEgASgLMgouY2l0eS5SZWN0EgsKA2xvZBgCIAEoDSIVCgRQaW5nEg0KBW5vbmNlGAEgASgNIhgKB1Byb3Bvc2USDQoFc3BlZWQYASABKA0iEwoEVm90ZRILCgN5ZXMYASABKAgiNgoKQ3JlYXRlQ2l0eRIMCgRiYm94GAEgAygBEgwKBG5hbWUYAiABKAkSDAoEc2VlZBgDIAEoDSJlCgdDaXR5Sm9iEgoKAmlkGAEgASgJEg8KB2NpdHlfaWQYAiABKAkSDgoGc3RhdHVzGAMgASgJEg8KB3Jvb21faWQYBCABKAkSDQoFZXJyb3IYBSABKAkSDQoFc3RhZ2UYBiABKAkiswEKDUNsaWVudE1lc3NhZ2USGgoEam9pbhgBIAEoCzIKLmNpdHkuSm9pbkgAEiQKCXN1YnNjcmliZRgCIAEoCzIPLmNpdHkuU3Vic2NyaWJlSAASGgoEcGluZxgDIAEoCzIKLmNpdHkuUGluZ0gAEiAKB3Byb3Bvc2UYBCABKAsyDS5jaXR5LlByb3Bvc2VIABIaCgR2b3RlGAUgASgLMgouY2l0eS5Wb3RlSABCBgoEYm9keSI3CgVBZ2VudBIKCgJpZBgBIAEoDRIJCgF4GAIgASgREgkKAXkYAyABKBESDAoEa2luZB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Z2FtZXBsYXkYDCABKAsyDi5jaXR5LkdhbWVwbGF5YgZwcm90bzM");
|
||||
|
||||
/**
|
||||
* @generated from message city.Rect
|
||||
@@ -144,6 +144,121 @@ export type Vote = Message<"city.Vote"> & {
|
||||
export const VoteSchema: GenMessage<Vote> = /*@__PURE__*/
|
||||
messageDesc(file_city, 5);
|
||||
|
||||
/**
|
||||
* Equal rights for every connected player; only these three bounded actions exist.
|
||||
*
|
||||
* @generated from message city.Intervene
|
||||
*/
|
||||
export type Intervene = Message<"city.Intervene"> & {
|
||||
/**
|
||||
* @generated from field: string action = 1;
|
||||
*/
|
||||
action: string;
|
||||
};
|
||||
|
||||
/**
|
||||
* Describes the message city.Intervene.
|
||||
* Use `create(InterveneSchema)` to create a new message.
|
||||
*/
|
||||
export const InterveneSchema: GenMessage<Intervene> = /*@__PURE__*/
|
||||
messageDesc(file_city, 6);
|
||||
|
||||
/**
|
||||
* @generated from message city.Needs
|
||||
*/
|
||||
export type Needs = Message<"city.Needs"> & {
|
||||
/**
|
||||
* @generated from field: uint32 hunger = 1;
|
||||
*/
|
||||
hunger: number;
|
||||
|
||||
/**
|
||||
* @generated from field: uint32 fatigue = 2;
|
||||
*/
|
||||
fatigue: number;
|
||||
|
||||
/**
|
||||
* @generated from field: uint32 morale = 3;
|
||||
*/
|
||||
morale: number;
|
||||
};
|
||||
|
||||
/**
|
||||
* Describes the message city.Needs.
|
||||
* Use `create(NeedsSchema)` to create a new message.
|
||||
*/
|
||||
export const NeedsSchema: GenMessage<Needs> = /*@__PURE__*/
|
||||
messageDesc(file_city, 7);
|
||||
|
||||
/**
|
||||
* @generated from message city.GameEvent
|
||||
*/
|
||||
export type GameEvent = Message<"city.GameEvent"> & {
|
||||
/**
|
||||
* @generated from field: uint64 minute = 1;
|
||||
*/
|
||||
minute: bigint;
|
||||
|
||||
/**
|
||||
* @generated from field: string kind = 2;
|
||||
*/
|
||||
kind: string;
|
||||
};
|
||||
|
||||
/**
|
||||
* Describes the message city.GameEvent.
|
||||
* Use `create(GameEventSchema)` to create a new message.
|
||||
*/
|
||||
export const GameEventSchema: GenMessage<GameEvent> = /*@__PURE__*/
|
||||
messageDesc(file_city, 8);
|
||||
|
||||
/**
|
||||
* @generated from message city.Gameplay
|
||||
*/
|
||||
export type Gameplay = Message<"city.Gameplay"> & {
|
||||
/**
|
||||
* @generated from field: sint64 treasury = 1;
|
||||
*/
|
||||
treasury: bigint;
|
||||
|
||||
/**
|
||||
* @generated from field: uint64 food = 2;
|
||||
*/
|
||||
food: bigint;
|
||||
|
||||
/**
|
||||
* @generated from field: city.Needs needs = 3;
|
||||
*/
|
||||
needs?: Needs | undefined;
|
||||
|
||||
/**
|
||||
* @generated from field: repeated city.GameEvent events = 4;
|
||||
*/
|
||||
events: GameEvent[];
|
||||
|
||||
/**
|
||||
* @generated from field: repeated string pending = 5;
|
||||
*/
|
||||
pending: string[];
|
||||
|
||||
/**
|
||||
* @generated from field: uint64 minute = 6;
|
||||
*/
|
||||
minute: bigint;
|
||||
|
||||
/**
|
||||
* @generated from field: uint64 next_intervention_minute = 7;
|
||||
*/
|
||||
nextInterventionMinute: bigint;
|
||||
};
|
||||
|
||||
/**
|
||||
* Describes the message city.Gameplay.
|
||||
* Use `create(GameplaySchema)` to create a new message.
|
||||
*/
|
||||
export const GameplaySchema: GenMessage<Gameplay> = /*@__PURE__*/
|
||||
messageDesc(file_city, 9);
|
||||
|
||||
/**
|
||||
* @generated from message city.CreateCity
|
||||
*/
|
||||
@@ -169,7 +284,7 @@ export type CreateCity = Message<"city.CreateCity"> & {
|
||||
* Use `create(CreateCitySchema)` to create a new message.
|
||||
*/
|
||||
export const CreateCitySchema: GenMessage<CreateCity> = /*@__PURE__*/
|
||||
messageDesc(file_city, 6);
|
||||
messageDesc(file_city, 10);
|
||||
|
||||
/**
|
||||
* @generated from message city.CityJob
|
||||
@@ -211,7 +326,7 @@ export type CityJob = Message<"city.CityJob"> & {
|
||||
* Use `create(CityJobSchema)` to create a new message.
|
||||
*/
|
||||
export const CityJobSchema: GenMessage<CityJob> = /*@__PURE__*/
|
||||
messageDesc(file_city, 7);
|
||||
messageDesc(file_city, 11);
|
||||
|
||||
/**
|
||||
* @generated from message city.ClientMessage
|
||||
@@ -250,6 +365,12 @@ export type ClientMessage = Message<"city.ClientMessage"> & {
|
||||
*/
|
||||
value: Vote;
|
||||
case: "vote";
|
||||
} | {
|
||||
/**
|
||||
* @generated from field: city.Intervene intervene = 6;
|
||||
*/
|
||||
value: Intervene;
|
||||
case: "intervene";
|
||||
} | { case: undefined; value?: undefined };
|
||||
};
|
||||
|
||||
@@ -258,7 +379,7 @@ export type ClientMessage = Message<"city.ClientMessage"> & {
|
||||
* Use `create(ClientMessageSchema)` to create a new message.
|
||||
*/
|
||||
export const ClientMessageSchema: GenMessage<ClientMessage> = /*@__PURE__*/
|
||||
messageDesc(file_city, 8);
|
||||
messageDesc(file_city, 12);
|
||||
|
||||
/**
|
||||
* @generated from message city.Agent
|
||||
@@ -290,7 +411,7 @@ export type Agent = Message<"city.Agent"> & {
|
||||
* Use `create(AgentSchema)` to create a new message.
|
||||
*/
|
||||
export const AgentSchema: GenMessage<Agent> = /*@__PURE__*/
|
||||
messageDesc(file_city, 9);
|
||||
messageDesc(file_city, 13);
|
||||
|
||||
/**
|
||||
* @generated from message city.Welcome
|
||||
@@ -327,7 +448,7 @@ export type Welcome = Message<"city.Welcome"> & {
|
||||
* Use `create(WelcomeSchema)` to create a new message.
|
||||
*/
|
||||
export const WelcomeSchema: GenMessage<Welcome> = /*@__PURE__*/
|
||||
messageDesc(file_city, 10);
|
||||
messageDesc(file_city, 14);
|
||||
|
||||
/**
|
||||
* @generated from message city.Snapshot
|
||||
@@ -349,7 +470,7 @@ export type Snapshot = Message<"city.Snapshot"> & {
|
||||
* Use `create(SnapshotSchema)` to create a new message.
|
||||
*/
|
||||
export const SnapshotSchema: GenMessage<Snapshot> = /*@__PURE__*/
|
||||
messageDesc(file_city, 11);
|
||||
messageDesc(file_city, 15);
|
||||
|
||||
/**
|
||||
* @generated from message city.Delta
|
||||
@@ -381,7 +502,7 @@ export type Delta = Message<"city.Delta"> & {
|
||||
* Use `create(DeltaSchema)` to create a new message.
|
||||
*/
|
||||
export const DeltaSchema: GenMessage<Delta> = /*@__PURE__*/
|
||||
messageDesc(file_city, 12);
|
||||
messageDesc(file_city, 16);
|
||||
|
||||
/**
|
||||
* @generated from message city.Error
|
||||
@@ -403,7 +524,7 @@ export type Error = Message<"city.Error"> & {
|
||||
* Use `create(ErrorSchema)` to create a new message.
|
||||
*/
|
||||
export const ErrorSchema: GenMessage<Error> = /*@__PURE__*/
|
||||
messageDesc(file_city, 13);
|
||||
messageDesc(file_city, 17);
|
||||
|
||||
/**
|
||||
* @generated from message city.VoteState
|
||||
@@ -440,7 +561,7 @@ export type VoteState = Message<"city.VoteState"> & {
|
||||
* Use `create(VoteStateSchema)` to create a new message.
|
||||
*/
|
||||
export const VoteStateSchema: GenMessage<VoteState> = /*@__PURE__*/
|
||||
messageDesc(file_city, 14);
|
||||
messageDesc(file_city, 18);
|
||||
|
||||
/**
|
||||
* @generated from message city.Clock
|
||||
@@ -467,7 +588,7 @@ export type Clock = Message<"city.Clock"> & {
|
||||
* Use `create(ClockSchema)` to create a new message.
|
||||
*/
|
||||
export const ClockSchema: GenMessage<Clock> = /*@__PURE__*/
|
||||
messageDesc(file_city, 15);
|
||||
messageDesc(file_city, 19);
|
||||
|
||||
/**
|
||||
* @generated from message city.ServerMessage
|
||||
@@ -518,6 +639,12 @@ export type ServerMessage = Message<"city.ServerMessage"> & {
|
||||
*/
|
||||
value: Clock;
|
||||
case: "clock";
|
||||
} | {
|
||||
/**
|
||||
* @generated from field: city.Gameplay gameplay = 8;
|
||||
*/
|
||||
value: Gameplay;
|
||||
case: "gameplay";
|
||||
} | { case: undefined; value?: undefined };
|
||||
};
|
||||
|
||||
@@ -526,7 +653,7 @@ export type ServerMessage = Message<"city.ServerMessage"> & {
|
||||
* Use `create(ServerMessageSchema)` to create a new message.
|
||||
*/
|
||||
export const ServerMessageSchema: GenMessage<ServerMessage> = /*@__PURE__*/
|
||||
messageDesc(file_city, 16);
|
||||
messageDesc(file_city, 20);
|
||||
|
||||
/**
|
||||
* @generated from message city.SavedAgent
|
||||
@@ -553,7 +680,7 @@ export type SavedAgent = Message<"city.SavedAgent"> & {
|
||||
* Use `create(SavedAgentSchema)` to create a new message.
|
||||
*/
|
||||
export const SavedAgentSchema: GenMessage<SavedAgent> = /*@__PURE__*/
|
||||
messageDesc(file_city, 17);
|
||||
messageDesc(file_city, 21);
|
||||
|
||||
/**
|
||||
* @generated from message city.Route
|
||||
@@ -580,7 +707,7 @@ export type Route = Message<"city.Route"> & {
|
||||
* Use `create(RouteSchema)` to create a new message.
|
||||
*/
|
||||
export const RouteSchema: GenMessage<Route> = /*@__PURE__*/
|
||||
messageDesc(file_city, 18);
|
||||
messageDesc(file_city, 22);
|
||||
|
||||
/**
|
||||
* @generated from message city.RoomSave
|
||||
@@ -640,6 +767,11 @@ export type RoomSave = Message<"city.RoomSave"> & {
|
||||
* @generated from field: string city_revision = 11;
|
||||
*/
|
||||
cityRevision: string;
|
||||
|
||||
/**
|
||||
* @generated from field: city.Gameplay gameplay = 12;
|
||||
*/
|
||||
gameplay?: Gameplay | undefined;
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -647,5 +779,5 @@ export type RoomSave = Message<"city.RoomSave"> & {
|
||||
* Use `create(RoomSaveSchema)` to create a new message.
|
||||
*/
|
||||
export const RoomSaveSchema: GenMessage<RoomSave> = /*@__PURE__*/
|
||||
messageDesc(file_city, 19);
|
||||
messageDesc(file_city, 23);
|
||||
|
||||
Reference in new issue
Block a user