# Graphics.Blit VRChat SDK Example: MiniMap

This is a simple MiniMap implementation using the new addition to Udon - Graphics.Blit.

## Sample Scene

The sample scene is located inside the Samples folder. It contains a simple scene with a minimap Pickup and an environment to walk around.

## Usage

To use the MiniMap in your own scene - do the following:
- Open the "Runtime" folder
- Put the either of MiniMap Graph or MiniMap USharp prefabs into your scene
- Put the MiniMap Pickup prefab into your scene
- Expand the main MiniMap prefab and position the camera in a way that captures your whole scene
  - Adjust the size and Clipping distance to your liking
- You should be able to press play and see yourself move around the world on the MiniMap pickup!

## Custom Events

Both the U# and Udon Graph variants of the Prefab expose a couple of events that you might find useful

- `_RecatpureScene`: Uses the camera to capture the scene again. This allows you to move camera to a different area. Calling this event will update the MiniMap to show this new area instead.
- `_UpdateSettings`: Use this event if you change any of the settings on the MiniMap prefab with Udon. This will update the MiniMap to reflect the new settings.
- `_ShowOthersToggle`: Use this event to toggle the visibility of other players on the MiniMap. This requires "Allow to show others" option to be enabled.
  - `_ShowOthersOn` and `_ShowOthersOff`, do the same thing as the `Toggle` variant, but allow explicitly enabling or disabling this functionality


