No edit summary |
No edit summary |
||
(5 intermediate revisions by the same user not shown) | |||
Line 265: | Line 265: | ||
|→ state | |→ state | ||
|string | |string | ||
|State reference: | |State reference: | ||
* ASSEMBLY , representing construction time, show to players in the game client and taken into account when MEL calculates pressures to be fed into the EwE model at hand. See the [[MEL configuration data schema|MEL ecosystem simulation configuration page]]. | |||
* ACTIVE , originally proposed for different ideas. But as yet not implemented. | |||
* DISMANTLE , originally meant to represent the demolishing/removal time for geometry set for deletion. But as yet not implemented. | |||
|- | |- | ||
|→ time | |→ time | ||
Line 294: | Line 298: | ||
|string | |string | ||
|Optional string of the layer geometry feature property that should be read when determining the type, as further defined under layer_type below. Null if irrelevant. | |Optional string of the layer geometry feature property that should be read when determining the type, as further defined under layer_type below. Null if irrelevant. | ||
For example, let's say the geodata layer in question provides points of all the cities around the sea area in question, and each point has a data property called 'country' indicating the country the city belongs to. By setting this layer_property_as_type variable to 'name', you can then map the country names to types using layer_type > map_type (see further below). | |||
|- | |- | ||
|layer_type | |layer_type | ||
Line 310: | Line 315: | ||
|→ value | |→ value | ||
|int | |int | ||
|The highest value of a raster cell. Minimum 0, maximum 255 (requiring layer_entity_value_max to be set to 255.0) or 1000 (default, no layer_entity_value_max setting required). | |Used in two ways: | ||
# The highest value of a raster cell. Minimum 0, maximum 255 (requiring layer_entity_value_max to be set to 255.0) or 1000 (default, no layer_entity_value_max setting required). | |||
# If the layer at hand is defined as the countries layer (see [[Configuration data schema|datamodel > countries]]), then this value is used as the country identifier, and the minimum value has to be 3 (because values 1 and 2 are reserved for the administrator and region manager 'countries'/teams). | |||
|- | |- | ||
|→ map_type | |→ map_type | ||
|string | |string | ||
|Optional, but required when layer_property_as_type is not null, representing the value of the layer's geometry feature property defined under layer_property_as_type that should be mapped to this type. Null if irrelevant. Can be 'other' indicating a 'catch-all' type if none of the other types can be mapped to. Can also be an integer or float/decimal range, without spaces, and using - (dash) as a separator. E.g. 10-20. | |Optional, but required when layer_property_as_type is not null, representing the value of the layer's geometry feature property defined under layer_property_as_type that should be mapped to this type. Null if irrelevant. Can be 'other' indicating a 'catch-all' type if none of the other types can be mapped to. Can also be an integer or float/decimal range, without spaces, and using - (dash) as a separator. E.g. 10-20. | ||
Returning to the city points example explained above under layer_property_as_type: you could now map all cities of specific countries to this type by setting map_type to the country string at hand. So, for example, by setting map_type to 'UK', all city points in the original geodata with the 'country' data property set to 'UK' would become this type. | |||
|- | |- | ||
|→ displayPolygon | |→ displayPolygon | ||
Line 326: | Line 335: | ||
|→ polygonPatternName | |→ polygonPatternName | ||
|string (of int) | |string (of int) | ||
|Pattern used (if the name does not exist, or string is empty, then the default pattern is used). This is a string representation of an integer. | |Pattern used (if the name does not exist, or string is empty, then the default pattern is used). This is a string representation of an integer. | ||
A [[Polygon pattern list|full list of values and the patterns they represent]] is available. | |||
A full list is | |||
|- | |- | ||
|→ innerGlowEnabled | |→ innerGlowEnabled |
Latest revision as of 09:21, 1 May 2024
meta
Defining vector and raster data layers that should be shown in the appropriate left-hand side menu and might be referred to elsewhere in the configuration file.
More information about what data layers to use can be found here and here.
We also note that all editions require a layer which name starts with '_PLAYAREA', depicting basically the 'bounding box' of all data (literally the play area of the players). More information about that can be found here.
"meta": [ { "layer_name": "_PLAYAREA_NS", "layer_geotype": "polygon", "layer_entity_value_max": null, "layer_short": "", "layer_category": "management", "layer_subcategory": "governance", "layer_download_from_geoserver": 1, "layer_width": 1024, "layer_height": 1024, "layer_raster_material": "RasterMELNew", "layer_raster_filter_mode": 1, "layer_raster_color_interpolation": 0, "layer_raster_pattern": "Default", "layer_raster_minimum_value_cutoff": 0.05, "layer_active": 1, "layer_selectable": 1, "layer_editable": 0, "layer_toggleable": 1, "layer_active_on_start": 0, "layer_green": 0, "layer_tooltip": "", "layer_information": "", "layer_media": null, "layer_text_info": null, "layer_states": [ { "state": "ASSEMBLY", "time": 0 }, { "state": "ACTIVE", "time": 10 }, { "state": "DISMANTLE", "time": 2 } ], "layer_editing_type": "", "layer_special_entity_type": "Default", "layer_depth": 1, "layer_property_as_type": null, "layer_type": { "0": { "displayName": "default", "approval": "EEZ", "value": 0, "map_type": null, "displayPolygon": 1, "polygonColor": "#6CFF1C80", "polygonPatternName": "0", "innerGlowEnabled": 0, "innerGlowRadius": 0, "innerGlowIterations": 0, "innerGlowMultiplier": 0.0, "innerGlowPixelSize": 3.0, "displayLines": 1, "lineColor": "#7AC943FF", "lineWidth": 0.0, "lineIcon": null, "linePatternType": "Solid", "displayPoints": 0, "pointColor": "#7AC943FF", "pointSize": 0.0, "pointSpriteName": "None", "description": "", "capacity": 0, "investmentCost": 0.0, "availability": -12, "media": "" } }, "layer_info_properties": [ { "property_name": "id", "enabled": 1, "editable": 0, "display_name": "", "sprite_name": null, "update_visuals": false, "update_text": false, "update_calculation": false, "content_type": 0, "content_validation": 0, "unit": null, "default_value": null } ], "layer_tags": [ "Polygon" ] } ]
Field | Type | Description |
---|---|---|
layer_name | string | Name of the data layer. Not the display name, but the actual geodata name. If the layer data should be downloaded from GeoServer (see layer_download_from_geoserver), then this value will be used in the GeoServer API call. So make sure a layer exists on GeoServer with the name you enter here. Another reference to the value entered here is datamodel > countries. |
layer_geotype | string | Type of geometry. Possible values: "polygon", "point", "line", "raster" |
layer_entity_value_max | float | Optional, representing the highest greyscale (black to white) value of a raster cell. Default is 1000.0, also when set to null. Other logical value is 255.0. |
layer_short | string | What is the in-game name of the layer |
layer_category | string | What category is this layer part of |
layer_subcategory | string | What subcategory is this layer part of |
layer_download_from_geoserver | int | Should GeoServer be called to attempt to obtain the layer data (regardless of the type)? 0 for no, 1 for yes (so the int functions as a boolean) |
layer_width | int | width of the raster (Not sure if still used) |
layer_height | int | Height of the raster (Not sure if still used) |
layer_raster_material | string | Name of the shader used for this raster. For more information, check this raster shader index page. |
layer_raster_filter_mode | int | 0 or 1, so int functions as a boolean. |
layer_raster_color_interpolation | int | Used to setup the gradient for raster layers.
Two options:
|
layer_raster_pattern | string | The pattern used by the raster file, this can remain on Default most of the time.
Other values presumably supported, but seemingly unused at the moment: MEL_pattern, MEL_pattern_dense, MEL_pattern_dense2 |
layer_raster_minimum_value_cutoff | float | The value where the raster drawing starts, this can be handy if the first part of the raster file should be transparent |
layer_active | int | 0 or 1, functioning as a boolean. If inactive, then the layer wont be loaded by the server |
layer_selectable | int | 0 or 1, functioning as a boolean. Can the layer be selected by the player (properties window) |
layer_editable | int | 0 or 1, functioning as a boolean. Can the layer be edited by the player |
layer_toggleable | int | 0 or 1, functioning as a boolean. Can the layer be toggled by the player (on/off) |
layer_active_on_start | int | 0 or 1, functioning as a boolean. Is the Layer on by default when the game starts? (Countries, Bathymetry, EEZ) |
layer_green | int | 0 or 1, functioning as a boolean. Used by the CEL energy simulation. If the layer has a CEL energy simulation specific value under layer_editing_type (see below), then this variable defines whether it is part of the green / renewable or grey / non-renewable energy simulation. |
layer_tooltip | string | Additional information shown when hovering over a layer in the client windows. |
layer_information | string | Unsure, likely unused in favour of layer_media (see next row). |
layer_media | string | link to the wiki page of this layer. The base URL is set in datamodel > wiki_base_url. The string must always be: "wiki://"+PageName e.g. "wiki://NS_EEZ" |
layer_text_info | object | Can be null. Otherwise the below are required, with which the text to be shown at the geometry on the map when a sufficient zoom level has been reached in the client by the player/user (see zoom_cutoff. Typically used with CEL energy simulation specific layers (e.g. wind farm areas) to show the capacity or usage in Watt, ports to show their names, or cities to show their names. |
→ property_per_state | object | Allows you to specify which fixed or geometry data property/variable available to the client should be shown on the map during different viewing states in the client. More specifically:
|
→→ Current | string | When viewing the sea basin in its current state (i.e., the current simulated month, so not looking back or ahead), which fixed or geometry data property/variable's value should be shown on the map. E.g. 'name'. |
→→ View | string | When viewing a plan (i.e., looking ahead at the plan's implementation date), which fixed or geometry data property/variable's value should be shown on the map. E.g. 'name'. |
→→ Edit | string | When editing a plan by means of creating/changing/removing geometry (so plan edit mode, still looking ahead at the plan's implementation date), which fixed or geometry data property/variable's value should be shown on the map. E.g. 'name'. |
→ text_color | string | Hexadecimal colour code (last two digits representing transparency) of the text as defined above to be shown next to the geometry. |
→ text_size | string | Size of the text to be shown Can be:
XS , for extra small S , for small M , for medium L , for large XL , for extra large |
→ zoom_cutoff | float | At which zoom level should the text as defined above no longer be shown next to the geometry. |
→ x | float | Horizontal position of the text as defined above to be shown next to the geometry. |
→ y | float | Vertical position of the text as defined above to be shown next to the geometry. |
→ z | float | Height/depth position of the text as defined above to be shown next to the geometry. |
layer_states | object[] | How long the geometry remains in a specific state |
→ state | string | State reference:
|
→ time | int | Time in months the state should last |
layer_editing_type | string | Type definition for particularly the CEL energy simulation.
CEL specific values (self-explanatory, but see also the CEL energy simulation documentation): cable, transformer, socket, sourcepoint, sourcepolygon Other values:
|
layer_special_entity_type | string | At one time, setting this to ShippingLine had an effect on the SEL shipping simulation. This is most likely no longer the case, because the SEL configuration has its own shipping_lane_layers definition to cover this. At the moment, the only remaining option is Default, which has no consequence. This variable might be deprecated. |
layer_depth | int | Layering position, the higher the number the further on top (2 = in front of 1) |
layer_property_as_type | string | Optional string of the layer geometry feature property that should be read when determining the type, as further defined under layer_type below. Null if irrelevant.
For example, let's say the geodata layer in question provides points of all the cities around the sea area in question, and each point has a data property called 'country' indicating the country the city belongs to. By setting this layer_property_as_type variable to 'name', you can then map the country names to types using layer_type > map_type (see further below). |
layer_type | object[] (with keys) | Defining which types this particular layer should have (minimum one, first key should always be 0). The keys of this list are referenced elsewhere in the configuration file, notably in MEL > pressures > name and in restrictions > starttype or endtype. |
→ displayName | string | The name of the type being defined here that the user will actually see. These are also referenced elsewhere in the configuration file, notably in SEL > restriction_layer_exceptions > layer_type and also > layer_type_ship_type_mapping > layer_type. |
→ approval | string | does this layer need to be approved by: EEZ, Region Manager/Admin, All Countries (IMO Routes), or not at all:
EEZ, AreaManager, AllCountries, NotDependent |
→ value | int | Used in two ways:
|
→ map_type | string | Optional, but required when layer_property_as_type is not null, representing the value of the layer's geometry feature property defined under layer_property_as_type that should be mapped to this type. Null if irrelevant. Can be 'other' indicating a 'catch-all' type if none of the other types can be mapped to. Can also be an integer or float/decimal range, without spaces, and using - (dash) as a separator. E.g. 10-20.
Returning to the city points example explained above under layer_property_as_type: you could now map all cities of specific countries to this type by setting map_type to the country string at hand. So, for example, by setting map_type to 'UK', all city points in the original geodata with the 'country' data property set to 'UK' would become this type. |
→ displayPolygon | int | 0 or 1, functioning as a boolean. is the polygon fill displayed (only possible for polygon geometry) |
→ polygonColor | string | Hexadecimal colour code (last two digits representing transparency) of the polygon. Has to start with hash #. |
→ polygonPatternName | string (of int) | Pattern used (if the name does not exist, or string is empty, then the default pattern is used). This is a string representation of an integer.
A full list of values and the patterns they represent is available. |
→ innerGlowEnabled | int | 0 or 1, functioning as a boolean. is there an inner glow on the polygon. This is currently used for EEZs, for example, to make it easier for users to see the EEZ polygons, representing their country's/team's planning area. |
→ innerGlowRadius | int | Size of the glow as it radiates out. |
→ innerGlowIterations | int | One of the ways to set up the strength of the glow. |
→ innerGlowMultiplier | float | One of the ways to set up the strength of the glow. |
→ innerGlowPixelSize | float | One of the ways to set up the strength of the glow. |
→ displayLines | int | 0 or 1, functioning as a boolean. Are the lines displayed (possible for Poly and Line data) |
→ lineColor | string | Hexadecimal colour code (last two digits representing transparency) of the line. Has to start with hash #. |
→ lineWidth | int | width of the line |
→ lineIcon | string | Currently always null. Not implemented. |
→ linePatternType | string | Pattern used (if the name does not exist, or string is empty, then the default pattern is used).
Known values: Solid, ShortDash, LongDash |
→ displayPoints | int | 0 or 1, functioning as a boolean. Are the points displayed (possible for Point, Poly and Line data). |
→ pointColor | string | Hexadecimal colour code (last two digits representing transparency) of the point. Has to start with hash #. |
→ pointSize | int | determines the point size, should always be >1, even for Poly and Line data, since this determines the size for the editable points. |
→ pointSpriteName | string | sprite used (nothing = regular dot) |
→ description | string | short description of the layer type, can be displayed when hovering over the type in the active layer window |
→ capacity | int | Used for calculations by the CEL energy simulation. The value here determines the maximum energy passthrough or production capacity in Watt. |
→ investmentCost | int | costs for planning this type (currently unused, planned to uses for assigning planning points) |
→ availability | int | In what year will the type should become available for use in plans, based on the start year of the game (see metadata > start). Set to 0 is irrelevant (i.e., the type should always be available).
Always make sure that (for editable layers) the first type of the layer is available before the game's starting date (so best to set to 0 for type 0). Otherwise players will be able to edit non-available types, since the system auto-selects the first type for editing. |
→ media | string | link to the wiki page of this layer type. The base URL is set in datamodel > wiki_base_url. The string must always be: "wiki://"+PageName e.g. "wiki://Ferry" |
layer_info_properties | object[] | Defining what and how feature property data should be shown to the user when clicking on the feature on the map. |
→ property_name | string | The feature property present in the data table of this layer's source data. |
→ enabled | int | 0 or 1 (so integer representation of a boolean) representing whether this feature property should be shown to the user at all. |
→ editable | int | 0 or 1 (so integer representation of a boolean) representing whether the user should be able to change feature property value. NOT IMPLEMENTED. |
→ display_name | string | The name that should replace the original property_name when showing it to the user (requires enabled to be 1). |
→ sprite_name | null | NOT IMPLEMENTED |
→ update_visuals | bool | Always false, NOT IMPLEMENTED |
→ update_text | bool | Always false, NOT IMPLEMENTED |
→ update_calculation | bool | Always false, NOT IMPLEMENTED |
→ content_type | int | Always 0, NOT IMPLEMENTED |
→ content_validation | int | Always 0, NOT IMPLEMENTED |
→ unit | null | NOT IMPLEMENTED |
→ default_value | string | representing what to show in case the source feature property data's value is null. |
layer_tags | string[] | Tags used by Procedural Ocean to determine how to show this layer data and what to enable on it.
Documented separately on this layer tag definition page. |
Back to the main configuration schema page.