mirror of
https://github.com/daffyyyy/CS2-SimpleAdmin.git
synced 2026-02-17 18:39:07 +00:00
Compare commits
8 Commits
fe73fa9917
...
91615ffc67
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
91615ffc67 | ||
|
|
eb9b438315 | ||
|
|
3d23b8981b | ||
|
|
39cbfdab1e | ||
|
|
4599f08fd7 | ||
|
|
4c43f14c82 | ||
|
|
f16f8cf1a5 | ||
|
|
193685826c |
@@ -22,7 +22,7 @@ public partial class CS2_SimpleAdmin : BasePlugin, IPluginConfig<CS2_SimpleAdmin
|
|||||||
public override string ModuleName => "CS2-SimpleAdmin" + (Helper.IsDebugBuild ? " (DEBUG)" : " (RELEASE)");
|
public override string ModuleName => "CS2-SimpleAdmin" + (Helper.IsDebugBuild ? " (DEBUG)" : " (RELEASE)");
|
||||||
public override string ModuleDescription => "Simple admin plugin for Counter-Strike 2 :)";
|
public override string ModuleDescription => "Simple admin plugin for Counter-Strike 2 :)";
|
||||||
public override string ModuleAuthor => "daffyy";
|
public override string ModuleAuthor => "daffyy";
|
||||||
public override string ModuleVersion => "1.7.8-beta-10";
|
public override string ModuleVersion => "1.7.8-beta-10b";
|
||||||
|
|
||||||
public override void Load(bool hotReload)
|
public override void Load(bool hotReload)
|
||||||
{
|
{
|
||||||
@@ -85,7 +85,7 @@ public partial class CS2_SimpleAdmin : BasePlugin, IPluginConfig<CS2_SimpleAdmin
|
|||||||
|
|
||||||
RegisterEvents();
|
RegisterEvents();
|
||||||
AddTimer(0.5f, RegisterCommands.InitializeCommands);
|
AddTimer(0.5f, RegisterCommands.InitializeCommands);
|
||||||
AddTimer(1.0f, () => ReloadAdmins(null));
|
AddTimer(3.0f, () => ReloadAdmins(null));
|
||||||
|
|
||||||
if (!CoreConfig.UnlockConCommands)
|
if (!CoreConfig.UnlockConCommands)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -512,11 +512,11 @@ public partial class CS2_SimpleAdmin
|
|||||||
AddTimer(1, () =>
|
AddTimer(1, () =>
|
||||||
{
|
{
|
||||||
if (!string.IsNullOrEmpty(adminsFile))
|
if (!string.IsNullOrEmpty(adminsFile))
|
||||||
AdminManager.LoadAdminData(ModuleDirectory + "/data/admins.json");
|
AddTimer(2.0f, () => AdminManager.LoadAdminData(ModuleDirectory + "/data/admins.json"));
|
||||||
if (!string.IsNullOrEmpty(groupsFile))
|
if (!string.IsNullOrEmpty(groupsFile))
|
||||||
AdminManager.LoadAdminGroups(ModuleDirectory + "/data/groups.json");
|
AddTimer(3.0f, () => AdminManager.LoadAdminGroups(ModuleDirectory + "/data/groups.json"));
|
||||||
if (!string.IsNullOrEmpty(adminsFile))
|
if (!string.IsNullOrEmpty(adminsFile))
|
||||||
AdminManager.LoadAdminData(ModuleDirectory + "/data/admins.json");
|
AddTimer(4.0f, () => AdminManager.LoadAdminData(ModuleDirectory + "/data/admins.json"));
|
||||||
|
|
||||||
_logger?.LogInformation("Loaded admins!");
|
_logger?.LogInformation("Loaded admins!");
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -103,12 +103,12 @@ public class ServerManager
|
|||||||
CS2_SimpleAdmin.ServerId = serverId;
|
CS2_SimpleAdmin.ServerId = serverId;
|
||||||
CS2_SimpleAdmin._logger?.LogInformation("Loaded server with ip {ip}", ipAddress);
|
CS2_SimpleAdmin._logger?.LogInformation("Loaded server with ip {ip}", ipAddress);
|
||||||
|
|
||||||
|
CS2_SimpleAdmin.ServerLoaded = true;
|
||||||
|
|
||||||
if (CS2_SimpleAdmin.Instance.CacheManager != null)
|
if (CS2_SimpleAdmin.Instance.CacheManager != null)
|
||||||
{
|
{
|
||||||
await CS2_SimpleAdmin.Instance.CacheManager.InitializeCacheAsync();
|
await CS2_SimpleAdmin.Instance.CacheManager.InitializeCacheAsync();
|
||||||
}
|
}
|
||||||
|
|
||||||
CS2_SimpleAdmin.ServerLoaded = true;
|
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
1.7.8-beta-10
|
1.7.8-beta-10b1
|
||||||
Reference in New Issue
Block a user