Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (522)
Games in Android Showcase (127)
games submitted by our members
Games in WIP (589)
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
  ignore  |  Print  
  Sunland Villagers (was: Learning OpenGL/LWJGL)  (Read 13647 times)
0 Members and 1 Guest are viewing this topic.
Offline Varkas
« Posted 2012-11-11 22:09:26 »

The real start of the thread is a bit below. Since it was moved to the WIP section (thanks!), I thought I should add some info and a recent screenshot to the first post.



The idea is a to create a village building and managing game, which loosely resembles the old "Settlers II" game. I don't want to implement the combat part, but have a more peaceful settlement simulation.

At the moment it's little more though than a LWJGL based landscape rendering engine, and some basic actions to place buildings and create paths.

It's open source, and the project site is hosted on Sourceforge:

http://sourceforge.net/projects/sunlands/

I try to keep things as simple as possible.

---- original start of the thread ----

This is my third attempt to learn OpenGL. Long ago I had been trying OpenGL and C, but the drivers were so buggy then, that it wasn't fun. Microsoft supllied drivers had different bugs from vendor supplied drivers, and it just was not nice to work with. Maybe that try to too early ...

Year later I tried JOGL, and the reuslt were quite pleasing. I didn't pursue that further though ...

Inspired by this thread http://www.java-gaming.org/topics/jogl-vs-lwjgl-and-the-best-way-to-start-learning/27543/msg/249455/view.html#msg249455 I now make my third attempt, this time with LWJGL. LWGL specific documentation seems to be a bit strange, overly complicated at times, buggy at other times, seldom exactly what I would need. But there is enough OpenGL documentation around to make up for that, at least in regard to the OpenGL functions themselves.

Results of half a day of trial-and-error: A little landscape renderer, using triangles.



Maybe this can become the base for few more modern toy projects, OpenGL is now available on many platforms and the drivers seem to be much better than 10 years ago. At least I can move on from purely 2D development now, and OpenGL seems to be good for 2D graphics, too.

Next to learn: Calculate smoothed vertex normals and enable lighting. Or at fake lighting, I don't know yet what will be the better approach.

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline Varkas
« Reply #1 - Posted 2012-11-12 13:09:14 »

me + math = </3

Calculating the normals turned out to be quite horrible. Actually not because of the vector math, but the way the map is stored in memory and it's not straight-forward to tell 3D coordinated from the map (2D array) indices. Took a lot of trial and error again, but now I think I have the basics in place:



Now, how can I make the display brighter? I'm not quite sure how to control the light yet.

Using this at the moment:

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
        glEnable(GL_DEPTH_TEST);
        glEnable(GL_LIGHTING);
        glEnable(GL_TEXTURE_2D);
        glEnable(GL_LIGHT0);
       
        FloatBuffer lightPos = BufferUtils.createFloatBuffer(4);
        lightPos.put(-100.0f).put(50.0f).put(100f).put(0f).position(0);
        glLight(GL_LIGHT0, GL_POSITION, lightPos);
       
        FloatBuffer ambient = BufferUtils.createFloatBuffer(4);
        ambient.put(0f).put(0f).put(0f).put(1.0f).position(0);
        glLight(GL_LIGHT0, GL_AMBIENT, ambient);

        FloatBuffer diffuse = BufferUtils.createFloatBuffer(4);
        diffuse.put(1.0f).put(1.0f).put(1.0f).put(1.0f).position(0);
        glLight(GL_LIGHT0, GL_DIFFUSE, diffuse);

        FloatBuffer specular = BufferUtils.createFloatBuffer(4);
        specular.put(1.0f).put(1.0f).put(1.0f).put(1.0f).position(0);
        glLight(GL_LIGHT0, GL_SPECULAR, specular);



Also, how to control the contrast, the difference between the darkest and lightest texture display?  

Edit: its seems I can do this:

1  
2  
3  
        FloatBuffer diffuse = BufferUtils.createFloatBuffer(4);
        diffuse.put(2.0f).put(2.0f).put(2.0f).put(2.0f).position(0);
        glLight(GL_LIGHT0, GL_DIFFUSE, diffuse);


but is this right, to put numbers > 1.0 in there?

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Online Riven
Global Moderator

« JGO Overlord »


Medals: 831
Projects: 4
Exp: 16 years


Hand over your head.


« Reply #2 - Posted 2012-11-12 13:14:57 »

