Mini Map Handler

Description

MiniMapHandler is a system that manages the registration and unregistration of minimap components. It functions online without the need to add any PhotonView components. This component serves as the heart of the system and handles the initialization and management of minimap UI objects.

MiniMapHandler is a versatile component that allows you to manage and customize the behavior and appearance of a minimap in your game. Adjust the variables according to your specific requirements for minimap functionality, such as using baked maps, rendering live maps, and setting up UI and world anchor references.

Inspector Fields

Mini Map Game Object

Type: GameObject

Description: The GameObject that is the parent of the minimap UI. If set to null, the MiniMapHandler component will default to using itself as the parent.

Default Value: null

Auto Initialize

Type: bool

Description: Determines whether this component should be automatically initialized along with any registered UI objects.

Default Value: true

Icon Prefab

Type: GameObject

Description: The prefab to spawn for registered minimap objects as icons.

Default Value: null

Shape Colliders

Type: Collider2D[]

Description: The colliders used for clamping icons on the minimap. Multiple colliders can be provided, allowing for custom-shaped maps.

Default Value: null

Shape Collider Index

Type: int

Description: The index of the shape collider to use for clamping icons on the minimap.

Default Value: 0

Border

Type: Sprite

Description: The border image of the minimap.

Default Value: null

Use Border As Map Texture

Type: bool

Description: Set this to true if you want to use the border image as the baked minimap texture.

Default Value: null

Map Mask

Type: Sprite

Description: The mask for the minimap display.

Default Value: null

Border Opacity

Type: float

The opacity of the minimap border.

Default Value: 1f

Map Opacity

Type: float

The opacity of the minimap.

Default Value: 1f

Map Scale

Type: Vector3

Description: Scale factor for the minimap and the icons.

Default Value: new Vector3(0, 0, 0) (Default uniform scale)

Only Scale Border

Type: bool

Description: If true, only the border of the minimap will be scaled.

Default Value: false

Hide Boarded Icons

Type: bool (optional, requires Ultimate Seating Controller)

Description: If true, any boarded character icons will be hidden.

Default Value: true

Note: Only avaible if Ultimate Seating Controller is installed.

Use Baked Map

Type: bool

Description: Set this to true if you will not use a render texture or render camera and want to use a baked map.

Default Value: false

Move Map

Type: bool

Description: Determines whether the map should move with the local player’s character.

Default Value: true

Baked Map

Type: Sprite

Description: The baked map image to use if you’re not using a render texture or render camera.

Default Value: null

UI Anchor Reference A

Type: RectTransform

Description: The UI anchor reference A position on the UI map that is relative to the world anchor reference A.

Default Value: null

UI Anchor Reference B

Type: RectTransform

Description: The UI anchor reference B position on the UI map that is relative to the world anchor reference B.

Default Value: null

World Anchor Reference A

Type: Transform

Description: The position in the world where the UI anchor reference A will match in the minimap.

Default Value: null

World Anchor Reference B

Type: Transform

Description: The position in the world where the UI anchor reference B will match in the minimap.

Default Value: null

Mini Map Render Material

Type: Material

Description: The material used for rendering the live minimap.

Default Value: null

Render Layers

Type: LayerMask

Description: Determines which layers to show in the minimap.

Default Value: Default

Camera Offset

Type: Vector3

Description: The offset of the camera from the target.

Default Value: Vector3(0, 20f, 0)

Camera Render Size

Type: float

Description: The orthographic size of the camera.

Default Value: 20f

Camera Far Clip Plane

Type: float

Description: The far clip plane of the camera.

Default Value: 1000f

Camera Rotation

Type: Vector3

Description: The rotation of the camera.

Default Value: Vector3.zero

Rotate Map With Local Player

Type: bool

Description: If true, the camera rotates according to the local player’s rotation.

Default Value: false

What are your feelings
Updated on August 14, 2023