Serialization

Official docs of Skript-gson

Examples of data serialization

Allows you to convert a JsonElement (json) to a list variable

options:
    storage: json from file "plugins/YourAwesome/storage.json"
    
on load:
    map json from {@storage} to {_example::*}
    '#Example 1
     broadcast {_example::*}

The Example 1 will print out only first key of JsonElement (Json), otherwise the Example 2 will print out everything from the list. The Example 3 looping everything inside the list and then printint out.

Last updated