From 4be5a72972027ec0bcc103b0fd2395b5874fba3c Mon Sep 17 00:00:00 2001 From: beppe Date: Mon, 4 Jul 2022 12:06:41 +0200 Subject: [PATCH] have to debug from_utf8 stuff. :/ --- README.md | 8 +++++++- main/saves/yellow_surfing_test.sav | Bin 0 -> 32768 bytes main/src/saves.rs | 4 ++++ main/src/test.rs | 23 +++++++++++++++++++++++ 4 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 main/saves/yellow_surfing_test.sav create mode 100644 main/src/saves.rs create mode 100644 main/src/test.rs diff --git a/README.md b/README.md index a16b504..71e72c7 100644 --- a/README.md +++ b/README.md @@ -1 +1,7 @@ -# pokevault \ No newline at end of file +# pokevault + +## save files + +### yellow +for pokemon yellow, this legend has created a bunch of save files and documented his journey doing so. Got it from him: +https://www.youtube.com/watch?v=hdUopla7T1E \ No newline at end of file diff --git a/main/saves/yellow_surfing_test.sav b/main/saves/yellow_surfing_test.sav new file mode 100644 index 0000000000000000000000000000000000000000..cad2c1194715d2fd47b536b5613c973152464a2c GIT binary patch literal 32768 zcmeHQ4|o$*w!b%%H2s@UnzSj@0s%?|qpS*2TS!6t1Jx3NR$2vHwhJPni2UjItYy+n zo3v>X(uC5=V%-H7ExNj0_ItbP79Q@C>|5V6`{#RR@$Dn(+lBA#A5vKbEp*;FGihxz ziJ!V<7vDEGAJa2;esk`fGv}N+_uM}66VQn0#G>|0* zDCtT+pCm;4VU8 zkCW1*mey9bm9T{qmM$O-OBc-caa{6UrItNo@9UUWW{^h0!|x1vgIGx;KjxsYV=xf1 zWQn1~`UaUn3DR4eUjhWkHwaa+OFRC+p0| z4#oPLj5m9hzWv%08=vwOtUR^t`PW|m%U|+-pFi=yZ!0|&fBMVPXBS`kZGr1Q-}zwm zhW@uQpC~HIxzqNRy=xbBZ~XJGU$XyZ<%w@+-po&Yr|`tTdoC9IspuV^@2%h~_+I$; z;f1DC{JX!Yc&C?Stj$0j<}0dS(4Kmyuwuuy-Xli_PR(JDY$bff%NN$JJ#`qU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*nWf{42z25WRC{zm-4%@z z4q*NP4|+L4)fpf{8x1dOXme_3W%IP~H6 zaV;%PethH$q#rC5oPyu#7KR@fqJX8dg6FV1eC=+R6Rln(A@%FBI2}!G4xb<0O`E&9 zS|OuO>ihZG7%stE3+pN?q!AfJD&a{&)>&aXsHv3>Ov8~# z;4X}1at$VT@j7WF0)wI8JOseYL=~0mq)k97BzzMBaDjkvi`u%tlCD z#YAK*g6lR&2Zf=t!QdvLiQ!cYlAtdXd}u_H zv!%f=#9N__Ba$?)m-GQ*-$*Y4pbtIf%1shLBoGd-7lyWa(}LnSoeaR;{3hyyN&raj zCIG_K7!?BGpb>NDF;@Yv%mnVos1N`eW06#&Ah{O!vVq*VrJW=VW5xL9#@f9fw!^p) zM{FHUU67L&#(%9{E^#s}I*wzl{_buF5L+NdL@3O?yE+^q>4PuByTz$I0Kli?y_n@{ z>4HSNO{gFB`FEQ`n7Ky|9Jf~-R6_P0)&zKQRRPSn!2nXEEX__fS_%1ZZx;-6@iaH2 z)VnZ-6-bN*k!*tw;*x+7(t{mJJ;E(7TehZZiA{WaN}P5%B4k??CeITEaV!hwQaD8# z>SS)S@m8>l7}J9}r{HoN^W`d-;@Wr|BB4MT0&)~g#o|g>_7cMZ>>{!Z0XhX!+qg>F z2XG*PHT0S~GHH^jHc{5O3a8dT53qz<0ia0C!A5(~(=yHLiox_^ItdBB@bC*{FtoKx z65BAeMIR!Uagl(;&;?b#Qndo}zuSi8APdAc`MR8zQU5UntQ2xI`Gss!H|r4{1q?yK z{Jl8yj%g=Y$m0_J(*PjB`eD*us0C8UTaWr*1c3azUCx+>#w literal 0 HcmV?d00001 diff --git a/main/src/saves.rs b/main/src/saves.rs new file mode 100644 index 0000000..fd2fe77 --- /dev/null +++ b/main/src/saves.rs @@ -0,0 +1,4 @@ +pub struct Save { + pub(crate) trainer_name: String, + pub(crate) playtime_hours: u8 //in seconds, biggest number should be like 4.3 mill, biggest available time (999:95) is like... 3.6 mill, maybe a little more. 3.7 max +} \ No newline at end of file diff --git a/main/src/test.rs b/main/src/test.rs new file mode 100644 index 0000000..da7ae4d --- /dev/null +++ b/main/src/test.rs @@ -0,0 +1,23 @@ + +#[cfg(test)] +mod test { + use std::env; + use std::path::Path; + use crate::{read_save, Save}; + + #[test] + fn basic_test() { + assert!(true) + } + + #[test] + fn test_name() { + let path = env::current_dir().unwrap(); + println!("The current dir: {}", path.display()); + println!("testing the savegames name"); + let s: Save = read_save(Path::new("saves/yellow_surfing_test.sav")).unwrap(); + println!("{}", s.trainer_name); + assert!(true); + } + +} \ No newline at end of file