HleSemaphore GetSemaphoreById(SemaphoreId SemaphoreId) { try { return SemaphoreManager.Semaphores.Get((int)SemaphoreId); } catch (KeyNotFoundException) { throw (new SceKernelException(SceKernelErrors.ERROR_KERNEL_NOT_FOUND_SEMAPHORE)); } }