Ok well here is my problem. I have made the basics to this plugin i am fiddling around with, for my first project. And i have ran into this problem. So i have 3 classes BlastPick.java, BlastPickPlayerListener.java, BlastPickBlockListener. and in my PlayeListener i have 2 methods onPlayerCommand and onLength. Code: public void onPlayerCommand(PlayerChatEvent event) { //Make the message a string. String[] split = event.getMessage().split(" "); //Get the player that talked. Player player = event.getPlayer(); //If the first part of the string is /BlastPick or /b then do this. if ((split[0].equalsIgnoreCase("/BlastBox"))) { //Run the method toggleVision for player plugin.toggleVision(player); event.setCancelled(true); } } Code: public int onLength(PlayerChatEvent event) { String s; int Length = 0; String[] split = event.getMessage().split(" "); if ((split[0].equalsIgnoreCase("/BlastLength"))) { s = split[1]; Length = Integer.parseInt(s.trim()); } return Length; } And see i want to use the return value i get from onLength in my BlockListener class but don't know how? Also Thanks for responding.
I think the plugin development section is more appropriate for this thread, try re-posting there and you will get a good answer http://forums.bukkit.org/forums/plugin-development.5/