|
Conquer Space 0.0.0
A space themed grand strategy game set in the near future, with realistic orbital mechanics, and an emphasis on economics and politics.
|
#include <modifier.h>
Public Member Functions | |
| void | recalculate () |
| operator double () const | |
| ModifiableValue ()=default | |
| ModifiableValue (double v) | |
| template<typename T > requires std::is_arithmetic_v<T> | |
| ModifiableValue & | operator= (T v) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| ModifiableValue & | operator+= (T v) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| ModifiableValue & | operator-= (T v) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| ModifiableValue & | operator*= (T v) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| ModifiableValue & | operator/= (T v) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| bool | operator== (T v) const |
| template<typename T > requires std::is_arithmetic_v<T> | |
| bool | operator!= (T v) const |
| template<typename T > requires std::is_arithmetic_v<T> | |
| bool | operator< (T v) const |
| template<typename T > requires std::is_arithmetic_v<T> | |
| bool | operator> (T v) const |
| template<typename T > requires std::is_arithmetic_v<T> | |
| bool | operator<= (T v) const |
| template<typename T > requires std::is_arithmetic_v<T> | |
| bool | operator>= (T v) const |
Public Attributes | |
| double | base = 0.0 |
| double | sum = identity |
| double | value = 0.0 |
| std::vector< std::pair< entt::entity, double > > | modifiers |
Static Public Attributes | |
| static constexpr double | identity = (Op == ModifierOp::Additive) ? 0.0 : 1.0 |
Private Member Functions | |
| constexpr double | _combine () const |
Friends | |
| template<typename T > requires std::is_arithmetic_v<T> | |
| double | operator+ (ModifiableValue lhs, T rhs) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| double | operator+ (T lhs, ModifiableValue rhs) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| double | operator- (ModifiableValue lhs, T rhs) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| double | operator- (T lhs, ModifiableValue rhs) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| double | operator* (ModifiableValue lhs, T rhs) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| double | operator* (T lhs, ModifiableValue rhs) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| double | operator/ (ModifiableValue lhs, T rhs) |
| template<typename T > requires std::is_arithmetic_v<T> | |
| double | operator/ (T lhs, ModifiableValue rhs) |
Modifier value for additive or multiplicative values Call recalculate() after adding a modifier
|
default |
|
inline |
|
inlineconstexprprivate |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
| double cqsp::core::components::ModifiableValue< Op >::base = 0.0 |
|
staticconstexpr |
| std::vector<std::pair<entt::entity, double> > cqsp::core::components::ModifiableValue< Op >::modifiers |
| double cqsp::core::components::ModifiableValue< Op >::sum = identity |
| double cqsp::core::components::ModifiableValue< Op >::value = 0.0 |