HnwPayoutLocked
Calculate end-of-bonus payout from all locked positions with multipliers
Inputs
valueTagstringrequiredTag prefix for symbol values (e.g. 'coin:value')
collectValueTagstringTag prefix for collect values (e.g. 'collect:value')
multiplierTagstringrequiredTag prefix for position multipliers (e.g. 'position:multiplier')
defaultMultipliernumberFallback multiplier if none set
Default: 1
lockedTagstringrequiredTag identifying locked positions
disabledTagstringTag identifying disabled positions (excluded from payout)
Default: disabled:true
totalPositionsnumberTotal positions on grid for Grand Jackpot check
Default: 15
grandJackpotValuenumberGrand jackpot payout multiplier
Default: 5000
Outputs
totalPayoutnumberTotal payout from all locked symbols
grandJackpotbooleanTrue if all positions were locked
Overview
End-of-bonus payout calculation: for each locked position, multiplies the symbol's coin value by the position's accumulated multiplier. Also checks for Grand Jackpot condition (all positions locked).
Algorithm
- Find all positions with the
lockedTag - For each locked position:
- Skip if position has
disabled:truetag - Read symbol value from
valueTag:NorcollectValueTag:N - Read position multiplier from
multiplierTag:N - Calculate:
payout = symbolValue × multiplier
- Skip if position has
- Sum all position payouts
- Check Grand Jackpot: if locked count ≥ totalPositions, add
grandJackpotValue - Write
hnw:payout:Ntag to global entity
Disabled Position Handling
Positions with the disabled:true tag are excluded from the payout calculation, even if they are locked. This allows for "blocker" symbols that persist but don't contribute value.
Example
// Locked positions after H&W bonus:
pos_0_0: locked:true, coin:value:5
pos_1_1: locked:true, coin:value:10, position:multiplier:2
pos_2_0: locked:true, disabled:true, coin:value:5 // SKIPPED
pos_3_2: locked:true, coin:value:5
// Calculation:
pos_0_0: 5 × 1 = 5
pos_1_1: 10 × 2 = 20
pos_2_0: SKIPPED (disabled)
pos_3_2: 5 × 1 = 5
// Total: 30