Click on the block in the region

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

L0mchansky

Member
Mar 5, 2018
1
0
0
27
Good afternoon, my friend! I have a problem. I need that when I click on any block in the region, the value of the variable changes.

code_language.skript:
on rightclick:
    loop all blocks in region{Ogorod}:
# PROBLEM LINE
        if {Proverka} = 0:
            set {Proverka} to 1
            if {Speed_Attack} = 1:
                subtract {Damagel} from {Heal}
                wait 1 seconds
                set {Proverka} to 0

And also, do not tell what color scheme do you use to highlight the code?
 
Good afternoon, my friend! I have a problem. I need that when I click on any block in the region, the value of the variable changes.

code_language.skript:
on rightclick:
    loop all blocks in region{Ogorod}:
# PROBLEM LINE
        if {Proverka} = 0:
            set {Proverka} to 1
            if {Speed_Attack} = 1:
                subtract {Damagel} from {Heal}
                wait 1 seconds
                set {Proverka} to 0

And also, do not tell what color scheme do you use to highlight the code?
I don't see where you are setting {Proverka} in the first place so that may be the problem. Your if statement will not trigger if {Proverka} has no value at all
code_language.skript:
if {Proverka} is not set:
    set {Proverka} to 0
If that's not the issue, could you explain what's not working a little more?
 
Status
Not open for further replies.