Page 19 of 22 FirstFirst ... 91516171819202122 LastLast
Results 181 to 190 of 211

  Click here to go to the first Developer post in this thread.  

Thread: Take On Java

  1. #181
    Quote Originally Posted by PvPscene View Post
    Does a project space at DH make sense to report issues and make feature requests?
    It is probably a good idea. I'm compiling a list and will be heading over there soon to open some issues.

    Quote Originally Posted by Major_Shepard View Post
    Well with some code like this into jniscripting.jar just think that Maven will be quite useless regarding Java and ArmA 3
    I'm not sure what is special about that code, but I'm already using Maven... If the code can be compiled then it can be compiled by Eclipse, Ant, Maven, Ivy, Gradle, or whatever build system you want to use. Its all just Java.

    Quote Originally Posted by MaHuJa View Post
    A couple issues that come to mind immediately.
    And these are exactly the issues that Ivy/Maven/Gradle et al are attempting to solve. Naming and versioning is a "Hard Problem", exactly for the reasons you've pointed out. Java 8 will improve things, but that is still over a year away. In the mean time it is up to the authors to mix and match versions of code that play nicely together.

    Quote Originally Posted by MaHuJa View Post
    The problem with these thread safe wrappers is that everyone needs to use the same instance.
    I didn't mean to imply that it was a good alternative, just pretty much the only thing we could do if RVEngine wasn't thread safe.

    Quote Originally Posted by MaHuJa View Post
    One did some 149.5k calls to RVEngine.diag_log. I think that crash came when I paused the game.
    That's a stress test! However, at this point there are so many bugs its hard to tell where the real problems are. I've had the game CTD on the statement if (args[0] instanceof GameObject)...

    Quote Originally Posted by MaHuJa View Post
    Maybe groovy++.
    I could live with that. I love the Groovy syntax not the performance, and dynamic typing is Groovy's biggest drawback. However, being able to write something like [a,b,c,d].each { doSomething() } becomes addictive. Once people see how much the TOH Java API uses List objects (and often Lists of Lists) they are going to want a better syntax.

  2. #182
    Here is the project space:
    https://dev-heaven.net/projects/jvm

    If you want tester/reporter status for more permissions/editing possibilities, send me a PM here.

    If you enjoy my work and want to my support efforts doing this for a living,
    please consider to become a patreon - Community Funded Modding!


    (310 of 1000$ per month by 37 patrons reached for first tier)


    Current projects: CUP, AiA TP, AiA SA, AiA HQ, IFA3, Blitzkrieg


    Help: Got a crash? Report it! What is the RPT log file?

  3. #183
    I shall not insult moderators
    Join Date
    Nov 25 2010
    Posts
    1,576
    Would anyone recommend this?:
    http://www.codecademy.com
    Codecademy is the easiest way to learn how to code. It's interactive, fun, and you can do it with your friends.

    JavaScript is a programming language that grew out of a need to add interactivity to web sites within the browser. It has since evolved into an incredibly versatile language that is used for both client-side (within the browser) and server-side (code that serves web pages to users) applications.

    Who is going to be our Mr-Murray for Arma3?

  4. #184
    Master Sergeant Serclaes's Avatar
    Join Date
    Nov 27 2005
    Location
    this town right here
    Posts
    775
    The language itself is not hard to learn. Really, it's a very basic set of tools. What is important is to understand and use all the tools how they should (and not necessarily can) be used.

    From a quick look, codeacademy seems to have some kind of goal driven learning. Meaning you have a goal and should use the tools you have to reach it (as in building a chair instead of just working wood). That should be a good start. You just have to understand that javascript is not java (though iirc it can compile to java bytecode).

    The next step is good practice and then sometime you will find yourself using the last little intricacy of the language. The art there is to keep it simple and not make your life harder by doing so.

  5. #185
    I shall not insult moderators
    Join Date
    Nov 25 2010
    Posts
    1,576
    Quote Originally Posted by Serclaes View Post
    The language itself is not hard to learn. Really, it's a very basic set of tools. What is important is to understand and use all the tools how they should (and not necessarily can) be used.
    Once the exact details are known, I hope someone can suggest some online learning sources. I think many would be grateful if the learning side is given some consideration. Codecademy was suggested to me and while a good code learning site, probably isn't exactly what we need.

  6. #186
    Master Sergeant Serclaes's Avatar
    Join Date
    Nov 27 2005
    Location
    this town right here
    Posts
    775
    Problem is, you can't just learn coding like you learn history. For me coding is a lot about creativity mixed with self discipline and most important: experience.

    But you're right, we need to make it easy for starters to get into java. I could imagine working out a little training. I've been coding java since almost 4 years now but gained the most experience in web frameworks. I'm far away from being an expert, but I'd volunteer to teach java as good as I can. Just let me dig up my old exercises from the university

  7. #187
    Just a couple of general API design comments I wanted to make. It is probably too late to do anything about these comments now, but I consider them serious design flaws so I wanted to say something just in case.

    1. Generics. The API uses raw Collection objects without specifying what they are collections of. This means the compiler can't do any type checking for us to make sure we are passing the values the API expects. Passing the wrong type results in a CTD.

    2. Stop the List madness! Please (please please) do not use Java Lists as a replacement for SQF lists. If you must, use arrays of primitive types, or better yet "unroll" the list contents into separate function parameters.

    Consider a typical SQF function:
    Code:
    light setLightColor [0.3, 0.0, 0.0];
    In Java this becomes RVEngine.setLightColor(GameObject, List)
    Code:
    List red = new ArrayList();
    red.add(new Float(0.3));
    red.add(new Float(0.0));
    red.add(new Float(0.0));
    RVEngine.setLightColor(light, red);
    Ok, we would actually write something like:
    Code:
    RVEngine.setLightColor(light, Arrays.asList(0.3f, 0.0f, 0.0f));
    But the JVM still has to execute the same sequence of instructions. First it has to create a new list object, then it needs to add three floats to the list, but Java collections can't store primitive types like float, so the JVM has to create a java.lang.Float object for each of the numbers.

    That is alot of work for what should be:
    Code:
    RVEngine.setLightColor(light, 0.3, 0, 0);
    With the above we don't have to create a bunch of unnecessary objects simply to pass three values to the game engine, the compiler is able to do type checking for us again, and the compiler is able to coerce values when needed (i.e. int to float).

    Having said all that, I get the sense that the user facing part of the Java API is machine generated, so I am hoping these are things that might be fixed "relatively" easily. Adding Generics is something that has to be done ASAP as adding it later will break all existing code. Getting rid of Lists can be done over time by overriding methods with their listless counterparts, but it's still code bloat that should go ASAP.
    Last edited by Slapstick; Mar 4 2012 at 03:29. Reason: Fix

  8. #188
    I'll distill all my observations into a one-liner:
    It's basically at the stage of proof-of-concept-that-you-can-load-java-code-and-have-things-happen.

    So yeah, that one was definitely machine generated. See also my list of things at page 16 - some of which are absolutely critical.

  9. #189
    Quote Originally Posted by PELHAM View Post
    Once the exact details are known, I hope someone can suggest some online learning sources. I think many would be grateful if the learning side is given some consideration. Codecademy was suggested to me and while a good code learning site, probably isn't exactly what we need.
    Hello PELHAM,

    If you are looking for an online video tutorials you can refer to this link(http://thenewboston.org/tutorials.php) where you can learn more than just Java, and they are all free.

    Anyways, if you navigate to the tutorials section and search for the java beginner and start your way from there. You will start learning from the very basic, including how to install the JDK, and eclipse. And as you get comfortable, you move to higher level tutorials. Another very important link you should always refer to is : http://docs.oracle.com/javase/7/docs/api/ .

    Good luck, if you have any questions you can send me a PM.

  10. #190

    Thumbs up

    Guys you definitely deserve my money more than any other game developers in world.
    But please, heavily improve the animations in Arma3, cause in Arma2 it was not good at all and it is very much needed.

Page 19 of 22 FirstFirst ... 91516171819202122 LastLast

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •