http://www.theintraclinic.com/wurm/ is dead, long live http://www.wurmonline.com/
celebrates
Just played with your newest version 0.0.19a
When hitting F1 I crash to the desktop. Win 2K Geforce 3
Edit: Passed this info to you in the game.
I think I’ve fixed that bug now. I got a bit thead-confused, and tried to perform opengl commands from the awt dispatch thread.
Note to self:
OpenGL from the awt thread = crash
awt from the OpenGL thread = deadlock
There we go! First version of the water is FINALLY done. =D
Screenshot
Try typing “/wurm.setDrawWater(true)” in Wurm now. w00t.
Oh, and I’ve added Joal support, but couldn’t find the linux or macos binaries (do they exist?), so you’ll only get sound on windows.
And the only sound right now are kinda quiet footssteps.
Nice!
Thanks. =)
Z-sorting the alpha-blended particles turned out a bit trickier than I thought. A TreeSet only sorts on entry, and Collections.sort(List) is slow… I ended up writing my own SortableList class based on some “Enhanced Quick Sort” algorithm I found after googling for some time.
[quote]Thanks. =)
Z-sorting the alpha-blended particles turned out a bit trickier than I thought. A TreeSet only sorts on entry,
[/quote]
Yes, the TreeSet of the the Java collection framework doesn’t help if you’ve to sort the entire “list” again, for example…
[quote]and Collections.sort(List) is slow…
[/quote]
Bad news for me. I intended to use this Collections.sort(…) for my alphablended surfaces too.
Isn’t there any faster way in the Java builtin framework?
Java 1.5 maybe?
I can post the SortedList I hacked together when I get back home tonight. It seems really fast, and it doesn’t create a bunch of new objects.
You might be interested to know that Cas did something like that in his SPGL lib. I think he radix sorted the sprites.
Radix sort is the way to go, it’s an order of magnitude faster than Collections.sort() and ultimately it sorts in 5 log n speed instead of n log n which I believe Collections manages.
Cas
Radix sort… isn’t that the one where you progressivly sort numbers depending on their most significant bits? Isn’t that magic ‘5’ in your big-O dependant on how many bits you need for your numbers to be sorted?
There are two problems with radix sort:
You need specific representation of value to be compared. Compare function is not enough, you need actual number. Think about comparing strings - if you can convert given value to string (for example number to hex representation), you can use radix sort.
It is memory consuming. A lot of sort routines work in place or needs at most double memory. With radix sort, if you want to be on safe side, you need multiple of n memory - and faster you want to be, more memory you need.
As for stability, AFAIK radix sort is stable, but as it is mostly used for numbers/strings, it is not important anyway.
Good annotations. The memory consumption of a sort algorithm is important too in many cases.
PS: Maybe we should move our “sort algorithm”-discussion to another thread?
Threadjackers!! ;D
[quote]Threadjackers!! ;D
[/quote]
Yes, that’s going off-topic, I know… So I dared to start another thread on the sorting stuff. All people interested I invite to continue discussion here: http://www.java-gaming.org/cgi-bin/JGNetForums/YaBB.cgi?board=Tuning;action=display;num=1066906739;start=0 (named “Good sort algorithms”).
How do you go into the water. It seems that I am walking across it. And you seem to be able to jump incredibly high by continually pressing the jump button.
You can’t dive, so you just swim across the water.
And… eh… the jump button hasn’t been in the game for a month or so now. Are you sure you’re running the latest version?
Hmm, maybe not. Gotta fix.
7 fps with graphics all high. Playable. Can you also make it so that you don’t have to have internet in order to play offline mode?
No, offline mode is a very unsupported feature that will be removed fairly soon. =)
In fact, I don’t think it works any more… haven’t tried.