Update Controllable.java

Add a registerControllerType method
This commit is contained in:
fullwall 2014-03-03 00:15:19 +08:00
parent d79ec59f49
commit a5f13cf0f5

View File

@ -353,6 +353,10 @@ public class Controllable extends Trait implements Toggleable, CommandConfigurab
handle.motY *= 0.98F;
}
}
public static void registerControllerType(EntityType type, Class<? extends MovementController> clazz) {
controllerTypes.put(type, clazz);
}
private static final Map<EntityType, Class<? extends MovementController>> controllerTypes = Maps
.newEnumMap(EntityType.class);