package com.elmakers.mine.bukkit.action.builtin;

import com.elmakers.mine.bukkit.action.BaseSpellAction;
import com.elmakers.mine.bukkit.api.action.CastContext;
import com.elmakers.mine.bukkit.api.spell.Spell;
import com.elmakers.mine.bukkit.api.spell.SpellResult;
import com.elmakers.mine.bukkit.spell.BaseSpell;
import org.bukkit.Material;
import org.bukkit.block.Block;
import org.bukkit.configuration.ConfigurationSection;

import java.util.Arrays;
import java.util.Collection;

public class ModifyBreakable extends BaseSpellAction {
    private double breakable = 1;
    private boolean skipAir = true;

    @Override
    public void prepare(CastContext context, ConfigurationSection parameters) {
        super.prepare(context, parameters);
        breakable = parameters.getDouble("breakable", 1);
        skipAir = parameters.getBoolean("skip_air", true);
    }

    @Override
    public SpellResult perform(CastContext context) {
        Block block = context.getTargetBlock();
        if (skipAir && block.getType() == Material.AIR) {
            return SpellResult.NO_TARGET;
        }
        if (!context.hasBreakPermission(block)) {
            return SpellResult.INSUFFICIENT_PERMISSION;
        }

        if (!context.isDestructible(block)) {
            return SpellResult.NO_TARGET;
        }

        context.registerForUndo(block);
        context.registerBreakable(block, breakable);
        return SpellResult.CAST;
    }

    @Override
    public void getParameterNames(Spell spell, Collection<String> parameters) {
        super.getParameterNames(spell, parameters);
        parameters.add("breakable");
    }

    @Override
    public void getParameterOptions(Spell spell, String parameterKey, Collection<String> examples) {
        if (parameterKey.equals("breakable")) {
            examples.addAll(Arrays.asList((BaseSpell.EXAMPLE_SIZES)));
        } else {
            super.getParameterOptions(spell, parameterKey, examples);
        }
    }

    @Override
    public boolean requiresBuildPermission() {
        return true;
    }

    @Override
    public boolean requiresTarget() {
        return true;
    }

    @Override
    public boolean isUndoable() {
        return true;
    }
}
@@ -590,21 +590,24 @@
 ean 
-skip
+target
 Air = 
-tru
+fals
 e;%0A%0A
@@ -810,20 +810,22 @@
         
-skip
+target
 Air = pa
@@ -849,22 +849,25 @@
 an(%22
-skip
+target
 _air%22, 
-tru
+fals
 e);%0A
@@ -1005,12 +1005,15 @@
 if (
-skip
+!target
 Air 

Change skip_air to target_air, seems more consistent