Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (538)
Games in Android Showcase (132)
games submitted by our members
Games in WIP (600)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: 1 2 [3] 4 5 6
  ignore  |  Print  
  JDK 8 is released  (Read 9886 times)
0 Members and 1 Guest are viewing this topic.
Offline Roquen
« Reply #60 - Posted 2014-03-20 09:13:36 »

Not many people are concerned.  And if you're a rare person that actually uses javac and using lambdas then avoid the construct until it's fixed.  Eclipse uses neither javac nor is the compiler based on jikes.  The bug isn't VM related so it's annoying but marginal.
Offline Mac70
« Reply #61 - Posted 2014-03-20 09:58:08 »

Is NetBeans affected by this bug?

Check out my Devblog! Smiley
Offline princec

« JGO Spiffy Duke »


Medals: 429
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #62 - Posted 2014-03-20 10:01:15 »

The biggest difference between Java and JavaScript is the Client File Access doesn't exist with the base API. You have to download a separate application just to get any sort of access to the client. In every other language, this functionality is built into the language so with a bit of permission flips, you can just access whatever you want to access and that is it. JavaScript's sandbox is literally that, you have no access to altering the files of the client PC, period.
The APIs provided by browsers in JavaScript just keep on expanding. There are already file access APIs in JS. It won't be long before JavaScript's limitations start annoying companies like Google and Microsoft and they start adding APIs to access the local filesystem, and then the next thing you know...

Quote from: ctomni231
If lambda's are the "BIG FEATURE" that everyone is talking about in Java 8, undeniably, this language is in grave trouble. I mean, we already have Scala, why should this be the most prominent feature? What I hope to see, is Java working hard to keep itself relevant. As it stands, even Unity is getting WebGL cross platform support with iOS and Android by working with Mozilla. If Java can't break its way into getting deals like its competitors can, it'll remain a niche language... and we all know what happens to those. Sad
Java is bigger and more important elsewhere than the relatively niche use case that Unity has. Scala is a giant mess of a language, and therefore unlikely to catch on. Instead of running off and saying "right I'm gonna make my OWN language, with blackjack! And hookers!" like Scala and Kotlin etc. the Java language evolves slowly and carefully, gradually simmering us frogs as we get used to the new stuff.

Cas Smiley

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Roquen
« Reply #63 - Posted 2014-03-20 10:16:40 »

I don't feel like making an argument for lambdas 'cause we've already done that a number of times.  If you're on the side-lines then wait a few months and see if there are use-cases that interest you.  A shortish answer is that plain old java can now access invokedynamic to some extent which is a good thing.

