• Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

skJson 2.6.2⚠️
Introduce


Hello everyone.

- New conventors for json.
- Adding automatic parsing.
- Cleanup code
- fix Typos


From
Code:
command test:
    trigger:
        set {_loc-json} to json from player's location
        set {_loc} to {_loc-json} parsed as a location
        teleport player to {_loc}
To
Code:
command test:
    trigger:
        set {_loc-json} to json from player's location
        teleport player to {_loc-json}

Please check SkriptHub or Wikipedia for syntax changes.
❌ If you found any bugs, feel free to post it.


Sincerely, Coffee.

What's Changed
* New Conventors by @cooffeeRequired in https://github.com/cooffeeRequired/skJson/pull/14

Full Changelog https://github.com/cooffeeRequired/skJson/compare/2.6.1...2.6.2
skJson 2.6.1⚠️
Introduce

Hello everyone.
Hotfixed issue #11 , also the #13
Also was fixed all mapping / append / write issues.


Please check SkriptHub or Wikipedia for syntax changes.
## ❌ If you found any bugs, feel free to post it.

Sincerely, Coffee.

Full Changelog: https://github.com/cooffeeRequired/skJson/compare/2.5.9...2.6.1
skJson 2.5.9 ⚠️

Introduce

Hello everyone.
Fixed changers, for json you are now able to remove/add or set objects even with cached json.
Added removing/setting for nested objects

This error was related to this thread #8


Version 2.5.9
Example

Code:
on load:
    set {_json} to json from string "{'A': [1,2,3,4,{'B':false}]}"
    set json value "A[1]" of {_json} to true
   
    # Before {"A":[1,2,3,4,{"B":false}]}
   
    remove json value "A[4]:B" from {_json}
    add values 1,2,3,4 to {_json}
    send {_json}
   
    # After {"A":[1,2,3,4,{}]}

    load json file "try3.json" as "try"
    send cached json "try"
    set json value "A[0]" of cached json "try" to true
    send cached json "try"

Please check SkriptHub or Wikipedia for syntax changes.
❌ If you found any bugs, feel free to post it.

Sincerely, Coffee.

Full Changelog: https://github.com/cooffeeRequired/skJson/compare/2.5...2.5.9
skJson 2.5 ⚠️
Introduce


Hello everyone.
This is a big milestone for skJson addon (*skript-gson*)
One of the first pieces of information is that it has been renamed from the current skript-gson to skJson. I renamed this addon because the gson in the name said little to anyone and was not as representative. thus skJson contains both json in the word and Skript (sk)

I should also mention that support for older versions of minecraft server has been added. Since version 1.8.8 this addon is able to work.

I must also mention that the kernels for file handling and json serialization have been redesigned. For example, you can now serialize nbt and or entities.

A lot of syntax has been modified and simplified. one of my favorites is the Append effect, here is an example
Code:
append player's tool with key uuid of player as nested object "data:players tools[1]" to json file "..."
Don't worry I'll show you everything here, the new syntax is more intiative and I hope you'll find it easier to work with this addon, at the moment the addon supports around 24/25 data-types, if you want to add some that isn't just create a github thread as suggestion and I'll be happy to take a look.

I would also like to thank the total number of support and downloads for this addon and that is 4129x to date.

Alright let's get on with the news.

News
[h3]Adapters ⏺️[/h3]
✅ NBT, Entity, Chunk, ItemStack, World, Inventory, bukkit-types, and some Skript-types.

Please check SkriptHub or Wikipedia for syntax changes.

Sincerely, Coffee.

Full Changelog: https://github.com/cooffeeRequired/skJson/compare/2.1.1...2.5
Hello everyone

Hi there we have a couple of changes regarding the new json from the request, also changes in the Versioning Area and its automatic updates.

Thank you all for your attention.
Sincerely Coffee.

Full Changelog: https://github.com/cooffeeRequired/skript-gson/compare/2.0.4...2.1.0
skript-gson 2.0.4
200513198-968073f2-8249-4c40-b161-e81ac7a92f99.png



Hello everyone
Changed internal object mapping for Items, now you are able to pull Item from mapped json as well
Code:
[/FONT]
command saveinv:
    trigger:
        set {inv} to json from player's inventory

command listinv:
    trigger:
        map {inv} to {_inv::*}
        loop (indices of {_inv::contents::*}):
            if {_inv::contents::%loop-value%::*} is set:
                set {_item} to {_inv::contents::%loop-value%::*}'s form parsed as skript-type
                give {_item} to "player's name" parsed as player



Thank you all for your attention.
Sincerely Coffee.

FTW skript-gson

Full Changelog: https://github.com/cooffeeRequired/skript-gson/compare/2.0.3...2.0.4
skript-gson 2.0.3
200513198-968073f2-8249-4c40-b161-e81ac7a92f99.png




Thank you all for your attention.
Sincerely Coffee.
FTW skript-gson

Full Changelog: https://github.com/cooffeeRequired/skript-gson/compare/2.0.2...2.0.3
added - all json elements from %jsonelement%
skript-gson 2.0.2

200513198-968073f2-8249-4c40-b161-e81ac7a92f99.png


  • Hello everyone
Addon

  • ♾️ Fixed: ExprSkriptCollectionToJson.class
  • Now you can finally change/set/remove nested things from Skript Variable and than make a formatted json!
  • ♾️ Fixed: JsonElementType.class
  • Fixed nested things for adding/remove, removed the SimplyKey.class hence ~ now you can use normally "String", false (Boolean), 10 . - (Integer) and so on, but if you want to change or remove the nested key there is another procedure:
  • if you do not add anything to the nested object you can use the clasic Object (String, bool, etc...)
    if you want to insert into a nested object you have to write it in the string "obejct1:emoji_astonished:bjectX:Key;Value"
  • Also you can mapped your own json
Code:
set {_json} to new json from string "{'A': {}, 'B': [], 'C': {'G': {}}}"
add false to {_json}                      # example 1
add "A:test;false" to {_json}          # example 2
add "C:G:test;A" to {_json}            # example 3
Code:
# Show case 1
{"A": {}, "B": [], "C": {"G": {}}, "3": false}
# Show case 2
{"A": {"test": false}, "B": [], "C": {"G": {}}}
# Show case 3
{"A": {}, "B": [], "C": {"G": {"test": "A"}}}
  • ♾️ Fixed: MapJson.class
  • Finally don't returning any nulls.
  • ♾️ Sanitized: All syntaxes..
Thank you all for your attention.
Sincerely Coffee.


FTW skript-gson

Full Changelog: https://github.com/cooffeeRequired/skript-gson/compare/2.0.0...2.0.2
New release of skript-gson it's out. 2.0.0 Fixed all known mapping bugs, also added SkriptTypes and Bukkit type conversion, also Inventory. Changed functionality and loaded Json as a custom ID, etc. https://skripthub.net/docs/?addon=skript-gson https://github.com/cooffeeRequired/skript-gson/releases/tag/2.0.0