This commit is contained in:
CocoTheOwner
2021-07-17 18:45:11 +02:00
parent b4602c1e48
commit 4eb1117659
5 changed files with 41 additions and 6 deletions
@@ -25,5 +25,6 @@ public class SaplingManager implements Listener {
// TODO: Remove this line
Iris.info("Sapling grew @ " + event.getLocation() + " for " + event.getSpecies().name() + " bonemealed is " + event.isFromBonemeal() + " by player " + Objects.requireNonNull(event.getPlayer()).getName());
}
}
@@ -82,7 +82,8 @@ public class IrisBiome extends IrisRegistrant implements IRare {
private KList<IrisEntityInitialSpawn> entityInitialSpawns = new KList<>();
@Desc("Sapling override settings")
private IrisSaplings saplings = new IrisSaplings();
@ArrayType(min = 1, type = IrisSapling.class)
private KList<IrisSapling> saplings = new KList<>();
@ArrayType(min = 1, type = IrisEffect.class)
@Desc("Effects are ambient effects such as potion effects, random sounds, or even particles around each player. All of these effects are played via packets so two players won't see/hear each others effects.\nDue to performance reasons, effects will play arround the player even if where the effect was played is no longer in the biome the player is in.")
@@ -66,7 +66,6 @@ public class IrisDimension extends IrisRegistrant {
private IrisDimension sky = null;
@RegistryListJigsaw
@Desc("If defined, Iris will place the given jigsaw structure where minecraft should place the overworld stronghold.")
private String stronghold;
@@ -75,10 +74,11 @@ public class IrisDimension extends IrisRegistrant {
private boolean aggressiveBiomeReshuffle = false;
@Desc("Sapling override settings")
private IrisSaplings saplings = new IrisSaplings();
@ArrayType(min = 1, type = IrisSapling.class)
private KList<IrisSapling> saplings = new KList<>();
@Desc("Enable sapling overrides")
private boolean useSaplings = false;
private boolean overrideSaplings = false;
@Desc("Instead of a flat bottom, applies a clamp (using this noise style) to the bottom instead of a flat bottom. Useful for carving out center-dimensions in a dimension composite world.")
@@ -80,7 +80,8 @@ public class IrisRegion extends IrisRegistrant implements IRare {
private KList<IrisEntityInitialSpawn> entityInitialSpawns = new KList<>();
@Desc("Sapling override settings")
private IrisSaplings saplings = new IrisSaplings();
@ArrayType(min = 1, type = IrisSapling.class)
private KList<IrisSapling> saplings = new KList<>();
@MinNumber(1)
@MaxNumber(128)
@@ -1,2 +1,34 @@
package com.volmit.iris.engine.object;public class IrisSapling {
package com.volmit.iris.engine.object;
import com.volmit.iris.engine.object.annotations.*;
import com.volmit.iris.util.collection.KList;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import org.bukkit.TreeType;
@Accessors(chain = true)
@AllArgsConstructor
@NoArgsConstructor
@Desc("Sapling override settings")
@Data
public class IrisSapling {
@Required
@Desc("The types of saplings overwritten")
@ArrayType(min = 1, type = TreeType.class)
private KList<TreeType> types;
@RegistryListObject
@Required
@ArrayType(min = 1, type = String.class)
@Desc("List of objects to overwrite saplings with")
private KList<String> replace = new KList<>();
@Desc("The size of the square of saplings this applies to (two means a 2 by 2 sapling area")
@MinNumber(1)
@MaxNumber(4)
private int size = 1;
}