/////////////////////////////////////////////////////////////////////
| 1445 | |
| 1446 | ////////////////////////////////////////////////////////////////////////// |
| 1447 | int CScriptObjectGame::AddCommand(IFunctionHandler *pH) |
| 1448 | { |
| 1449 | int nPCount=pH->GetParamCount(); |
| 1450 | const char *sName; |
| 1451 | const char *sCommand; |
| 1452 | const char *sHelp=NULL; |
| 1453 | int iflags=0; |
| 1454 | pH->GetParam(1,sName); |
| 1455 | if (nPCount>1) |
| 1456 | { |
| 1457 | pH->GetParam(2,sCommand); |
| 1458 | if (nPCount>2) |
| 1459 | { |
| 1460 | if (!pH->GetParam(3,sHelp)) |
| 1461 | sHelp=NULL; |
| 1462 | } |
| 1463 | if (sHelp) |
| 1464 | m_pConsole->AddCommand(sName,sCommand,0,sHelp); |
| 1465 | else |
| 1466 | m_pConsole->AddCommand(sName,sCommand,VF_NOHELP,""); |
| 1467 | } |
| 1468 | |
| 1469 | return pH->EndFunction(); |
| 1470 | } |
| 1471 | |
| 1472 | ////////////////////////////////////////////////////////////////////////// |
| 1473 | int CScriptObjectGame::GetLevelName(IFunctionHandler *pH) |
no test coverage detected