|
1 | 1 | using System.Collections.Generic; |
2 | 2 | using System.IO; |
3 | 3 | using GSSerializer; |
| 4 | +using UnityEngine; |
4 | 5 | using static GalacticScale.GS2; |
5 | 6 |
|
6 | 7 | namespace GalacticScale |
@@ -31,6 +32,7 @@ public class GS2MainSettings : iConfigurableGenerator |
31 | 32 | public bool SkipTutorials => Preferences.GetBool("Skip Tutorials"); |
32 | 33 | public bool ScarletRevert => Preferences.GetBool("RevertScarlet"); |
33 | 34 | public bool CheatMode => Preferences.GetBool("Cheat Mode"); |
| 35 | + public float MechaScale => Preferences.GetFloat("MechaScale", 1f); |
34 | 36 |
|
35 | 37 | // public bool VanillaGrid => Preferences.GetBool("Vanilla Grid"); |
36 | 38 | public bool MinifyJson |
@@ -152,6 +154,7 @@ public void Init() |
152 | 154 | DebugOptions.Add(GSUI.Checkbox("Debug Log".Translate(), false, "Debug Log", null, "Print extra logs to BepInEx console".Translate())); |
153 | 155 | DebugOptions.Add(GSUI.Checkbox("Force Rare Spawn".Translate(), false, "Force Rare Spawn", null, "Ignore randomness/distance checks".Translate())); |
154 | 156 | _cheatModeCheckbox = DebugOptions.Add(GSUI.Checkbox("Enable Teleport".Translate(), false, "Cheat Mode", null, "TP by ctrl-click nav arrow in star map".Translate())); |
| 157 | + DebugOptions.Add(GSUI.Slider("Mecha Scale".Translate(), 0.1f, 1f, 10f, 0.1f, "MechaScale", ScaleMecha, "How big Icarus should be. 1 = default")); |
155 | 158 | DebugOptions.Add(GSUI.Slider("Ship Speed Multiplier".Translate(), 1f, 1f, 100f, "Logistics Ship Multi", null, "Multiplier for Warp Speed of Ships".Translate())); |
156 | 159 | DebugOptions.Add(GSUI.Slider("GalaxySelect Planet ScaleFactor".Translate(), 0.1f, 0.6f, 100f, 0.1f, "VSPlanetScaleFactor", null, "How big planets should be in the new game system view".Translate())); |
157 | 160 | DebugOptions.Add(GSUI.Slider("GalaxySelect Star ScaleFactor".Translate(), 0.1f, 0.6f, 100f, 0.1f, "VSStarScaleFactor", null, "How big star should be in the new game system view".Translate())); |
@@ -199,9 +202,13 @@ public void EnableDevMode() |
199 | 202 | SavePreferences(); |
200 | 203 | } |
201 | 204 |
|
| 205 | + public void ScaleMecha(Val o) |
| 206 | + { |
| 207 | + if (GameMain.mainPlayer != null) GameMain.mainPlayer.transform.localScale = Vector3.one * Preferences.GetFloat("MechaScale", 1f); |
| 208 | + } |
202 | 209 | public void ResetBinaryStars(Val o) |
203 | 210 | { |
204 | | - var random = new Random(GSSettings.Seed); |
| 211 | + var random = new GS2.Random(GSSettings.Seed); |
205 | 212 | foreach (var star in GSSettings.Stars) |
206 | 213 | if (star.BinaryCompanion != null) |
207 | 214 | { |
|
0 commit comments