great persons (#186)
This commit is contained in:
parent
909f62fe25
commit
d06883257d
56 changed files with 5874 additions and 239 deletions
|
|
@ -140,7 +140,21 @@ fn get_card_object(card: &HandCard) -> HandCardObject {
|
|||
),
|
||||
HandCard::ActionCard(id) => {
|
||||
let a = get_action_card(*id);
|
||||
let mut description = vec![a.civil_card.description.clone()];
|
||||
let mut description = vec![];
|
||||
let action_type = a.civil_card.action_type;
|
||||
description.push(
|
||||
if action_type.free {
|
||||
"As a free action"
|
||||
} else {
|
||||
"As a regular action"
|
||||
}
|
||||
.to_string(),
|
||||
);
|
||||
let cost = action_type.cost;
|
||||
if !cost.is_empty() {
|
||||
description.push(format!("Cost: {cost}"));
|
||||
}
|
||||
description.push(a.civil_card.description);
|
||||
if let Some(t) = a.tactics_card {
|
||||
description.extend(vec![
|
||||
format!("Tactics: {}", t.name),
|
||||
|
|
|
|||
|
|
@ -87,7 +87,7 @@ fn wonder_icons<'a>(rc: &'a RenderContext, city: &'a City) -> IconActionVec<'a>
|
|||
|
||||
wonder_cards(owner)
|
||||
.into_iter()
|
||||
.filter(|w| city.can_build_wonder(w, owner, game))
|
||||
.filter(|w| city.can_build_wonder(w, owner, game).is_ok())
|
||||
.map(|w| {
|
||||
let a: IconAction<'a> = (
|
||||
&rc.assets().wonders[&w.name],
|
||||
|
|
@ -116,7 +116,7 @@ fn building_icons<'a>(rc: &'a RenderContext, city: &'a City) -> IconActionVec<'a
|
|||
Building::all()
|
||||
.iter()
|
||||
.filter_map(|b| {
|
||||
if city.can_construct(*b, owner, rc.game) {
|
||||
if city.can_construct(*b, owner, rc.game).is_ok() {
|
||||
Some(*b)
|
||||
} else {
|
||||
None
|
||||
|
|
@ -125,11 +125,17 @@ fn building_icons<'a>(rc: &'a RenderContext, city: &'a City) -> IconActionVec<'a
|
|||
.flat_map(|b| new_building_positions(b, rc, city))
|
||||
.map(|(b, pos)| {
|
||||
let name = b.name();
|
||||
let cost_info = owner.construct_cost(rc.game, b, None);
|
||||
let tooltip = format!(
|
||||
"Built {}{} for {}",
|
||||
"Built {}{} for {}{}",
|
||||
name,
|
||||
pos.map_or(String::new(), |p| format!(" at {p}")),
|
||||
owner.construct_cost(b, city, None).cost,
|
||||
cost_info.cost,
|
||||
if cost_info.activate_city {
|
||||
""
|
||||
} else {
|
||||
" (without city activation)"
|
||||
}
|
||||
);
|
||||
let a: IconAction<'a> = (
|
||||
&rc.assets().buildings[&b],
|
||||
|
|
|
|||
|
|
@ -48,12 +48,9 @@ pub fn pay_construction_dialog(rc: &RenderContext, cp: &ConstructionPayment) ->
|
|||
},
|
||||
|payment| match &cp.project {
|
||||
ConstructionProject::Building(b, pos) => StateUpdate::execute_activation(
|
||||
Action::Playing(PlayingAction::Construct(Construct {
|
||||
city_position: cp.city_position,
|
||||
city_piece: *b,
|
||||
payment,
|
||||
port_position: *pos,
|
||||
})),
|
||||
Action::Playing(PlayingAction::Construct(
|
||||
Construct::new(cp.city_position, *b, payment).with_port_position(*pos),
|
||||
)),
|
||||
vec![],
|
||||
city,
|
||||
),
|
||||
|
|
@ -105,7 +102,7 @@ impl ConstructionPayment {
|
|||
) -> ConstructionPayment {
|
||||
let p = rc.game.get_player(city.player_index);
|
||||
let cost = match &project {
|
||||
ConstructionProject::Building(b, _) => p.construct_cost(*b, city, None),
|
||||
ConstructionProject::Building(b, _) => p.construct_cost(rc.game, *b, None),
|
||||
ConstructionProject::Wonder(name) => p.wonder_cost(
|
||||
wonder_cards(p).iter().find(|w| w.name == *name).unwrap(),
|
||||
city,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
[tasks.update-tests]
|
||||
description = "Run server tests and update json files"
|
||||
run = "cargo test"
|
||||
env = { RUST_BACKTRACE = "1", UPDATE_EXPECTED = "true" }
|
||||
run = 'cargo test {{arg(name="test", default="")}}'
|
||||
env = { UPDATE_EXPECTED = "true" }
|
||||
dir = "server"
|
||||
|
||||
[tasks.server-format-and-lint]
|
||||
|
|
|
|||
|
|
@ -159,7 +159,7 @@ pub(crate) trait AbilityInitializerSetup: Sized {
|
|||
priority: i32,
|
||||
listener: impl Fn(&Game, &Combat, &mut CombatStrength, CombatRole) + Clone + 'static,
|
||||
) -> Self {
|
||||
self.add_simple_current_event_listener(
|
||||
self.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_combat_round_start,
|
||||
priority,
|
||||
move |game, p, _, s| {
|
||||
|
|
@ -275,7 +275,7 @@ pub(crate) trait AbilityInitializerSetup: Sized {
|
|||
)
|
||||
}
|
||||
|
||||
fn add_simple_current_event_listener<V, E, F>(
|
||||
fn add_simple_persistent_event_listener<V, E, F>(
|
||||
self,
|
||||
event: E,
|
||||
priority: i32,
|
||||
|
|
|
|||
|
|
@ -99,63 +99,79 @@ impl City {
|
|||
self.activations > 0
|
||||
}
|
||||
|
||||
#[must_use]
|
||||
pub fn can_construct(&self, building: Building, player: &Player, game: &Game) -> bool {
|
||||
if self.player_index != player.index {
|
||||
return false;
|
||||
}
|
||||
if self.pieces.amount() == MAX_CITY_SIZE {
|
||||
return false;
|
||||
}
|
||||
///
|
||||
/// # Errors
|
||||
/// Returns an error if the building cannot be built
|
||||
pub fn can_construct(
|
||||
&self,
|
||||
building: Building,
|
||||
player: &Player,
|
||||
game: &Game,
|
||||
) -> Result<(), String> {
|
||||
self.can_build_anything(player)?;
|
||||
if matches!(self.mood_state, Angry) {
|
||||
return false;
|
||||
return Err("City is angry".to_string());
|
||||
}
|
||||
if !self.pieces.can_add_building(building) {
|
||||
return false;
|
||||
}
|
||||
let size = self.pieces.amount() + 1;
|
||||
if size >= player.cities.len() {
|
||||
return false;
|
||||
return Err("Building already exists".to_string());
|
||||
}
|
||||
if !player
|
||||
.advances
|
||||
.iter()
|
||||
.any(|a| a.unlocked_building == Some(building))
|
||||
{
|
||||
return false;
|
||||
return Err("Building not researched".to_string());
|
||||
}
|
||||
if !player.is_building_available(building, game) {
|
||||
return false;
|
||||
return Err("All non-destroyed buildings are built".to_string());
|
||||
}
|
||||
player.can_afford(&player.construct_cost(building, self, None).cost)
|
||||
if !player.can_afford(&player.construct_cost(game, building, None).cost) {
|
||||
return Err("Not enough resources".to_string());
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[must_use]
|
||||
pub fn can_build_wonder(&self, wonder: &Wonder, player: &Player, game: &Game) -> bool {
|
||||
fn can_build_anything(&self, player: &Player) -> Result<(), String> {
|
||||
if self.player_index != player.index {
|
||||
return false;
|
||||
return Err("Not your city".to_string());
|
||||
}
|
||||
if self.pieces.amount() == MAX_CITY_SIZE {
|
||||
return false;
|
||||
if self.pieces.amount() >= MAX_CITY_SIZE {
|
||||
return Err("City is full".to_string());
|
||||
}
|
||||
if self.pieces.amount() >= player.cities.len() {
|
||||
return false;
|
||||
return Err("Need more cities".to_string());
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
///
|
||||
/// # Errors
|
||||
/// Returns an error if the wonder cannot be built
|
||||
pub fn can_build_wonder(
|
||||
&self,
|
||||
wonder: &Wonder,
|
||||
player: &Player,
|
||||
game: &Game,
|
||||
) -> Result<(), String> {
|
||||
self.can_build_anything(player)?;
|
||||
if !matches!(self.mood_state, Happy) {
|
||||
return false;
|
||||
return Err("City is not happy".to_string());
|
||||
}
|
||||
if !player.can_afford(&player.wonder_cost(wonder, self, None).cost) {
|
||||
return false;
|
||||
return Err("Not enough resources".to_string());
|
||||
}
|
||||
for advance in &wonder.required_advances {
|
||||
if !player.has_advance(advance) {
|
||||
return false;
|
||||
return Err(format!("Advance missing: {advance}"));
|
||||
}
|
||||
}
|
||||
if let Some(placement_requirement) = &wonder.placement_requirement {
|
||||
return placement_requirement(self.position, game);
|
||||
if !placement_requirement(self.position, game) {
|
||||
return Err("Placement requirement not met".to_string());
|
||||
}
|
||||
}
|
||||
true
|
||||
Ok(())
|
||||
}
|
||||
|
||||
///
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@ pub enum CombatModifier {
|
|||
SteelWeaponsAttacker,
|
||||
SteelWeaponsDefender,
|
||||
TrojanHorse,
|
||||
GreatWarlord,
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Clone, PartialEq, Eq, Debug, Copy)]
|
||||
|
|
@ -697,8 +698,8 @@ pub mod tests {
|
|||
let position = Position::new(0, 0);
|
||||
game.players[old].cities.push(City::new(old, position));
|
||||
game.build_wonder(wonder, position, old);
|
||||
game.players[old].construct(Academy, position, None);
|
||||
game.players[old].construct(Obelisk, position, None);
|
||||
game.players[old].construct(Academy, position, None, true);
|
||||
game.players[old].construct(Obelisk, position, None, true);
|
||||
|
||||
game.players[old].victory_points(&game).assert_eq(7.0);
|
||||
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ use crate::content::custom_phase_actions::ResourceRewardRequest;
|
|||
use crate::game::Game;
|
||||
use crate::payment::PaymentOptions;
|
||||
use crate::player::Player;
|
||||
use crate::player_events::{CurrentEvent, PersistentEvents};
|
||||
use crate::resource::ResourceType;
|
||||
use crate::resource_pile::ResourcePile;
|
||||
use itertools::Itertools;
|
||||
|
|
@ -59,27 +60,51 @@ pub(crate) fn collect_taxes(game: &mut Game, player_index: usize, gain: Resource
|
|||
}
|
||||
|
||||
fn trade_routes() -> AdvanceBuilder {
|
||||
Advance::builder(
|
||||
"Trade Routes",
|
||||
"At the beginning of your turn, you gain 1 food for every trade route you can make, to a maximum of 4. A trade route is made between one of your Settlers or Ships and a non-Angry enemy player city within 2 spaces (without counting through unrevealed Regions). Each Settler or Ship can only be paired with one enemy player city. Likewise, each enemy player city must be paired with a different Settler or Ship. In other words, to gain X food you must have at least X Units (Settlers or Ships), each paired with X different enemy cities.")
|
||||
.add_resource_request(
|
||||
|event| &mut event.on_turn_start,
|
||||
0,
|
||||
|game, _player_index, ()| {
|
||||
trade_route_reward(game).map(|(reward, routes)| {
|
||||
gain_market_bonus(game, &routes);
|
||||
ResourceRewardRequest::new(
|
||||
reward,
|
||||
"Collect trade routes reward".to_string(),
|
||||
)
|
||||
})
|
||||
},
|
||||
|game, p, ()| {
|
||||
let (_, routes) =
|
||||
trade_route_reward(game).expect("No trade route reward");
|
||||
trade_route_log(game, p.player_index, &routes, &p.choice, p.actively_selected)
|
||||
},
|
||||
)
|
||||
add_trade_routes(
|
||||
Advance::builder(
|
||||
"Trade Routes",
|
||||
"At the beginning of your turn, you gain 1 food for every trade route \
|
||||
you can make, to a maximum of 4. A trade route is made between one of your \
|
||||
Settlers or Ships and a non-Angry enemy player city within 2 spaces \
|
||||
(without counting through unrevealed Regions). Each Settler or Ship can only be paired \
|
||||
with one enemy player city. Likewise, each enemy player city must be paired with \
|
||||
a different Settler or Ship. In other words, to gain X food you must have at least \
|
||||
X Units (Settlers or Ships), each paired with X different enemy cities.",
|
||||
),
|
||||
|event| &mut event.on_turn_start,
|
||||
)
|
||||
}
|
||||
|
||||
pub(crate) fn add_trade_routes<E, S, V>(b: S, event: E) -> S
|
||||
where
|
||||
E: Fn(&mut PersistentEvents) -> &mut CurrentEvent<V> + 'static + Clone,
|
||||
S: AbilityInitializerSetup,
|
||||
V: Clone + PartialEq,
|
||||
{
|
||||
b.add_resource_request(
|
||||
event,
|
||||
0,
|
||||
|game, player_index, _| {
|
||||
if !game.get_player(player_index).has_advance("Trade Routes") {
|
||||
return None;
|
||||
}
|
||||
|
||||
trade_route_reward(game).map(|(reward, routes)| {
|
||||
gain_market_bonus(game, &routes);
|
||||
ResourceRewardRequest::new(reward, "Collect trade routes reward".to_string())
|
||||
})
|
||||
},
|
||||
|game, p, _| {
|
||||
let (_, routes) = trade_route_reward(game).expect("No trade route reward");
|
||||
trade_route_log(
|
||||
game,
|
||||
p.player_index,
|
||||
&routes,
|
||||
&p.choice,
|
||||
p.actively_selected,
|
||||
)
|
||||
},
|
||||
)
|
||||
}
|
||||
|
||||
fn gain_market_bonus(game: &mut Game, routes: &[TradeRoute]) {
|
||||
|
|
|
|||
|
|
@ -99,7 +99,7 @@ fn philosophy() -> AdvanceBuilder {
|
|||
.add_one_time_ability_initializer(|game, player_index| {
|
||||
game.players[player_index].gain_resources(ResourcePile::ideas(1));
|
||||
})
|
||||
.add_simple_current_event_listener(
|
||||
.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_advance,
|
||||
0,
|
||||
|game, player_index, player_name, advance| {
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@ fn state_religion() -> AdvanceBuilder {
|
|||
.add_once_per_turn_listener(
|
||||
|event| &mut event.construct_cost,
|
||||
|i| &mut i.info.info,
|
||||
|i, _city, b| {
|
||||
|i, b, _| {
|
||||
if matches!(b, Temple) {
|
||||
i.cost.conversions.push(PaymentConversion::limited(
|
||||
ResourcePile::of(ResourceType::Food, 1),
|
||||
|
|
|
|||
|
|
@ -5,6 +5,8 @@ use crate::combat_listeners::{
|
|||
choose_carried_units_casualties, choose_fighter_casualties, offer_retreat, place_settler,
|
||||
};
|
||||
use crate::content::incidents::famine::pestilence_permanent_effect;
|
||||
use crate::content::incidents::great_builder::use_great_engineer;
|
||||
use crate::content::incidents::great_warlord::use_great_warlord;
|
||||
use crate::content::incidents::trojan::{
|
||||
anarchy_advance, decide_trojan_horse, solar_eclipse_end_combat,
|
||||
};
|
||||
|
|
@ -86,6 +88,8 @@ pub fn get_all() -> Vec<Builtin> {
|
|||
decide_trojan_horse(),
|
||||
solar_eclipse_end_combat(),
|
||||
anarchy_advance(),
|
||||
use_great_warlord(),
|
||||
use_great_engineer(),
|
||||
]
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2,8 +2,10 @@ mod civil_war;
|
|||
mod earthquake;
|
||||
pub(crate) mod famine;
|
||||
mod good_year;
|
||||
pub(crate) mod great_builder;
|
||||
mod great_explorer;
|
||||
pub(crate) mod great_persons;
|
||||
pub(crate) mod great_warlord;
|
||||
mod pandemics;
|
||||
mod trade;
|
||||
pub(crate) mod trojan;
|
||||
|
|
|
|||
79
server/src/content/incidents/great_builder.rs
Normal file
79
server/src/content/incidents/great_builder.rs
Normal file
|
|
@ -0,0 +1,79 @@
|
|||
use crate::ability_initializer::AbilityInitializerSetup;
|
||||
use crate::action_card::ActionCard;
|
||||
use crate::content::builtin::Builtin;
|
||||
use crate::content::incidents::great_persons::{
|
||||
great_person_action_card, great_person_description,
|
||||
};
|
||||
use crate::incident::PermanentIncidentEffect;
|
||||
use crate::playing_actions::{ActionType, PlayingActionType};
|
||||
use crate::utils::remove_element;
|
||||
|
||||
pub(crate) fn great_engineer() -> ActionCard {
|
||||
let groups = &["Construction"];
|
||||
great_person_action_card(
|
||||
26,
|
||||
"Great Engineer",
|
||||
&format!(
|
||||
"{} Then, you may build a building in a city without spending an action and without activating it.",
|
||||
great_person_description(groups)
|
||||
),
|
||||
ActionType::regular(),
|
||||
groups,
|
||||
|_game, _player| true,
|
||||
)
|
||||
.add_bool_request(
|
||||
|e| &mut e.on_play_action_card,
|
||||
0,
|
||||
|_, _, _| Some("Build a building in a city without spending an action and without activating it?".to_string()),
|
||||
|game, s, _| {
|
||||
if s.choice {
|
||||
game.permanent_incident_effects.push(PermanentIncidentEffect::GreatEngineer);
|
||||
game.actions_left += 1; // to offset the action spent for building
|
||||
game.add_info_log_item("Great Engineer: You may build a building in a city without spending an action and without activating it.");
|
||||
} else {
|
||||
game.add_info_log_item("Great Engineer: You decided not to use the ability.");
|
||||
}
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
||||
pub(crate) fn use_great_engineer() -> Builtin {
|
||||
Builtin::builder("great_engineer", "-")
|
||||
.add_transient_event_listener(
|
||||
|event| &mut event.is_playing_action_available,
|
||||
2,
|
||||
|available, game, i| {
|
||||
if game
|
||||
.permanent_incident_effects
|
||||
.contains(&PermanentIncidentEffect::GreatEngineer)
|
||||
&& !matches!(i.action_type, PlayingActionType::Construct)
|
||||
{
|
||||
*available = false;
|
||||
}
|
||||
},
|
||||
)
|
||||
.add_transient_event_listener(
|
||||
|event| &mut event.construct_cost,
|
||||
1,
|
||||
|c, _, game| {
|
||||
if game
|
||||
.permanent_incident_effects
|
||||
.contains(&PermanentIncidentEffect::GreatEngineer)
|
||||
{
|
||||
c.activate_city = false;
|
||||
}
|
||||
},
|
||||
)
|
||||
.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_construct,
|
||||
2,
|
||||
|game, _, _, _| {
|
||||
remove_element(
|
||||
&mut game.permanent_incident_effects,
|
||||
&PermanentIncidentEffect::GreatEngineer,
|
||||
);
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
|
@ -2,7 +2,9 @@ use crate::ability_initializer::AbilityInitializerSetup;
|
|||
use crate::action::Action;
|
||||
use crate::action_card::ActionCard;
|
||||
use crate::content::custom_phase_actions::{EventResponse, PaymentRequest, PositionRequest};
|
||||
use crate::content::incidents::great_persons::great_person_action_card;
|
||||
use crate::content::incidents::great_persons::{
|
||||
great_person_action_card, great_person_description,
|
||||
};
|
||||
use crate::explore::move_to_unexplored_block;
|
||||
use crate::game::Game;
|
||||
use crate::map::{get_map_setup, BlockPosition, UNEXPLORED_BLOCK};
|
||||
|
|
@ -13,12 +15,18 @@ use crate::resource_pile::ResourcePile;
|
|||
use itertools::Itertools;
|
||||
|
||||
pub(crate) fn great_explorer() -> ActionCard {
|
||||
let groups = &["Seafaring"];
|
||||
great_person_action_card(
|
||||
18,
|
||||
"Great Explorer",
|
||||
"todo",
|
||||
&format!(
|
||||
"{} Then, you may explore a region adjacent to a region \
|
||||
where you have a city. If you do, you may found a city in the explored region,\
|
||||
without using a Settler.",
|
||||
great_person_description(groups)
|
||||
),
|
||||
ActionType::regular(),
|
||||
&["Seafaring"],
|
||||
groups,
|
||||
|_game, _player| true,
|
||||
)
|
||||
.add_position_request(
|
||||
|
|
@ -82,6 +90,8 @@ pub(crate) fn great_explorer() -> ActionCard {
|
|||
"{} decided to build a city at {pos}",
|
||||
s.player_name
|
||||
));
|
||||
} else {
|
||||
game.add_info_log_item(&format!("{} decided not to build a city", s.player_name));
|
||||
}
|
||||
a.selected_position = pos;
|
||||
},
|
||||
|
|
@ -100,7 +110,10 @@ pub(crate) fn great_explorer() -> ActionCard {
|
|||
|game, s, a| {
|
||||
let pos = a.selected_position.expect("position not found");
|
||||
build_city(game.get_player_mut(s.player_index), pos);
|
||||
game.add_info_log_item(&format!("{} built a city at {pos}", s.player_name));
|
||||
game.add_info_log_item(&format!(
|
||||
"{} built a city at {pos} for {}",
|
||||
s.player_name, s.choice[0]
|
||||
));
|
||||
},
|
||||
)
|
||||
.build()
|
||||
|
|
|
|||
|
|
@ -1,27 +1,45 @@
|
|||
use crate::ability_initializer::AbilityInitializerSetup;
|
||||
use crate::action_card::{ActionCard, ActionCardBuilder};
|
||||
use crate::action_card::{gain_action_card_from_pile, ActionCard, ActionCardBuilder};
|
||||
use crate::advance::gain_advance;
|
||||
use crate::city::MoodState;
|
||||
use crate::city_pieces::Building;
|
||||
use crate::content::advances;
|
||||
use crate::content::custom_phase_actions::{AdvanceRequest, PaymentRequest};
|
||||
use crate::content::advances::{economy, get_governments};
|
||||
use crate::content::custom_phase_actions::{AdvanceRequest, PaymentRequest, PositionRequest};
|
||||
use crate::content::incidents::great_builder::great_engineer;
|
||||
use crate::content::incidents::great_explorer::great_explorer;
|
||||
use crate::content::incidents::great_warlord::great_warlord;
|
||||
use crate::game::Game;
|
||||
use crate::incident::{Incident, IncidentBaseEffect};
|
||||
use crate::payment::PaymentOptions;
|
||||
use crate::player::Player;
|
||||
use crate::player_events::IncidentTarget;
|
||||
use crate::playing_actions::ActionType;
|
||||
use crate::playing_actions::{construct, ActionType, Construct};
|
||||
use crate::resource_pile::ResourcePile;
|
||||
use crate::utils::format_list;
|
||||
use itertools::Itertools;
|
||||
use std::vec;
|
||||
|
||||
pub(crate) fn great_person_incidents() -> Vec<Incident> {
|
||||
vec![great_person_incident(
|
||||
IncidentBaseEffect::ExhaustedLand,
|
||||
great_explorer(),
|
||||
)]
|
||||
}
|
||||
|
||||
pub(crate) const GREAT_PERSON_OFFSET: u8 = 100;
|
||||
|
||||
pub(crate) const GREAT_PERSON_DESCRIPTION: &str = "You make take the Event Card to your \
|
||||
hand for 1 culture token. If you pass, any other player (in player order) may take it \
|
||||
for 2 culture tokens: Action card: ";
|
||||
|
||||
pub(crate) fn great_person_incidents() -> Vec<Incident> {
|
||||
vec![
|
||||
great_person_incident(IncidentBaseEffect::ExhaustedLand, great_explorer()),
|
||||
great_person_incident(IncidentBaseEffect::BarbariansMove, great_artist()),
|
||||
great_person_incident(IncidentBaseEffect::BarbariansMove, great_prophet()),
|
||||
great_person_incident(IncidentBaseEffect::BarbariansMove, great_philosopher()),
|
||||
great_person_incident(IncidentBaseEffect::BarbariansMove, great_scientist()),
|
||||
great_person_incident(IncidentBaseEffect::BarbariansMove, elder_statesman()),
|
||||
great_person_incident(IncidentBaseEffect::ExhaustedLand, great_warlord()),
|
||||
great_person_incident(IncidentBaseEffect::BarbariansMove, great_merchant()),
|
||||
great_person_incident(IncidentBaseEffect::BarbariansMove, great_engineer()),
|
||||
]
|
||||
}
|
||||
|
||||
fn great_person_incident(base: IncidentBaseEffect, action_card: ActionCard) -> Incident {
|
||||
let card_id = action_card.id;
|
||||
let id = card_id - GREAT_PERSON_OFFSET;
|
||||
|
|
@ -40,7 +58,7 @@ fn great_person_incident(base: IncidentBaseEffect, action_card: ActionCard) -> I
|
|||
} else {
|
||||
2
|
||||
};
|
||||
let options = PaymentOptions::resources(ResourcePile::ideas(cost));
|
||||
let options = PaymentOptions::resources(ResourcePile::culture_tokens(cost));
|
||||
let p = game.get_player(player_index);
|
||||
if p.can_afford(&options) {
|
||||
Some(vec![PaymentRequest::new(
|
||||
|
|
@ -75,17 +93,22 @@ fn great_person_incident(base: IncidentBaseEffect, action_card: ActionCard) -> I
|
|||
.build()
|
||||
}
|
||||
|
||||
pub(crate) fn great_person_action_card<F>(
|
||||
pub(crate) fn great_person_action_card<F, S: AsRef<str> + Clone>(
|
||||
incident_id: u8,
|
||||
name: &str,
|
||||
description: &str,
|
||||
action_type: ActionType,
|
||||
free_advance_groups: &'static [&'static str],
|
||||
free_advance_groups: &[S],
|
||||
can_play: F,
|
||||
) -> ActionCardBuilder
|
||||
where
|
||||
F: Fn(&Game, &Player) -> bool + 'static,
|
||||
{
|
||||
let groups = free_advance_groups
|
||||
.iter()
|
||||
.map(|s| s.as_ref().to_string())
|
||||
.collect_vec();
|
||||
|
||||
ActionCard::builder(
|
||||
incident_id + GREAT_PERSON_OFFSET,
|
||||
name,
|
||||
|
|
@ -98,14 +121,13 @@ where
|
|||
10,
|
||||
move |game, player_index, _| {
|
||||
let p = game.get_player(player_index);
|
||||
Some(AdvanceRequest::new(
|
||||
free_advance_groups
|
||||
.iter()
|
||||
.flat_map(|g| advances::get_group(g).advances)
|
||||
.filter(|a| p.can_advance_free(a))
|
||||
.map(|a| a.name.clone())
|
||||
.collect(),
|
||||
))
|
||||
let choices = groups
|
||||
.iter()
|
||||
.flat_map(|g| advances::get_group(g.as_ref()).advances)
|
||||
.filter(|a| p.can_advance_free(a))
|
||||
.map(|a| a.name.clone())
|
||||
.collect();
|
||||
Some(AdvanceRequest::new(choices))
|
||||
},
|
||||
|game, s, _| {
|
||||
let name = &s.choice;
|
||||
|
|
@ -114,3 +136,233 @@ where
|
|||
},
|
||||
)
|
||||
}
|
||||
|
||||
fn great_artist() -> ActionCard {
|
||||
let groups = &["Culture"];
|
||||
great_person_action_card(
|
||||
19,
|
||||
"Great Artist",
|
||||
&format!(
|
||||
"{} Then, you make one of your cities Happy.",
|
||||
great_person_description(groups)
|
||||
),
|
||||
ActionType::regular(),
|
||||
groups,
|
||||
|_game, _player| true,
|
||||
)
|
||||
.add_position_request(
|
||||
|e| &mut e.on_play_action_card,
|
||||
0,
|
||||
|game, player_index, _| {
|
||||
let player = game.get_player(player_index);
|
||||
let cities = player
|
||||
.cities
|
||||
.iter()
|
||||
.filter(|c| c.mood_state != MoodState::Happy)
|
||||
.map(|c| c.position)
|
||||
.collect_vec();
|
||||
if cities.is_empty() {
|
||||
game.add_info_log_item("No cities to make happy");
|
||||
}
|
||||
Some(PositionRequest::new(cities, 1..=1, "Make a city Happy"))
|
||||
},
|
||||
|game, s, _| {
|
||||
let position = s.choice[0];
|
||||
game.add_info_log_item(&format!(
|
||||
"{} made city at {} Happy",
|
||||
s.player_name, position
|
||||
));
|
||||
game.get_player_mut(s.player_index)
|
||||
.get_city_mut(position)
|
||||
.mood_state = MoodState::Happy;
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
||||
fn great_prophet() -> ActionCard {
|
||||
let groups = &["Spirituality"];
|
||||
great_person_action_card(
|
||||
20,
|
||||
"Great Prophet",
|
||||
&format!(
|
||||
"{} Then, you build a Temple without activating the city.",
|
||||
great_person_description(groups)
|
||||
),
|
||||
ActionType::regular(),
|
||||
groups,
|
||||
|_game, _player| true,
|
||||
)
|
||||
.add_position_request(
|
||||
|e| &mut e.on_play_action_card,
|
||||
1,
|
||||
|game, player_index, _| {
|
||||
let player = game.get_player(player_index);
|
||||
if !player.is_building_available(Building::Temple, game) {
|
||||
return None;
|
||||
}
|
||||
if !player.can_afford(&temple_cost(game, player)) {
|
||||
return None;
|
||||
}
|
||||
|
||||
let cities = player
|
||||
.cities
|
||||
.iter()
|
||||
.filter(|c| c.pieces.temple.is_none())
|
||||
.map(|c| c.position)
|
||||
.collect_vec();
|
||||
if cities.is_empty() {
|
||||
game.add_info_log_item("No cities can build a Temple");
|
||||
}
|
||||
Some(PositionRequest::new(cities, 0..=1, "Build a Temple"))
|
||||
},
|
||||
|game, s, a| {
|
||||
let pos = s.choice.first().copied();
|
||||
if let Some(pos) = pos {
|
||||
game.add_info_log_item(&format!(
|
||||
"{} decided to build a Temple at {pos}",
|
||||
s.player_name
|
||||
));
|
||||
} else {
|
||||
game.add_info_log_item(&format!("{} declined to build a Temple", s.player_name));
|
||||
}
|
||||
a.selected_position = pos;
|
||||
},
|
||||
)
|
||||
.add_payment_request_listener(
|
||||
|e| &mut e.on_play_action_card,
|
||||
0,
|
||||
|game, player, a| {
|
||||
a.selected_position?;
|
||||
Some(vec![PaymentRequest::new(
|
||||
temple_cost(game, game.get_player(player)),
|
||||
"Pay to build the Temple",
|
||||
true,
|
||||
)])
|
||||
},
|
||||
|game, s, a| {
|
||||
let pile = s.choice[0].clone();
|
||||
let name = &s.player_name;
|
||||
if pile.is_empty() {
|
||||
game.add_info_log_item(&format!("{name} declined to build the Temple"));
|
||||
return;
|
||||
}
|
||||
|
||||
let pos = a.selected_position.expect("position not found");
|
||||
game.add_info_log_item(&format!("{name} built a Temple at {pos} for {pile}",));
|
||||
|
||||
construct(
|
||||
game,
|
||||
s.player_index,
|
||||
&Construct::new(pos, Building::Temple, pile),
|
||||
);
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
||||
fn temple_cost(game: &Game, player: &Player) -> PaymentOptions {
|
||||
player.construct_cost(game, Building::Temple, None).cost
|
||||
}
|
||||
|
||||
pub(crate) fn great_person_description<S: AsRef<str>>(free_advance_groups: &[S]) -> String {
|
||||
format!(
|
||||
"{GREAT_PERSON_DESCRIPTION} As a regular action, you may advance \
|
||||
in any {} technology for free and without changing the Game Event counter.",
|
||||
format_list(free_advance_groups, "no", "or")
|
||||
)
|
||||
}
|
||||
|
||||
fn great_philosopher() -> ActionCard {
|
||||
let groups = &["Education"];
|
||||
great_person_action_card(
|
||||
21,
|
||||
"Great Philosopher",
|
||||
&format!("{} Then, gain 2 ideas.", great_person_description(groups)),
|
||||
ActionType::regular(),
|
||||
groups,
|
||||
|_game, _player| true,
|
||||
)
|
||||
.add_simple_persistent_event_listener(
|
||||
|e| &mut e.on_play_action_card,
|
||||
0,
|
||||
|game, player_index, player_name, _| {
|
||||
game.add_info_log_item(&format!("{player_name} gained 2 ideas",));
|
||||
game.get_player_mut(player_index)
|
||||
.gain_resources(ResourcePile::ideas(2));
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
||||
fn great_scientist() -> ActionCard {
|
||||
let groups = &["Science"];
|
||||
great_person_action_card(
|
||||
22,
|
||||
"Great Scientist",
|
||||
&format!(
|
||||
"{} Then, gain 1 idea and 1 Action Card.",
|
||||
great_person_description(groups)
|
||||
),
|
||||
ActionType::regular(),
|
||||
groups,
|
||||
|_game, _player| true,
|
||||
)
|
||||
.add_simple_persistent_event_listener(
|
||||
|e| &mut e.on_play_action_card,
|
||||
0,
|
||||
|game, player_index, player_name, _| {
|
||||
game.add_info_log_item(&format!("{player_name} gained 1 idea",));
|
||||
game.get_player_mut(player_index)
|
||||
.gain_resources(ResourcePile::ideas(1));
|
||||
gain_action_card_from_pile(game, player_index);
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
||||
fn elder_statesman() -> ActionCard {
|
||||
let groups = get_governments()
|
||||
.into_iter()
|
||||
.map(|a| a.name.clone())
|
||||
.collect_vec();
|
||||
great_person_action_card(
|
||||
23,
|
||||
"Elder Statesman",
|
||||
&format!(
|
||||
"{} Then, draw 2 Action Cards.",
|
||||
great_person_description(&groups)
|
||||
),
|
||||
ActionType::regular(),
|
||||
&groups,
|
||||
|_game, _player| true,
|
||||
)
|
||||
.add_simple_persistent_event_listener(
|
||||
|e| &mut e.on_play_action_card,
|
||||
0,
|
||||
|game, player_index, _player_name, _| {
|
||||
gain_action_card_from_pile(game, player_index);
|
||||
gain_action_card_from_pile(game, player_index);
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
||||
fn great_merchant() -> ActionCard {
|
||||
let groups = &["Economy"];
|
||||
economy::add_trade_routes(
|
||||
great_person_action_card(
|
||||
25,
|
||||
"Great Merchant",
|
||||
&format!(
|
||||
"{} Then, if you have the Trade Routes advance, gain the Trade Routes income.",
|
||||
great_person_description(groups)
|
||||
),
|
||||
ActionType::regular(),
|
||||
groups,
|
||||
|_game, _player| true,
|
||||
),
|
||||
|e| &mut e.on_play_action_card,
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
|
|
|||
69
server/src/content/incidents/great_warlord.rs
Normal file
69
server/src/content/incidents/great_warlord.rs
Normal file
|
|
@ -0,0 +1,69 @@
|
|||
use crate::ability_initializer::AbilityInitializerSetup;
|
||||
use crate::action_card::ActionCard;
|
||||
use crate::combat::CombatModifier;
|
||||
use crate::content::builtin::Builtin;
|
||||
use crate::content::incidents::great_persons::{
|
||||
great_person_action_card, great_person_description,
|
||||
};
|
||||
use crate::game::GameState;
|
||||
use crate::game::GameState::Movement;
|
||||
use crate::movement::MoveState;
|
||||
use crate::playing_actions::ActionType;
|
||||
use std::mem;
|
||||
|
||||
pub(crate) fn great_warlord() -> ActionCard {
|
||||
let groups = &["Warfare"];
|
||||
great_person_action_card(
|
||||
24,
|
||||
"Great Warlord",
|
||||
&format!(
|
||||
"{} Then, gain a Move action. On the first battle you fight, \
|
||||
gain 2 combat value in every round.",
|
||||
great_person_description(groups)
|
||||
),
|
||||
ActionType::regular(),
|
||||
groups,
|
||||
|_game, _player| true,
|
||||
)
|
||||
.add_simple_persistent_event_listener(
|
||||
|e| &mut e.on_play_action_card,
|
||||
0,
|
||||
|game, _player_index, _player_name, _| {
|
||||
game.state = GameState::Movement(MoveState {
|
||||
great_warlord_used: true,
|
||||
..MoveState::default()
|
||||
});
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
||||
pub(crate) fn use_great_warlord() -> Builtin {
|
||||
Builtin::builder("great_warlord", "-")
|
||||
.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_combat_start,
|
||||
9,
|
||||
|game, _player_index, _name, c| {
|
||||
if let Movement(m) = &mut game.state {
|
||||
if mem::replace(&mut m.great_warlord_used, false) {
|
||||
c.modifiers.push(CombatModifier::GreatWarlord);
|
||||
};
|
||||
}
|
||||
},
|
||||
)
|
||||
.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_combat_round_start,
|
||||
9,
|
||||
|_game, player_index, _name, r| {
|
||||
if r.combat.modifiers.contains(&CombatModifier::GreatWarlord)
|
||||
&& r.combat.attacker == player_index
|
||||
{
|
||||
r.attacker_strength.extra_combat_value += 2;
|
||||
r.attacker_strength
|
||||
.roll_log
|
||||
.push("Player gets +2 combat value for Great Warlord".to_string());
|
||||
}
|
||||
},
|
||||
)
|
||||
.build()
|
||||
}
|
||||
|
|
@ -96,7 +96,7 @@ fn solar_eclipse() -> Incident {
|
|||
|
||||
pub(crate) fn solar_eclipse_end_combat() -> Builtin {
|
||||
Builtin::builder("Solar Eclipse", "-")
|
||||
.add_simple_current_event_listener(
|
||||
.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_combat_round_end,
|
||||
10,
|
||||
|game, _player, name, r| {
|
||||
|
|
@ -182,7 +182,7 @@ fn anarchy() -> Incident {
|
|||
|
||||
pub(crate) fn anarchy_advance() -> Builtin {
|
||||
Builtin::builder("Anarchy", "-")
|
||||
.add_simple_current_event_listener(
|
||||
.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_advance,
|
||||
10,
|
||||
|game, player_index, player_name, i| {
|
||||
|
|
|
|||
|
|
@ -77,10 +77,11 @@ pub fn construct_wonder(
|
|||
let wonder = get_wonder(name);
|
||||
|
||||
let city = game.players[player_index].get_city(city_position);
|
||||
assert!(
|
||||
city.can_build_wonder(&wonder, &game.players[player_index], game),
|
||||
"Illegal action"
|
||||
);
|
||||
|
||||
city.can_build_wonder(&wonder, &game.players[player_index], game)
|
||||
.map_err(|e| panic!("{e}"))
|
||||
.ok();
|
||||
|
||||
game.players[player_index].lose_resources(payment);
|
||||
|
||||
game.build_wonder(wonder, city_position, player_index);
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ where
|
|||
info: &U,
|
||||
details: &V,
|
||||
extra_value: &mut W,
|
||||
is_ok: impl Fn(&T) -> bool,
|
||||
mut is_ok: impl FnMut(&T) -> bool,
|
||||
set_modifiers: impl Fn(&mut T, Vec<EventOrigin>),
|
||||
) -> T
|
||||
where
|
||||
|
|
@ -147,6 +147,8 @@ where
|
|||
{
|
||||
let mut initial_value = value.clone();
|
||||
let initial_modifiers = self.trigger(&mut initial_value, info, details, extra_value);
|
||||
// to see what's possible
|
||||
is_ok(&initial_value);
|
||||
|
||||
initial_modifiers
|
||||
.iter()
|
||||
|
|
|
|||
|
|
@ -107,6 +107,7 @@ pub enum PermanentIncidentEffect {
|
|||
TrojanHorse,
|
||||
SolarEclipse,
|
||||
Anarchy(Anarchy),
|
||||
GreatEngineer,
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
|
|
@ -213,7 +214,7 @@ impl IncidentBuilder {
|
|||
where
|
||||
F: Fn(&mut Game, usize, &str, &mut IncidentInfo) + 'static + Clone,
|
||||
{
|
||||
self.add_simple_current_event_listener(
|
||||
self.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_incident,
|
||||
priority,
|
||||
move |game, player_index, player_name, i| {
|
||||
|
|
|
|||
|
|
@ -139,11 +139,11 @@ pub fn format_happiness_increase(
|
|||
None
|
||||
}
|
||||
})
|
||||
.collect::<Vec<String>>();
|
||||
.collect_vec();
|
||||
format!(
|
||||
"{player_name} paid {} to increase happiness in {}",
|
||||
i.payment,
|
||||
utils::format_list(&happiness_increases, "no city")
|
||||
utils::format_and(&happiness_increases, "no city")
|
||||
)
|
||||
}
|
||||
|
||||
|
|
@ -181,12 +181,12 @@ fn format_recruit_log_item(player: &Player, player_name: &String, r: &Recruit) -
|
|||
1 => " and replaces the unit at ",
|
||||
_ => " and replaces units at ",
|
||||
};
|
||||
let replace_pos = utils::format_list(
|
||||
let replace_pos = utils::format_and(
|
||||
&replaced_units
|
||||
.iter()
|
||||
.map(|unit_id| player.get_unit(*unit_id).position.to_string())
|
||||
.unique()
|
||||
.collect::<Vec<String>>(),
|
||||
.collect_vec(),
|
||||
"",
|
||||
);
|
||||
format!(
|
||||
|
|
@ -196,11 +196,11 @@ fn format_recruit_log_item(player: &Player, player_name: &String, r: &Recruit) -
|
|||
|
||||
pub(crate) fn format_collect_log_item(player: &Player, player_name: &str, c: &Collect) -> String {
|
||||
let collections = &c.collections;
|
||||
let res = utils::format_list(
|
||||
let res = utils::format_and(
|
||||
&collections
|
||||
.iter()
|
||||
.map(|(_, collection)| collection.to_string())
|
||||
.collect::<Vec<String>>(),
|
||||
.collect_vec(),
|
||||
"nothing",
|
||||
);
|
||||
let total = if collections.len() > 1
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ use crate::map::Terrain::{Forest, Mountain};
|
|||
use crate::payment::PaymentOptions;
|
||||
use crate::resource_pile::ResourcePile;
|
||||
use crate::unit::Unit;
|
||||
use crate::utils;
|
||||
|
||||
use crate::consts::{ARMY_MOVEMENT_REQUIRED_ADVANCE, MOVEMENT_ACTIONS, SHIP_CAPACITY, STACK_LIMIT};
|
||||
use crate::game::GameState::Movement;
|
||||
|
|
@ -45,6 +46,9 @@ pub struct MoveState {
|
|||
#[serde(default)]
|
||||
#[serde(skip_serializing_if = "CurrentMove::is_none")]
|
||||
pub current_move: CurrentMove,
|
||||
#[serde(default)]
|
||||
#[serde(skip_serializing_if = "utils::is_false")]
|
||||
pub great_warlord_used: bool,
|
||||
}
|
||||
|
||||
impl Default for MoveState {
|
||||
|
|
@ -60,6 +64,7 @@ impl MoveState {
|
|||
movement_actions_left: MOVEMENT_ACTIONS,
|
||||
moved_units: Vec::new(),
|
||||
current_move: CurrentMove::None,
|
||||
great_warlord_used: false,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -68,7 +73,7 @@ pub(crate) fn get_move_state(game: &mut Game) -> &mut MoveState {
|
|||
if let Movement(m) = &mut game.state {
|
||||
m
|
||||
} else {
|
||||
panic!("no move state to pop");
|
||||
panic!("no move state");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -394,8 +394,12 @@ impl Player {
|
|||
}
|
||||
|
||||
pub(crate) fn pay_cost(&mut self, cost: &PaymentOptions, payment: &ResourcePile) {
|
||||
assert!(cost.can_afford(payment), "invalid payment");
|
||||
assert!(cost.is_valid_payment(payment), "Invalid payment");
|
||||
assert!(cost.can_afford(payment), "invalid payment - got {payment}");
|
||||
assert!(
|
||||
cost.is_valid_payment(payment),
|
||||
"Invalid payment - got {payment} for default cost {}",
|
||||
cost.default
|
||||
);
|
||||
self.lose_resources(payment.clone());
|
||||
}
|
||||
|
||||
|
|
@ -563,15 +567,15 @@ impl Player {
|
|||
#[must_use]
|
||||
pub fn construct_cost(
|
||||
&self,
|
||||
game: &Game,
|
||||
building: Building,
|
||||
city: &City,
|
||||
execute: Option<&ResourcePile>,
|
||||
) -> CostInfo {
|
||||
self.trigger_cost_event(
|
||||
|e| &e.construct_cost,
|
||||
&PaymentOptions::resources(CONSTRUCT_COST),
|
||||
city,
|
||||
&building,
|
||||
game,
|
||||
execute,
|
||||
)
|
||||
}
|
||||
|
|
@ -680,20 +684,18 @@ impl Player {
|
|||
.is_some_and(|city| city.size() == 1)
|
||||
}
|
||||
|
||||
///
|
||||
///
|
||||
/// # Panics
|
||||
///
|
||||
/// Panics if city does not exist
|
||||
pub fn construct(
|
||||
pub(crate) fn construct(
|
||||
&mut self,
|
||||
building: Building,
|
||||
city_position: Position,
|
||||
port_position: Option<Position>,
|
||||
activate: bool,
|
||||
) {
|
||||
let index = self.index;
|
||||
let city = self.get_city_mut(city_position);
|
||||
city.activate();
|
||||
if activate {
|
||||
city.activate();
|
||||
}
|
||||
city.pieces.set_building(building, index);
|
||||
if let Some(port_position) = port_position {
|
||||
city.port_position = Some(port_position);
|
||||
|
|
@ -782,13 +784,23 @@ impl Player {
|
|||
) -> CostInfo {
|
||||
let event = get_event(&self.events.transient).get();
|
||||
let mut cost_info = CostInfo::new(self, value.clone());
|
||||
let mut can_avoid_activate = false;
|
||||
if let Some(execute) = execute {
|
||||
event.trigger_with_minimal_modifiers(
|
||||
&cost_info,
|
||||
info,
|
||||
details,
|
||||
&mut (),
|
||||
|i| i.cost.is_valid_payment(execute),
|
||||
|i| {
|
||||
if can_avoid_activate && i.activate_city {
|
||||
return false;
|
||||
}
|
||||
if !i.activate_city {
|
||||
can_avoid_activate = true;
|
||||
}
|
||||
|
||||
i.cost.is_valid_payment(execute)
|
||||
},
|
||||
|i, m| i.cost.modifiers = m,
|
||||
)
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ pub(crate) struct TransientEvents {
|
|||
pub on_influence_culture_success: Event<Game, usize>,
|
||||
pub before_move: Event<Game, MoveInfo>,
|
||||
|
||||
pub construct_cost: Event<CostInfo, City, Building>,
|
||||
pub construct_cost: Event<CostInfo, Building, Game>,
|
||||
pub wonder_cost: Event<CostInfo, City, Wonder>,
|
||||
pub advance_cost: Event<CostInfo, Advance>,
|
||||
pub happiness_cost: Event<CostInfo>,
|
||||
|
|
@ -208,6 +208,7 @@ impl IncidentInfo {
|
|||
#[derive(Clone, PartialEq)]
|
||||
pub struct CostInfo {
|
||||
pub cost: PaymentOptions,
|
||||
pub activate_city: bool,
|
||||
pub(crate) info: ActionInfo,
|
||||
}
|
||||
|
||||
|
|
@ -216,6 +217,7 @@ impl CostInfo {
|
|||
CostInfo {
|
||||
cost,
|
||||
info: ActionInfo::new(player),
|
||||
activate_city: true,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -33,6 +33,24 @@ pub struct Construct {
|
|||
pub port_position: Option<Position>,
|
||||
}
|
||||
|
||||
impl Construct {
|
||||
#[must_use]
|
||||
pub fn new(city_position: Position, city_piece: Building, payment: ResourcePile) -> Self {
|
||||
Self {
|
||||
city_position,
|
||||
city_piece,
|
||||
payment,
|
||||
port_position: None,
|
||||
}
|
||||
}
|
||||
|
||||
#[must_use]
|
||||
pub fn with_port_position(mut self, port_position: Option<Position>) -> Self {
|
||||
self.port_position = port_position;
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, PartialEq, Eq, Clone)]
|
||||
pub struct Collect {
|
||||
pub city_position: Position,
|
||||
|
|
@ -350,14 +368,13 @@ pub(crate) fn play_action_card(game: &mut Game, player_index: usize, i: ActionCa
|
|||
);
|
||||
}
|
||||
|
||||
fn construct(game: &mut Game, player_index: usize, c: &Construct) {
|
||||
pub(crate) fn construct(game: &mut Game, player_index: usize, c: &Construct) {
|
||||
let player = &game.players[player_index];
|
||||
let city = player.get_city(c.city_position);
|
||||
let cost = player.construct_cost(c.city_piece, city, Some(&c.payment));
|
||||
assert!(
|
||||
city.can_construct(c.city_piece, player, game),
|
||||
"Illegal action"
|
||||
);
|
||||
let cost = player.construct_cost(game, c.city_piece, Some(&c.payment));
|
||||
city.can_construct(c.city_piece, player, game)
|
||||
.map_err(|e| panic!("{e}"))
|
||||
.ok();
|
||||
if matches!(c.city_piece, Port) {
|
||||
let port_position = c.port_position.as_ref().expect("Illegal action");
|
||||
assert!(
|
||||
|
|
@ -367,7 +384,12 @@ fn construct(game: &mut Game, player_index: usize, c: &Construct) {
|
|||
} else if c.port_position.is_some() {
|
||||
panic!("Illegal action");
|
||||
}
|
||||
game.players[player_index].construct(c.city_piece, c.city_position, c.port_position);
|
||||
game.players[player_index].construct(
|
||||
c.city_piece,
|
||||
c.city_position,
|
||||
c.port_position,
|
||||
cost.activate_city,
|
||||
);
|
||||
if matches!(c.city_piece, Academy) {
|
||||
game.players[player_index].gain_resources(ResourcePile::ideas(2));
|
||||
game.add_info_log_item("Academy gained 2 ideas");
|
||||
|
|
|
|||
|
|
@ -341,7 +341,7 @@ impl Display for ResourcePile {
|
|||
}
|
||||
));
|
||||
}
|
||||
write!(f, "{}", utils::format_list(&resources, "nothing"))
|
||||
write!(f, "{}", utils::format_and(&resources, "nothing"))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -137,7 +137,7 @@ pub(crate) fn free_advance() -> Builtin {
|
|||
|
||||
pub(crate) fn draw_cards() -> Builtin {
|
||||
Builtin::builder("Draw Cards", "-")
|
||||
.add_simple_current_event_listener(
|
||||
.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_status_phase,
|
||||
0,
|
||||
|game, p, _name, _s| {
|
||||
|
|
|
|||
|
|
@ -120,7 +120,7 @@ impl TacticsCardBuilder {
|
|||
listener: impl Fn(usize, &mut Game, &Combat, &mut CombatStrength) + Clone + 'static,
|
||||
) -> Self {
|
||||
let target = self.tactics_card_target;
|
||||
self.add_simple_current_event_listener(
|
||||
self.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_combat_round_start_tactics,
|
||||
priority,
|
||||
move |game, p, _, s| {
|
||||
|
|
@ -140,7 +140,7 @@ impl TacticsCardBuilder {
|
|||
listener: impl Fn(usize, &mut Game, &mut CombatRoundEnd) + Clone + 'static,
|
||||
) -> Self {
|
||||
let target = self.tactics_card_target;
|
||||
self.add_simple_current_event_listener(
|
||||
self.add_simple_persistent_event_listener(
|
||||
|event| &mut event.on_combat_round_end_tactics,
|
||||
priority,
|
||||
move |game, p, _, s| {
|
||||
|
|
|
|||
|
|
@ -409,7 +409,7 @@ impl Display for Units {
|
|||
format!("{} leaders", self.leaders)
|
||||
});
|
||||
}
|
||||
write!(f, "{}", utils::format_list(&unit_types, "no units"))
|
||||
write!(f, "{}", utils::format_and(&unit_types, "no units"))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,13 +1,26 @@
|
|||
use itertools::Itertools;
|
||||
|
||||
#[must_use]
|
||||
pub(crate) fn format_list(list: &[String], empty_message: &str) -> String {
|
||||
pub(crate) fn format_and<S: AsRef<str>>(list: &[S], empty_message: &str) -> String {
|
||||
format_list(list, empty_message, "and")
|
||||
}
|
||||
|
||||
#[must_use]
|
||||
pub(crate) fn format_list<S: AsRef<str>>(
|
||||
list: &[S],
|
||||
empty_message: &str,
|
||||
conjunction: &str,
|
||||
) -> String {
|
||||
match list {
|
||||
[] => empty_message.to_string(),
|
||||
[element] => element.clone(),
|
||||
[element] => element.as_ref().to_string(),
|
||||
_ => format!(
|
||||
"{} and {}",
|
||||
&list[..list.len() - 1].join(", "),
|
||||
"{} {} {}",
|
||||
&list[..list.len() - 1].iter().map(AsRef::as_ref).join(", "),
|
||||
conjunction,
|
||||
list.last()
|
||||
.expect("collection should have at least 2 elements"),
|
||||
.expect("collection should have at least 2 elements")
|
||||
.as_ref(),
|
||||
),
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -422,12 +422,11 @@ fn test_dogma() {
|
|||
),
|
||||
TestAction::undoable(
|
||||
1,
|
||||
Action::Playing(Construct(playing_actions::Construct {
|
||||
city_position: Position::from_offset("C1"),
|
||||
city_piece: Temple,
|
||||
payment: ResourcePile::new(0, 1, 1, 0, 0, 0, 0),
|
||||
port_position: None,
|
||||
})),
|
||||
Action::Playing(Construct(playing_actions::Construct::new(
|
||||
Position::from_offset("C1"),
|
||||
Temple,
|
||||
ResourcePile::new(0, 1, 1, 0, 0, 0, 0),
|
||||
))),
|
||||
),
|
||||
TestAction::undoable(
|
||||
1,
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ use std::{
|
|||
env,
|
||||
fs::{self, OpenOptions},
|
||||
io::Write,
|
||||
mem,
|
||||
path::MAIN_SEPARATOR as SEPARATOR,
|
||||
vec,
|
||||
};
|
||||
|
|
@ -33,11 +34,16 @@ impl GamePath {
|
|||
name: name.to_string(),
|
||||
}
|
||||
}
|
||||
|
||||
#[must_use]
|
||||
pub fn path(&self) -> String {
|
||||
format!("{}{SEPARATOR}{}.json", self.directory, self.name)
|
||||
}
|
||||
}
|
||||
|
||||
impl Display for GamePath {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
write!(f, "{}{SEPARATOR}{}.json", self.directory, self.name)
|
||||
write!(f, "{}", self.path())
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -204,16 +210,18 @@ pub(crate) fn test_actions(test: &JsonTest, name: &str, actions: Vec<TestAction>
|
|||
};
|
||||
let path = test.path(name);
|
||||
let mut game = load_game(&path);
|
||||
let mut last_json_compare = false;
|
||||
for (i, action) in actions.into_iter().enumerate() {
|
||||
let from = if i == 0 {
|
||||
path.clone()
|
||||
} else {
|
||||
outcome(&path, i - 1)
|
||||
};
|
||||
let compare = mem::replace(&mut last_json_compare, action.compare_json);
|
||||
game = catch_unwind(AssertUnwindSafe(|| {
|
||||
test_action_internal(game, name, &from, &outcome(&path, i), action)
|
||||
test_action_internal(game, name, &from, &outcome(&path, i), action, compare)
|
||||
}))
|
||||
.unwrap_or_else(|e| panic!("test action {i} should not panic: {e:?}"))
|
||||
.unwrap_or_else(|e| panic!("test action {i} should not panic: {e:?}"));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -223,6 +231,7 @@ fn test_action_internal(
|
|||
original: &GamePath,
|
||||
outcome: &GamePath,
|
||||
test: TestAction,
|
||||
last_json_compare: bool,
|
||||
) -> Game {
|
||||
let action = test.action;
|
||||
let a = serde_json::to_string(&action).expect("action should be serializable");
|
||||
|
|
@ -254,11 +263,12 @@ fn test_action_internal(
|
|||
for post_assert in test.post_asserts {
|
||||
post_assert(&game);
|
||||
}
|
||||
let compare_json = test.compare_json && last_json_compare;
|
||||
undo_redo(
|
||||
name,
|
||||
test.player_index,
|
||||
test.compare_json,
|
||||
if test.compare_json {
|
||||
compare_json,
|
||||
if compare_json {
|
||||
read_game_str(original)
|
||||
} else {
|
||||
"".to_string()
|
||||
|
|
|
|||
|
|
@ -78,12 +78,11 @@ fn basic_actions() {
|
|||
.cities
|
||||
.push(City::new(0, Position::new(0, 2)));
|
||||
|
||||
let construct_action = Action::Playing(Construct(playing_actions::Construct {
|
||||
let construct_action = Action::Playing(Construct(playing_actions::Construct::new(
|
||||
city_position,
|
||||
city_piece: Observatory,
|
||||
payment: ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
port_position: None,
|
||||
}));
|
||||
Observatory,
|
||||
ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
)));
|
||||
let game = game_api::execute(game, construct_action, 0);
|
||||
let player = &game.players[0];
|
||||
|
||||
|
|
@ -407,12 +406,11 @@ fn test_construct() {
|
|||
"construct",
|
||||
vec![TestAction::undoable(
|
||||
0,
|
||||
Action::Playing(Construct(playing_actions::Construct {
|
||||
city_position: Position::from_offset("C2"),
|
||||
city_piece: Observatory,
|
||||
payment: ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
port_position: None,
|
||||
})),
|
||||
Action::Playing(Construct(playing_actions::Construct::new(
|
||||
Position::from_offset("C2"),
|
||||
Observatory,
|
||||
ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
))),
|
||||
)],
|
||||
);
|
||||
}
|
||||
|
|
@ -423,12 +421,14 @@ fn test_construct_port() {
|
|||
"construct_port",
|
||||
vec![TestAction::undoable(
|
||||
0,
|
||||
Action::Playing(Construct(playing_actions::Construct {
|
||||
city_position: Position::from_offset("A1"),
|
||||
city_piece: Port,
|
||||
payment: ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
port_position: Some(Position::from_offset("A2")),
|
||||
})),
|
||||
Action::Playing(Construct(
|
||||
playing_actions::Construct::new(
|
||||
Position::from_offset("A1"),
|
||||
Port,
|
||||
ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
)
|
||||
.with_port_position(Some(Position::from_offset("A2"))),
|
||||
)),
|
||||
)],
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ use server::card::HandCard;
|
|||
use server::city_pieces::Building::Fortress;
|
||||
use server::content::custom_phase_actions::{EventResponse, Structure};
|
||||
use server::playing_actions;
|
||||
use server::playing_actions::PlayingAction;
|
||||
use server::playing_actions::PlayingAction::{Advance, Construct};
|
||||
use server::playing_actions::{PlayingAction, PlayingActionType};
|
||||
use server::position::Position;
|
||||
use server::resource_pile::ResourcePile;
|
||||
use server::status_phase::{ChangeGovernment, ChangeGovernmentType};
|
||||
|
|
@ -133,12 +133,11 @@ const FAMINE: JsonTest = JsonTest::child("incidents", "famine");
|
|||
|
||||
#[test]
|
||||
fn test_pestilence() {
|
||||
let cons = Action::Playing(Construct(playing_actions::Construct {
|
||||
city_position: Position::from_offset("C2"),
|
||||
city_piece: Fortress,
|
||||
payment: ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
port_position: None,
|
||||
}));
|
||||
let cons = Action::Playing(Construct(playing_actions::Construct::new(
|
||||
Position::from_offset("C2"),
|
||||
Fortress,
|
||||
ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
)));
|
||||
FAMINE.test(
|
||||
"pestilence",
|
||||
vec![
|
||||
|
|
@ -682,7 +681,9 @@ fn test_great_explorer() {
|
|||
),
|
||||
TestAction::not_undoable(
|
||||
1,
|
||||
Action::Response(EventResponse::Payment(vec![ResourcePile::ideas(1)])),
|
||||
Action::Response(EventResponse::Payment(vec![ResourcePile::culture_tokens(
|
||||
1,
|
||||
)])),
|
||||
),
|
||||
TestAction::undoable(1, Action::Playing(PlayingAction::ActionCard(118))),
|
||||
TestAction::undoable(
|
||||
|
|
@ -705,3 +706,166 @@ fn test_great_explorer() {
|
|||
],
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_great_artist() {
|
||||
GREAT_PERSONS.test(
|
||||
"great_artist",
|
||||
vec![
|
||||
TestAction::not_undoable(
|
||||
0,
|
||||
Action::Playing(Advance {
|
||||
advance: String::from("Storage"),
|
||||
payment: ResourcePile::food(2),
|
||||
}),
|
||||
),
|
||||
TestAction::not_undoable(
|
||||
1,
|
||||
Action::Response(EventResponse::Payment(vec![ResourcePile::culture_tokens(
|
||||
2,
|
||||
)])),
|
||||
),
|
||||
TestAction::not_undoable(0, Action::Playing(PlayingAction::EndTurn)),
|
||||
TestAction::undoable(1, Action::Playing(PlayingAction::ActionCard(119))),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_great_prophet() {
|
||||
GREAT_PERSONS.test(
|
||||
"great_prophet",
|
||||
vec![
|
||||
TestAction::not_undoable(
|
||||
0,
|
||||
Action::Playing(Advance {
|
||||
advance: String::from("Storage"),
|
||||
payment: ResourcePile::food(2),
|
||||
}),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::not_undoable(
|
||||
0,
|
||||
Action::Response(EventResponse::Payment(vec![ResourcePile::culture_tokens(
|
||||
1,
|
||||
)])),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(0, Action::Playing(PlayingAction::ActionCard(120)))
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(
|
||||
0,
|
||||
Action::Response(EventResponse::SelectPositions(vec![Position::from_offset(
|
||||
"C1",
|
||||
)])),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(
|
||||
0,
|
||||
Action::Response(EventResponse::Payment(vec![ResourcePile::gold(2)])),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_great_warlord() {
|
||||
GREAT_PERSONS.test(
|
||||
"great_warlord",
|
||||
vec![
|
||||
TestAction::not_undoable(
|
||||
1,
|
||||
Action::Playing(Advance {
|
||||
advance: String::from("Storage"),
|
||||
payment: ResourcePile::food(2),
|
||||
}),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::not_undoable(
|
||||
1,
|
||||
Action::Response(EventResponse::Payment(vec![ResourcePile::culture_tokens(
|
||||
1,
|
||||
)])),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(1, Action::Playing(PlayingAction::ActionCard(124)))
|
||||
.without_json_comparison(),
|
||||
TestAction::not_undoable(1, move_action(vec![0], Position::from_offset("C8"))),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_great_merchant() {
|
||||
GREAT_PERSONS.test(
|
||||
"great_merchant",
|
||||
vec![
|
||||
TestAction::not_undoable(
|
||||
0,
|
||||
Action::Playing(Advance {
|
||||
advance: String::from("Storage"),
|
||||
payment: ResourcePile::food(2),
|
||||
}),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::not_undoable(
|
||||
0,
|
||||
Action::Response(EventResponse::Payment(vec![ResourcePile::culture_tokens(
|
||||
1,
|
||||
)])),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(0, Action::Playing(PlayingAction::ActionCard(125)))
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(
|
||||
0,
|
||||
Action::Response(EventResponse::ResourceReward(ResourcePile::gold(1))),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_great_engineer() {
|
||||
GREAT_PERSONS.test(
|
||||
"great_engineer",
|
||||
vec![
|
||||
TestAction::not_undoable(
|
||||
0,
|
||||
Action::Playing(Advance {
|
||||
advance: String::from("Storage"),
|
||||
payment: ResourcePile::food(2),
|
||||
}),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::not_undoable(
|
||||
0,
|
||||
Action::Response(EventResponse::Payment(vec![ResourcePile::culture_tokens(
|
||||
1,
|
||||
)])),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(0, Action::Playing(PlayingAction::ActionCard(126)))
|
||||
.without_json_comparison(),
|
||||
TestAction::not_undoable(
|
||||
0,
|
||||
Action::Response(EventResponse::SelectAdvance("Engineering".to_string())),
|
||||
)
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(0, Action::Response(EventResponse::Bool(true)))
|
||||
.without_json_comparison(),
|
||||
TestAction::undoable(
|
||||
0,
|
||||
Action::Playing(Construct(playing_actions::Construct::new(
|
||||
Position::from_offset("C2"),
|
||||
Fortress,
|
||||
ResourcePile::new(1, 1, 1, 0, 0, 0, 0),
|
||||
))),
|
||||
)
|
||||
.with_pre_assert(|game| {
|
||||
// must do construct
|
||||
assert!(!PlayingActionType::Advance.is_available(game, 0))
|
||||
}),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -405,7 +405,7 @@
|
|||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"rng": "104943774643039980141625808767669774303",
|
||||
"rng": "152200054503393540076191958055355598",
|
||||
"dice_roll_log": [],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
|
|
@ -414,50 +414,58 @@
|
|||
],
|
||||
"action_cards_left": [],
|
||||
"incidents_left": [
|
||||
35,
|
||||
16,
|
||||
13,
|
||||
42,
|
||||
26,
|
||||
25,
|
||||
12,
|
||||
37,
|
||||
32,
|
||||
30,
|
||||
45,
|
||||
38,
|
||||
44,
|
||||
14,
|
||||
49,
|
||||
40,
|
||||
2,
|
||||
30,
|
||||
39,
|
||||
1,
|
||||
8,
|
||||
9,
|
||||
37,
|
||||
36,
|
||||
11,
|
||||
29,
|
||||
27,
|
||||
31,
|
||||
53,
|
||||
51,
|
||||
12,
|
||||
5,
|
||||
46,
|
||||
47,
|
||||
41,
|
||||
32,
|
||||
48,
|
||||
3,
|
||||
7,
|
||||
28,
|
||||
42,
|
||||
52,
|
||||
4,
|
||||
33,
|
||||
50,
|
||||
6,
|
||||
38,
|
||||
33,
|
||||
52,
|
||||
14,
|
||||
36,
|
||||
23,
|
||||
28,
|
||||
21,
|
||||
29,
|
||||
17,
|
||||
4,
|
||||
34,
|
||||
10,
|
||||
9,
|
||||
41,
|
||||
48,
|
||||
53,
|
||||
35,
|
||||
19,
|
||||
22,
|
||||
49,
|
||||
39,
|
||||
7,
|
||||
5,
|
||||
51,
|
||||
13,
|
||||
15,
|
||||
54,
|
||||
46,
|
||||
1,
|
||||
11,
|
||||
8,
|
||||
10,
|
||||
24,
|
||||
31,
|
||||
20,
|
||||
47,
|
||||
44,
|
||||
18,
|
||||
54
|
||||
3,
|
||||
16
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,257 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"mood_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"State Religion",
|
||||
"Tactics",
|
||||
"Voting"
|
||||
],
|
||||
"incident_tokens": 1,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [],
|
||||
"action_log_index": 0,
|
||||
"log": [],
|
||||
"undo_limit": 0,
|
||||
"actions_left": 3,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": [],
|
||||
"incidents_left": [
|
||||
19
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,338 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"events": [
|
||||
{
|
||||
"event_type": {
|
||||
"Incident": {
|
||||
"active_player": 0,
|
||||
"barbarians": {}
|
||||
}
|
||||
},
|
||||
"players_used": [
|
||||
0
|
||||
],
|
||||
"player": 1,
|
||||
"last_priority_used": 0,
|
||||
"handler": {
|
||||
"priority": 0,
|
||||
"request": {
|
||||
"Payment": [
|
||||
{
|
||||
"cost": {
|
||||
"default": {
|
||||
"culture_tokens": 2
|
||||
},
|
||||
"conversions": [
|
||||
{
|
||||
"from": [
|
||||
{
|
||||
"food": 1
|
||||
},
|
||||
{
|
||||
"wood": 1
|
||||
},
|
||||
{
|
||||
"ore": 1
|
||||
},
|
||||
{
|
||||
"ideas": 1
|
||||
}
|
||||
],
|
||||
"to": {
|
||||
"gold": 1
|
||||
},
|
||||
"type": "Unlimited"
|
||||
}
|
||||
]
|
||||
},
|
||||
"name": "Pay to gain the Action Card",
|
||||
"optional": true
|
||||
}
|
||||
]
|
||||
},
|
||||
"origin": {
|
||||
"Incident": 19
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"mood_tokens": 8
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"State Religion",
|
||||
"Storage",
|
||||
"Tactics",
|
||||
"Voting"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Advance": {
|
||||
"advance": "Storage",
|
||||
"payment": {
|
||||
"food": 2
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"action_log_index": 1,
|
||||
"log": [
|
||||
[
|
||||
"Player1 paid 2 food to get the Storage advance",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"A new game event has been triggered: Great Artist",
|
||||
"Base effect: Barbarians move",
|
||||
"Barbarians cannot move - will try to spawn a new city instead",
|
||||
"Barbarians cannot spawn a new city",
|
||||
"Player1 cannot afford to buy Great Artist"
|
||||
]
|
||||
],
|
||||
"undo_limit": 1,
|
||||
"actions_left": 2,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": [],
|
||||
"incidents_left": [
|
||||
19
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,296 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"mood_tokens": 8
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"State Religion",
|
||||
"Storage",
|
||||
"Tactics",
|
||||
"Voting"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 5
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"action_cards": [
|
||||
119
|
||||
],
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Advance": {
|
||||
"advance": "Storage",
|
||||
"payment": {
|
||||
"food": 2
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"culture_tokens": 2
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"action_log_index": 2,
|
||||
"log": [
|
||||
[
|
||||
"Player1 paid 2 food to get the Storage advance",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"A new game event has been triggered: Great Artist",
|
||||
"Base effect: Barbarians move",
|
||||
"Barbarians cannot move - will try to spawn a new city instead",
|
||||
"Barbarians cannot spawn a new city",
|
||||
"Player1 cannot afford to buy Great Artist"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Artist for 2 culture tokens"
|
||||
]
|
||||
],
|
||||
"undo_limit": 2,
|
||||
"actions_left": 2,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": []
|
||||
}
|
||||
|
|
@ -0,0 +1,304 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"mood_tokens": 8
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"State Religion",
|
||||
"Storage",
|
||||
"Tactics",
|
||||
"Voting"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 5
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"action_cards": [
|
||||
119
|
||||
],
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 1,
|
||||
"action_log": [
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Advance": {
|
||||
"advance": "Storage",
|
||||
"payment": {
|
||||
"food": 2
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"culture_tokens": 2
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Playing": "EndTurn"
|
||||
}
|
||||
}
|
||||
],
|
||||
"action_log_index": 3,
|
||||
"log": [
|
||||
[
|
||||
"Player1 paid 2 food to get the Storage advance",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"A new game event has been triggered: Great Artist",
|
||||
"Base effect: Barbarians move",
|
||||
"Barbarians cannot move - will try to spawn a new city instead",
|
||||
"Barbarians cannot spawn a new city",
|
||||
"Player1 cannot afford to buy Great Artist"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Artist for 2 culture tokens"
|
||||
],
|
||||
[
|
||||
"Player1 ended their turn with 2 actions left"
|
||||
],
|
||||
[
|
||||
"It's Player2's turn"
|
||||
]
|
||||
],
|
||||
"undo_limit": 3,
|
||||
"actions_left": 3,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": []
|
||||
}
|
||||
|
|
@ -0,0 +1,353 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"mood_tokens": 8
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"State Religion",
|
||||
"Storage",
|
||||
"Tactics",
|
||||
"Voting"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 6
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 1,
|
||||
"action_log": [
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Advance": {
|
||||
"advance": "Storage",
|
||||
"payment": {
|
||||
"food": 2
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"culture_tokens": 2
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Playing": "EndTurn"
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"ActionCard": 119
|
||||
}
|
||||
},
|
||||
"undo": [
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/actions_left",
|
||||
"value": 3
|
||||
},
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/players/1/action_cards",
|
||||
"value": [
|
||||
119
|
||||
]
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/1/advances/0",
|
||||
"value": "Farming"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/1/advances/1",
|
||||
"value": "Mining"
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/players/1/advances/2"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/1/cities/0/mood_state",
|
||||
"value": "Angry"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/1/resources/culture_tokens",
|
||||
"value": 5
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"action_log_index": 4,
|
||||
"log": [
|
||||
[
|
||||
"Player1 paid 2 food to get the Storage advance",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"A new game event has been triggered: Great Artist",
|
||||
"Base effect: Barbarians move",
|
||||
"Barbarians cannot move - will try to spawn a new city instead",
|
||||
"Barbarians cannot spawn a new city",
|
||||
"Player1 cannot afford to buy Great Artist"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Artist for 2 culture tokens"
|
||||
],
|
||||
[
|
||||
"Player1 ended their turn with 2 actions left"
|
||||
],
|
||||
[
|
||||
"It's Player2's turn"
|
||||
],
|
||||
[
|
||||
"Player2 played the action card Great Artist",
|
||||
"Player2 gained Arts",
|
||||
"Player gained 1 culture token as advance bonus",
|
||||
"Player2 made city at A1 Happy"
|
||||
]
|
||||
],
|
||||
"undo_limit": 3,
|
||||
"actions_left": 2,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": []
|
||||
}
|
||||
|
|
@ -0,0 +1,257 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"food": 3,
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"gold": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Bartering",
|
||||
"Currency",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"Tactics"
|
||||
],
|
||||
"incident_tokens": 1,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [],
|
||||
"action_log_index": 0,
|
||||
"log": [],
|
||||
"undo_limit": 0,
|
||||
"actions_left": 3,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": [],
|
||||
"incidents_left": [
|
||||
26
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,414 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"wood": 5,
|
||||
"ore": 5,
|
||||
"gold": 7,
|
||||
"mood_tokens": 1,
|
||||
"culture_tokens": 6
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Bartering",
|
||||
"Currency",
|
||||
"Engineering",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"Storage",
|
||||
"Tactics"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"wonder_cards": [
|
||||
"Pyramids"
|
||||
],
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Advance": {
|
||||
"advance": "Storage",
|
||||
"payment": {
|
||||
"food": 2
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"ActionCard": 126
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"SelectAdvance": "Engineering"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Bool": true
|
||||
}
|
||||
},
|
||||
"undo": [
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/actions_left",
|
||||
"value": 1
|
||||
},
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/events",
|
||||
"value": [
|
||||
{
|
||||
"event_type": {
|
||||
"ActionCard": {
|
||||
"id": 126
|
||||
}
|
||||
},
|
||||
"handler": {
|
||||
"origin": {
|
||||
"CivilCard": 126
|
||||
},
|
||||
"priority": 0,
|
||||
"request": {
|
||||
"BoolRequest": "Build a building in a city without spending an action and without activating it?"
|
||||
}
|
||||
},
|
||||
"last_priority_used": 0,
|
||||
"player": 0
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/permanent_incident_effects"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Construct": {
|
||||
"city_position": "C2",
|
||||
"city_piece": "Fortress",
|
||||
"payment": {
|
||||
"food": 1,
|
||||
"wood": 1,
|
||||
"ore": 1
|
||||
},
|
||||
"port_position": null
|
||||
}
|
||||
}
|
||||
},
|
||||
"undo": [
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/actions_left",
|
||||
"value": 2
|
||||
},
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/permanent_incident_effects",
|
||||
"value": [
|
||||
"GreatEngineer"
|
||||
]
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/players/0/cities/0/city_pieces/fortress"
|
||||
},
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/players/0/resources/food",
|
||||
"value": 1
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/resources/ore",
|
||||
"value": 6
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/resources/wood",
|
||||
"value": 6
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"action_log_index": 6,
|
||||
"log": [
|
||||
[
|
||||
"Player1 paid 2 food to get the Storage advance",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"A new game event has been triggered: Great Engineer",
|
||||
"Base effect: Barbarians move",
|
||||
"Barbarians cannot move - will try to spawn a new city instead",
|
||||
"Barbarians cannot spawn a new city"
|
||||
],
|
||||
[
|
||||
"Player1 gained Great Engineer for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player1 played the action card Great Engineer"
|
||||
],
|
||||
[
|
||||
"Player1 gained Engineering",
|
||||
"Player1 drew a wonder card from the pile"
|
||||
],
|
||||
[
|
||||
"Great Engineer: You may build a building in a city without spending an action and without activating it."
|
||||
],
|
||||
[
|
||||
"Player1 paid 1 food, 1 wood and 1 ore to construct a Fortress in the city at C2"
|
||||
]
|
||||
],
|
||||
"undo_limit": 4,
|
||||
"actions_left": 1,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [],
|
||||
"action_cards_left": []
|
||||
}
|
||||
|
|
@ -41,7 +41,7 @@
|
|||
"id": 1,
|
||||
"resources": {
|
||||
"food": 4,
|
||||
"ideas": 2
|
||||
"culture_tokens": 2
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@
|
|||
{
|
||||
"cost": {
|
||||
"default": {
|
||||
"ideas": 1
|
||||
"culture_tokens": 1
|
||||
},
|
||||
"conversions": [
|
||||
{
|
||||
|
|
@ -93,8 +93,8 @@
|
|||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"ideas": 2,
|
||||
"mood_tokens": 1
|
||||
"mood_tokens": 1,
|
||||
"culture_tokens": 2
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
|
|
|
|||
|
|
@ -41,8 +41,8 @@
|
|||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"ideas": 1,
|
||||
"mood_tokens": 1
|
||||
"mood_tokens": 1,
|
||||
"culture_tokens": 1
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
|
|
@ -380,7 +380,7 @@
|
|||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"ideas": 1
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -398,7 +398,7 @@
|
|||
"Player2 exhausted the land in position E8"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Explorer for 1 idea"
|
||||
"Player2 gained Great Explorer for 1 culture token"
|
||||
]
|
||||
],
|
||||
"undo_limit": 2,
|
||||
|
|
|
|||
|
|
@ -72,8 +72,8 @@
|
|||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"ideas": 1,
|
||||
"mood_tokens": 2
|
||||
"mood_tokens": 2,
|
||||
"culture_tokens": 1
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
|
|
@ -409,7 +409,7 @@
|
|||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"ideas": 1
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -471,7 +471,7 @@
|
|||
"Player2 exhausted the land in position E8"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Explorer for 1 idea"
|
||||
"Player2 gained Great Explorer for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player2 played the action card Great Explorer",
|
||||
|
|
|
|||
|
|
@ -85,8 +85,8 @@
|
|||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"ideas": 1,
|
||||
"mood_tokens": 2
|
||||
"mood_tokens": 2,
|
||||
"culture_tokens": 1
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
|
|
@ -422,7 +422,7 @@
|
|||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"ideas": 1
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -523,7 +523,7 @@
|
|||
"Player2 exhausted the land in position E8"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Explorer for 1 idea"
|
||||
"Player2 gained Great Explorer for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player2 played the action card Great Explorer",
|
||||
|
|
|
|||
|
|
@ -73,8 +73,8 @@
|
|||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"ideas": 1,
|
||||
"mood_tokens": 2
|
||||
"mood_tokens": 2,
|
||||
"culture_tokens": 1
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
|
|
@ -410,7 +410,7 @@
|
|||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"ideas": 1
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -566,7 +566,7 @@
|
|||
"Player2 exhausted the land in position E8"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Explorer for 1 idea"
|
||||
"Player2 gained Great Explorer for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player2 played the action card Great Explorer",
|
||||
|
|
|
|||
|
|
@ -94,8 +94,8 @@
|
|||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"ideas": 1,
|
||||
"mood_tokens": 2
|
||||
"mood_tokens": 2,
|
||||
"culture_tokens": 1
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
|
|
@ -431,7 +431,7 @@
|
|||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"ideas": 1
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -633,7 +633,7 @@
|
|||
"Player2 exhausted the land in position E8"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Explorer for 1 idea"
|
||||
"Player2 gained Great Explorer for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player2 played the action card Great Explorer",
|
||||
|
|
|
|||
|
|
@ -40,8 +40,8 @@
|
|||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"ideas": 1,
|
||||
"mood_tokens": 2
|
||||
"mood_tokens": 2,
|
||||
"culture_tokens": 1
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
|
|
@ -384,7 +384,7 @@
|
|||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"ideas": 1
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -665,7 +665,7 @@
|
|||
"Player2 exhausted the land in position E8"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Explorer for 1 idea"
|
||||
"Player2 gained Great Explorer for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player2 played the action card Great Explorer",
|
||||
|
|
@ -682,7 +682,7 @@
|
|||
"Player2 decided to build a city at B6"
|
||||
],
|
||||
[
|
||||
"Player2 built a city at B6"
|
||||
"Player2 built a city at B6 for 2 food"
|
||||
]
|
||||
],
|
||||
"undo_limit": 2,
|
||||
|
|
|
|||
|
|
@ -0,0 +1,258 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"gold": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Bartering",
|
||||
"Currency",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"Taxes"
|
||||
],
|
||||
"incident_tokens": 1,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [],
|
||||
"action_log_index": 0,
|
||||
"log": [],
|
||||
"undo_limit": 0,
|
||||
"actions_left": 3,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": [],
|
||||
"incidents_left": [
|
||||
25
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,389 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"gold": 7,
|
||||
"mood_tokens": 1,
|
||||
"culture_tokens": 6
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Bartering",
|
||||
"Currency",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"Storage",
|
||||
"Taxes",
|
||||
"Trade Routes"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Advance": {
|
||||
"advance": "Storage",
|
||||
"payment": {
|
||||
"food": 2
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"ActionCard": 125
|
||||
}
|
||||
},
|
||||
"undo": [
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/actions_left",
|
||||
"value": 2
|
||||
},
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/players/0/action_cards",
|
||||
"value": [
|
||||
125
|
||||
]
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/players/0/advances/7"
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/events"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"ResourceReward": {
|
||||
"gold": 1
|
||||
}
|
||||
}
|
||||
},
|
||||
"undo": [
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/events",
|
||||
"value": [
|
||||
{
|
||||
"event_type": {
|
||||
"ActionCard": {
|
||||
"id": 125
|
||||
}
|
||||
},
|
||||
"handler": {
|
||||
"origin": {
|
||||
"CivilCard": 125
|
||||
},
|
||||
"priority": 0,
|
||||
"request": {
|
||||
"ResourceReward": {
|
||||
"name": "Collect trade routes reward",
|
||||
"reward": {
|
||||
"conversions": [
|
||||
{
|
||||
"from": [
|
||||
{
|
||||
"gold": 1
|
||||
}
|
||||
],
|
||||
"to": {
|
||||
"food": 1
|
||||
},
|
||||
"type": "Unlimited"
|
||||
}
|
||||
],
|
||||
"default": {
|
||||
"gold": 1
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"last_priority_used": 0,
|
||||
"player": 0
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"action_log_index": 4,
|
||||
"log": [
|
||||
[
|
||||
"Player1 paid 2 food to get the Storage advance",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"A new game event has been triggered: Great Merchant",
|
||||
"Base effect: Barbarians move",
|
||||
"Barbarians cannot move - will try to spawn a new city instead",
|
||||
"Barbarians cannot spawn a new city"
|
||||
],
|
||||
[
|
||||
"Player1 gained Great Merchant for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player1 played the action card Great Merchant",
|
||||
"Player1 gained Trade Routes"
|
||||
],
|
||||
[
|
||||
"Player1 selected trade routes",
|
||||
"Settler at C2 traded with city at A3",
|
||||
"Total reward is 1 gold",
|
||||
"Player1 could not store 1 gold"
|
||||
]
|
||||
],
|
||||
"undo_limit": 2,
|
||||
"actions_left": 1,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": []
|
||||
}
|
||||
|
|
@ -0,0 +1,259 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"State Religion",
|
||||
"Tactics",
|
||||
"Voting"
|
||||
],
|
||||
"incident_tokens": 1,
|
||||
"next_unit_id": 8
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [],
|
||||
"action_log_index": 0,
|
||||
"log": [],
|
||||
"undo_limit": 0,
|
||||
"actions_left": 3,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": [],
|
||||
"incidents_left": [
|
||||
20
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,557 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"events": [
|
||||
{
|
||||
"event_type": {
|
||||
"ActionCard": {
|
||||
"id": 120,
|
||||
"selected_position": "C1"
|
||||
}
|
||||
},
|
||||
"player": 0,
|
||||
"last_priority_used": 0
|
||||
},
|
||||
{
|
||||
"event_type": {
|
||||
"Construct": "Temple"
|
||||
},
|
||||
"player": 0,
|
||||
"last_priority_used": 1,
|
||||
"handler": {
|
||||
"priority": 1,
|
||||
"request": {
|
||||
"ResourceReward": {
|
||||
"reward": {
|
||||
"default": {
|
||||
"mood_tokens": 1
|
||||
},
|
||||
"conversions": [
|
||||
{
|
||||
"from": [
|
||||
{
|
||||
"mood_tokens": 1
|
||||
}
|
||||
],
|
||||
"to": {
|
||||
"culture_tokens": 1
|
||||
},
|
||||
"type": "Unlimited"
|
||||
}
|
||||
]
|
||||
},
|
||||
"name": "Select Temple bonus"
|
||||
}
|
||||
},
|
||||
"origin": {
|
||||
"Advance": "Myths"
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"wood": 6,
|
||||
"ore": 6,
|
||||
"gold": 3,
|
||||
"mood_tokens": 9,
|
||||
"culture_tokens": 6
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0,
|
||||
"temple": 1
|
||||
},
|
||||
"mood_state": "Neutral",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "C2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"temple": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 1,
|
||||
"angry_activation": false,
|
||||
"position": "C1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B2"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "B3"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 1
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Elephant",
|
||||
"id": 3
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 4
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 5
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 6
|
||||
},
|
||||
{
|
||||
"position": "C2",
|
||||
"unit_type": "Settler",
|
||||
"id": 7
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Arts",
|
||||
"Farming",
|
||||
"Mining",
|
||||
"Myths",
|
||||
"State Religion",
|
||||
"Storage",
|
||||
"Tactics",
|
||||
"Voting"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 8,
|
||||
"event_info": {
|
||||
"State Religion": "used"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7,
|
||||
"mood_tokens": 7,
|
||||
"culture_tokens": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Angry",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A1"
|
||||
},
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A3"
|
||||
},
|
||||
{
|
||||
"city_pieces": {
|
||||
"fortress": 0
|
||||
},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "A4"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 2
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"civilization": "Barbarians",
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 0
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"A2",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"A3",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"A4",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B1",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"C1",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Water"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Water"
|
||||
]
|
||||
]
|
||||
},
|
||||
"starting_player_index": 0,
|
||||
"current_player_index": 0,
|
||||
"action_log": [
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Advance": {
|
||||
"advance": "Storage",
|
||||
"payment": {
|
||||
"food": 2
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"ActionCard": 120
|
||||
}
|
||||
},
|
||||
"undo": [
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/actions_left",
|
||||
"value": 2
|
||||
},
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/players/0/action_cards",
|
||||
"value": [
|
||||
120
|
||||
]
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/advances/3",
|
||||
"value": "State Religion"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/advances/4",
|
||||
"value": "Storage"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/advances/5",
|
||||
"value": "Tactics"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/advances/6",
|
||||
"value": "Voting"
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/players/0/advances/7"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/resources/mood_tokens",
|
||||
"value": 8
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/events"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"SelectPositions": [
|
||||
"C1"
|
||||
]
|
||||
}
|
||||
},
|
||||
"undo": [
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/events/0/event_type/ActionCard/selected_position"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/events/0/handler/priority",
|
||||
"value": 1
|
||||
},
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/events/0/handler/request/SelectPositions",
|
||||
"value": {
|
||||
"choices": [
|
||||
"C1",
|
||||
"B2",
|
||||
"B3"
|
||||
],
|
||||
"description": "Build a Temple",
|
||||
"needed": {
|
||||
"end": 1,
|
||||
"start": 0
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/events/0/handler/request/Payment"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/events/0/last_priority_used",
|
||||
"value": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"gold": 2
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"undo": [
|
||||
{
|
||||
"op": "add",
|
||||
"path": "/events/0/handler",
|
||||
"value": {
|
||||
"origin": {
|
||||
"CivilCard": 120
|
||||
},
|
||||
"priority": 0,
|
||||
"request": {
|
||||
"Payment": [
|
||||
{
|
||||
"cost": {
|
||||
"conversions": [
|
||||
{
|
||||
"from": [
|
||||
{
|
||||
"food": 1
|
||||
},
|
||||
{
|
||||
"wood": 1
|
||||
},
|
||||
{
|
||||
"ore": 1
|
||||
},
|
||||
{
|
||||
"ideas": 1
|
||||
}
|
||||
],
|
||||
"to": {
|
||||
"gold": 1
|
||||
},
|
||||
"type": "Unlimited"
|
||||
},
|
||||
{
|
||||
"from": [
|
||||
{
|
||||
"food": 1
|
||||
}
|
||||
],
|
||||
"to": {},
|
||||
"type": {
|
||||
"MayNotOverpay": 1
|
||||
}
|
||||
}
|
||||
],
|
||||
"default": {
|
||||
"food": 1,
|
||||
"ore": 1,
|
||||
"wood": 1
|
||||
},
|
||||
"modifiers": [
|
||||
{
|
||||
"Advance": "State Religion"
|
||||
}
|
||||
]
|
||||
},
|
||||
"name": "Pay to build the Temple",
|
||||
"optional": true
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/events/1"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/cities/1/activations",
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/players/0/cities/1/city_pieces/temple"
|
||||
},
|
||||
{
|
||||
"op": "replace",
|
||||
"path": "/players/0/resources/gold",
|
||||
"value": 7
|
||||
},
|
||||
{
|
||||
"op": "remove",
|
||||
"path": "/players/0/event_info"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"action_log_index": 5,
|
||||
"log": [
|
||||
[
|
||||
"Player1 paid 2 food to get the Storage advance",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"A new game event has been triggered: Great Prophet",
|
||||
"Base effect: Barbarians move",
|
||||
"Barbarians cannot move - will try to spawn a new city instead",
|
||||
"Barbarians cannot spawn a new city"
|
||||
],
|
||||
[
|
||||
"Player1 gained Great Prophet for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player1 played the action card Great Prophet",
|
||||
"Player1 gained Myths",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"Player1 decided to build a Temple at C1"
|
||||
],
|
||||
[
|
||||
"Player1 built a Temple at C1 for 2 gold",
|
||||
"State Religion reduced the food cost to 0"
|
||||
]
|
||||
],
|
||||
"undo_limit": 2,
|
||||
"actions_left": 1,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
1,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10,
|
||||
10
|
||||
],
|
||||
"dice_roll_log": [
|
||||
10
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": []
|
||||
}
|
||||
|
|
@ -0,0 +1,579 @@
|
|||
{
|
||||
"state": "Playing",
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"food": 2
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "D1"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C8",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 1,
|
||||
"next_unit_id": 1
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 4,
|
||||
"culture_tokens": 2
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "D8"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "D7",
|
||||
"unit_type": "Infantry",
|
||||
"id": 0
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 1,
|
||||
"next_unit_id": 1
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"A5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"A7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C8",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"D1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"D3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"D4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"D5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"D6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"D7",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"D8",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"E2",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"E3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E8",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"F2",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"G3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"G5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"G7",
|
||||
"Unexplored"
|
||||
]
|
||||
],
|
||||
"unexplored_blocks": [
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "B2",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Forest",
|
||||
"Water",
|
||||
"Fertile",
|
||||
"Forest"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "F2",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Water",
|
||||
"Water",
|
||||
"Forest",
|
||||
"Forest"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "D3",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Water",
|
||||
"Forest",
|
||||
"Water",
|
||||
"Fertile"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "B4",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Water",
|
||||
"Fertile",
|
||||
"Forest",
|
||||
"Mountain"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "F4",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Fertile",
|
||||
"Water",
|
||||
"Fertile",
|
||||
"Barren"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "D5",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Forest",
|
||||
"Mountain",
|
||||
"Fertile",
|
||||
"Mountain"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "B6",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Fertile",
|
||||
"Fertile",
|
||||
"Fertile",
|
||||
"Barren"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "F6",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Fertile",
|
||||
"Fertile",
|
||||
"Fertile",
|
||||
"Forest"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"starting_player_index": 1,
|
||||
"current_player_index": 1,
|
||||
"action_log": [],
|
||||
"action_log_index": 0,
|
||||
"log": [],
|
||||
"undo_limit": 0,
|
||||
"actions_left": 3,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
3,
|
||||
3,
|
||||
7,
|
||||
1,
|
||||
0,
|
||||
6,
|
||||
9,
|
||||
7,
|
||||
3,
|
||||
5,
|
||||
3,
|
||||
0,
|
||||
1,
|
||||
11,
|
||||
2,
|
||||
5,
|
||||
6,
|
||||
3,
|
||||
3,
|
||||
9,
|
||||
9,
|
||||
4,
|
||||
6,
|
||||
2,
|
||||
9,
|
||||
8,
|
||||
11,
|
||||
6,
|
||||
1,
|
||||
0,
|
||||
3,
|
||||
2,
|
||||
9,
|
||||
1,
|
||||
4,
|
||||
6,
|
||||
11,
|
||||
8,
|
||||
4,
|
||||
0,
|
||||
1,
|
||||
5,
|
||||
7,
|
||||
4,
|
||||
10,
|
||||
5,
|
||||
7,
|
||||
4,
|
||||
2,
|
||||
11,
|
||||
1,
|
||||
5,
|
||||
10,
|
||||
5,
|
||||
3,
|
||||
9,
|
||||
1,
|
||||
10,
|
||||
3,
|
||||
7,
|
||||
2,
|
||||
11,
|
||||
10,
|
||||
2,
|
||||
6,
|
||||
5,
|
||||
7,
|
||||
3,
|
||||
1,
|
||||
3,
|
||||
5,
|
||||
1,
|
||||
9,
|
||||
5,
|
||||
4,
|
||||
4,
|
||||
2,
|
||||
7,
|
||||
6,
|
||||
11,
|
||||
10,
|
||||
6,
|
||||
5,
|
||||
8,
|
||||
2,
|
||||
10,
|
||||
0,
|
||||
3,
|
||||
10,
|
||||
0,
|
||||
6,
|
||||
4,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
0,
|
||||
1,
|
||||
11,
|
||||
10,
|
||||
2,
|
||||
4,
|
||||
1,
|
||||
8,
|
||||
8,
|
||||
6,
|
||||
9,
|
||||
2,
|
||||
0,
|
||||
8,
|
||||
8,
|
||||
1,
|
||||
7,
|
||||
5,
|
||||
5,
|
||||
8,
|
||||
8,
|
||||
11,
|
||||
5,
|
||||
0,
|
||||
3,
|
||||
10,
|
||||
7,
|
||||
0,
|
||||
11,
|
||||
6,
|
||||
0,
|
||||
5,
|
||||
3,
|
||||
8,
|
||||
9,
|
||||
5,
|
||||
7,
|
||||
2,
|
||||
7,
|
||||
9,
|
||||
9,
|
||||
4,
|
||||
0,
|
||||
6,
|
||||
5,
|
||||
4,
|
||||
5,
|
||||
10,
|
||||
2,
|
||||
9,
|
||||
3,
|
||||
9,
|
||||
7,
|
||||
4,
|
||||
4,
|
||||
1,
|
||||
8,
|
||||
10,
|
||||
4,
|
||||
6,
|
||||
3,
|
||||
1,
|
||||
10,
|
||||
11,
|
||||
6,
|
||||
0,
|
||||
0,
|
||||
8,
|
||||
8,
|
||||
6,
|
||||
10,
|
||||
7,
|
||||
6,
|
||||
1,
|
||||
3,
|
||||
7,
|
||||
3,
|
||||
9,
|
||||
5,
|
||||
0,
|
||||
8,
|
||||
0,
|
||||
10,
|
||||
6,
|
||||
11,
|
||||
7,
|
||||
1,
|
||||
11,
|
||||
11,
|
||||
1,
|
||||
1,
|
||||
7,
|
||||
10,
|
||||
6,
|
||||
9,
|
||||
5,
|
||||
5,
|
||||
7,
|
||||
6,
|
||||
10,
|
||||
6,
|
||||
2,
|
||||
0,
|
||||
2,
|
||||
8
|
||||
],
|
||||
"dice_roll_log": [],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": [],
|
||||
"incidents_left": [
|
||||
24
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,657 @@
|
|||
{
|
||||
"state": {
|
||||
"Movement": {
|
||||
"movement_actions_left": 2,
|
||||
"moved_units": [
|
||||
0
|
||||
]
|
||||
}
|
||||
},
|
||||
"players": [
|
||||
{
|
||||
"id": 0,
|
||||
"resources": {
|
||||
"food": 2
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 2,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "D1"
|
||||
}
|
||||
],
|
||||
"civilization": "test1",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining"
|
||||
],
|
||||
"incident_tokens": 1,
|
||||
"next_unit_id": 1
|
||||
},
|
||||
{
|
||||
"id": 1,
|
||||
"resources": {
|
||||
"food": 2,
|
||||
"mood_tokens": 1,
|
||||
"culture_tokens": 2
|
||||
},
|
||||
"resource_limit": {
|
||||
"food": 7,
|
||||
"wood": 7,
|
||||
"ore": 7,
|
||||
"ideas": 7,
|
||||
"gold": 7
|
||||
},
|
||||
"cities": [
|
||||
{
|
||||
"city_pieces": {},
|
||||
"mood_state": "Happy",
|
||||
"activations": 0,
|
||||
"angry_activation": false,
|
||||
"position": "D8"
|
||||
}
|
||||
],
|
||||
"units": [
|
||||
{
|
||||
"position": "C8",
|
||||
"unit_type": "Infantry",
|
||||
"movement_restrictions": [
|
||||
"Battle"
|
||||
],
|
||||
"id": 0
|
||||
}
|
||||
],
|
||||
"civilization": "test0",
|
||||
"advances": [
|
||||
"Farming",
|
||||
"Mining",
|
||||
"Storage",
|
||||
"Tactics"
|
||||
],
|
||||
"incident_tokens": 3,
|
||||
"next_unit_id": 1
|
||||
}
|
||||
],
|
||||
"map": {
|
||||
"tiles": [
|
||||
[
|
||||
"A3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"A5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"A7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B2",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"B7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C2",
|
||||
"Forest"
|
||||
],
|
||||
[
|
||||
"C3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"C8",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"D1",
|
||||
"Fertile"
|
||||
],
|
||||
[
|
||||
"D2",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"D3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"D4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"D5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"D6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"D7",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"D8",
|
||||
"Barren"
|
||||
],
|
||||
[
|
||||
"E2",
|
||||
"Mountain"
|
||||
],
|
||||
[
|
||||
"E3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"E8",
|
||||
{
|
||||
"Exhausted": "Forest"
|
||||
}
|
||||
],
|
||||
[
|
||||
"F2",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F4",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F6",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"F7",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"G3",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"G5",
|
||||
"Unexplored"
|
||||
],
|
||||
[
|
||||
"G7",
|
||||
"Unexplored"
|
||||
]
|
||||
],
|
||||
"unexplored_blocks": [
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "B2",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Forest",
|
||||
"Water",
|
||||
"Fertile",
|
||||
"Forest"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "F2",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Water",
|
||||
"Water",
|
||||
"Forest",
|
||||
"Forest"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "D3",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Water",
|
||||
"Forest",
|
||||
"Water",
|
||||
"Fertile"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "B4",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Water",
|
||||
"Fertile",
|
||||
"Forest",
|
||||
"Mountain"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "F4",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Fertile",
|
||||
"Water",
|
||||
"Fertile",
|
||||
"Barren"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "D5",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Forest",
|
||||
"Mountain",
|
||||
"Fertile",
|
||||
"Mountain"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "B6",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Fertile",
|
||||
"Fertile",
|
||||
"Fertile",
|
||||
"Barren"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"position": {
|
||||
"top_tile": "F6",
|
||||
"rotation": 0
|
||||
},
|
||||
"block": {
|
||||
"terrain": [
|
||||
"Fertile",
|
||||
"Fertile",
|
||||
"Fertile",
|
||||
"Forest"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"starting_player_index": 1,
|
||||
"current_player_index": 1,
|
||||
"action_log": [
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"Advance": {
|
||||
"advance": "Storage",
|
||||
"payment": {
|
||||
"food": 2
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Response": {
|
||||
"Payment": [
|
||||
{
|
||||
"culture_tokens": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Playing": {
|
||||
"ActionCard": 124
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"Movement": {
|
||||
"Move": {
|
||||
"units": [
|
||||
0
|
||||
],
|
||||
"destination": "C8"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"action_log_index": 4,
|
||||
"log": [
|
||||
[
|
||||
"Player2 paid 2 food to get the Storage advance",
|
||||
"Player gained 1 mood token as advance bonus"
|
||||
],
|
||||
[
|
||||
"A new game event has been triggered: Great Warlord",
|
||||
"Player2 exhausted the land in position E8"
|
||||
],
|
||||
[
|
||||
"Player2 gained Great Warlord for 1 culture token"
|
||||
],
|
||||
[
|
||||
"Player2 played the action card Great Warlord",
|
||||
"Player2 gained Tactics",
|
||||
"Player gained 1 culture token as advance bonus"
|
||||
],
|
||||
[
|
||||
"Player2 marched 1 infantry from D7 to C8"
|
||||
],
|
||||
[
|
||||
"Combat round 1",
|
||||
"Player2 rolled 5 (Cavalry, no bonus) for combined combat value of 7 and gets 1 hits against defending units.",
|
||||
"Player1 rolled 2 (Cavalry, no bonus) for combined combat value of 2 and gets 0 hits against attacking units.",
|
||||
"Player2 used the following combat modifiers: Player gets +2 combat value for Great Warlord",
|
||||
"Player1 has to remove all of their defending units",
|
||||
"Player1 removed 1 infantry",
|
||||
"Attacker wins"
|
||||
]
|
||||
],
|
||||
"undo_limit": 4,
|
||||
"actions_left": 1,
|
||||
"round": 1,
|
||||
"age": 1,
|
||||
"messages": [
|
||||
"The game has started"
|
||||
],
|
||||
"dice_roll_outcomes": [
|
||||
3,
|
||||
3,
|
||||
7,
|
||||
1,
|
||||
0,
|
||||
6,
|
||||
9,
|
||||
7,
|
||||
3,
|
||||
5,
|
||||
3,
|
||||
0,
|
||||
1,
|
||||
11,
|
||||
2,
|
||||
5,
|
||||
6,
|
||||
3,
|
||||
3,
|
||||
9,
|
||||
9,
|
||||
4,
|
||||
6,
|
||||
2,
|
||||
9,
|
||||
8,
|
||||
11,
|
||||
6,
|
||||
1,
|
||||
0,
|
||||
3,
|
||||
2,
|
||||
9,
|
||||
1,
|
||||
4,
|
||||
6,
|
||||
11,
|
||||
8,
|
||||
4,
|
||||
0,
|
||||
1,
|
||||
5,
|
||||
7,
|
||||
4,
|
||||
10,
|
||||
5,
|
||||
7,
|
||||
4,
|
||||
2,
|
||||
11,
|
||||
1,
|
||||
5,
|
||||
10,
|
||||
5,
|
||||
3,
|
||||
9,
|
||||
1,
|
||||
10,
|
||||
3,
|
||||
7,
|
||||
2,
|
||||
11,
|
||||
10,
|
||||
2,
|
||||
6,
|
||||
5,
|
||||
7,
|
||||
3,
|
||||
1,
|
||||
3,
|
||||
5,
|
||||
1,
|
||||
9,
|
||||
5,
|
||||
4,
|
||||
4,
|
||||
2,
|
||||
7,
|
||||
6,
|
||||
11,
|
||||
10,
|
||||
6,
|
||||
5,
|
||||
8,
|
||||
2,
|
||||
10,
|
||||
0,
|
||||
3,
|
||||
10,
|
||||
0,
|
||||
6,
|
||||
4,
|
||||
1,
|
||||
10,
|
||||
10,
|
||||
0,
|
||||
1,
|
||||
11,
|
||||
10,
|
||||
2,
|
||||
4,
|
||||
1,
|
||||
8,
|
||||
8,
|
||||
6,
|
||||
9,
|
||||
2,
|
||||
0,
|
||||
8,
|
||||
8,
|
||||
1,
|
||||
7,
|
||||
5,
|
||||
5,
|
||||
8,
|
||||
8,
|
||||
11,
|
||||
5,
|
||||
0,
|
||||
3,
|
||||
10,
|
||||
7,
|
||||
0,
|
||||
11,
|
||||
6,
|
||||
0,
|
||||
5,
|
||||
3,
|
||||
8,
|
||||
9,
|
||||
5,
|
||||
7,
|
||||
2,
|
||||
7,
|
||||
9,
|
||||
9,
|
||||
4,
|
||||
0,
|
||||
6,
|
||||
5,
|
||||
4,
|
||||
5,
|
||||
10,
|
||||
2,
|
||||
9,
|
||||
3,
|
||||
9,
|
||||
7,
|
||||
4,
|
||||
4,
|
||||
1,
|
||||
8,
|
||||
10,
|
||||
4,
|
||||
6,
|
||||
3,
|
||||
1,
|
||||
10,
|
||||
11,
|
||||
6,
|
||||
0,
|
||||
0,
|
||||
8,
|
||||
8,
|
||||
6,
|
||||
10,
|
||||
7,
|
||||
6,
|
||||
1,
|
||||
3,
|
||||
7,
|
||||
3,
|
||||
9,
|
||||
5,
|
||||
0,
|
||||
8,
|
||||
0,
|
||||
10,
|
||||
6,
|
||||
11,
|
||||
7,
|
||||
1,
|
||||
11,
|
||||
11,
|
||||
1,
|
||||
1,
|
||||
7,
|
||||
10,
|
||||
6,
|
||||
9,
|
||||
5,
|
||||
5,
|
||||
7,
|
||||
6,
|
||||
10,
|
||||
6,
|
||||
2,
|
||||
0
|
||||
],
|
||||
"dice_roll_log": [
|
||||
8,
|
||||
2
|
||||
],
|
||||
"dropped_players": [],
|
||||
"wonders_left": [
|
||||
"Pyramids"
|
||||
],
|
||||
"action_cards_left": []
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue