skip to Main Content

General map events

public event OnMouseClick OnClick; 
public event OnMouseClick OnMouseDown; 
public event OnMouseClick OnMouseRelease; 
public event OnMouseEvent OnMouseMove; 
public event OnSimpleMapEvent OnFlyTo; 
public event OnSimpleMapEvent OnFlyEnd;

Country events

public event OnCountryEvent OnCountryEnter; 
public event OnCountryEvent OnCountryExit; 
public event OnCountryClick OnCountryClick; 
public event OnCountryHighlight OnCountryHighlight;

Province events

public event OnProvinceEvent OnProvinceEnter; 
public event OnProvinceEvent OnProvinceExit; 
public event OnProvinceClick OnProvinceClick; 
public event OnProvinceHighlight OnProvinceHighlight;

Region (country or province) events

public event OnRegionClickEvent OnRegionClick; 
public event OnRegionEnterEvent OnRegionEnter; 
public event OnRegionEnterEvent OnRegionExit;

City Events

public event OnCityEnter OnCityEnter; 
public event OnCityEnter OnCityExit; 
public event OnCityClick OnCityClick;

Grid Cell events

public event OnCellEnter OnCellEnter; 
public event OnCellExit OnCellExit; 
public event OnCellClick OnCellClick;

Path-finding events

public event OnPathFindingCrossPosition OnPathFindingCrossPosition; 
public event OnPathFindingCrossAdminEntity OnPathFindingCrossCountry; 
public event OnPathFindingCrossAdminEntity OnPathFindingCrossProvince; 
public event OnPathFindingCrossAdminEntity OnPathFindingCrossCell;

Events associated with gameobjects added to the map

public Action<GameObjectAnimator> OnVGOPointerDown; 
public Action<GameObjectAnimator> OnVGOPointerUp; 
public Action<GameObjectAnimator> OnVGOPointerEnter; 
public Action<GameObjectAnimator> OnVGOPointerDown; 
public Action<GameObjectAnimator> OnVGOMoveStart; 
public Action<GameObjectAnimator> OnVGOMove; 
public Action<GameObjectAnimator> OnVGOMoveEnd; 
public Action<GameObjectAnimator> OnVGOCountryEnter; 
public Action<GameObjectAnimator> OnVGOCountryRegionEnter; 
public Action<GameObjectAnimator> OnVGOProvinceEnter; 
public Action<GameObjectAnimator> OnVGOProvinceRegionEnter; 
public Action<GameObjectAnimator> OnVGOKilled;

Events associated with sprites and 3D markers added to the map

Check demo scenes “501 Viewport Intro” (add clickable sprite) or “517 Markers Clicking”) for working examples:

map.AddMarker2DSprite(star, planeLocation, 0.02f, enableEvents:true); // you can also use map.AddMarker3DObject with events
map.OnMarkerMouseDown += (buttonIndex => Debug.Log("Click on sprite with button " + buttonIndex + "!"));

public OnMarkerPointerClickEvent OnMarkerMouseDown; 
public OnMarkerPointerClickEvent OnMarkerMouseUp; 
public OnMarkerEvent OnMarkerMouseEnter; 
public OnMarkerEvent OnMarkerMouseExit; 
public OnMarkerEvent OnMarkerDragStart; 
public OnMarkerEvent OnMarkerDragEnd;
Back To Top