public void Patch() { _logger.Info("Starting Patching..."); _patcher.Patch(this, typeof(Game), "Update", null, "GameUpdated"); _patcher.Patch(this, typeof(SimulationPlayer), "FireEvent", null, "PlayerEvent", typeof(PlayerEvent)); _patcher.Patch(this, typeof(Simulation), "FireEvent", null, "SimulationEvent", typeof(SimulationEvent)); _logger.Info("Patching Finished"); }
public void Awake() { try { _patcher.Patch(this, typeof(Game), "Start", null, "GameStart_Bind"); _patcher.Patch(this, typeof(ResourcePanel), "Initialize", null, "PatchVersion_Bind"); _patcher.Patch(this, typeof(PlayerChapter), "Initialize", null, "PatchGameTime_Bind"); } catch (Exception ex) { _logger.Error("Error occurred while performing initial patching:\r\n" + ex); } }