File tree Expand file tree Collapse file tree 1 file changed +29
-2
lines changed Expand file tree Collapse file tree 1 file changed +29
-2
lines changed Original file line number Diff line number Diff line change @@ -54,10 +54,32 @@ public override void Update()
5454 {
5555 if ( Keyboard . IsPressed ( Key . UpArrow ) )
5656 {
57-
57+ foreach ( var planet in CurrentSystem . Planets )
58+ {
59+ var planetData = planet . GetPlanetData ( ) ;
60+ Logger . WriteLine ( $ "Planet { planetData . Name . Value . ToString ( ) } has a seed { planetData . GenerationData . Seed . Seed . ToHex ( ) } ") ;
61+
62+
63+ }
5864
5965 }
6066
67+ if ( Keyboard . IsPressed ( Key . RightArrow ) )
68+ {
69+ foreach ( var planet in CurrentSystem . Planets )
70+ {
71+ var planetData = planet . GetPlanetData ( ) ;
72+
73+ var seedRandomizer = new GcSeed ( ) ;
74+ seedRandomizer . Seed = ( ( long ) Random . Range ( 0 , 18446744073709551615 ) ) ;
75+ planetData . GenerationData . Seed . Seed = seedRandomizer . Seed ;
76+ Logger . WriteLine ( $ "Seeds Randomized") ;
77+ planet . SetPlanetData ( planetData ) ;
78+
79+ }
80+
81+
82+ }
6183
6284
6385
@@ -162,7 +184,12 @@ private void planetLoaded(IPlanet planet)
162184 {
163185 //Testing
164186 Logger . WriteLine ( $ "{ planetData . GenerationData . Biome . Biome . ToString ( ) } Planet { planetData . Name . Value } has been loaded") ;
165-
187+
188+ //Testing Names
189+ var nameString = new NMSString0x80 ( ) ;
190+ nameString = "Testing Name" ;
191+ planetData . Name = nameString ;
192+
166193 //Randomize Colours
167194 foreach ( var pallette in planetData . Colours . Palettes )
168195 {
You can’t perform that action at this time.
0 commit comments