Created
September 18, 2016 18:12
-
-
Save Ivorforce/b1d65df91ae753aee91746818969a383 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static GenericYSelector surfaceYSelector() | |
{ | |
return new GenericYSelector(Arrays.asList( | |
// Keep above caves | |
new FactorLimit(1, Arrays.asList( | |
new FactorLimit.RayDynamicPosition(null, FactorLimit.RayDynamicPosition.Type.WORLD_HEIGHT), | |
new FactorLimit.RayMatcher(1f, false, .5f, new PositionedBlockMatcher(RecurrentComplex.specialRegistry, "!(is.air | is.foliage | is.replaceable)")), | |
new FactorLimit.RayMove(1f, -5))), | |
// Spawn in air | |
new FactorMatch(1, "!(reccomplex:generic_space | reccomplex:generic_solid)", "is.air", 0.5f), | |
// Spawn on top of solids | |
new FactorMatch(1, "reccomplex:generic_solid & #0", "!(is.air | is.foliage | is.replaceable)", 0.5f), | |
// Spawn in non-solids | |
new FactorMatch(.5f, "!(reccomplex:generic_space | reccomplex:generic_solid)", "is.air | is.foliage | is.replaceable", 0.5f) | |
)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment