GS2-Stamina Buff Reference

Describes the fields within models/actions whose parameters can be adjusted when applying buffs with GS2-Buff, and the scope in which those buffs are applied.

Model

Target model types available for buff application

Gs2Stamina:Stamina

Stamina

Target fields for buff application

maxValue
TypeConditionRequiredDefaultValue LimitsDescription
maxValueint
1 ~ 2147483646Maximum Stamina
The per-user maximum stamina value, resolved from the StaminaModel and optionally overridden by a MaxStaminaTable based on the player’s GS2-Experience rank.
When overflow is disabled, this value is floored at initialCapacity. When overflow is enabled, it is capped at maxCapacity.
Natural time-based recovery stops at this value.
Example Master Data

rate specifies the multiplier applied to the target field.

"targetModel": {
    "targetModelName": "Gs2Stamina:Stamina",
    "targetFieldName": "maxValue",
    "conditionGrns": [
    ],
    "rate": 1.0
}

Buff Application Condition Model

Gs2Stamina:StaminaModel

Stamina Model

Example Master Data
"conditionGrns": [
    {
        "targetModelName": "Gs2Stamina:StaminaModel",
        "targetGrn": "grn:gs2:any:any:stamina:{namespaceName}:model:{staminaName}"
    }
]

recoverIntervalMinutes
TypeConditionRequiredDefaultValue LimitsDescription
recoverIntervalMinutesint1 ~ 2147483646Stamina Recovery Interval (Minutes)
The per-user recovery interval in minutes, resolved from the StaminaModel and optionally overridden by a RecoverIntervalTable based on the player’s GS2-Experience rank.
If no table is configured, the value falls back to the model’s default recoverIntervalMinutes.
Example Master Data

rate specifies the multiplier applied to the target field.

"targetModel": {
    "targetModelName": "Gs2Stamina:Stamina",
    "targetFieldName": "recoverIntervalMinutes",
    "conditionGrns": [
    ],
    "rate": 1.0
}

Buff Application Condition Model

Gs2Stamina:StaminaModel

Stamina Model

Example Master Data
"conditionGrns": [
    {
        "targetModelName": "Gs2Stamina:StaminaModel",
        "targetGrn": "grn:gs2:any:any:stamina:{namespaceName}:model:{staminaName}"
    }
]

recoverValue
TypeConditionRequiredDefaultValue LimitsDescription
recoverValueint1 ~ 2147483646Stamina Recovery Amount
The per-user recovery amount per tick, resolved from the StaminaModel and optionally overridden by a RecoverValueTable based on the player’s GS2-Experience rank.
If no table is configured, the value falls back to the model’s default recoverValue.
Example Master Data

rate specifies the multiplier applied to the target field.

"targetModel": {
    "targetModelName": "Gs2Stamina:Stamina",
    "targetFieldName": "recoverValue",
    "conditionGrns": [
    ],
    "rate": 1.0
}

Buff Application Condition Model

Gs2Stamina:StaminaModel

Stamina Model

Example Master Data
"conditionGrns": [
    {
        "targetModelName": "Gs2Stamina:StaminaModel",
        "targetGrn": "grn:gs2:any:any:stamina:{namespaceName}:model:{staminaName}"
    }
]

Action

Types of actions that can apply buffs

Gs2Stamina:ConsumeStamina

Consume Stamina

Deducts the specified amount from the current stamina value. Returns an Insufficient error if the current stamina value is less than the consume amount.

Target fields for buff application

consumeValue

Stamina - Stamina

TypeConditionRequiredDefaultValue LimitsDescription
consumeValueint
1 ~ 2147483646Amount of stamina consumed
Example Master Data
"targetAction": {
    "targetActionName": "Gs2Stamina:ConsumeStamina",
    "targetFieldName": "consumeValue",
    "conditionGrns": [
    ],
    "rate": 1.0
}

Buff Application Condition Model

Gs2Stamina:StaminaModel

Stamina Model

Example Master Data
"conditionGrns": [
    {
        "targetModelName": "Gs2Stamina:StaminaModel",
        "targetGrn": "grn:gs2:{region}:{ownerId}:stamina:{namespaceName}:model:{staminaName}"
    }
]

Gs2Stamina:ConsumeStaminaByUserId

Consume Stamina by specifying a user ID

Deducts the specified amount from the current stamina value for the given user. Returns an Insufficient error if the current stamina value is less than the consume amount.

Target fields for buff application

consumeValue

Stamina - Stamina

TypeConditionRequiredDefaultValue LimitsDescription
consumeValueint
1 ~ 2147483646Amount of stamina consumed
Example Master Data
"targetAction": {
    "targetActionName": "Gs2Stamina:ConsumeStaminaByUserId",
    "targetFieldName": "consumeValue",
    "conditionGrns": [
    ],
    "rate": 1.0
}

Buff Application Condition Model

Gs2Stamina:StaminaModel

Stamina Model

Example Master Data
"conditionGrns": [
    {
        "targetModelName": "Gs2Stamina:StaminaModel",
        "targetGrn": "grn:gs2:{region}:{ownerId}:stamina:{namespaceName}:model:{staminaName}"
    }
]

Gs2Stamina:RecoverStaminaByUserId

Recover Stamina by specifying a user ID

Recovers stamina by the specified amount up to the maximum capacity. If the recovery causes the value to exceed the maximum and overflow mode is enabled, the excess is tracked as an overflow value.

Target fields for buff application

recoverValue

Stamina - Stamina

TypeConditionRequiredDefaultValue LimitsDescription
recoverValueint
1 ~ 2147483646Amount of stamina recovery
Example Master Data
"targetAction": {
    "targetActionName": "Gs2Stamina:RecoverStaminaByUserId",
    "targetFieldName": "recoverValue",
    "conditionGrns": [
    ],
    "rate": 1.0
}

Buff Application Condition Model

Gs2Stamina:StaminaModel

Stamina Model

Example Master Data
"conditionGrns": [
    {
        "targetModelName": "Gs2Stamina:StaminaModel",
        "targetGrn": "grn:gs2:{region}:{ownerId}:stamina:{namespaceName}:model:{staminaName}"
    }
]