Saturday, October 8, 2011

59 – It's good to be backhh

Before I talk about today's topic, let me get back to the topic of the last LL3DLGLD. Because of the left-handed Cartesian coordinate systems it seems I can't avoid building the world upside down, but I can avoid the need for meshes to be created upside down. So the creation of models can be done as usual I hope.

So if you have some models lying around mail me a few so I can do some quick world population tests. I will create and search for some meshes myself, but some help is always appreciated. I am not asking you to create meshes for my game. But if you have some meshes available or know links to some sites that offer such meshes send me a link. I do not know what format to use so I'll try to load anything that I can get my hands on and later decide which one is best for my needs.

So back to the subject: basic merger with DwarvesH is done and GUI and a few simple interactions are working again:



The merger was fairly uneventful. I ended up greatly enhancing all those thing a GUI system does behind the curtains  like focus management, event handling, order system, etc. I worked 6 hours only on this. I could write pages upon pages on this subject, but I would bore you so let me just say that the GUI system is slowly becoming a really great and to my liking widgeting system for games. The only problem is that the framerate took a noticeable hit. Could the GUI eat up so many resources or did I introduce a bottleneck somewhere else?

I also started experimenting with shadows and lighting. I still need to learn a lot, but I'll leave you with this very ugly first failed experiment:

9 comments:

  1. http://www.blendswap.com/

    There you find a lot of free and CC models. You can open them in Blender and export them to every format you want

    ReplyDelete
  2. The ground in your system is the XY plane, with -Z as height. The standard in 3D applications is to have the ground as the XZ plane, with +Y as height.

    You're rendering everything sideways :)

    ReplyDelete
  3. How do the undersides of textures look, as in the case of a cave or overhang?

    ReplyDelete
  4. To Anonymous:

    I like to think that the rest of the world is rendering sideways :). No sane mathematician would consider XZ the ground plane.

    Anyway, I'll rotate meshes and it should be OK.

    To Bryan:

    Right now they look the same as the surface textures. And they are turned off by default since you can't see them only in first person mode when you are in a cave. So for first person mode I'll enable them, probably only in a set radius from the camera.

    ReplyDelete
  5. This comment has been removed by the author.

    ReplyDelete
  6. @anon:

    have to agree with DHDev on that, I've used 3D applications for 20 years, and +Z is ALWAYS up! with XY falt on the ground :P

    ReplyDelete
  7. When will you reveal that you are not a single person working on an indie game but a huge software company with hundreds of developers?

    ReplyDelete
  8. @BrewStew, DHD

    Rendering and modelling have different approaches. Modelling programs typically do use the more "intuitive" coordinate system with Z as height.

    With rendering, it's more that XY is the plane the camera initially faces, and Z is the view depth. When you consider that these system evolved by adding the third "depth" dimension to a 2d system which obviously treats the screen as an XY plane, it's not as silly as you think :)

    It also makes perspective camera transforms easier to deal with.

    ReplyDelete
  9. You could reuse your existing 2D images and use billboarding techniques to render them. This way you'd have a lot of content without the need to provide a 3d model for every object you need. With the right camera this could look like the original 2D Version...

    ReplyDelete