Formula (SEV)
From SEWiki
Contents |
Introduction
A formula is an expression (often mathematical) that performs a calculation that is used to determine specific statistical values, all abilities and requirements. Some of the values that use formulae are costs, tonnage, facility space and a wide variety of other object values. A formulaic expression may be very complex (containing many functions and comparisons) or very simple (a number), but must always return a value to be used by the setting. Many times, a formula will references a game value via a function or variable. The variables that may be used in a formula depend on the formula type and, sometimes, the functions that other formulae may call.
Variables and Formulae
Frequently, a formula will have to reference a variable to determine a specific value. A variable may be indicated by [%Variable Name%]. Space Empires V has a number of variables for use with formulae. For a list of available variables, see Variables. Since some variables are dependent upon functions, it is also advised that the modder also review the Function List. These are not to be confused with scripting variables and functions which encompass a wholely different variety of functionality.
Special Formulae
Some formulae are reused so often that they require special clarification. Because of the way that they are formatted, improper use may cause strange behavior or even crashes to the game.
Requirements
Requirements are used for technologies, facilities, components, and vehicles. They determine whether an empire may research, build or use the object in question. In the cases of facilities, components and vehicles, requirements also determine the level of the actual game object. A given object may have single or multiple requirements evaluated in different ways. For more detail, see Requirements.
Abilities
Abilities are used by Achievements, Components, Facilities, and Racial Traits. They are what make these things desirable to players to research and build. An object may have a single or multiple abilities. For more detail see Abilities.
