Change how a station trait is declared abstract (#80268)

## About The Pull Request

@Fikou requested this and it seemed like a good idea.
This change the pattern for "how we declare that we don't want a station
trait to actually exist" from "it's a bitfield" to the other
commonly-used pattern of "it's a var which points at a typepath".
The purpose of doing this is that most of the station traits which have
an abstract parent want the default `trait_flags` value of their
grandparent and have to redeclare it for no reason, which becomes more
tedious the more children there are. This means that you don't need to
do that because the `abstract_type` var will only evaluate to true when
checked on the specified abstract type, without needing to change its
value on any children.

## Why It's Good For The Game

Makes extending traits marginally easier

## Changelog

not player facing
This commit is contained in:
Jacquerel
2023-12-12 22:46:12 +00:00
committed by GitHub
parent 160dcc5109
commit 659a343dbf
6 changed files with 11 additions and 22 deletions
@@ -58,7 +58,7 @@ PROCESSING_SUBSYSTEM_DEF(station)
setup_trait(trait_typepath)
continue
if(initial(trait_typepath.trait_flags) & STATION_TRAIT_ABSTRACT)
if(initial(trait_typepath.abstract_type) == trait_typepath)
continue //Dont add abstract ones to it
if(!(initial(trait_typepath.trait_flags) & STATION_TRAIT_PLANETARY) && SSmapping.is_planetary()) // we're on a planet but we can't do planet ;_;