-
-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathRealCity.cs
More file actions
101 lines (86 loc) · 2.56 KB
/
RealCity.cs
File metadata and controls
101 lines (86 loc) · 2.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
using ICities;
using System.IO;
using RealCity.Util;
using ColossalFramework.UI;
using CitiesHarmony.API;
using RealCity.UI;
namespace RealCity
{
public class RealCity : IUserMod
{
public static bool IsEnabled = false;
public static bool debugMode = false;
public static bool reduceVehicle = false;
public static bool realCityV10 = true;
public static bool randomEvent = false;
public static bool noPassengerCar = true;
public string Name
{
get { return "Real City"; }
}
public string Description
{
get { return "Make your city reality, Combine CS and SimCity in game playing"; }
}
public void OnEnabled()
{
IsEnabled = true;
FileStream fs = File.Create("RealCity.txt");
fs.Close();
HarmonyHelper.EnsureHarmonyInstalled();
if (UIView.GetAView() != null)
{
OnGameIntroLoaded();
}
else
{
LoadingManager.instance.m_introLoaded += OnGameIntroLoaded;
}
}
public void OnDisabled()
{
IsEnabled = false;
LoadingManager.instance.m_introLoaded -= OnGameIntroLoaded;
}
private static void OnGameIntroLoaded()
{
ModsCompatibilityChecker mcc = new ModsCompatibilityChecker();
mcc.PerformModCheck();
}
public void OnSettingsUI(UIHelperBase helper)
{
OptionUI.MakeSettings(helper);
}
public static bool GetRealCityV10()
{
return realCityV10;
}
public static float GetAverageSalary()
{
if (MainDataStore.citizenCount != 0)
return MainDataStore.citizenSalaryTotal / MainDataStore.citizenCount;
else
return 1f;
}
public static int GetReduceCargoDiv()
{
return MainDataStore.reduceCargoDiv;
}
public static float GetOutsideTouristMoney()
{
return MainDataStore.outsideTouristMoney;
}
public static void SetOutsideTouristMoney(float value)
{
MainDataStore.outsideTouristMoney = value;
}
public static float GetOutsideGovermentMoney()
{
return MainDataStore.outsideGovermentMoney;
}
public static void SetOutsideGovermentMoney(float value)
{
MainDataStore.outsideGovermentMoney = value;
}
}
}