UI - Map Pins

whoward69

DLL Minion
Joined
May 30, 2011
Messages
8,699
Location
Near Portsmouth, UK
"X marks the spot" - enables "pins" to be added to the map

  • Place any number of pins on the map
  • Add "hover" (tooltip) text to the pin
  • 10 pin types (5 coloured flags and 5 others)
  • Edit, move and delete placed pins
  • Toggle all pins on/off (via Shift-X)
  • Pins saved between sessions
  • List of pins added to InfoCorner
  • View, edit, delete pins from InfoCorner list
  • Works in both main map and strategic views
  • Range of Lua events permits pins to be placed and manipulate by other mods

Use Control-X to enter "pinboard mode" - the cursor changes to a green pin pointer (doesn't show in the screen grabs)

Spoiler :


When in "pinboard mode" click on the map to place a pin - a popup dialog prompts for the text to associate with the pin and the "flag" to use



(Use Control-X or Escape to cancel "pinboard mode" without placing a pin)

Moving the mouse over the pin displays the text

Spoiler :


Right-Click on a pin to edit/move/delete it

Spoiler :


Adds an entry to the InfoCorner (top left) to display a list of all pins, sortable by type and notes

Spoiler :


From the pin list, click to view, right-click to edit, shift-right-click to delete



Works in strategic view as well

Spoiler :


Modifies the core game files InfoCorner.lua and InfoCorner.xml, so will be incompatible with any other mod that changes these (although the mod works without the InfoCorner changes, you just lose the Map Pin List functionality)

Edit: For those wanting labels on the map, see this mod "Map Labels"
 
Great work again ! :goodjob:

Just launched a quick hotseat game with it (had to test it in that type of game ;) ) and the pins are shown for all player. Do you think a version with public/private pins is possible ?
 
Great work again ! :goodjob:

Thanks

Just launched a quick hotseat game with it (had to test it in that type of game ;) ) and the pins are shown for all player. Do you think a version with public/private pins is possible ?

Some of us do actually use the Compatibility options in ModBuddy ;)

A hot-seat version is certainly possible (would need to use the same approach as the ResourceIconManager for the pins, and a change to the database table would be needed) - I'll add it the long list of things to do :mischief:

 
Ho, yes, right, I must add a check for the compatibility option in the custom setup mod (to give at least a fair warning to the user on hotseat game launch). My own todo is updated :D
 
Version 2 uploaded - (should) now support Hot Seat (thanks to Gedemon for doing some initial testing)

Also keeps the flag toggle state between sessions (so if you save the game with the flags showing, when you load the game they should still be showing - without the need to Shift-X to turn them on)

Incompatible with games using version 1 (due to a change to the table that stores the flags)
 
Many thanks for that, I'll include the translation in version 3 (coming soon!)

I've added another text entry - "Show/Hide pins" - Google translate is giving me "Anzeigen/Ausblenden Pin"
 
Version 3 uploaded (should be compatible with games using version 2)

General changes
  • Changed the flower "flag" to the star
  • Added check box on list to show/hide pins (Shift-X equivalent)
  • Includes German translation
  • Shift-Right-Click from the pin list now deletes without the confirmation popup (I figured anybody holding the shift key down while right-clicking probably doesn't need to confirm their action!)

API changes
  • Pin text can now contain TXT_KEY_ values
  • Added LuaEvents.MapPins_Visibility and LuaEvents.MapPins_SendVisibility
 
Associated mod uploaded - "UI - Auto Map Pins" -automatically adds map pins for

  • Natural Wonders as they are discovered
  • City States as they are met
  • Unimproved Resources as they are revealed
Requires the "UI - Map Pins" mod to be installed and enabled
 
i was playing with this today (v2) and later on in the game i could not select, delete or edit map pins. i could add them but they were unelectable after that. they did not show up in the panel either. it's like they were ghost pins.

confirmed it does this in v3 as well it happened in under 100 turns this time.
 
later on in the game i could not select, delete or edit map pins.

By right clicking the pin (to bring up the Edit/Move/Delete pop-up menu) or from the Pin List (right-click to edit, shift-right-click to delete) or both?

Presumable if you could still add pins, the Notes/Flag entry pop-up was still working.

Did any Edit/Delete pop-ups appear for the other actions and then not work, or just no menu/dialog pop-ups at all for them?

Approx how many pins did you have at the time?

Also, any other major mods installed?

TIA
 
i'm using nights mod

i couldnt right click the pins but can add more on all pins
 
I can't replicate this, but then I'm not playing with Nights ...

I've uploaded V4, which has a couple of minor bug fixes (getting the previous icon and not translating TXT_KEY_s in the hover over), but also leaves all the debug output switched on

If you feel like it, can you enable logging, load a save game, and then attach the lua.log file when it stops working.

TIA

W
 
i forgot to mention i was adding pins with no labels, text?
 
Shouldn't make a difference - the pin "text" is the control tooltip and the actual control text is the "flag", and you can have controls with no tooltip.
 
Top Bottom