1
0
mirror of https://git.ngram.ca/OpenJam/rc-servers synced 2026-08-23 23:08:52 +00:00

Add server for game data (implement login sequence)

This commit is contained in:
NGnius (Graham)
2025-02-12 18:46:27 -05:00
parent ca4a0ce675
commit d8885d811f
52 changed files with 2734 additions and 5 deletions

View File

@@ -0,0 +1,23 @@
use polariton::operation::Typed;
pub struct CustomisationData {
pub id: String,
pub localised_name: String,
pub skin_scene_name: String,
pub simulation_prefab: String,
pub preview_image_name: String,
pub is_default: bool,
}
impl CustomisationData {
pub fn as_transmissible(&self) -> Typed {
Typed::HashMap(vec![
(Typed::Str("id".into()), Typed::Str(self.id.clone().into())),
(Typed::Str("localisedName".into()), Typed::Str(self.localised_name.clone().into())),
(Typed::Str("skinsceneName".into()), Typed::Str(self.skin_scene_name.clone().into())),
(Typed::Str("simulationPrefab".into()), Typed::Str(self.simulation_prefab.clone().into())),
(Typed::Str("previewImageName".into()), Typed::Str(self.preview_image_name.clone().into())),
(Typed::Str("isDefault".into()), Typed::Bool(self.is_default.into())),
].into())
}
}