LWGL specific documentation seems to be a bit strange, overly complicated at times, buggy at other times
Could you elaborate?

Hi, appreciate more people! Σ ♥ = ¾
Learn how to award medals... and work your way up the social rankings
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Online Riven
Global Moderator

« JGO Overlord »


Medals: 831
Projects: 4
Exp: 16 years


Hand over your head.


« Reply #3 - Posted 2012-11-12 13:17:27 »

GL_DIFFUSE determines how much of the incoming light is scattered (multiples light color).
GL_AMBIENT adds an omni-directional light source (increases the pixel values)

Hi, appreciate more people! Σ ♥ = ¾
Learn how to award medals... and work your way up the social rankings
Offline Varkas
« Reply #4 - Posted 2012-11-12 13:35:49 »

LWGL specific documentation seems to be a bit strange, overly complicated at times, buggy at other times
Could you elaborate?

It's a bit difficult, since I have surely checked 30 or so differnet tutorials and documentation sites since I started working on this.

Overly complicated - this one I can remember fairly clearly. I wanted to know how to put a texture onto a triangle. This tuturial (The Quad Textured)

http://lwjgl.org/wiki/index.php?title=The_Quad_textured

includes that, but it also comes with a lot of openGL calls that are not needed or aren't specific to just creating textures, and make it very difficult to extract the part that one needs for textuzres and stripü off the rest. Actually I missed one line in stripping (something about Mipmaps) and it caused my textures not to show, while I was searching the mistake in different places till I found another tutorial and while copmparing I noticed the mipmap setting line, removed it, and it worked ... a more focused tutorial would have been easier.

The buggy one I forgot the source. But I Tried the perlin noise code from your blog, and found it (a) doesn't compile, and when I fixed that, (b) smooth_noise() produces 0.0. for each coordinate that I've tried.

http://riven8192.blogspot.de/2009/08/perlinnoise.html

Maybe I misunderstood the class. I have ported my old Perlin noise code from C++ to Java, and it worked, so I could continue, but I had expected that the published code was tested before being published (-> would compile at least). Well A comment tells that, but I didn't check all comments when getting the code.

The rest blurred away in my memory from reading too many openGL documentation recently. Ah right, LWJGL API documentation leaves many parameters undocumented which is uncomfortable - even that I can google the functions, in my IDE it doesn't show much, although there was a Java Doc supplied with LWJGL, just it's quite void for many (?) methods.

Edit:

Also took me a while to fi9nd out about this:

FloatBuffer buf = BufferUtils.createFloatBuffer(4);

I used this initially, and it complained about "not direct" which was quite meaningless to me as a pointer what is wrong:

FloatBuffer buf = FloatBuffer.allocate(4);

This is what a Java coder uses if he doesn't know that LWJGL has it's own, special buffers implementaion. Again, I lost time and had to do research why LWJGL wouldn't like my buffer.

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline Varkas
« Reply #5 - Posted 2012-11-12 13:37:40 »

GL_DIFFUSE determines how much of the incoming light is scattered (multiples light color).

I guess this means it's safe to use values larger than 1.0. The functions I've understood, I just don't know which value ranges are good/sane/allowed/common. I'm almost completely new to OpenGL, and have no experienc with it.

Edit:

Next step: add billboard trees. I remember there were tricks to circumvent blurry texture borders for partly transparent textures, but it seems I've lost the code from my lat OpenGL test with JOGL, and besides a faint memory that there existed a trick, I have nothing anymore ... I'll see how long it takes to add the trees.

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline princec

« JGO Spiffy Duke »


Medals: 421
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #6 - Posted 2012-11-12 14:18:21 »

Also took me a while to fi9nd out about this:

FloatBuffer buf = BufferUtils.createFloatBuffer(4);

I used this initially, and it complained about "not direct" which was quite meaningless to me as a pointer what is wrong:

FloatBuffer buf = FloatBuffer.allocate(4);

This is what a Java coder uses if he doesn't know that LWJGL has it's own, special buffers implementaion. Again, I lost time and had to do research why LWJGL wouldn't like my buffer.
It doesn't use its own special buffers implementation; there is simply a library-wide requirement that all buffers passed to native methods are direct bytebuffers as opposed to array-backed ones. Blame "Java the platform" for even having the distinction...

Normally you would use
1  
FloatBuffer buf = ByteBuffer.allocateDirect(4 * 4).order(ByteOrder.nativeOrder()).asFloatBuffer();

