mirror of
https://github.com/songoda/UltimateTimber.git
synced 2024-12-01 14:23:24 +01:00
Invalid tree animation in config handling, fix typo
This commit is contained in:
parent
5ce176841e
commit
0e1afcef84
@ -20,7 +20,7 @@ import java.util.List;
|
||||
public class TreeAnimationDisintegrate extends TreeAnimation {
|
||||
|
||||
public TreeAnimationDisintegrate(DetectedTree detectedTree, Player player) {
|
||||
super(TreeAnimationType.DISINTIGRATE, detectedTree, player);
|
||||
super(TreeAnimationType.DISINTEGRATE, detectedTree, player);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -5,7 +5,7 @@ package com.songoda.ultimatetimber.animation;
|
||||
*/
|
||||
public enum TreeAnimationType {
|
||||
FANCY,
|
||||
DISINTIGRATE,
|
||||
DISINTEGRATE,
|
||||
CRUMBLE,
|
||||
NONE;
|
||||
|
||||
|
@ -7,6 +7,7 @@ import com.songoda.ultimatetimber.animation.TreeAnimationCrumble;
|
||||
import com.songoda.ultimatetimber.animation.TreeAnimationDisintegrate;
|
||||
import com.songoda.ultimatetimber.animation.TreeAnimationFancy;
|
||||
import com.songoda.ultimatetimber.animation.TreeAnimationNone;
|
||||
import com.songoda.ultimatetimber.animation.TreeAnimationType;
|
||||
import com.songoda.ultimatetimber.tree.DetectedTree;
|
||||
import com.songoda.ultimatetimber.tree.ITreeBlock;
|
||||
import com.songoda.ultimatetimber.tree.TreeDefinition;
|
||||
@ -73,17 +74,17 @@ public class TreeAnimationManager extends Manager implements Listener, Runnable
|
||||
* @param player The Player who toppled the tree
|
||||
*/
|
||||
public void runAnimation(DetectedTree detectedTree, Player player) {
|
||||
switch (ConfigurationManager.Setting.TREE_ANIMATION_TYPE.getString()) {
|
||||
case "FANCY":
|
||||
switch (TreeAnimationType.fromString(ConfigurationManager.Setting.TREE_ANIMATION_TYPE.getString())) {
|
||||
case FANCY:
|
||||
this.registerTreeAnimation(new TreeAnimationFancy(detectedTree, player));
|
||||
break;
|
||||
case "DISINTEGRATE":
|
||||
case DISINTEGRATE:
|
||||
this.registerTreeAnimation(new TreeAnimationDisintegrate(detectedTree, player));
|
||||
break;
|
||||
case "CRUMBLE":
|
||||
case CRUMBLE:
|
||||
this.registerTreeAnimation(new TreeAnimationCrumble(detectedTree, player));
|
||||
break;
|
||||
case "NONE":
|
||||
case NONE:
|
||||
this.registerTreeAnimation(new TreeAnimationNone(detectedTree, player));
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user