> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XGameRuntimeIsFeatureAvailable

> XGameRuntimeIsFeatureAvailable

# XGameRuntimeIsFeatureAvailable

Indica si una característica del entorno de ejecución de juegos (Gaming Runtime) está disponible.

## Sintaxis

```cpp theme={null}
bool XGameRuntimeIsFeatureAvailable(  
         XGameRuntimeFeature feature  
)  
```

### Parámetros

*feature*   \
Tipo: [XGameRuntimeFeature](https://docs.xbox.com/es/reference/system/xgameruntimefeature/enums/xgameruntimefeature.md)

La característica de Gaming Runtime que se va a consultar.

### Valor devuelto

Tipo: bool

Devuelve **true** si la característica de Gaming Runtime está disponible; de lo contrario, **false**.

## Comentarios

Después de inicializar Gaming Runtime con [XGameRuntimeInitialize](https://docs.xbox.com/es/reference/system/xgameruntimeinit/functions/xgameruntimeinitialize.md), use esta función para comprobar si hay características específicas de Gaming Runtime disponibles para su juego.

En el ejemplo siguiente se usa la función **XGameRuntimeIsFeatureAvailable** para comprobar si las características Async, AsyncProvider y TaskQueue están disponibles. Las tres características son necesarias para usar colas de tareas para ejecutar tareas asincrónicas.

```cpp theme={null}
// Confirm that all of the features needed to run asynchronous tasks on 
// task queues are available.
bool Game::CheckAsyncTaskQueueFeatures()
{
    
    return (XGameRuntimeIsFeatureAvailable(XGameRuntimeFeature::XTaskQueue) &&
        XGameRuntimeIsFeatureAvailable(XGameRuntimeFeature::XAsyncProvider) &&
        XGameRuntimeIsFeatureAvailable(XGameRuntimeFeature::XAsync));

}
```

## Requisitos

**Encabezado:** XGameRuntimeFeature.h

**Biblioteca:** xgameruntime.lib

**Plataformas compatibles:** Windows, consolas de la familia XBOX One y consolas XBOX Series

## Documentación conceptual

* [Introducción a Game Chat 2](https://docs.xbox.com/es/services/xbox-services/multiplayer/chat/game-chat2/game-chat-2-intro.md)

## Consulte también

[Glosario de Gaming Runtime](https://learn.microsoft.com/gaming/gdk/docs/gdk-dev/intro/gaming-runtime-glossary)\
[Clase XGameRuntimeFeature](https://docs.xbox.com/es/reference/system/xgameruntimefeature/xgameruntimefeature_members.md)\
[Enumeración XGameRuntimeFeature](https://docs.xbox.com/es/reference/system/xgameruntimefeature/enums/xgameruntimefeature.md)


## Related topics

- [Referencia de XGameRuntimeFeature](https://docs.xbox.com/es/reference/system/xgameruntimefeature/enums/xgameruntimefeature.md)
- [XGameRuntimeFeature (contenido de la API)](https://docs.xbox.com/es/reference/system/xgameruntimefeature/xgameruntimefeature_members.md)
- [Información general de Windows Sockets](https://docs.xbox.com/es/build/console-features/networking/game-mesh/winsock-intro-networking.md)
- [XSystemRuntimeInfo](https://docs.xbox.com/es/reference/system/xsystem/structs/xsystemruntimeinfo.md)
- [XGameRuntimeInitialize](https://docs.xbox.com/es/reference/system/xgameruntimeinit/functions/xgameruntimeinitialize.md)
