$ObjectIncrease

To increase key value, if not exists, it will create it and set to the value

Usage

$ObjectIncrease[Key;Amount]

Notes on Amount:

  • It can be a number like 5, or negative -5 to reduce instead of increase\
  • It can be expression like x*2 where x is the current value

Example 1:

Member04/02/2024
!!exec $objectIncrease[Mido;10]
$objectIncrease[Rake;5]
$objectGet

Custom Command Bot 04/02/2024
{"Mido":10,"Rake":5}

Example 2:

Member04/02/2024
!!exec $objectIncrease[Mido;10]
$objectIncrease[Mido;x*2]
$objectGet

Custom Command Bot 04/02/2024
{"Mido":20}