Initial commit

Signed-off-by: Grafe <flingelfrank@hotmail.com>
This commit is contained in:
Grafe 2013-02-10 23:24:30 +01:00
commit 80c21409c9
5 changed files with 80 additions and 0 deletions

20
.gitignore vendored Normal file
View File

@ -0,0 +1,20 @@
# Eclipse stuff
/.classpath
/.project
/.settings
# NetBeans
/nbproject
/build.xml
# vim
.*.sw[a-p]
# various other potential build files
/build
/bin
/dist
/*.jardesc
# Mac filesystem dust
.DS_Store

9
plugin.yml Normal file
View File

@ -0,0 +1,9 @@
name: Brewery
version: 0.1
main: com.dre.brewery.P
authors: [Frank Baumann]
softdepend: [Vault]
commands:
brewery:
description: Reference command for Brewery.
aliases: [brew,br]

View File

@ -0,0 +1,5 @@
package com.dre.brewery;
public class Barrel {
}

View File

@ -0,0 +1,29 @@
package com.dre.brewery;
import org.bukkit.plugin.java.JavaPlugin;
import com.dre.brewery.listeners.BlockListener;
public class P extends JavaPlugin{
public static P p;
//Listeners
public BlockListener blockListener;
@Override
public void onEnable(){
p = this;
//Listeners
blockListener = new BlockListener();
p.getServer().getPluginManager().registerEvents(blockListener, p);
}
@Override
public void onDisable(){
}
}

View File

@ -0,0 +1,17 @@
package com.dre.brewery.listeners;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.block.SignChangeEvent;
public class BlockListener implements Listener{
@EventHandler
public void onSignChange(SignChangeEvent event){
String[] lines = event.getLines();
if(lines[0].equalsIgnoreCase("[Barrel]")){
event.getPlayer().sendMessage("Barrel created!");
}
}
}