Skip to content

Instantly share code, notes, and snippets.

@ryanwarsaw
Created August 3, 2014 19:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ryanwarsaw/527bdb4beb2556fabde0 to your computer and use it in GitHub Desktop.
Save ryanwarsaw/527bdb4beb2556fabde0 to your computer and use it in GitHub Desktop.
SignListener
private static class SignListener implements Listener {
@EventHandler()
public void onSignWrite(SignChangeEvent sign) {
Player player = sign.getPlayer();
for(int x = 1; x < 5; x = x+1) {
if(sign.getLine(x).equalsIgnoreCase("<3")) {
sign.setLine(x, "<heart>");
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment