manabrew_protocol/prompts/
choose_board_targets.rs1use serde::{Deserialize, Serialize};
2use ts_rs::TS;
3
4use crate::game::TargetingIntent;
5use crate::prompts::common::{PromptPresentation, TargetRef};
6
7#[derive(Debug, Clone, Serialize, Deserialize, TS)]
8#[serde(rename_all = "camelCase")]
9#[ts(export, export_to = "prompts/chooseBoardTargets.ts")]
10pub struct ChooseBoardTargetsInput {
11 pub presentation: PromptPresentation,
12 pub candidates: Vec<TargetRef>,
13 #[serde(default)]
14 pub hostile: bool,
15 pub intent: TargetingIntent,
16 pub min_targets: i32,
17 pub max_targets: i32,
18 pub chosen_targets: i32,
19}
20
21#[derive(Debug, Clone, Serialize, Deserialize, TS)]
22#[serde(
23 tag = "type",
24 rename_all = "camelCase",
25 rename_all_fields = "camelCase"
26)]
27#[ts(export, export_to = "prompts/chooseBoardTargets.ts")]
28pub enum ChooseBoardTargetsOutput {
29 BoardTargets { chosen: Vec<TargetRef> },
30}