private void OnPlayerConnected(BasePlayer player) { if (ContainerController.FindIndex(player) != -1) { return; } _controllers.Add(new ContainerController(player)); // lol }
private void OnPlayerDisconnected(BasePlayer player) { var index = ContainerController.FindIndex(player); if (index == -1) { return; } _controllers[index].Destroy(); _controllers.RemoveAt(index); }