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

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
use serde::{Deserialize, Serialize};

use crate::modules::galaxy::StarClass;

#[derive(Debug, Serialize, Deserialize, Clone, PartialEq)]
#[serde(rename_all = "PascalCase")]
pub struct StartJumpEvent {
    #[serde(flatten)]
    pub jump: StartJumpType,

    #[serde(default)]
    pub taxi: bool,
}

#[derive(Debug, Serialize, Deserialize, Clone, PartialEq)]
#[serde(rename_all = "PascalCase", tag = "JumpType")]
pub enum StartJumpType {
    #[serde(rename_all = "PascalCase")]
    Hyperspace {
        star_system: String,
        system_address: u64,
        star_class: StarClass,
    },
    Supercruise,
}