when attacking by boat, attack execution only starts from boat pixel

This commit is contained in:
evanpelle
2024-09-04 20:06:20 -07:00
parent 2082b229b4
commit a92bebce05
8 changed files with 22 additions and 10 deletions
+5 -2
View File
@@ -24,6 +24,7 @@ export type ClientIntentMessage = z.infer<typeof ClientIntentMessageSchema>
export type ClientJoinMessage = z.infer<typeof ClientJoinMessageSchema>
export type ClientLeaveMessage = z.infer<typeof ClientLeaveMessageSchema>
// TODO: create Cell schema
export interface Lobby {
id: string;
@@ -42,8 +43,10 @@ export const AttackIntentSchema = BaseIntentSchema.extend({
attackerID: z.string(),
targetID: z.string().nullable(),
troops: z.number(),
targetX: z.number(),
targetY: z.number()
sourceX: z.number().nullable(),
sourceY: z.number().nullable(),
targetX: z.number().nullable(),
targetY: z.number().nullable()
});