-------------------------------------------------------------------------------- -- Handler.......... : onKeyboardKeyDown -- Author........... : -- Description...... : -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- function FPSMain.onKeyboardKeyDown ( kKeyCode ) -------------------------------------------------------------------------------- if ( kKeyCode == input.kKeyEscape ) then local b = not this.bGameMode ( ) object.sendEvent ( application.getCurrentUserMainCamera ( ), "FPSCamera", "onCaptureInput", b ) this.bGameMode ( b ) else -- Forward to camera -- object.sendEvent ( application.getCurrentUserMainCamera ( ), "FPSCamera", "onKeyboardKeyDown", kKeyCode ) end -------------------------------------------------------------------------------- end --------------------------------------------------------------------------------