| 32 | #include "HalfLife2.h" |
| 33 | |
| 34 | static cell_t sm_GetCommandLine(IPluginContext *pCtx, const cell_t *params) |
| 35 | { |
| 36 | ICommandLine *pCmdLine = g_HL2.GetValveCommandLine(); |
| 37 | |
| 38 | if (pCmdLine == NULL) |
| 39 | { |
| 40 | return pCtx->ThrowNativeError("Unable to get valve command line"); |
| 41 | } |
| 42 | |
| 43 | const char *commandLine = pCmdLine->GetCmdLine(); |
| 44 | |
| 45 | if (commandLine == NULL) |
| 46 | { |
| 47 | return 0; |
| 48 | } |
| 49 | |
| 50 | pCtx->StringToLocal(params[1], params[2], commandLine); |
| 51 | |
| 52 | return 1; |
| 53 | } |
| 54 | |
| 55 | static cell_t sm_GetCommandLineParam(IPluginContext *pCtx, const cell_t *params) |
| 56 | { |
nothing calls this directly
no test coverage detected