Location Selector

Overview

Similar to the player selector, the BP_DeviceModule_LocationSelector allows for selecting a location through a number of means:

  • Manual selection: click at a location, that will be used as the location selected

  • "Your location": your character's current location will be used

  • "Marked locations": you can add actors into the world which are used as "marked locations" which will show up in this list. For more details, see Marked Locations.

  • "World list": returns the list of deployments you can world travel to.

Usage

To use this selector, add it to your item executor's button data. It will then show up in your item controls' button list.

Be sure to enable your module on Event Initialize Executor, and clean it up in Event Tear Down Executor, using SetEnabled and TearDownOnClient respectively.

Configuring the module data

The fields to customize within the location selector module are as follows:

  • ClearOptionsOnSelect - if true, once you have made a selection, the options are cleared immediately. Use this if you want selecting the location to trigger the item's effect. (If you have it false, you can select the location, then trigger the ability separately)

  • AllowManualSelection - if true, you can click on locations in the world, and treat that as the location.

  • AllowSelectSelf - provides the "Your location" option

  • AllowMarkerSelection - shows the "Marked Locations" list

  • AllowWorldSelection - shows the "World List" option.

  • ShortcutAction/ShortcutMapping - controls what button is used for making manual selections. The recommended shortcuts are IA_PresenterSelector1/2 which are bound to left and right click respectively.

Listen to selection events

Depending on what kind of selection you're using, there are different events you can bind to:

  • OnSelectManual - called when a location is selected manually. Provides the vector of the clicked point.

  • OnSelectMarker - called when you select a "marked location" option. Provides the BPM_LocationMarker actor.

  • OnSelectWorld - called when a world list option is selected. Provides the J_WorldTravelWorld details for the selected world.

  • OnSelectOwnLocation - called when the "your location" option is selected.

Marked Locations

We can mark in-world locations using actors extending BPM_LocationMarkerBase. These are then collected, and can be selected as locations for e.g. navigation. Each provides a Location Name, and provides some methods to get details about the marker, e.g. its centre, and how to get a valid location within its area. There are currently two types (but more could be added):

  • BPM_LocationMarkerSphere - the location has a radius around it which is considered valid.

  • BPM_LocationMarkerPolygon - allows you to make a marker shaped by an arbitrary polygon, for more complex areas

Last updated