This repository was archived by the owner on Oct 22, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +63
-48
lines changed
src/main/java/me/travis/wurstplusthree Expand file tree Collapse file tree 4 files changed +63
-48
lines changed Original file line number Diff line number Diff line change 1+ package me .travis .wurstplusthree .command .commands ;
2+
3+ import me .travis .wurstplusthree .WurstplusThree ;
4+ import me .travis .wurstplusthree .command .Command ;
5+ import me .travis .wurstplusthree .hack .combat .Burrow ;
6+ import me .travis .wurstplusthree .manager .ConfigManager ;
7+ import me .travis .wurstplusthree .util .ClientMessage ;
8+ import me .travis .wurstplusthree .util .WhitelistUtil ;
9+ import net .minecraft .block .Block ;
10+
11+ import java .io .IOException ;
12+
13+ /**
14+ * @author Madmegsox1
15+ * @since 08/05/2021
16+ */
17+
18+ public class BurrowBlockCommand extends Command {
19+ public BurrowBlockCommand (){
20+ super ("BurrowBlock" , "bb" );
21+ }
22+ String bBlock = "" ;
23+
24+ @ Override
25+ public void execute (String [] message ) {
26+ Burrow bClass = (Burrow ) WurstplusThree .HACKS .getHackByName ("Burrow" );
27+ Block b = new WhitelistUtil ().findBlock (message [0 ]);
28+
29+ if (b .equals (null )){
30+ ClientMessage .sendMessage ("Cannot set Block to " + message [0 ]);
31+ return ;
32+ }
33+ bClass .setBlock (b );
34+ ClientMessage .sendMessage ("Set Block to " + message [0 ]);
35+ bBlock = message [0 ];
36+ try {
37+ WurstplusThree .CONFIG_MANAGER .saveBurrowBlock ();
38+ }catch (IOException e ){
39+ }
40+ }
41+
42+ public String getBBlock (){
43+ return bBlock ;
44+ }
45+
46+ public void setBBlock (String b ){
47+ bBlock = b ;
48+ }
49+ }
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ package me .travis .wurstplusthree .util ;
2+
3+ import net .minecraft .block .Block ;
4+
5+ /**
6+ * @author Madmegsox1
7+ * @since 08/05/2021
8+ */
9+
10+ public class WhitelistUtil {
11+ public static Block findBlock (String name ){
12+ return Block .getBlockFromName (name );
13+ }
14+ }
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments