Skip to main content

ed_journals/modules/logs/content/log_event_content/
commit_crime_event.rs

1//! Fired when the player commits a crime.
2
3use crate::civilization::Crime;
4use serde::{Deserialize, Serialize};
5
6/// Fired when the player commits a crime.
7#[derive(Debug, Serialize, Deserialize, Clone, PartialEq)]
8#[serde(rename_all = "PascalCase")]
9pub struct CommitCrimeEvent {
10    /// The kind of crime the player committed.
11    pub crime_type: Crime,
12
13    /// The faction that the player has commited the crime to.
14    pub faction: String,
15
16    /// The fine that needs to be paid for the crime.
17    pub fine: Option<u64>,
18
19    /// The bounty that has been placed on the player for committing the crime.
20    pub bounty: Option<u64>,
21}