Open klingbolt opened 1 year ago
Some brainstorming:
Category.name
- Is not used in the proto now that icons and trails are nested
Category.display_name
should be used to infer what name
should be when writing to xml without name otherwise setCategory.display_name
should also be renamed to Category.name
Icon.texture_path
, Trail.texture_path
- is possibly a highly duplicated string, existing on every icon and trail that uses the same texture
Icon.rgba_color
Trail.rgba_color
should have "white" as the default value
#00000000
and #FFFFFFFF
equivalent. We already have precedent for not allowing all 0's in the filter messages. Where if they are all left as false then no filters are applied.(#FFFFFFFF - color)
which would mean #FFFFFFFF
becomes #00000000
and visa versa.#FFFFFFFF
and #00000000
specifically so they represent each other. This adds some hidden complexity. Probably the worst option so far.Icon.can_fade
Trail.can_fade
- should default to false
prevent_fading
and add inversion logic in converteralways_visible
and add inversion logic in converterrender_over_player
and add inversion logic in converterCategory.default_visibility
- should default to false
hidden_by_default
and add inversion logic in converterhide_by_default
and add inversion logic in converterIcon.distance_fade_start
Trail.distance_fade_start
- should default to 0, currently the default is 700.
if N < 0:
default / POW((10/9), -N/100)
else
default * POW((10/9), N/100)
Icon.distance_fade_end
Trail.distance_fade_end
- should default to 0, currently the default is 900.
distance_fade_duration
and use as a distance from distance_fade_start
(still would have a default problem of 200)distance_fade_length
and use as a distance from distance_fade_start
(still would have a default problem of 200)Icon.height_offset
- Should default to 0, currently the default is 1.5
Icon.tentative__scale
should become Icon.scale
and default to zero
Icon.scale
Trail.scale
- should default to 0, currently default to 1POW((10/9), -N/100)
algorithm above0
be an invalid value and any 0
or missing values become 1
as scale to 0 does not make senseIcon.map_display_size
, Trail.map_display_size
- default is 20
Icon.scale_on_map_with_zoom
should default false, currently true
constant_size_on_map
and add inversion logic in converterignore_map_zoom_scale
and add inversion logic in converterIcon.minimum_size_on_screen
- Should default to 0, currently the default is 5.
Icon.maximum_size_on_screen
- Should default to 0, currently the default is 2048. Maybe change to be a delta or scale of the images original size.
Trigger.range
- should default to 0, currently defaults to 2 ?
Icon.category
, Trail.category
- no longer needed in the proto because everything is hierarchical
Category.name
s of the parents should be used to infer the value when parsing the proto
The current
.proto
file was written based on the way data is stored in the XML files, but we aren't restricted to that. The following is a list of improvements that can be made to either improve data storage in the protobuf formatted files or improve the performance of the Godot code. Many on this list will be changing the code so that a default value is always stored as 0 if possible and that both the XML Converter and Burrito handle the default value correctly. This list includes the current default values if applicable.The following fields could be improved if the default value is stored in the proto file as 0 where both Burrito and xml_converter know that "0" should be interpreted as the default value. For now, these values are not implemented in burrito, so we are going to comment them out in the proto. They can be re-enabled once a solution is found to keep track of default values in xml_converter.