1
Bukkit Development Help
Hello there! I have wonderer a while now how to make strings in bukkit. What i mean by that is if i type (Example: /setmessage 1 Hello There Everyone!
And it says that message when someone does /message show?
I mean i wonder how to set things without configs!
Hope you understand!
Thanks for a reply!
~Garneift~
And it says that message when someone does /message show?
I mean i wonder how to set things without configs!
Hope you understand!
Thanks for a reply!
~Garneift~
19
omg guys i went through this and n one gave any help whatsoever
public boolean onCommand(CommandSender sender, Command command, String name, String[] args) {
Player player = (Player) sender; {
if(cmd.getName().equalsIgnoreCase("setmessage") {
if(args.length == 3) {
if(args[0].equalsIgnoreCase("hello") {
if(args.[1].equalsIgnoreCase("there") {
if(args.[2].equalsIgnoreCase("Everyone") {
//THEN PUT YOUR CODE HERE
}
}
}
}
}
}
}
public boolean onCommand(CommandSender sender, Command command, String name, String[] args) {
Player player = (Player) sender; {
if(cmd.getName().equalsIgnoreCase("setmessage") {
if(args.length == 3) {
if(args[0].equalsIgnoreCase("hello") {
if(args.[1].equalsIgnoreCase("there") {
if(args.[2].equalsIgnoreCase("Everyone") {
//THEN PUT YOUR CODE HERE
}
}
}
}
}
}
}
https://www.youtube.com/watch?v=YkcrFfVyDZM <-- tutorial
"if(Args.length == something)"
I never knew how to decompile a jar in eclipse just how to add it to the build path troll!
I wrote some Bukkit tutorials ages ago, click my profile and try those.
Not trying to be rude, but OP really isn't ready to make Bukkit plugins if he/she
doesn't know how to save Strings in a text file and thinks that you can save
Strings without one. Programming knowledge is required to make anything
original or decent.
doesn't know how to save Strings in a text file and thinks that you can save
Strings without one. Programming knowledge is required to make anything
original or decent.
Taking a lot longer than I thought. May be a while longer yet.
Ok
Also,,, Thanks
Or something like that
Just TestMessage
What do you want the plugin folder to be called? I will have a file to store messages. You can edit it the file.
So, my files got corrupted and I lost the source code. Got to rewrite it. *FACEDESK*
If you have the JAR, decompile it?
@OP All you have to do is make
a String and save it into a text file,
then when the plugin stops/starts you save/load the data.
You say you want to do it without a file, but if you had any programming
experience you would know that this is not possible. How will the server
know about your variable after it stops/reloads and wipes all the variables
unless you save it somewhere?
@OP All you have to do is make
a String and save it into a text file,
then when the plugin stops/starts you save/load the data.
You say you want to do it without a file, but if you had any programming
experience you would know that this is not possible. How will the server
know about your variable after it stops/reloads and wipes all the variables
unless you save it somewhere?
Ok finding it now coz my old pc is slow as hell
weakwizardsucks2SnapsCraftHello there! I have wonderer a while now how to make strings in bukkit. What i mean by that is if i type (Example: /setmessage 1 Hello There Everyone!
And it says that message when someone does /message show?
I mean i wonder how to set things without configs!
Hope you understand!
Thanks for a reply!
~Garneift~
Also, by /message show, do you mean /showmessage 1?
Yeah i did. Thanks
You could save it in the plugin.yml
SnapsCraftHello there! I have wonderer a while now how to make strings in bukkit. What i mean by that is if i type (Example: /setmessage 1 Hello There Everyone!
And it says that message when someone does /message show?
I mean i wonder how to set things without configs!
Hope you understand!
Thanks for a reply!
~Garneift~
Also, by /message show, do you mean /showmessage 1?
I did this in one of my plugins on my old pc. Will pm you with code
EDIT: Code is in Java BTW
EDIT: Code is in Java BTW
