Problems with data values

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

Status
Not open for further replies.

PlayerSerV

Member
Feb 18, 2022
1
0
1
22
Script Version: 2.6.1
Script Author: TPGamesNL
Minecraft Version: 1.18.1
Full Code:
Code:
command /testthisstuff:
    trigger:
        loop all blocks in radius 3 around player:
            if loop-block is wheat plant:
                set data value of loop-block to 2

Errors on Reload:
There is no errors on reload in game, it just doesn't work.

Other Useful Info:
So yea, I am looping blocks in 3 block radius and finding wheat plant and then setting its stage/age to certain number. But it doesn't work.

The thing is that I would use
Code:
set loop-block to stage 3 wheat plant
but the code abouve is test code for something like this:
Code:
function farmFirstSet(plant: item, lvl: number, loc: locatiom, othercorner: location):
    loop blocks within {_loc} to {_othercorner}:
        if loop-block is farmland:
            set block above loop-block to stage {_lvl} {_plant}
and with thiscode, it shows a error that it doesn't understand code, because of the variables. Ahh.

Addons using (including versions):
Skript-placeholder 1.5.2,
Skellett v2.0.2,
skript-gui 1.3-beta1,
skript-yaml 1.4,
skUtilities 0.9.2,
skript-reflect 2.2.3,
skRayFall 1.9.26,
SkQuery 4.1.5,
SkBee 1.14.1

Have you tried searching the docs?
So yea, I tried to find help in docs, internet, I tried skript built-in functions, event java code with skript-reflect, I tried to ask in skript help discord, but everyone ignored and didn't know how to fix this.
[doublepost=1645546811,1645229618][/doublepost]I even tried using different kind of java (skript-reflect) stuff and it didn't work, I think I am somhow bit wrong with something here. Has anything changed?
 
Status
Not open for further replies.