package net.asrex.skillful.requirement;

import lombok.Data;
import net.asrex.skillful.PlayerSkillInfo;
import net.asrex.skillful.util.Conditional;
import net.minecraft.entity.player.EntityPlayer;

/**
 *
 */
@Data
public class BlockLevelRequirement implements Requirement {

	private int level;
	private Conditional is = Conditional.below;
	
	@Override
	public boolean satisfied(EntityPlayer player, PlayerSkillInfo info) {
		return is.compare(level, (int) player.posY);
	}

	@Override
	public String describe() {
		return String.format("Player block level %s %d",
				is.text,
				level);
	}
	
}

@@ -442,15 +442,8 @@
 are(
-level, 
 (int
@@ -455,16 +455,23 @@
 yer.posY
+, level
 );%0A%09%7D%0A%0A%09

Fix block level conditional