| Topic: Adaptation of Series 2
|
|
 | Adaptation of Series 2 | |  |
| Poster | : JCKodel | | Posts | : 2 | | Country | : | | City | : |
| | | | Posted by JCKodel on 03/01/2007 at 18:47:03
| | First of all, excelent tutorials! It's my primary source to what I'm intending to do: an isometric engine using tiled terrain based on an array of tile code and height.
So far, I managed to obtain this: with help from Series 2. It renders just one part of the array (as the map is VERY huge) while you move out the camera.
But, there is some problems that I'm unable to work out...
First of all: in Series 2, you use a tiled bitmap with all textures used. I've tried to do that and there is some lines between the tiles (the math isn't precise enough and one tile displays one or more pixels from the tile at side, creating a wireframe effect in the borders of the terrain's tiles.)
The image above is ok because my texture file has only one texture... I need to correct the "blend" of tiled textures or insert more than one texture in the scene, but I just can't think out how! =(
Another problem: the terrain lighning was made using a phong algorithm that I've found on google, but it's not too precise, because all of three normals for a vertex are the same. It would be nice some more tutorials about lights, specially how to calculate normals in this case and what means the light position >.< (where is the light and to where it points out?)
Finally, I'm having problems... better... I just can't at all find the coordinates of the mouse in 3D scene. The scale of the engine is the same of the Series 2 tutorial. How could we click in a top of a building and know exact which array coordinates are those?
I'm willing to share the source code with anyone (my intention was to made some kind of tutorial, as there is no tiled height map for XNA). Ah! It's in VB ^^
Thanx in advance for any help. | |
|
| | | | | | Poster | : Anonymous | | Posts | : | | Country | : | | City | : |
| | | | Posted by Anonymous on 03/01/2007 at 18:48:05
| | The image failed to load >.<
The URL is:
http://www.tenebree.com/isometricengine.png
 | |
|
| | | | | | Poster | : riemer | | Posts | : 1392 | | Country | : Belgium | | City | : Antwerp |
| | | | Posted by riemer on 04/01/2007 at 14:32:02
| | I'm currently finishing Series 3 for XNA, where you'll learn to create your own effect. Once you've learned this, creating alpha blending shouldn't be a problem. Also, the series contains a few chapters on lighting. For example, the lighting intensity relative to a light in 3D space for each pixel is calculated. I think this can be helpful for your second question.
I will make sure I'll have the full 3rd series posted this weekend.
If you're planning to write a tutorial about your code, I would of course be more than happy if I could host it on this site ;) This weekend, XNA will become the primary contents of this site, it's very easy to add a 'XNA for VB' chapter, and the site gets quite a large audience. Of course, you'll get full credits for your pages! | |
|
| | | | | | Poster | : JCKodel | | Posts | : 2 | | Country | : | | City | : |
| | | | Posted by JCKodel on 14/01/2007 at 13:02:46
| | I've managed to write the complete isometric engine in XNA, but later I realized that XNA only runs on machines with pixel shader >.< I know... stupid of my part...
Then, I have translated my engine to Managed DirectX. Everything is working very fine... it's possible to render a Ultima Online map, with animated (and transluced) water, etc... but, I'm facing a problem that I'm not able to resolve: how to click on a tile and know what tile is it!
This engine is based on Flightsim tutorial. The tutorial draws a map based on an array.
It is possible to add a tutorial to get the array XY coordinate based on the building top (or ground) clicked by the mouse? | |
|
| | | | | | Poster | : riemer | | Posts | : 1392 | | Country | : Belgium | | City | : Antwerp |
| | | | Posted by riemer on 16/01/2007 at 07:10:06
| | You can use Viewport.Transform to do the maths for you.
I should write a ShortTut on this, currently I'm writing on a chapter about normals. | |
|
|
 | | |  |
|
|
|
If you appreciate the amount of time I spend creating and updating these pages, feel free to donate -- any amount is welcome !
|
- Website design & DirectX code : Riemer Grootjans - ©2006 Riemer Grootjans
|
|