use of com.voxelgameslib.voxelgameslib.api.feature.features.MapInfoFeature in project VoxelGamesLibv2 by VoxelGamesLib.
the class GracePhase method init.
@Override
public void init() {
setName("GracePhase");
super.init();
setAllowJoin(false);
setAllowSpectate(true);
setTicks(60 * GameConstants.TPS);
MapFeature mapFeature = getGame().createFeature(MapFeature.class, this);
mapFeature.setShouldUnload(false);
addFeature(mapFeature);
SpawnFeature spawnFeature = getGame().createFeature(SpawnFeature.class, this);
addFeature(spawnFeature);
MapInfoFeature mapInfoFeature = getGame().createFeature(MapInfoFeature.class, this);
addFeature(mapInfoFeature);
ScoreboardFeature scoreboardFeature = getGame().createFeature(ScoreboardFeature.class, this);
addFeature(scoreboardFeature);
NoBlockBreakFeature noBlockBreakFeature = getGame().createFeature(NoBlockBreakFeature.class, this);
addFeature(noBlockBreakFeature);
NoBlockPlaceFeature noBlockPlaceFeature = getGame().createFeature(NoBlockPlaceFeature.class, this);
addFeature(noBlockPlaceFeature);
ClearInventoryFeature clearInventoryFeature = getGame().createFeature(ClearInventoryFeature.class, this);
addFeature(clearInventoryFeature);
NoDamageFeature noDamageFeature = getGame().createFeature(NoDamageFeature.class, this);
addFeature(noDamageFeature);
HealFeature healFeature = getGame().createFeature(HealFeature.class, this);
addFeature(healFeature);
GameModeFeature gameModeFeature = getGame().createFeature(GameModeFeature.class, this);
gameModeFeature.setGameMode(GameMode.SURVIVAL);
addFeature(gameModeFeature);
MobFeature mobFeature = getGame().createFeature(MobFeature.class, this);
addFeature(mobFeature);
SpectatorFeature spectatorFeature = getGame().createFeature(SpectatorFeature.class, this);
addFeature(spectatorFeature);
}
Aggregations