Plugin : Save slot

Author:Rex.Rainbow

Download

Properties

Class name of header

  • Class name for storing header structure.

Class name of body

  • Class name for storing body structure.

Write permission

  • All user or only owner could write the save slot.
    • Options : ["All users","Owner"]

Read permission

  • All user or only owner could read the save slot.
    • Options : ["All users","Owner"]

Actions

0. Setup

Action:Set owner

  • Set user ID of slot owner.
    • User ID ( string ) : User ID from authentication.

Clean

Action:Clean all slots

  • Clean all slots on server.

Action:Clean slot

  • Clean slot on server.
    • Name ( number or string ) : The slot name.

Initial

Action:Initial table

  • Initial table.

Load

Action:Get all headers

  • Get all slot headers from server.

Action:Get body

  • Get slot body from server.
    • Name ( number or string ) : The slot name.

Save

Action:Set value

  • Sets value into slot.
    • Key ( string ) : The name of the key.
    • Value ( number or string ) : The value to set
    • Slot ( Combo ) : Header or body.
      • Options : ["Header","Body"]

Action:Save

  • Save slot into server.
    • Name ( number or string ) : The slot name.

Action:Set boolean value

  • Sets boolean value into slot.
    • Key ( string ) : The name of the key.
    • Boolean ( Combo ) : Boolean value.
      • Options : ["False","True"]
    • Slot ( Combo ) : Header or body.
      • Options : ["Header","Body"]

Expressions

Body

Expression:BodyValue

  • Get body value by key. Add default value at 2nd parameter if read data is null
    • Key ( string ) : The name of the key, could be string or number.

Error

Expression:ErrorCode

  • Error code.

Expression:ErrorMessage

  • Error message.

For each header

Expression:CurSlotName

  • Get current slot name in a For Each loop.

Expression:CurHeaderValue

  • Get current header value by key in a For Each loop. Add default value at 2nd parameter if read data is null.
    • Key ( string ) : The name of the key.

For each key

Expression:CurKey

  • Get current key in a For Each loop.

Expression:CurValue

  • Get current value in a For Each loop.

Headers

Expression:HeaderValue

  • Get header value by slot name and key. Add default value at 3rd parameter if read data is null.
    • Slot name ( string ) : The name of the slot.
    • Key ( string ) : The name of the key.

JSON

Expression:HeadersToJSON

  • Get all headers in JSON string.

Expression:BodyToJSON

  • Get all body values in JSON string.

Key

Expression:KeyLastSaveTime

  • Key of Last saved time ("updatedAt")

Conditions

Clean

Condition:On clean

  • Triggered when clean slots complete on server complete.

Condition:On clean error

  • Triggered when clean slots error on server error.

Load - body

Condition:On get body

  • Triggered when get slot body complete from server complete.

Condition:On get body error

  • Triggered when get slot body error from server error.

Condition:For each key

  • Repeat the event for each key in body.

Load - header

Condition:On get headers

  • Triggered when get all slot headers from server.

Condition:For each header

  • Repeat the event for each slot header.

Condition:On get headers error

  • Triggered when get all slot headers error.

Condition:For each key

  • Repeat the event for each key in a header.
    • Name ( number or string ) : The slot name.

Load - slot

Condition:Empty

  • All slots are unused. Call it after load headers from server.

Condition:Is occupied

  • Slot is occupied. Call it after load headers from server.
    • Name ( number or string ) : The slot name.

Save

Condition:On save

  • Triggered when save complete.

Condition:On save error

  • Triggered when save error.