Self-Teaching Java [HowTo]

Discussion in 'Bukkit Discussion' started by xYourFreindx, Aug 11, 2014.

Thread Status:
Not open for further replies.
  1. I, along with many other newer bukkit devs...
    Have never taken a java class.
    Everything we do, we've either picked up from tutorials or trial and error.

    Following tutorials is nice.... But everything you learn is one sided. From one (probably not all that qualified to teach) guy. And his bad habits, become yours.

    Trial and error is great too... But the solutions may or may not even be legitimate, or they may not be able to be reproduced when you come across a similar problem, and you'll en up stumbling through the same thing over and over, every time you have to do it.

    Not all of are capable of taking classes.
    Whether it be because of financial trouble, or the school we tend.

    My question to all bukkit devs out there, (hopefully someone who's been in the same shoes),
    How did you do it?

    Did you use on of those "treehouse" or related sites?
    Did you find a more experienced dev to walk you through your journey?
    Did you just fumble around like us until you got a real class?

    What would be the best option that us bukkit devs, with minimal java knowledge, could take? ​
     
  2. xYourFreindx I personally would recommend using a Java book, and would definitely leaving plugin development alone until you have learned a sufficient amount of Java. I could make a huge list of the number of threads and problems people have had as a direct result of not knowing Java, and the only solution is to actually learn it. But I'm not one for making long lists (that's a lie).

    Also, I like the poem-esque style you've used here :p
     
    Zupsub likes this.
  3. Offline

    austinv11

    Personally, I had experience in Lua and Javascript, so I understood the basics of coding in any language. But I first learned Java from theNewBoston. He really explains a lot, and he is really easy to follow. Learning to code a plugin, I used the wiki's tutorial on it. But (as with any language) all about trial and error. The more you code and research, the more you know. Wish you the best of luck on your endeavors!
     
  4. AdamQpzm
    Thank you for your reply.
    I appreciate the suggestion. Though I'd like to comment on how I feel about such an attitude...

    Imagine I wanted to spend the rest of my life in Spain.
    And Imagine, that I have not an ounce of knowledge in the spanish language.
    I could..... As you suggest.... Stay in the U.S... Get a job, pay for a house, meet someone... Basically live life, until I've managed to get myself enough knowledge to speak and understand spanish fluently. Now... That may take a few months, or it may take a few years, dependent upon my situation. And then when I finally have learned the language, I'd need to completely transition the life I've made, and make a new one in Spain. Now with the knowledge of their language...
    Or....
    I could jump right up and move to Spain.... Immerse myself in it. Make the life I'll be living for the rest of my days. Of course, it will be more difficult, without the immediate knowledge of the language right at hand... But the best choices aren't always to make everything easy. I'll slowly begin to learn the local styles of language, and eventually, I'll understand just as well as everyone else, and be able to create works of poetry with the language that are completely my own.

    Of course, both options are completely legitimate. And dependent upon the person, who they are, who they want to be. Where they are, where they want to be...
    But for me, personally... I don't care if it's easier to wait a few years until I get the proper knowledge. I'll work hard, and I'll do what I want to do. And I'll do it immediately. Graciously accepting any assistance along the way from all who are willing and able to offer it.
     
  5. Offline

    Necrodoom

    xYourFreindx this is an incompatible analogy for plugin development.
    Trying to learn bukkit API without knowing the Java dependency under it is like saying you want to know how to run without knowing how to walk, or wanting to understand and write Spanish words, without knowing the letters.

    I've seen time and time again people who try to write plugins without any Java knowledge, and it basically ends up being basic Java questions one after another, with the user not knowing much except how to copy-paste bunch of lines that seem to do what he wants.
     
    Zupsub, ZodiacTheories and AdamQpzm like this.
  6. Necrodoom I think you're over exaggerating... And misunderstanding...
    I'm not saying they'll be able to write an awesome plugin first day, no experience....
    I'm saying, JUMP INTO IT, and you'll force yourself to learn java along the way, even if you have no background knowledge....

    Using your examples....
    Try to learn to run, and by the time you've managed it, you will have learned how to walk along the way. (And with great strides)
    And... Well, the spanish thing was completely off.... I consider knowing letters to be common sense, which in that example you insinuate that people don't have. And common sense can easily be applied to any task when reaching for success.

    I'm not afraid to make a few mistakes while coding my plugins.
    Sure I may not have made them had I had previous knowledge, but as I make them, I learn how to correct them, and eventually I'll stop making that mistake.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 9, 2016
  7. Offline

    Necrodoom

    xYourFreindx go and try to run without knowing how to walk, youd need someone to guide you all the way though, and when you want to run uphill, or downhill, you'd need to learn it all over again. Why? Because you don't know how running works. You just know you need to lift and swing the legs in certain ways.

    You cannot learn bukkit API without knowing Java. The only reason people manage to write simple plugins is because bukkit API is extremely forgiving and gives you a lot of freedom. Throw the person into actual modding and it is if he has never learnt Java.

    There is no alternative to knowing the basically properly before moving on. People who try to skip whole libraries of knowledge, thinking they would just somehow pick them up themselves, will become a burden on other people who essentially need to code most of the project for them. Stop trying to tell people to ignore basic common sense, and have them learn Java properly. An API is not a game you just play with, attach some cubes, and get plugins. You need to work for it.

    If you think you can take that broken knowledge, where you just have barely some idea about how a certain API works, and teach people Java off that, you are dead wrong.
    Learn Java properly, then decide if you are able to teach or not.
     
    kekistar, ZodiacTheories and AdamQpzm like this.
  8. Necrodoom
    Luckly for us runners, we have a whole internet full of pre-written tutorials, you tube videos, websites dedicated to "guiding" us. So we have plenty of hands to help us up when we fall and to lead us in the right direction...
    Assuming that everyone will have you or another more experienced person do their coding is very pessimistic, if I do say so... Of course the newbs will need examples. That's part of learning. And not just java... That goes for anything and everything. But that's not to say that everyone who needs an example will take nothing out of it other than a good copy paste. Again, it's individualized. Some people actually want to learn how to run and walk, and others just want you to get them somewhere.
    Bukkit api IS forgiving. That's why it's such a lovely platform for people to learn java through. Make a mistake, and you can easily see it's consequence. Make that mistake enough times, and you'll have learnt something.
     
  9. Offline

    Gerov

    I have learnt and am currently learning from a book called, "Murach's Java Programming 4th Edition" it is a great book, the only thing I don't like about it is that is teaches in Net Beans, but you can get around that, on Amazon it is about $35 USD.
     
  10. Offline

    Necrodoom

    xYourFreindx
    Oh?
    So instead of getting someone to do the work for you, you copy-paste lines off pre-written tutorials. How interesting.
    You want examples, go and understand how they work. Examples are not there for you to copy them. There are for you to understand them.
    If people do not want to learn Java before coding plugins, they should not bother trying to code bukkit plugins either.

    Just because bukkit API is forgiving, in the sense that it won't cause your code to error in all kinds of ways that you can't understand, doesn't mean you need to exploit it. There are already much better ways to learn Java properly.

    All you do it tell people that "you don't need to know Java before coding in it! That's fine!" I had enough of that. People end up following this crap, think they understand Java properly, then go on and post utter bullshit, and the new generation of people who jump straight to bukkit plugins end up reading said bullshit, and think that's how Java actually works. A perfect example exists here: http://forums.bukkit.org/threads/resource-the-complete-list-of-java-keywords.199291/
    This manages to contain so much false information in one thread that any self-respecting Java developer would throw it to hell, but since people like you teach people that Java is not important, they end up following these tutorials and think they are now ready to code everything in Java. And hence you just produced a plugin 'developer' who has no freaking idea what he is doing.
     
    AdamQpzm likes this.
  11. xYourFreindx To add on to what Necrodoom is saying - believe me, you're not the first that maintains that you can learn Java through the Bukkit API. But, time and time again, we see people having problems as a direct result of this attempt. Sure, people will eventually get round to picking up bits and pieces of knowledge, but for the most part they'll not really understand what they're doing. They'll know they should use equals() for Strings, but they won't know why they should. They'll know that they can't have more than one "extends JavaPlugin", but they won't know why they shouldn't. They'll know that their listeners need to implement Listener, but they won't know why it has to.

    The list goes on, but let's draw it back to your Spanish analogy. Learning Java through Bukkit is like learning Spanish through going on holiday there. When you're on holiday in Spain, you'll probably learn a few things that you need to say while there. You might learn "gracias" or "de nada" or "piscina", but you most likely won't learn the grammatical rules or spelling. Just as you wouldn't necessarily learn the rules that make up Java.

    Your analogy is also inaccurate in the sense that, there may be external reasons why someone has to move to Spain before learning the language - life is a very complicated thing and moving is a big deal. Due to financial, safety, legal, or a variety of other reasons too numerous to list, you may have to move much earlier than you would like. With Bukkit & Java programming, this is less of a point. By far the most common reason for wanting to learn Java through Bukkit is impatience. In fact, I've yet to meet someone who has a legitimate reason that doesn't stem from impatience.

    My insincere advice is to back up and learn Java first. Don't touch Bukkit until you're ready. If you don't think you need to do that, then please prove me wrong. I challenge you to create plugins without asking for support on basic Java knowledge :) And I am begging you, do not try to support people with topics that you have not got much experience in. I know you would like to help, and that's an honourable intention (although you may also be doing it to try and help yourself) but a lot of the time it really does more harm than good.
     
  12. Offline

    theguynextdoor

    I think i'm going to write a book. Oh wait, I am illiterate. Do you see the problem here?
     
  13. Necrodoom Copy paste lines off of pre-written tutorials?? What? No. Otherwise I'd be spending my time making something already available to the public and myself. And yes, I know what examples are there for... I use them. Have I ever once said that I prefer to copy paste people's example? If that's how it came across, I'm sorry for the confusion. Examples can be used for more than just copy pasting.... Some people, like I said, just use them to get you to get them somewhere, and other people actually use them to create their own versions, examples, and will take the knowledge that that example provided in solving a problem, and will be able to apply it later on. Aka, learning.

    I am known for encouraging people, yes. And I'm not going to pretend not to be proud of that.
    You do bring up an excellent point.... That people that haven't learned java properly, will act as a model for people who know even less, and there is where bad habits get passed on.
    But, any "self-respecting java developer", who is legitimately interested in learning java, and not in just creating a fun plugin for their server, would, as I'm sure you agree, go far beyond the bukkit forums in search of knowledge. (In case you haven't noticed, it's not filled with the brightest of people. :p) The other people, why worry about? They (the newbs) will either make their plugin(s) and move on, or should they be legitimately interested, they'll continue their education with actual classes in a professional environment, and better resources than what they were provided when making their minecraft plugin.

    The bukkit forums is not anywhere near a professional place to learn java. It will never be, and I don't think we should pretend it is (or will be). It's a community.
    If people are interested in REALLY learning java, they need to take some self responsibility, and not take everything said in this cesspool as gospel. We the community are here to help each other, not to provide an education. People aught to know that. And if they don't want to take that personal responsibility, it is not then your duty, nor anyone else's on this site, to cushion them from any and all "bad habits".

    AdamQpzm
    I do see your point.
    But I reference the statment I made previously... That the people who are actually interested in learning java, will look for the why. They are just as capable of asking a question while doing bukkit, and then going to look up the answer to why.... As they are in a classroom, with basic java.
    I'd also like to point out that many of the newbs you run into who will practice the "I know what but not why" method of bukkit coding... Are NOT interested in learning java. And ARE impatient. They want their plugin and that's where they'll stop their education.

    This thread was NOT meant for them. It was meant for the minority, who are constantly asking themselves "Why" while they learn java through bukkit.
    Recall in my original post, that I did not suggest using bukkit as a soul source for java education. And that is why I've posted this. Not for help learning bukkit, but for java through whatever means necessary when classes are not available.

    EDIT: And, in response to your comment on my "helping" newbs in the development section... You're right the whole way. I do go there to help people with simple problems that I recall myself once having.. Mostly out of empathy, and remembering that when I was at that stage, there were very few people who wanted to help me, because I didn't know anything. Anything. Also, yes, I'm interested in learning. Every time I visit, I learn something new. Like yesterday. The difference between async and sync threads. :p Thanks for that. Anyways... I do recognize that I am no professional, and in every case, when I offer my two cents... I remember to mention that I am not a professional, and am not qualified to answer their questions. I'd like to think I help. But, maybe I should stick to educating myself before I attempt to educate others. Even if I am confident that it's something simple enough for me to handle.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 9, 2016
  14. xYourFreindx Let me ask you the question then: Why do you want to make a Bukkit plugin before you've finished learning the basics of Java?
     
  15. AdamQpzm
    Why do I not dedicate my time to learning java online, instead of learning bukkit API?...

    It started out that I had a server... And nobody had the plugins I needed. And I thought... Gee, I'll take some personal responsibility, and do it myself (I'm too poor to afford a privately made plugin). At that time, I was already working as a voluntary plugin manager for server owners who had a great vision in mind for a server, and the money to pay for it... But no time to manage it. I had done this for at least two dozen servers total (setting up plugins, configuring perms, blah blah... Then keeping in distant touch if they ever needed help upgrading or getting a new plugin). And my skills were pretty freakin good, if I do say so myself. So I started advertising myself, (I loved what I did), and people started asking if I could code custom plugins... And I got sick of having to say no to people... So that, and my need for plugins myself... I decided I'd self teach. It was really freakin hard getting started... Then once I actually got rolling and could customize so many things about how the game worked, I got addicted. I loved it! :D But I was disappointed with the limitations that my lack of java knowledge placed on me... So I tried taking school classes... But the highest level they could offer me didn't even involve java... It was stupid qfreakin basic.... After that class was over... I said screw it, it's going to be a whole year before I can take another class, and that class wont even have java either.... So I've been coding bukkit plugins and trying to learn java at the same time, both through the bukkit task at hand, and watching java tutorials, reading articles, taking free trial classes online....
    And here is where I came for help asking for some references to other resources that could help me learn java.
     
  16. xYourFreindx And as I said, it's rooted in impatience. You have had some resources recommended, and also the genuine advice to leave the bukkit api for now.
     
  17. AdamQpzm I don't think there's a single life choice that can not be sais to somehow be rooted in impatience. We only life for so long, and as we grow older, our choices become more limited. My favorite quote...
    "
    Life is made of choices.
    The smallest, the most insignificant, the thoughtless... Are the ones that define us.
    Do as much of everything as possible, if only to discover all of life's paths; and enable you to choose your own."
    Do as much of everything as possible....
    I'm going to do as much as possible. That includes java and the bukkit api.
    You never know when you're life will end. Ima taste all it's fruits.
    And I do appreciate the resources. That is, mind you, the reason for this thread. To gather resources. Nothing else.
     
  18. xYourFreindx I'm not saying don't do it I'm saying don't do it before you've learned Java. The fact that you don't know how long you're going to live is no excuse, and I doubt you're trying to learn bukkit now because you're worried you'll die before you get the chance, I think you're doing because you can't or won't delay gratification.
     
  19. AdamQpzm I do it because I enjoy it, and I want to continue enjoying it. Why else?
    And since when is the fact that you will die not a valid excuse for doing what you want?
     
  20. xYourFreindx It is an excuse for doing the things you want to do, but it's not an excuse to skip the necessary preparation
     
  21. Offline

    Necrodoom

    Do what you want, but learn java properly first before thinking you can code plugins well, or to provide java support.
     
    timtower likes this.
  22. Necrodoom
    Ok ok..... I'll.. Stop giving java support..... And uh... Lower my expectations of the plugins I make.
    AdamQpzm
    You prepare when you want a specific outcome. Like for a test, you prepare when you want an A. Or for programming, you learn java when you want a good program.... I'm just here for the experience. Bukkit is not my life's work. I'm not going to "prepare" to have a good time and enjoy what I can get out of this.
    The java that I'm learning on the side, that is what I will take with me for the rest of my life. But I'm not going to pause my fun just so I know how to have it better. :p I can learn along the way. Just like any worthwhile adventure.
     
  23. xYourFreindx Then this whole debate is meaningless, you don't understand the core issues.
     
  24. AdamQpzm
    We all, obviously, have different priorities. I've said my piece, y'all have said yours.
    I understand your issue, and I'm sure you can understand where mine is coming from....
    But... We will never agree. We can't change each other's minds.
    So.....
    It was fun debating with you. I'm glad we got to know each other a little better.
     
  25. Offline

    Skye

    I'm the kind of person that hates asking how to do something if I can find the information on my own, which works great for learning how to do anything.

    Pretty much any question a beginner will ask has already been answered; they need only search for it. Finding answers on one's own is great because it will reveal what else needs to be understood before proceeding.

    If someone looks at a code snippet and doesn't understand how it works, then they should look up the parts they don't understand. If the answers contain more elements that aren't understood, then they should also look those up, and so on. For a beginner that doesn't understand Java, most questions they ask will trace all the way back to Java fundamentals. So in the end, they will have to teach themselves Java to ever know what they're really doing.
     
  26. AdamQpzm

    My point still stands.
    (or should I come back in a few years) ​
     
  27. xYourFreindx Hmmph, my point still stands. Regardless of what happens to Bukkit, you still shouldn't be using it before learning Java :)
     
  28. AdamQpzm GOD how can you use a smily face at a time like this??? I'm in tears...
    Screw you and your beliefs... I love bukkit. And working my @$$ off to learn java as I needed it in bukkit was 100% worth all the experience I managed to squeeze out of the time I had with it.....
     
  29. xYourFreindx Because all things come to an end, and because of other reasons :) It's interesting you say that, though, since there's no real connection between the emotions inferred from what I say here and what I really feel, no matter how often the two coincide. As it turns out, this story is not yet over, and I too love Bukkit.
     
  30. Offline

    AronTheGamer

    1: lear HTML
    2: learn JavaScript
    3: learn PHP
    4: java is right around the corner, just read a paper about references and implement the differences in language like . instead of -> an != instead of !==
     
Thread Status:
Not open for further replies.

Share This Page