This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Arduino.h> | |
const int greenLED = 10; | |
const int orangeLED = 9; | |
const int redLED = 8; | |
const int volPin = A2; | |
int dt = 250; | |
int readVal = 0; | |
float volts = 0; | |
void setup() { | |
// put your setup code here, to run once: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Override | |
public boolean onCommand(CommandSender sender, Command command, String label, String[] args) { | |
if (command.getName().equalsIgnoreCase("heal")) { | |
if (sender instanceof Player) { | |
Player player = (Player) sender; | |
player.setHealth(20); | |
player.setFoodLevel(20); | |
} | |
} | |
return true; |