but that LWJGL util method just does it for you.

Cas Smiley

Offline Varkas
« Reply #7 - Posted 2012-11-12 14:27:18 »

Blame "Java the platform" for even having the distinction...

Will do. I'd too lazy/busy to research this buffer thing any further Tongue

Icanhastreesnow!



Now I have everything in place to make a new Settlers II clone Grin

Widelands is there, but it's C++, and I don't want to cde C++ anymore. But I have too many projects started already ...

At least I now have a OpenGL landscape renderer that does everything that I need Cheesy

And it's still quite fast, despite my horrid coding, and it surely can be optimized, so this has potential. Thanks for pointing me to LWJGL, it's been a good start Smiley

Edit: Just noticed that I forgot to rotate the tree sprites towards the viewer. But it's not much of a problem.

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline Varkas
« Reply #8 - Posted 2012-11-12 21:12:31 »

1) Switched to orthographic projection like the old settler games used.
2) Got panning and zooming in place now (map dragged by mouse  - I think it was done this way in Settler II as well)



Display is fast enough for sure, even for large maps with a lot of objects. OpenGL really pays off here Smiley

Edit: I found out how to use LWGL to render to a canvas in a AWT Frame. Using other AWT components as part of the canvas worked well.

Can I overwrite the canvas paint method to draw something over the OpenGl output?

I assume I can use Swing components in an AWT panel, but I haven't tested that and it's been too long ago that I used AWT, I just remember that mixing causes problems. But it seems I can build some game UI around the OpenGL display area.

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline ra4king

JGO Kernel


Medals: 355
Projects: 3
Exp: 5 years


I'm the King!


« Reply #9 - Posted 2012-11-13 00:27:43 »

No, once LWJGL takes control of the Canvas, you can't draw to it using the Graphics object.

I also noticed you're using old fixed function OpenGL. I suggest you learn about the programmable pipeline.
The Arcsynthesis tutorial is an excellent resource, and here are the LWJGL ports.

I don't want to stop you while you're having your fun making this game, though Grin

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Varkas
« Reply #10 - Posted 2012-11-13 12:00:57 »

The drawing isn't a big problem, I can either port a UI system that I have from C++ to Java and make it use the openGL primitives, or just write something new. Also it might be sufficient to have the controls below/aside of the world view, that might be good enough. But thanks for the explanation, no I don't need to try it by myself.

When I started to learn openGL for the first time, OpenGL 1.1 was the only standard that was commonly available in drivers. So I didn't look at the extensions and newer version, even at that time.

When coming back, I mad the essumption that OpenGL 1.1 will be available on all devices, and since I knew it will be good enough for my needs, I didn't look beyond that standard. I didn't even look into display lists yet, becuase performance of the immediate mode was good enough and I had enough CPU left on the one used core, so I didn't bother about learning anything more.

But in the book I saw this:

Quote
The only exception to this deals with OpenGL 3.0 and above, relative to previous versions. v3.0 deprecated a number of older functions, and v3.1 removed most of those functions from the API

This actually worries me. I don't know yet which of the old API functions were dropped, but it means that OpenGL 1.1 might not be so universally available as I had thought, and that I need to learn how to do things with OpenGL 3.1 instead. This will take time again. Particulalry it seems to make use of concepts which I considered voodoo (vertex shaders and everything newer - I'm a late adopter and very hesitant with new concepts), and which I wanted to avoid. But it seems that what I considered "voodoo" is now the standard way to do things and I must learn it :/

Well, thanks for the link, it will help to avoid mistakes. The book is easy to read and a good source of information. I don't know if/when I actually will have time and the guts to dive into learning again, but at least I now have a good source of information.

Thanks for the link again, ra4king Smiley


if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline princec

« JGO Spiffy Duke »


Medals: 421
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #11 - Posted 2012-11-13 12:31:04 »

Meh, don't listen to ra4king about all that 3.0+ stuff. The old-style APIs are here to stay for a number of years at the very least. Most Macs are still stuck on 2.1. Even with drivers that support 3.1 and above LWJGL can use the "compatibility context" path which gives you the old-style APIs anyway. So: use the fixed function pipeline.

Cas Smiley

Offline Sickan

Senior Devvie


Medals: 9



« Reply #12 - Posted 2012-11-13 14:50:17 »

