type
property is intended to determine how a player's activities are considered during evaluation. A criterion will consider a set of relevant activities and its type will determine what value to use when applying its rule
property.amount
: When evaluated, if any single relevant activity's amount
value allows the criterion's rule to pass, then the criterion is met.average
: When evaluated, this type of criterion takes the average of all relevant activity amounts, which is then used by the rule
.sum
: This type of criterion, when evaluated, calculates the sum of all relevant activity amounts. This sum is then used when applying the rule
.amount
, then the rule will look at each of the individual amount
values. If any of them allow the rule to pass, then the criterion will have been met.gt:5
: false, because none of the amounts are greater than 5lt:3
: trueeq:12
: false, because none of the amounts are equal to 12average
, then the rule will look at an average of the various amount
values, which happens to be 3 in this case. If the rule passes when using 3, then the criterion will have been met.gt:5
: false, because the average is 3, which is not greater than 5lt:3
: false, because the average is 3, which is not less than 3eq:12
: false, because the average is 3, which is not equal to 12sum
, then the rule will look at a sum of the various amount
values, which happens to be 12 in this case. If the rule passes when using 12, then the criterion will have been met.gt:5
: truelt:3
: false, because the sum is 12, which is not less than 3eq:12
: truecustom_action_id
, which corresponds to the related action's custom_id
property. When a criterion is evaluated, its rule is applied against all player activities for the same action to determine whether or not the criterion has been met.rule
property is used during evaluation. It consists of an operator and a threshold. They have the following form: operator:threshold
.threshold
. The comparison is determined by operator
.eq
: If a criterion rule's operator
is set to eq
, then the criterion will resolve to true if the given value is equal to threshold
.gt
: If a criterion rule's operator
is set to gt
, then the criterion will resolve to true if the given value is greater than threshold
.gte
: If a criterion rule's operator
is set to gte
, then the criterion will resolve to true if the given value is greater than or equal to threshold
.lt
: If a criterion rule's operator
is set to lt
, then the criterion will resolve to true if the given value is less than threshold
.lte
: If a criterion rule's operator
is set to lte
, then the criterion will resolve to true if the given value is less than or equal to threshold
.eq
, since there are times where a player will record activities where the amount might increment the total count for a given action such that the threshold is passed, meaning the criterion might not be met when it's otherwise expected. More often than not, gte
should be used.threshold
is a number that is compared to the value determined by its type. The comparison is made using the specified operator.streak
property is used during evaluation. It consists of an interval and an amount. They have the following form: interval:amount
.days
: The criterion will have been met if, after all of the conditions have been applied, the rule resolves to true over the course of several consecutive days, which is determined by the streak amount
.hours
: The criterion will have been met if, after all of the conditions have been applied, the rule resolves to true over the course of several consecutive hours, which is determined by the streak amount
.amount
is an integer indicated the minimum length of the streak.days:5
: The rule must resolve to true for five consecutive days.hours:12
: The rule must resolve to true for twelve consecutive hours.