# Game Modules Viewer

The `GameModulesViewer` component reveals the live data associated with your Game Modules enabled objects during runtime, and allows for various edit time and run time modifications. This works on Prefabs as well as objects in the Scene!

<figure><img src="https://2431624982-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MY3N_li2jPq7az6mYfq%2Fuploads%2FJ7kR7hRWX1JCqL8Dn31I%2FScreenshot%202024-12-08%20at%204.59.50%E2%80%AFPM.png?alt=media&#x26;token=a78ba748-25af-4a88-899a-d20a5197ef1a" alt=""><figcaption></figcaption></figure>

Any class which has viewable types will be displayed in the Game Modules Viewer inspector. Click each to view and manage their values. In this example from the [**RPG Game Demo**](https://infinitypbr.gitbook.io/infinity-pbr/game-modules/game-module-demo-projects/party-based-rpg), the "Game Data" object has the party stats and quests, along with four entries for each "Actor", who each have their own full set of viewable values.

{% hint style="success" %}
Use the `GameModulesViewer` to add starting [**Stats**](https://infinitypbr.gitbook.io/infinity-pbr/game-modules/module-documentation/stats-and-skills) to your Actors! Now you can pre-set specific Stats and default values on your prefabs and objects to be used when they are instantiated at runtime.
{% endhint %}

## Get Started Fast

1. Add `GameModulesViewer` to any object which has Game Modules data types, incluing the [`GameModulesActor`](https://infinitypbr.gitbook.io/infinity-pbr/game-modules/module-documentation/game-modules-actor) class.
2. View the data directly in the Inspector!

{% embed url="<https://www.youtube.com/watch?v=HEt8DIfVnNc>" %}

## Visible Data Types

The viewer will display `Stat`, `ItemObject`, `ItemAttribute`, `Condition`, `Quest`, and `Dictionaries` data, including individual fields and lists `GameStatList`, `GameConditionList`, `GameItemObjectList`, `GameItemAttributeList`, and `GameQuestList`.

Each type has a various amount of editing capabilities, and various datapoints displayed. The Inspector script will update each frame, so you can see data changes as they happen.

Check out the pages for each data type to learn more.

## Gear Icon

Many types have a "Gear" icon. Clicking this will expand options for that `GameModulesList` type.

<figure><img src="https://2431624982-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MY3N_li2jPq7az6mYfq%2Fuploads%2FVnFpi9aIBLUe8sXV2qcL%2FScreenshot%202024-12-08%20at%204.30.25%E2%80%AFPM.png?alt=media&#x26;token=e9271a90-87e1-4347-9e72-dbdb36515b99" alt=""><figcaption></figcaption></figure>

These can also be set by viewing the normal `List` in the Inspector. They are provided here to improve quality of life!
