Variables Not Saving

  • 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!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

SuperRcraft

Member
Apr 30, 2024
12
0
1
24
Code:
function createKit(p:player,k:text):
    set {_slot} to 0
    loop 36 times:
        if slot {_slot} of {_p}'s inventory is not air:
            set {kit::%{_k}%::slot::%{_slot}%} to slot {_slot} of {_p}'s inventory
        add 1 to {_slot}
    if {_p}'s helmet is set:
        set {kit::%{_k}%::helmet} to {_p}'s helmet
    if {_p}'s chestplate is set:
        set {kit::%{_k}%::chestplate} to {_p}'s chestplate
    if {_p}'s leggings is set:
        set {kit::%{_k}%::leggings} to {_p}'s leggings
    if {_p}'s boots is set:
        set {kit::%{_k}%::boots} to {_p}'s boots
    set {kit::%{_k}%::offhand} to {_p}'s offhand item
    send "&aSucessfuly created %{_k}%" to {_p}
The code is not being saved after a server restart. It is not being written down in the variables files but when the kit is bound to a player it saves
 
1715811267546.png