summaryrefslogtreecommitdiffstats
path: root/src/launcher.rs
diff options
context:
space:
mode:
authorLibravatar bigfoot547 <[email protected]>2025-01-01 03:06:56 -0600
committerLibravatar bigfoot547 <[email protected]>2025-01-01 03:06:56 -0600
commitc21df3c73ae0dd18999f72504f96930f2c69b4eb (patch)
tree61568d7c065312953572e4e3fb98f60f329f3c32 /src/launcher.rs
parentsome stuff has changed (diff)
add string sub algorithm
Diffstat (limited to 'src/launcher.rs')
-rw-r--r--src/launcher.rs25
1 files changed, 19 insertions, 6 deletions
diff --git a/src/launcher.rs b/src/launcher.rs
index 70c313c..06a5d5b 100644
--- a/src/launcher.rs
+++ b/src/launcher.rs
@@ -1,18 +1,31 @@
mod constants;
mod version;
-mod instance;
mod profile;
+mod strsub;
-use std::error::Error;
+use std::collections::HashMap;
+use serde::{Deserialize, Serialize};
use version::VersionList;
+use crate::launcher::profile::{Instance, Profile};
+
+#[derive(Debug, Clone, Serialize, Deserialize)]
+pub struct Settings {
+ profiles: HashMap<String, Profile>,
+ instances: HashMap<String, Instance>
+}
pub struct Launcher {
- pub versions: VersionList
-
+ versions: VersionList,
+ settings: Settings,
}
impl Launcher {
- pub async fn new() -> Result<Launcher, Box<dyn Error>> {
- todo!()
+ pub fn new(versions: VersionList, settings: Settings) -> Launcher {
+ Launcher {
+ versions,
+ settings
+ }
}
+
+
} \ No newline at end of file