Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Suggestion] add value to yaml #34

Open
qsef1256 opened this issue Sep 16, 2021 · 3 comments
Open

[Suggestion] add value to yaml #34

qsef1256 opened this issue Sep 16, 2021 · 3 comments

Comments

@qsef1256
Copy link

Currently it is not possible to "add" value to yaml value.

Example:

command /addValue [<number>]:
  trigger:
    load yaml "plugins/Skript/scripts/config.yml"
    add arg 1 to yaml value "test" from "config"

Result:
yaml value "test" from "config" can't have anything added to it (BugReport.sk, line 53: add arg 1 to yaml value "test" from "config"')

It can be bypassed by set original value to (the original value + value to add) , but It's quite inconvenient, reduce readability and gets in the way of updating legacy scripts.

I would like to be able to add/remove other values to a yaml value whose value is a number.

@qsef1256
Copy link
Author

Versions:
Server: 3227-Spigot-3c1fc60-a0a37f4 (MC: 1.17.1)
Skript Version: 2.6-beta2
Installed Skript Addons:
Skellett v1.9.11 (https://forums.skunity.com/resources/skellett.24/)
skript-yaml v1.4
skRayFall v1.9.26 (https://sk.rayfall.net/)
SkQuery v4.1.5
SkBee v1.11.2 (https://github.com/ShaneBeee/SkBee)

@Sashie
Copy link
Owner

Sashie commented Apr 7, 2022

Technically this is due to the use of lists vs. values, i never took into account adding numbers or strings to a yaml value
I'll see what i can do for this issue!

(sorry for the super late reply)

@Blackninja04010
Copy link

is there an estimate for how long until this feature comes out?
it would fix some issues I'm having with my code and it's a lot so I don't really want to change it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants