Today I finally broke down the last barrier preventing me from learning java: the inability to use the command javac from the command line. Now I'm beginning to learn, and it would be great to have some help from the community too!
So far, I've used Java From the Ground Up, and made a Hello, World! program. Please post links to resources and tutorials to help people like me!
Edit: I now made a dev blog, 16skittles.tumblr.com! All my java achievements will go there, although they don't really matter much.
Last edited by 16Skittles (2012-02-02 18:08:05)
Offline
Magmawulf wrote:
@poopo: Netbeans is great, isn't it?
@All: I want to get the mcp working with Netbeans though.
Yes.
I know how to make it work with NetBeans.
1)Make a new project named Minecraft
2)Drag and drop all the minecraft .java files to Minecraft\src
Viola! you can edit the files in netbeans. You can't run it since it needs the other jars but you can have netbeans superior error catching skill behind you.
Offline
I'll try netbeans, so far I've been using notepad++. It's good for syntax checking in HTML and such, but besides that it isn't really good for much.
It is great to be cross-platform and such, but it really is annoying that file names are case sensitive.
Last edited by 16Skittles (2012-02-02 17:41:18)
Offline
Java's way too complicated for me :c
Offline
RedRocker227 wrote:
Java's way too complicated for me :c
Sames
I just don't get it!
Offline
fungirl123 wrote:
RedRocker227 wrote:
Java's way too complicated for me :c
Sames
I just don't get it!
Well, to be fair, I haven't actually tried it XD But if Stencyl blows my mind, and that's supposed to be the next step up from Scratch, then there's not really much point in even trying to learn Java :l
Offline
I suggest trying Java, it is commonly used, and no programming language is easy without good tutorials. Right now, I'm going through the Official Java Tutorials and they seem to be good (duh).
Also, NetBeans is MAGICAL!!! No need to remember those stupid declarations!
But on the other hand, I can't feel like a h4x0r by typing in command line. Oh well, I might as well make a hacking game in Java to really feel like a hacker XD
Edit: Thank you moderator!
Last edited by 16Skittles (2012-02-02 18:43:25)
Offline
I prefer Eclipse. MCP has built-in support for it.
Offline
Meh, I think I'll stick with Netbeans for now. Although I must say, Java is much easier and more fun than I thought it would be! In the Java tutorial, I am currently around the if-then and if-then-else part.
Offline
16Skittles wrote:
Meh, I think I'll stick with Netbeans for now. Although I must say, Java is much easier and more fun than I thought it would be! In the Java tutorial, I am currently around the if-then and if-then-else part.
Maybe make a mod for Minecraft. Use the Minecraft Coders Pack, and figure out how to use it with Netbeans. It comes with builtin Eclipse support, and I prefer eclipse a lot more. But you can also manually edit the files with any text editor and use recompile/startclient/startserver files that come.
Offline
ihaveamac wrote:
16Skittles wrote:
Meh, I think I'll stick with Netbeans for now. Although I must say, Java is much easier and more fun than I thought it would be! In the Java tutorial, I am currently around the if-then and if-then-else part.
Maybe make a mod for Minecraft. Use the Minecraft Coders Pack, and figure out how to use it with Netbeans.
Please note my earlier statement.
Anyone want to make a program with me? We can use the java.net team server built into netbeans.
Offline
ihaveamac wrote:
16Skittles wrote:
Meh, I think I'll stick with Netbeans for now. Although I must say, Java is much easier and more fun than I thought it would be! In the Java tutorial, I am currently around the if-then and if-then-else part.
Maybe make a mod for Minecraft. Use the Minecraft Coders Pack, and figure out how to use it with Netbeans. It comes with builtin Eclipse support, and I prefer eclipse a lot more. But you can also manually edit the files with any text editor and use recompile/startclient/startserver files that come.
Lol, I'm not that advanced yet, this is only my first day in Java! I have managed to make a (not really) useful program, basically a bruteforce program that can guess a number (defined in the code, I haven't gotten to input yet) by repeatedly adding one to the variable. It isn't much, but in it I managed to make it probably more complicated than it needs to be by implementing Boolean.
Here's my code:
Instead of this, which will go until it reaches the number only,
package javasandbox; public class JavaSandbox { public static void main(String[] args) { //This java file is specifically for testing random stuff! Delete the remaining code and start fresh! //This Program will repeatedly try a number until it reaches the predefined number. int counter = 0; boolean correct = false; while(counter != 45){ counter = counter + 1; } System.out.println( "And the number is... *drumroll*"); System.out.println( counter); } } }
//This stuff is just the necessary things to open a file, it is necessary for the compiler, but does virtually nothing to affect the code package javasandbox; public class JavaSandbox { public static void main(String[] args) { //This java app is specifically for testing random stuff! Delete the remaining code and start fresh! //This Program will repeatedly try a number until it reaches the predefined number. /**All variables must be declared before we can use them. int counter = 0; declares *that counter is an integer and is equal to zero to begin. *boolean correct = false; declares that correct is a boolean (has two states, true or *false) and begins equal to false. */ int counter = 0; boolean correct = false; /**The while() statement makes it so that while the boolean correct is false, the *within the { } will be executed. */ while(correct == false){ //This statement just adds one to the value of counter counter = counter + 1; /**This statement is just like the if in Scratch. If the counter equals 45, it will *Set the boolean correct to true, completing the while() loop and allowing the code *to output the value. */ if (counter == 45){ correct = true; } } //This is simple, it will output "And the number is... *drumroll*" followed by the //value of counter System.out.println( "And the number is... *drumroll*"); System.out.println( counter); } } }
This code uses a Boolean to check whether or not the number is correct. If you want to see how it works, I added a few extra comments in the bottom one.
Offline
16Skittles wrote:
ihaveamac wrote:
16Skittles wrote:
Meh, I think I'll stick with Netbeans for now. Although I must say, Java is much easier and more fun than I thought it would be! In the Java tutorial, I am currently around the if-then and if-then-else part.
Maybe make a mod for Minecraft. Use the Minecraft Coders Pack, and figure out how to use it with Netbeans. It comes with builtin Eclipse support, and I prefer eclipse a lot more. But you can also manually edit the files with any text editor and use recompile/startclient/startserver files that come.
Lol, I'm not that advanced yet, this is only my first day in Java! I have managed to make a (not really) useful program, basically a bruteforce program that can guess a number (defined in the code, I haven't gotten to input yet) by repeatedly adding one to the variable. It isn't much, but in it I managed to make it probably more complicated than it needs to be by implementing Boolean.
It's pretty easy to do some simple mods. Just use MCP and it deobfuscates it for you. Then you have all these classes like GuiIngame, BlockPiston, etc.
Offline
LOL so much talk about how that dev env is inferior to this one, and I use NotePad!
Offline
poopo wrote:
YOU GUYS NEED TO BUY A BOOK!!!!!!!!!! It makes it so much easier. I suggest
Java 24 hours by rogers cadenhead.
i first learned java from that book
Offline
maxskywalker wrote:
LOL so much talk about how that dev env is inferior to this one, and I use NotePad!
Lol, if you use notepad, the biggest thing you miss is syntax highlighting and automatic tabbing. Other than that it works just fine, but especially for someone learning the syntax it is best to use an IDE
Offline
I made my first program of any real use! In Geometry, we are learning about the Fibonacci Sequence and the Golden Ratio, so I made a program to calculate the first 45 Fibonacci numbers! This is the java class file, but I want to embed it in an HTML document. Any tips on how to do this?
Also, the source code can be found Here, it is a .java file, which can be opened in any text editor.
Offline
poopo wrote:
Magmawulf wrote:
@poopo: Netbeans is great, isn't it?
@All: I want to get the mcp working with Netbeans though.Yes.
I know how to make it work with NetBeans.
1)Make a new project named Minecraft
2)Drag and drop all the minecraft .java files to Minecraft\src
Viola! you can edit the files in netbeans. You can't run it since it needs the other jars but you can have netbeans superior error catching skill behind you.
So how do I rerun it?
Offline
Magmawulf wrote:
poopo wrote:
Magmawulf wrote:
@poopo: Netbeans is great, isn't it?
@All: I want to get the mcp working with Netbeans though.Yes.
I know how to make it work with NetBeans.
1)Make a new project named Minecraft
2)Drag and drop all the minecraft .java files to Minecraft\src
Viola! you can edit the files in netbeans. You can't run it since it needs the other jars but you can have netbeans superior error catching skill behind you.So how do I rerun it?
I think you would need to copy all of the .java files back into the MCP src directory.
Offline