Show / Hide Table of Contents

Class MinimapManager

Manager for adding custom Map Overlays to the game.
Inheritance
System.Object
MinimapManager
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Jotunn.Managers
Assembly: Jotunn.dll
Syntax
public class MinimapManager : IManager

Fields

| Improve this Doc View Source

FilterOff

Colour which sets a filter off. See FilterOn.
Declaration
public static Color FilterOff
Field Value
Type Description
Color
| Improve this Doc View Source

FilterOn

Colour which sets a filter on. Used for ForestFilter and FogFilter. A full alpha value enables this pixel, and then the red value is written to the result texture.
Declaration
public static Color FilterOn
Field Value
Type Description
Color
| Improve this Doc View Source

MeadowHeight

Height "Colour" used for the base height of "Meadows"
Declaration
public static Color MeadowHeight
Field Value
Type Description
Color

Properties

| Improve this Doc View Source

Instance

The singleton instance of this manager.
Declaration
public static MinimapManager Instance { get; }
Property Value
Type Description
MinimapManager

Methods

| Improve this Doc View Source

GetDrawingNames()

Return a list of all current MapDrawing names
Declaration
public List<string> GetDrawingNames()
Returns
Type Description
System.Collections.Generic.List<System.String> List of names
| Improve this Doc View Source

GetMapDrawing(String)

Create a new MapDrawing with a custom overlay name
Declaration
public MinimapManager.MapDrawing GetMapDrawing(string name)
Parameters
Type Name Description
System.String name Custom name for the MapDrawing
Returns
Type Description
MinimapManager.MapDrawing Reference to MapDrawing for modder to edit
| Improve this Doc View Source

GetMapOverlay(String, Boolean)

Create a new MapOverlay with a custom overlay name
Declaration
public MinimapManager.MapOverlay GetMapOverlay(string name, bool ignoreFog = false)
Parameters
Type Name Description
System.String name Custom name for the MapOverlay
System.Boolean ignoreFog When set to true, that layer will be drawn regardless of exploration status, defaults to false
Returns
Type Description
MinimapManager.MapOverlay Reference to MapOverlay for modder to edit
| Improve this Doc View Source

GetOverlayNames()

Return a list of all current overlay names
Declaration
public List<string> GetOverlayNames()
Returns
Type Description
System.Collections.Generic.List<System.String> List of names
| Improve this Doc View Source

Init()

Creates the Overlays and registers hooks.
Declaration
public void Init()
| Improve this Doc View Source

OverlayToWorldCoords(Vector2, Int32)

Input a MapOverlay Coordinate and the size of the overlay texture to retrieve the translated World coordinates.
Declaration
public Vector3 OverlayToWorldCoords(Vector2 input, int texSize)
Parameters
Type Name Description
Vector2 input The 2D Overlay coordinate
System.Int32 texSize The size of the Overlay
Returns
Type Description
Vector3 The 3D World coordinate that corresponds to the input Vector
| Improve this Doc View Source

RemoveMapDrawing(String)

Causes MapManager to stop updating the MapDrawing object and removes this Manager's reference to that drawing.
Declaration
public bool RemoveMapDrawing(string name)
Parameters
Type Name Description
System.String name The name of the MapDrawing to be removed
Returns
Type Description
System.Boolean True if removal was successful. False if there was an error removing the object from the internal dict.
| Improve this Doc View Source

RemoveMapOverlay(String)

Causes MapManager to stop updating the MapOverlay object and removes this Manager's reference to that overlay.
Declaration
public bool RemoveMapOverlay(string name)
Parameters
Type Name Description
System.String name The name of the MapOverlay to be removed
Returns
Type Description
System.Boolean True if removal was successful. False if there was an error removing the object from the internal dict.
| Improve this Doc View Source

WorldToOverlayCoords(Vector3, Int32)

Input a World Coordinate and the size of the overlay texture to retrieve the translated overlay coordinates.
Declaration
public Vector2 WorldToOverlayCoords(Vector3 input, int texSize)
Parameters
Type Name Description
Vector3 input World Coordinates
System.Int32 texSize Size of the image from your MapOverlay
Returns
Type Description
Vector2 The 2D coordinate space on the MapOverlay

Events

| Improve this Doc View Source

OnVanillaMapAvailable

Event that gets fired once the Map for a World has started and Mods can begin to draw.
Declaration
public static event Action OnVanillaMapAvailable
Event Type
Type Description
System.Action
| Improve this Doc View Source

OnVanillaMapDataLoaded

Event that gets fired once data for a specific Map for a world has been loaded. Eg, Pins are available after this has fired.
Declaration
public static event Action OnVanillaMapDataLoaded
Event Type
Type Description
System.Action

Extension Methods

PrefabExtension.FixReferences(Object)
  • Improve this Doc
  • View Source
☀
☾
In This Article
Back to top
Generated by DocFX
☀
☾