Meh, don't listen to ra4king about all that 3.0+ stuff. The old-style APIs are here to stay for a number of years at the very least. Most Macs are still stuck on 2.1. Even with drivers that support 3.1 and above LWJGL can use the "compatibility context" path which gives you the old-style APIs anyway. So: use the fixed function pipeline.

Cas Smiley
My Mac can't do anything over 2.1, besides, the old stuff can do everything the new stuff can, so uh, here's the deal, why change? [size=7pt]I will keep this opinion until I can get a better Mac somehow.[/size]

Cheers! Cheesy
Offline Varkas
« Reply #13 - Posted 2012-11-13 15:36:18 »

I assume that I'll learn more about OpenGL while working on this project. But it's good to know that for the moment I can stick with OpenGl 1.1/1.3. Thanks for the feedback!

Levelling ground was a feature and restriction in the settlers games, because bigger buildings required more level space. So I wrote some testing code to see if levelling is as easy as expected and it seems to be. Just setting the height values for the vertices and recalculating the normals does it.

I've added a few small houses as example, which need a level triangle as ground to be built.



The houses don't blend in perfectly yet. Also I think the ground perspective and the sprite perspective don't match 100% yet, but the code basically works.


if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline matheus23

JGO Kernel


Medals: 113
Projects: 3


You think about my Avatar right now!


« Reply #14 - Posted 2012-11-13 20:41:18 »

What's up with those grassy and sandy triangles? Are you going to change this? :X

They somehow look... bad... I think this would be something very important to "fix" before going on with game features...

What are you trying to accomplish with them?

Other than that: Very good Smiley

See my:
    My development Blog:     | Or look at my RPG | Or simply my coding
http://matheusdev.tumblr.comRuins of Revenge  |      On Github
Offline Varkas
« Reply #15 - Posted 2012-11-13 22:00:31 »

Hehe, actually I didn't think much when made the map structure. I just wanted to have two textures to see if the map display works. I also found them useful for tracking the triangle positions and later the tree positions. That's a bit hard without a pattern on the landscape.

Later I'll have some real landscape textures, but I haven't made up up my mind yet how exactly they will have to look. I assume most of the land will be grassy, with some rocky places and water areas in between. I'll need to experiment a bit with layered textures/polygons to make it look interesting.

Other than that: Very good Smiley

Thanks Smiley


if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline ra4king

JGO Kernel


Medals: 355
Projects: 3
Exp: 5 years


I'm the King!


« Reply #16 - Posted 2012-11-14 06:08:13 »

Meh, don't listen to ra4king about all that 3.0+ stuff. The old-style APIs are here to stay for a number of years at the very least. Most Macs are still stuck on 2.1. Even with drivers that support 3.1 and above LWJGL can use the "compatibility context" path which gives you the old-style APIs anyway. So: use the fixed function pipeline.

Cas Smiley
Well at least 2.1 be minimum for good ol' shaders! Grin

Offline davedes
« Reply #17 - Posted 2012-11-14 07:25:56 »

Meh, don't listen to ra4king about all that 3.0+ stuff. The old-style APIs are here to stay for a number of years at the very least. Most Macs are still stuck on 2.1. Even with drivers that support 3.1 and above LWJGL can use the "compatibility context" path which gives you the old-style APIs anyway. So: use the fixed function pipeline.

Cas Smiley
Why would you limit yourself to the old-style API?

Having the understanding of GLSL will give you a much richer toolset to play with. Personally I did not find myself advancing very quickly with OpenGL until I sat down and forced myself to learn the programmable pipeline. It was only after wrapping my head around shaders did the fixed-function pipeline all come together and make sense to me.

I'm on a Mac with GL 2.1 and I have no trouble playing with fragment and geometry shaders, float textures, texture arrays, etc.

Offline masteryoom

JGO Coder


Medals: 5
Projects: 2


If you look closely, you might see it turning...


« Reply #18 - Posted 2012-11-14 08:47:15 »

I would be very interested if you supplied some source code.  Cheesy

Smiley
Offline princec

« JGO Spiffy Duke »


Medals: 421
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #19 - Posted 2012-11-14 08:56:59 »

Meh, don't listen to ra4king about all that 3.0+ stuff. The old-style APIs are here to stay for a number of years at the very least. Most Macs are still stuck on 2.1. Even with drivers that support 3.1 and above LWJGL can use the "compatibility context" path which gives you the old-style APIs anyway. So: use the fixed function pipeline.

Cas Smiley
Why would you limit yourself to the old-style API?

