aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src-tauri/src/launcher/launcher.rs
blob: 22a88812106230c7377ce7d0ff5d854d6ca361d6 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
pub struct Launcher {
    pub config: crate::launcher::config::Config,
}

impl Launcher {
    pub fn new(config: crate::launcher::config::Config) -> Self {
        Launcher { config }
    }

    pub fn launch(&self) {
        // 启动游戏的逻辑
        println!("启动游戏,用户名: {}", self.config.username);
        println!(
            "分辨率: {}x{}",
            self.config.resolution.0, self.config.resolution.1
        );
    }
}