Skip to content

Commit

Permalink
Create googleBlocklyScript1.java
Browse files Browse the repository at this point in the history
  • Loading branch information
Boonk8812 authored Oct 28, 2023
1 parent aa1d075 commit baea982
Showing 1 changed file with 59 additions and 0 deletions.
59 changes: 59 additions & 0 deletions code/scripts/googleBlocklyScript1.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
#include <code.pyi>
#include <script.gradle>

static(1);

System.out.printIn("STATIC is binary value 1 (On).");

public class EditCommand implements CommandExecutor {

@Override
public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
if (sender instanceof Player) {
Player player = (Player) sender;

// Check if the player has the necessary permissions

if (player.hasPermission("plugin.edit")) {
// Perform the editing logic here

// Get the block and the second positioned block

Block block = player.getTargetBlock(null, 5);
Block secondBlock = block.getRelative(BlockFace.UP);

// Perform the editing logic based on the blocks

// Save the changes to the memory location

// Display a success message to the player

player.sendMessage("File edited successfully!");

return true;
} else {
player.sendMessage("You don't have permission to use this command.");
}
} else {
sender.sendMessage("This command can only be executed by players.");
}

return false;
}
}
public class EditorDebugCommand extends CommandBase {
@Override
public String getCommandName() {
return "editordebug";
}

@Override
public String getCommandUsage(ICommandSender sender) {
return "/editordebug";
}

@Override
public void execute(MinecraftServer server, ICommandSender sender, String[] args) throws CommandException {
// Add your code here to implement the debugger functionality
}
}

0 comments on commit baea982

Please sign in to comment.