-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMod.cs
More file actions
34 lines (30 loc) · 1.15 KB
/
Copy pathMod.cs
File metadata and controls
34 lines (30 loc) · 1.15 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
using Colossal.Logging;
using Game;
using Game.Modding;
namespace RemoveBlockingWorkVehicles
{
public class Mod : IMod
{
// Create a new log just for this mod.
// This mod will have its own log file in the game's Logs folder.
public static readonly ILog log = LogManager.GetLogger(ModAssemblyInfo.Name)
.SetShowsErrorsInUI(true) // Show message in UI for severity level Error and above.
.SetShowsStackTraceAboveLevels(Level.Error); // Include stack trace for severity level Error and above.
/// <summary>
/// One-time mod loading.
/// </summary>
public void OnLoad(UpdateSystem updateSystem)
{
log.Info($"{nameof(Mod)}.{nameof(OnLoad)} Version {ModAssemblyInfo.Version}");
// Create and activate this mod's one system.
updateSystem.UpdateAt<RemoveBlockersSystem>(SystemUpdatePhase.GameSimulation);
}
/// <summary>
/// One-time mod disposing.
/// </summary>
public void OnDispose()
{
log.Info($"{nameof(Mod)}.{nameof(OnDispose)}");
}
}
}