| 389 | } |
| 390 | |
| 391 | int CScriptObjectInput::ResetKeyState(IFunctionHandler *pH) |
| 392 | { |
| 393 | if(!m_pInput) |
| 394 | return pH->EndFunctionNull(); |
| 395 | |
| 396 | if (pH->GetParamCount() > 0) |
| 397 | { |
| 398 | char *szKeyName = 0; |
| 399 | |
| 400 | if (pH->GetParam(1, szKeyName)) |
| 401 | { |
| 402 | m_pInput->GetIKeyboard()->ClearKey(m_pInput->GetKeyID(szKeyName)); |
| 403 | |
| 404 | return pH->EndFunction(); |
| 405 | } |
| 406 | } |
| 407 | |
| 408 | m_pInput->ClearKeyState(); |
| 409 | |
| 410 | return pH->EndFunction(); |
| 411 | } |
| 412 | /*! set the inverted mouse state |
| 413 | @param bEnable !=nil(enabled) nil(disabled) |
| 414 | */ |
nothing calls this directly
no test coverage detected