Added some more basic properties

This commit is contained in:
Ammar Askar 2012-11-09 23:01:20 +05:00
parent ea38d3dc4e
commit 2aee358ec1

View File

@ -1,6 +1,7 @@
package com.onarandombox.multiverse.core.api;
import com.dumptruckman.minecraft.pluginbase.locale.Message;
import com.dumptruckman.minecraft.pluginbase.properties.ListProperty;
import com.dumptruckman.minecraft.pluginbase.properties.Properties;
import com.dumptruckman.minecraft.pluginbase.properties.PropertyFactory;
import com.dumptruckman.minecraft.pluginbase.properties.SimpleProperty;
@ -27,6 +28,42 @@ public interface WorldProperties extends Properties {
.description(Descriptions.PREFIX_CHAT)
.build();
SimpleProperty<Long> SEED = PropertyFactory.newProperty(Long.class, "seed", 0L)
.comment("The seed property allows you to change the world's seed.")
.description(Descriptions.SEED)
.build();
SimpleProperty<String> GENERATOR = PropertyFactory.newProperty(String.class, "generator", "")
.comment("The generator property allows you to specify the generator used to generate this world.")
.description(Descriptions.GENERATOR)
.build();
SimpleProperty<Integer> PLAYER_LIMIT = PropertyFactory.newProperty(Integer.class, "playerLimit", -1)
.comment("The player limit property limits the number of players in a world at a time.")
.comment("A value of -1 or lower signifies no player limit.")
.description(Descriptions.PLAYER_LIMIT)
.build();
SimpleProperty<Boolean> AUTO_LOAD = PropertyFactory.newProperty(Boolean.class, "autoLoad", true)
.comment("This property dictates whether this world is loaded automatically on startup or not.")
.description(Descriptions.AUTO_LOAD)
.build();
SimpleProperty<Boolean> BED_RESPAWN = PropertyFactory.newProperty(Boolean.class, "bedRespawn", true)
.comment("This property specifies if a player dying in this world should respawn in their bed or not.")
.description(Descriptions.BED_RESPAWN)
.build();
SimpleProperty<Boolean> HUNGER = PropertyFactory.newProperty(Boolean.class, "hunger", true)
.comment("This property specifies if hunger is depleted in this world")
.description(Descriptions.HUNGER)
.build();
ListProperty<String> BLACK_LIST = PropertyFactory.newListProperty(String.class, "worldBlacklist")
.comment("This property allows you to specify worlds that people cannot go to from this specified world.")
.description(Descriptions.BLACK_LIST)
.build();
/**
* Houses localized (english) descriptions of the Multiverse world properties.
*/
@ -41,5 +78,28 @@ public interface WorldProperties extends Properties {
public static final Message PREFIX_CHAT = new Message("world_properties.descriptions.prefixChat",
"The prefixChat property adds the world's name (or alias) as a prefix to chat messages.");
public static final Message SEED = new Message("world_properties.descriptions.seed",
"The seed property allows you to change the world's seed.");
public static final Message GENERATOR = new Message("world_properties.descriptions.generator",
"The generator property allows you to specify the generator used to generate this world.");
public static final Message PLAYER_LIMIT = new Message("world_properties.descriptions.playerLimit",
"The player limit property limits the number of players in a world at a time.",
"A value of -1 or lower signifies no player limit.");
public static final Message AUTO_LOAD = new Message("world_properties.descriptions.autoLoad",
"This value dictates whether this world is loaded automatically on startup or not.");
public static final Message BED_RESPAWN = new Message("world_properties.descriptions.bedRespawn",
"This property specifies if a player dying in this world should respawn in their bed or not.");
public static final Message HUNGER = new Message("world_properties.descriptions.hunger",
"This property specifies if hunger is depleted in this world");
public static final Message BLACK_LIST = new Message("world_properties.descriptions.worldBlacklist",
"This property allows you to specify worlds that people cannot go to from this specified world.");
}
}