-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMain.cs
More file actions
37 lines (29 loc) · 831 Bytes
/
Main.cs
File metadata and controls
37 lines (29 loc) · 831 Bytes
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
using System;
using UnityEngine;
namespace ColorCorrection {
public class Main : IMod {
private GameObject _go;
public void onEnabled() {
_go = new GameObject(Name);
ColorCorrection colorCorrection = _go.AddComponent<ColorCorrection>();
colorCorrection.modPath = Path != null ? Path : System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location);
}
public void onDisabled() {
if (_go != null) {
UnityEngine.Object.Destroy(_go);
_go = null;
}
}
public string Name {
get { return "ColorCorrection"; }
}
public string Description {
get { return "Changes the colors of the game."; }
}
public string Identifier {
get { return "com.themeparkitect.ColorCorrection"; }
}
// PN mod location path
public string Path { get; set; }
}
}