Having the understanding of GLSL will give you a much richer toolset to play with. Personally I did not find myself advancing very quickly with OpenGL until I sat down and forced myself to learn the programmable pipeline. It was only after wrapping my head around shaders did the fixed-function pipeline all come together and make sense to me.

I'm on a Mac with GL 2.1 and I have no trouble playing with fragment and geometry shaders, float textures, texture arrays, etc.
GL2.1 is still the old-style API. It's only 3.1 (?) and beyond that totally do away with all the old style API commands and you have to ask for a compatibility context instead.
I'm targeting 2.1 these days, but still using all my old code; I've just added a couple of shaders.

Cas Smiley

Offline Varkas
« Reply #20 - Posted 2012-11-14 11:10:40 »

I would be very interested if you supplied some source code.  Cheesy

It's now on sourceforge:

http://sourceforge.net/projects/sunlands/

There isn't much yet, really. A main class, the OpenGL map renderer and some utility classes. If you notice bugs, problems mistakes or anything else strange with my code, please let me know. Since I'm quite new to LWJGL I assume that there are quite some things that could be done better.

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline Varkas
« Reply #21 - Posted 2012-11-14 11:20:30 »

Why would you limit yourself to the old-style API?

Having the understanding of GLSL will give you a much richer toolset to play with. Personally I did not find myself advancing very quickly with OpenGL until I sat down and forced myself to learn the programmable pipeline.

Old usually means well tested, widely available and less bugs. I think I made good progress so far. To get a new display engine up from the ground in about 2 days is quite fast I think. Back when I coded C++, and I started using a new display library like SDL or Allegro, it wasn't much faster, let alone learning an API like GDI for Windows or X11 for Unix.

What I have problems with is the projection matrix, and the sequence of translate and rotate commands. This is due to my bad understanding of vector math, and something I'll have to learn some day.

Since I don't think that hobby project can or should try to compete in graphics quality with professional projects, I rather want to invest my time into the games features. I know for many the big task seem to be to build the "engine", but for me the most difficult task is to build the game upon the engine. I'm quite sure that once I have the besic display in place, the real problems will start for me - the questions how to make things fun to the player, how to keep the player motivated, how to make the game easily accessible to new players. From this point of view a "richer toolset" for the graphics pipleine isn't something that I feel a big need for nor something that will pose a problem for me if I decide that I should need it at some point. It's just that at the moment I think it's not needed for my plans, since I aim for a graphics detail level that was seen in games about 15 years ago. While this was a challenge back then, todays tools make it easy, and I thinks that's what is good for swift progress Smiley



if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline Varkas
« Reply #22 - Posted 2012-11-14 14:27:16 »

I've added code to draw paths on the map (Settlers II style). I have no real maps though, just randomly created ones, so the screenshot shows a random mesh of paths. Still missing is the handling of normals for the paths, but that shouldn't be much of a problem.



I think I have now all graphical elements that Settlers II had - ground textures, paths and objects on the map.

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline Varkas
« Reply #23 - Posted 2012-11-15 15:27:52 »

New:

- Normals for paths
- Textures depend on map height (needs more in-between textures though)



Things about which I haven't made up my mind yet:

- How hilly should the landscape be?
- Which relation of triangles to map object size should I choose?

The latter has the restriction that a map object's (like a house) "width" and "depth" need to fit onto a group of triangles, so there must be some sort of non-fractional relation. But this is a very soft constraint.

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline Varkas
« Reply #24 - Posted 2012-11-16 13:15:14 »

I've been trying to improve the landscape generation a little (valley bottoms are more flat now, and hills more pointy), and added some in-between textures. Not looking too great, but it works.

Next will be to get the calculation mouse position -> vertex so that the user can interact with the map. And I must decide how to build in-game menues (AWT popups, pure OpenGL code, UI besides/below the map display).

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline matheus23

JGO Kernel


Medals: 113
Projects: 3


You think about my Avatar right now!


« Reply #25 - Posted 2012-11-16 17:45:32 »

Proooobably it's overkill, and it depends on your skill whether you'd be able to code that, but what about masking the two textures on the edges. It's actually quite easy.

Since you've only got triangles, you only have 1 single mask texture. You can rotate and invert this texture to get any mask texture you need. (by rotate I mean switch the texture coords)