This is the bit that slightly concerns me. <snip> ... but lambda expressions seem to me more like making the syntax more compact but more difficult to read by taking away a bit of context.
<snip>.. but do lambda expressions actually offer more beyond that?
So to rephrase your question: "Do lambdas do anything other than make some programming techniques drastically easier and in some cases move from either major PITA to impossible to 'not too bad'"?  Anything beyond that?  Well the short answer is yes.  The long answer is pretty long.  One example is half-assed faking of lambdas requires a class per implementation where with lambdas is may be a class, or multiple might be baked into a single class or no extra class is needed...less load/link/compile, less garbage and more opportunities for the backend compiler to reason.  Another is real immutables.  Just wait and see.  (Oh and again, lambda in java has never been a high priority for me...so this ain't self-interest reasoning)
Offline gouessej
« Reply #64 - Posted 2014-03-20 10:38:56 »

Eclipse uses neither javac nor is the compiler based on jikes.
Eclipse Compiler for Java is written in Java but was originally inspired by Jikes if you prefer.

Is NetBeans affected by this bug?
I think Netbeans is affected by this bug but I can't be sure as I haven't switched to OpenJDK 1.8 yet. You can look at the bug report, there are 2 very short examples allowing to reproduce it.

Offline mike_bike_kite

Senior Devvie


Medals: 1
Projects: 2



« Reply #65 - Posted 2014-03-20 12:30:21 »

If you need some help to get rid of those warnings, let me know. I agree with you but I'll probably have to buy a "trusted" certificate Sad
I tried to PM you but you don't seem to have that facility. What is possible regarding all the warnings? Should I start another thread?

Arcade swarm
Board Chess - Checkers - Othello
Offline kappa
« League of Dukes »

JGO Kernel


Medals: 80
Projects: 15


★★★★★


« Reply #66 - Posted 2014-03-20 13:13:07 »

Not sure why people even bother with Java Web Start and Applets anymore, these distributions methods are effectively dead, they have lost their once 80%+ market share (which they'll never gain back) and its only going to drop further, Oracle should just remove them in Java 9 (or make them an external component from the JRE distribution). They never did get client side distribution right and its too late for such methods to succeed on todays internet.

Also browser plugins in general are also pretty much on the way out, the new hotness these days are pluginless technologies like ASM.js and Emscripten. Even plugins that that did almost everything right (e.g. Unity Web Player) have realised this and are moving over to Asm.js.

Being able to run stuff like Unity3d, Unreal Engine 4, etc at near native speeds without a plugin is pretty much the killer tech now. Java as a plugin has pretty much no future on the web anymore, hopefully won't be long before pluginless JVM's that run in the browser start appearing (possibly when something like ASM.js gets support for handling managed languages).
Offline kpars

JGO Kernel


Medals: 119
Projects: 5
Exp: 4 years


Radirius Games


« Reply #67 - Posted 2014-03-20 13:55:57 »

Not sure why people even bother with Java Web Start and Applets anymore, these distributions methods are effectively dead, they have lost their once 80%+ market share (which they'll never gain back) and its only going to drop further, Oracle should just remove them in Java 9 (or make them an external component from the JRE distribution). They never did get client side distribution right and its too late for such methods to succeed on todays internet.

This.

I wasn't that annoyed when Applets were basically destroyed a few weeks ago, they aren't worth using anymore IMO.

- Jev

Offline mike_bike_kite

Senior Devvie


Medals: 1
Projects: 2



« Reply #68 - Posted 2014-03-20 16:49:25 »

That's all well and good but if you've already spent time creating the damn things then you want them to continue working. What you don't want is the language to suddenly change and make all your stuff either obsolete or so difficult to run that any rational end user would simply give up. I also don't want to have to rewrite my code just so they can continue working with whatever flash in the pan technology is introduced with each time. I believe most languages, including Java, try to ensure that, once you write a program, it will stay working in future versions. That's not the case here.

Webstart suited me great because a user could run an application from the web and/or install it on his desktop with a nice icon. Additionally, I could offer updates and these would be passed out to users meaning I don't have to worry about umpteen different versions of the program being active at the same time. The user didn't need a degree in IT to run them either. As a final benefit I didn't have to send out anything from my server unless there was an software update so I had less bandwidth issues.

I could embrace ASM.js or Emscripten (whatever they are) but who's to say they won't be just as obsolete in a years time. I simply want some stability. If I had a set of features that worked well (webstart) then I don't want all that capability to just disappear over night. It took me quite a while to embrace webstart because I wanted to make sure I wouldn't have the rug pulled from underneath me. I guess I didn't wait long enough  Sad

Perhaps in a few years I might understand what lamda expressions are or I might even find some rational use for them. For the moment you'll have to forgive me that I'm not jumping up and down for joy with the latest Java version  Undecided

Arcade swarm
Board Chess - Checkers - Othello
Offline gouessej
« Reply #69 - Posted 2014-03-20 23:01:22 »

If you need some help to get rid of those warnings, let me know. I agree with you but I'll probably have to buy a "trusted" certificate Sad
I tried to PM you but you don't seem to have that facility. What is possible regarding all the warnings? Should I start another thread?
You can send me a private message, another JGO user succeeded in doing so, he asked me some help and he fixed a regression in my MD3 loader. I agree with you, I just want to go on using it even though it isn't perfect. I'll just try to use only OpenJDK even under Windows in the next years, we still need to port Icedtea-web to Windows.

Just make it simple, set those nasty manifest attributes (Permissions, Codebase, application name, Trusted-only, ...), sign your JARs with a "trusted" certificate and that's fine. I have used Java Webstart since 2006, I'm accustomed to its bugs and its limitations. For example, my source code that creates a desktop shortcut under Linux in KDE was used to fix this feature in OpenJDK and probably Oracle Java, it was already working correctly with GNOME. Some versions still fail in parsing correctly java-vm-args, the list is quite long.

I still disagree with kappa about the speed even though ASM.js gives a noticeable boost. That's why several JogAmp contributors still work on JiGong and cooperate with the OpenJDK team. I want to encourage people to use OpenJDK + Icedtea-web everywhere even on high end mobile phones. Imagine a reliable replacement of Java Webstart working both in desktop and mobile environments, then the real "app store" can be ... Internet  Grin You don't have to pay Apple, Google and their friends  Grin

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline badlogicgames

« JGO Bitwise Duke »


Medals: 74
Projects: 2



« Reply #70 - Posted 2014-03-20 23:24:39 »

'm awaiting with interest when the same sorts of things inevitably turn up in JavaScript.

Cas Smiley

i have a feeling that day isn't so far away. It will be glorious.

http://www.badlogicgames.com - musings on Android and Java game development
Offline gouessej
« Reply #71 - Posted 2014-03-21 09:07:44 »

'm awaiting with interest when the same sorts of things inevitably turn up in JavaScript.

i have a feeling that day isn't so far away. It will be glorious.
I'm impatient, I will laugh a lot when it happens but Mozilla, Google and their friends will do their best to make their popups not too scary in order to favor their baby.

Offline kappa
« League of Dukes »

JGO Kernel


Medals: 80
Projects: 15


★★★★★


« Reply #72 - Posted 2014-03-21 15:31:43 »

No need to wait, it already happens regularly (e.g. at least annually at events like pwn2own).

@gouessej - it was never about speed (e.g. see flash vs java and why flash succeded over java on the web despite being inferior in most things), its all about ease of use and availability for end users, gone are the days when users would put up with the hassle of installing a third party plug ins (possibly with bundled malware), or being unavailable on mobile and walled gardened platforms, the additional security hoops placed by browsers and the constant nagging of the plugin to update itself as well as being another possible target for security exploits. Further normal HTML, CSS and Javascript have matured to a point where plugins are mostly no longer needed to fill a gap left due to missing functionality. That's why third party plug-in can't succeed anymore.
Offline jacobgood1

Senior Newbie





« Reply #73 - Posted 2014-03-21 16:32:35 »

Lambda expression allow you to pass around blocks of code, a very powerful, expressive feature.

A pseudo code example.

someFn(lambda){

    do some stuff default crap right here;
    //now launch some code I passed in right here...
    lambda();
}
Offline opiop65

JGO Kernel


Medals: 160
Projects: 7
Exp: 3 years


JumpButton Studios


« Reply #74 - Posted 2014-03-21 18:38:52 »

I think most of us here know what lambdas expressions are... but thank you?

Offline Drenius
« Reply #75 - Posted 2014-03-21 18:59:36 »

I did not, so really thank you.
Offline Gibbo3771
« Reply #76 - Posted 2014-03-21 20:47:46 »

Neither did I, however I can see how overpowered that can be, if I understand you can pass methods...?

"This code works flawlessly first time and exactly how I wanted it"
Said no programmer ever
Online BurntPizza

« JGO Bitwise Duke »


Medals: 287
Exp: 5 years



« Reply #77 - Posted 2014-03-21 20:48:58 »

See the tutorial I linked in the OP for all your Java 8 needs! It's actually pretty good.
The official Oracle tuts also cover everything, but the one I linked has it all in one place and is intuitive and succinct.
Offline Andre Lopes
« Reply #78 - Posted 2014-03-21 22:51:02 »

See the tutorial I linked in the OP for all your Java 8 needs! It's actually pretty good.
The official Oracle tuts also cover everything, but the one I linked has it all in one place and is intuitive and succinct.

Though it seems NB 8.0 projects arent compatible with NB 7.2

Sad
Offline gene9

Senior Devvie


Medals: 10



« Reply #79 - Posted 2014-03-21 23:13:47 »

If lambda's are the "BIG FEATURE" that everyone is talking about in Java 8, undeniably, this language is in grave trouble. I mean, we already have Scala, why should this be the most prominent feature? What I hope to see, is Java working hard to keep itself relevant. As it stands, even Unity is getting WebGL cross platform support with iOS and Android by working with Mozilla. If Java can't break its way into getting deals like its competitors can, it'll remain a niche language... and we all know what happens to those. Sad

- Java 8, is not just the language, it's the VM and platform, which is used by Scala, Clojure, Groovy, and the rest.
- Scala is much better than Java/C#... if you can get past the learning curve. It's very foreign to many regular programmers.
- Java 8 is catching up. If you can learn Scala, that is better. Scala still needs the Java platform. For some people, Scala is too complex, or they have to use Java for some reason.
- C/C++ are pretty terrible from a syntax perspective. Worse than even Java/C#. C/C++ have important advantages, very low level, can work with absolutely anything, ingrained in some communities.
- For games, Java is really niche. For everything else, Java is extremely popular.
- "getting deals"? No one has pushed Java for games, and you're right, Java isn't popular for game dev. Technically, it would be a good fit though.

Offline gene9

Senior Devvie


Medals: 10



« Reply #80 - Posted 2014-03-21 23:15:39 »

Java as a plugin has pretty much no future on the web anymore, hopefully won't be long before pluginless JVM's that run in the browser start appearing (possibly when something like ASM.js gets support for handling managed languages).

Agreed completely. Java is great, the ecosystem and tool system is amazing. But the web plugin system has been terrible for many years now.
Offline gene9

Senior Devvie


Medals: 10



« Reply #81 - Posted 2014-03-21 23:39:52 »

Perhaps in a few years I might understand what lamda expressions are or I might even find some rational use for them. For the moment you'll have to forgive me that I'm not jumping up and down for joy with the latest Java version  Undecided

Two easy steps to see the practical value in the basics of lambdas and fp:

1) Whenever you manually iterate through a collection, try to replace it with a functional equivalent. Use functions like "map", "filter". You can do that in Java 8, Scala, or JavaScript or Ruby or Python. With Java 8, you need to do ".stream()" on your collection to use the functional functions. You can also do this in Java 6/7 with the Functional Java library. That is somewhat hardcore though. The Java 8 stuff is easier to use.

2) With Java 8, use Optional to represent nullable types rather than just raw nullable types, especially for return values. It can make your code much more concise and easy to read.
Offline gene9

Senior Devvie


Medals: 10



« Reply #82 - Posted 2014-03-21 23:46:09 »

Java is bigger and more important elsewhere than the relatively niche use case that Unity has.

In games, C# is bigger mainly due to Unity and Playstation deals. Outside of games, Java is bigger in various data, science, academic, and server functions.

Scala is a giant mess of a language, and therefore unlikely to catch on.

Scala is extremely elegant and is catching on in a big way! What don't you like?

Try the assignments in this class by the creator of the language:

https://www.coursera.org/course/progfun

You will see the elegance of it if you get into it. Java/C# are ugly hacks in comparison and you see many things that were fixed. I've listed the flaws before, but for example why do C# and Java use a completely different syntax for arrays than for generics? Legacy reasons. It's nice to see Scala fix that so arrays use generics and compile to the same byte code as Java arrays so there is no runtime difference.
Offline HeroesGraveDev

JGO Kernel


Medals: 309
Projects: 11
Exp: 3 years


┬─┬ノ(ಠ_ಠノ)(╯°□°)╯︵ ┻━┻


« Reply #83 - Posted 2014-03-21 23:47:23 »

Why double-post when you can double-double-post?

Offline gene9

Senior Devvie


Medals: 10



« Reply #84 - Posted 2014-03-21 23:51:19 »

Though it seems NB 8.0 projects arent compatible with NB 7.2

Most of the Java world has moved away from those type of IDE "projects" and uses a declarative build tool like Maven. If you define your build in Maven, you can use NetBeans or IntelliJ or Eclipse on top of that. All three of those IDEs will natively read Maven project definitions. I'd also suggest Gradle as basically a much better version of Maven, however NetBeans doesn't work too well with that. IntelliJ is probably just a better IDE choice, it reads Gradle projects natively, and the free community edition is adequate for almost all projects.
Offline Andre Lopes
« Reply #85 - Posted 2014-03-22 15:37:46 »

Why double-post when you can double-double-post?
Why double-double-post if you can double-triple-post ?


Well, i will use NB portable anyway. Smiley

Offline gouessej
« Reply #86 - Posted 2014-03-22 16:39:47 »

@gouessej - it was never about speed (e.g. see flash vs java and why flash succeded over java on the web despite being inferior in most things), its all about ease of use and availability for end users, gone are the days when users would put up with the hassle of installing a third party plug ins (possibly with bundled malware), or being unavailable on mobile and walled gardened platforms, the additional security hoops placed by browsers and the constant nagging of the plugin to update itself as well as being another possible target for security exploits. Further normal HTML, CSS and Javascript have matured to a point where plugins are mostly no longer needed to fill a gap left due to missing functionality. That's why third party plug-in can't succeed anymore.
Web browsers aren't inherently safer, the current trend just moves the problems from the plugins to the browser, it doesn't mean that there will be fewer malwares, most of them will rather target the major browsers instead of Java. If a plugin becomes really hard to install, it will have absolutely no chance to succeed but at first, players will go on accepting the use of a plugin with the games are worth a try (for example Minecraft). Secondly, if a plugin is as safe as the duplicated features available in the web browser, Mozilla and co. shouldn't display scary warnings only when using this plugin, it's not fair but they will artificially favor their technologies. I won't accept that and I'm not alone to protest. Several Java developers bothered Google for years because of the bad support and the bugs of Chrome affecting Webstart. If the developers increase this gap you talked about, some end users will still see a plus value in installing some plugins. Even on a Samsung S3 the performance of plain 2D HTML5 games is sometimes really bad (for example "Pirates loves daisy", "Runestone Defense", ...). We can't drive Java as easy to use as plugin-less technologies (except by using Java to Javascript solutions) but it's up to us to do our best to improve its performance and to make great Java games but I'm not the best guy for this mission. The latest security changes in Oracle Java itself are discouraging.

Offline Roquen
« Reply #87 - Posted 2014-03-23 08:53:15 »

..example why do C# and Java use a completely different syntax for arrays than for generics?
This is no comment on other syntax choices (what's important is self-consistence and not polluting the syntax) but from the perspective of Java:  a generic is a type bounds contract.  An array is limited pointer arithmetic.  These two features are completely unrelated.  So for a java like language it would be a bad choice to make them look similar.
Offline Nate

« JGO Bitwise Duke »


Medals: 158
Projects: 4
Exp: 14 years


Esoteric Software


« Reply #88 - Posted 2014-03-23 15:34:54 »

invokedynamic is cool, rest is a bunch of fluff. Disclaimer: I haven't looked at any of it because I don't really care. Lambdas are neat but don't make a big difference for me. Iterating using them annoys the shit out of me. Stack map frames are FUBAR and apparently mandatory soon, yay.

Offline Roquen
« Reply #89 - Posted 2014-03-23 20:03:26 »

Ditch bytecodes as transport ir ... ast for the win.  The improvements to annotations is pretty big.
Pages: 1 2 [3] 4 5 6
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

rwatson462 (28 views)
2014-12-15 09:26:44

Mr.CodeIt (19 views)
2014-12-14 19:50:38

BurntPizza (37 views)
2014-12-09 22:41:13

BurntPizza (73 views)
2014-12-08 04:46:31

JscottyBieshaar (34 views)
2014-12-05 12:39:02

SHC (46 views)
2014-12-03 16:27:13

CopyableCougar4 (42 views)
2014-11-29 21:32:03

toopeicgaming1999 (110 views)
2014-11-26 15:22:04

toopeicgaming1999 (96 views)
2014-11-26 15:20:36

toopeicgaming1999 (29 views)
2014-11-26 15:20:08
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!