-
-
Notifications
You must be signed in to change notification settings - Fork 51
Code Style
zumbak04 edited this page Nov 19, 2019
·
8 revisions
Hello! In this article you will find the code style that we use in events, decisions, traits etc. It is advisable to follow this style so that different developers do not get lost in each other's code.
There should be gaps (empty lines) between the numbered groups written below. In essence, all conditions in the same number group will occur together in one code block.
-
has_dlc
,is_untouchable_trigger
,can_rule_peacefully_trigger
. -
ai
,is_playable
,is_adult
,is_incapable
,prisoner
,is_inaccessible_trigger
. -
is_ruler
,is_landed
,independent
,is_tributary
,mercenary
,holy_order
,controls_religion
,is_offmap_governor
,government
,tier
,war
,in_revolt
. -
character
,is_within_diplo_range
,same_realm
. - Flags/traits/modifiers working as cooldowns, attempt limits and other blockers.
- Being type (
being_
traits) , race (creature_
traits), class (class_
traits), mana triggers (has_5_mana_trigger
,has_4_mana_trigger
etc.), religion, culture, other traits. - Wealth, piety, prestige, society currency, offmap currency and user variables.
- Other conditions.
-
show_scope_change
,save_event_target_as
. - Flags/traits/modifiers working as cooldowns, attempt limits and other blockers.
- Being type (
being_
traits) , race (creature_
traits), class (class_
traits), mana triggers (has_5_mana_trigger
,has_4_mana_trigger
etc.), religion, culture, other traits. - Wealth, piety, prestige, society currency, offmap currency and user variables.
- Other effects.
- Event firing (character_event etc.).
death
Utilize the order given in This Article making a gap between the modifiers similar to how they are sectioned off. For example, there should be a gap between "Character Attribute Modifiers" and "Realm Modifiers".