|
14 | 14 |
|
15 | 15 | namespace CaiBotLite;
|
16 | 16 |
|
17 |
| -[ApiVersion(2, 1)] |
18 |
| -公共 class Plugin : TerrariaPlugin |
| 17 | +[ApiVersion(2, 1)] |
| 18 | +public class Plugin : TerrariaPlugin |
19 | 19 | {
|
20 |
| - 公共 static readonly Version VersionNum = new (2025, 3, 3, 1); //日期+版本号(0,1,2...) |
| 20 | + public static readonly Version VersionNum = new (2025, 3, 3, 1); //日期+版本号(0,1,2...) |
21 | 21 | internal static int InitCode = -1;
|
22 |
| - 公共 static bool DebugMode; |
| 22 | + public static bool DebugMode; |
23 | 23 | private static bool _stopWebsocket;
|
24 | 24 | internal static ClientWebSocket WebSocket
|
25 | 25 | {
|
26 | 26 | get => PacketWriter.WebSocket;
|
27 | 27 | set => PacketWriter.WebSocket = value;
|
28 | 28 | }
|
29 | 29 |
|
30 |
| - 公共 Plugin(Main game) : base(game) |
| 30 | + public Plugin(Main game) : base(game) |
31 | 31 | {
|
32 | 32 | }
|
33 | 33 |
|
34 |
| - 公共 override string Author => "Cai,羽学,西江"; |
35 |
| - 公共 override string Description => "CaiBot官方机器人的适配插件"; |
36 |
| - 公共 override string Name => "CaiBotLitePlugin"; |
37 |
| - 公共 override Version Version => VersionNum; |
| 34 | + public override string Author => "Cai,羽学,西江"; |
| 35 | + public override string Description => "CaiBot官方机器人的适配插件"; |
| 36 | + public override string Name => "CaiBotLitePlugin"; |
| 37 | + public override Version Version => VersionNum; |
38 | 38 |
|
39 | 39 |
|
40 |
| - 公共 override void Initialize() |
| 40 | + public override void Initialize() |
41 | 41 | {
|
42 | 42 | DebugMode = Program.LaunchParameters.ContainsKey("-caidebug");
|
43 | 43 | AppDomain.CurrentDomain.AssemblyResolve += this.CurrentDomain_AssemblyResolve;
|
44 |
| - Commands.ChatCommands.Add(new Command("caibotlite.admin", this.CaiBotCommand, "caibotlite")); |
| 44 | + Commands.ChatCommands.Add(new Command("caibotlite.admin", this.CaiBotCommand, "caibotlite")); |
45 | 45 | Config.Settings.Read();
|
46 | 46 | Config.Settings.Write();
|
47 | 47 | ServerApi.Hooks.NetGetData.Register(this, Login.OnGetData, int.MaxValue);
|
|
0 commit comments