added specific return statements
I dont even know why
This commit is contained in:
1 parent
40dcd31bb0
commit
771fc8a437
1 file changed
+6
-1
@@ -272,22 +272,27 @@ public class DrawCommand {
|
|||||||
|
|
||||||
private static int selectCone(ServerCommandSource source, BlockPos pos, int radius, int height, boolean pointup, String direction, BlockStateArgument block,
|
private static int selectCone(ServerCommandSource source, BlockPos pos, int radius, int height, boolean pointup, String direction, BlockStateArgument block,
|
||||||
Predicate<CachedBlockPosition> replacement){
|
Predicate<CachedBlockPosition> replacement){
|
||||||
|
int succeeded=0;
|
||||||
|
|
||||||
if(direction=="x"){
|
if(direction=="x"){
|
||||||
drawConex(source, pos, radius, height, pointup, block, replacement);
|
drawConex(source, pos, radius, height, pointup, block, replacement);
|
||||||
|
succeeded=1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(direction=="y"){
|
if(direction=="y"){
|
||||||
drawConey(source, pos, radius, height, pointup, block, replacement);
|
drawConey(source, pos, radius, height, pointup, block, replacement);
|
||||||
|
succeeded=1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(direction=="z"){
|
if(direction=="z"){
|
||||||
drawConez(source, pos, radius, height, pointup, block, replacement);
|
drawConez(source, pos, radius, height, pointup, block, replacement);
|
||||||
|
succeeded=1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(direction!="x" && direction!="y" && direction!="z"){
|
if(direction!="x" && direction!="y" && direction!="z"){
|
||||||
Messenger.m(source,"Invalid direction, must be \"x\",\"y\" or \"z\"");
|
Messenger.m(source,"Invalid direction, must be \"x\",\"y\" or \"z\"");
|
||||||
}
|
}
|
||||||
return(1);
|
return succeeded;
|
||||||
}
|
}
|
||||||
|
|
||||||
private static int drawConey(ServerCommandSource source, BlockPos pos, int radius, int height, boolean pointup, BlockStateArgument block,
|
private static int drawConey(ServerCommandSource source, BlockPos pos, int radius, int height, boolean pointup, BlockStateArgument block,
|
||||||
|
|||||||
Reference in new issue
Block a user