Skip to content

Commit

Permalink
Merge pull request nwnxee#1272 from mtijanic/hardexit
Browse files Browse the repository at this point in the history
core: add hard exit option
  • Loading branch information
mtijanic authored Feb 27, 2021
2 parents c188f0c + 67df3fa commit 6e2b934
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Core/NWNXCore.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -483,6 +483,8 @@ void NWNXCore::Shutdown()
UnloadServices();
Tasks::StopAsyncWorkers();
g_core = nullptr;
if (Config::Get<bool>("HARD_EXIT", false))
exit(0);
}
}

Expand Down
1 change: 1 addition & 0 deletions Core/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ The core of NWNX:EE that does all the things.
| `NWNX_CORE_LOG_COLOR` | 0-1 | 1 | Set whether to show logs printed by NWNX in color (only when printing to a TTY).
| `NWNX_CORE_LOG_FORCE_COLOR` | 0-1| 0 | Sets whether to force color output.
| `NWNX_CORE_LOG_ASYNC` | 0-1| 0 | Sets whether to flush the log to disk in an async thread.
| `NWNX_CORE_HARD_EXIT` | 0-1| 0 | If set, NWNX will hard kill the process after it unloads.

## Console Commands

Expand Down

0 comments on commit 6e2b934

Please sign in to comment.