Then you only need a simple shader (It looks like you've already got one, where you calculate the light...) and...

voila!

See my:
    My development Blog:     | Or look at my RPG | Or simply my coding
http://matheusdev.tumblr.comRuins of Revenge  |      On Github
Offline Varkas
« Reply #26 - Posted 2012-11-16 21:11:34 »

The shading is a feature of OpenGL itself, if you supply normals for the triangle corners. I'm somewhat confident that I can make the texture transitions look alright in the final version, but I haven't worked on that yet. The textures themselves need more work, too.

A big step forward is that I can handle mouse input now. I mean to transform the mouse x/y coordinate to a vertex or triangle of the map. So I can start to build a UI now to control the game.



Since it's an AWT frame it seems I can use all AWT components, but a quick test with JPanels and JLabels seemed to tell that I can use Swing components too. Next steps will be to give the player tool menues to place buildings and create paths.

Thanks for the medal, matheus23 Smiley

if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Offline matheus23

JGO Kernel


Medals: 113
Projects: 3


You think about my Avatar right now!


« Reply #27 - Posted 2012-11-16 21:14:49 »

Thanks for the medal, matheus23 Smiley

You deserved it Smiley

But... somehow... I wanted to give the medal to the post before the one I medal'ed... strange thing... I SWEAR I have't even seen that post :O

EDIT: On-topic:
You should try doing the shading in the Fragment shader.
Really, there is almost no hardware out there, which doesn't support OpenGL 2.1.

And in the end GLSL isn't too hard either. You only have to write yourself some utility classes like a Class for compiling shader-programs (or better: call opengl, to compile the GLSL shader), or just find on on the internet. I really have to say, that lwjgl-basics is a pretty good project by davedes. I've contibuted to it myself, and it really helped me a lot since then.

See my:
    My development Blog:     | Or look at my RPG | Or simply my coding
http://matheusdev.tumblr.comRuins of Revenge  |      On Github
Offline Gjallar

JGO Coder


Medals: 13
Projects: 1


Follower of Nurgle


« Reply #28 - Posted 2012-11-16 22:00:44 »

The speed of how fast you throw out new stuff frightens me.


What happend to your gardening simulator, abandoned?
Offline Varkas
« Reply #29 - Posted 2012-11-17 12:39:27 »

You should try doing the shading in the Fragment shader. [...] lwjgl-basics

I'll look into shaders, you're right they quite powerful tools. Thanks also for the link, next week I should have some time again to study code Smiley

The speed of how fast you throw out new stuff frightens me.

Grin

I can draw from some older projects of mine, also there is a lot of helpful stuff on the web. And I assume I just put a lot of time into it. Almost worked last night through because I wanted to put together a first demo.

What happend to your gardening simulator, abandoned?

That's my bane. My interest in my projects comes and goes in kind of short runs ... usually they sleep a while, then I get some new ideas and I work on them for a few weeks, then they sleep again while I work on another project. I'm trying not to let my project list grow too much so that each sees some updates a year. It's kind of project ADHS.

The gardening simulation is on hold currently because planting and watching plants grow felt a bit boring, and I haven't made up my mind yet how to make it better. A faint idea is to allow some multi-player features, like sharing selfmade plants, but I'm not quite decided on the path to go. So it waits till I have new ideas again.

For today, I have put together a little demo. It's mostly to see if the code runs on other systems but mine, too, and also to get a little bit of feedback, although there surely isn't much to comment on but if zooming and panning works, and the like.



You can get the demo from here:

https://sourceforge.net/projects/sunlands/files/v0.01/

So far I've only taken care about windows and supplied a "star.bat" which starts the Java runtime with the right parameters. Some day I hope to have a better startup system which works on Linux and MacOS, too. I assume you could copy the start.bat, and transform it into a start.sh which does about the same thing for Linux, but right now I have no Linux system to test that.




if (error) throw new Brick(); // Blog (german): http://gedankenweber.wordpress.com
Pages: [1] 2 3
  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.

xFryIx (62 views)
2014-11-13 12:34:49

digdugdiggy (41 views)
2014-11-12 21:11:50

digdugdiggy (36 views)
2014-11-12 21:10:15

digdugdiggy (30 views)
2014-11-12 21:09:33

kovacsa (53 views)
2014-11-07 19:57:14

TehJavaDev (56 views)
2014-11-03 22:04:50

BurntPizza (55 views)
2014-11-03 18:54:52

moogie (70 views)
2014-11-03 06:22:04

CopyableCougar4 (71 views)
2014-11-01 23:36:41

DarkCart (156 views)
2014-11-01 14:51:03
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!