Author Topic: XCOM Inspired Fantasy Game  (Read 34455 times)

Offline NashGold

  • Colonel
  • ****
  • Posts: 107
    • View Profile
Re: XCOM Inspired Fantasy Game
« Reply #330 on: August 05, 2020, 01:04:45 am »
Trying to implement the voxel interpolation with a few advanced raytracing techniques. I've also learned that the tensor space deformation is not really required to implement the proper soft body animation with voxels. One can do it in the plain euclidean space in a much more simple and elegant, albeit related, way, employing the same algorithm used to render fractals. But it apparently works only with octree, since it needs fractal structure to be efficient. I.e. you can't apply it to the plain grid.

Offline NashGold

  • Colonel
  • ****
  • Posts: 107
    • View Profile
Re: XCOM Inspired Fantasy Game
« Reply #331 on: August 12, 2020, 06:28:11 pm »
Still working on the voxel engine. After converting it to use SIMD, it can run relatively fast even on a single CPU PC. Along the way I've also invented the algorithm to properly raytrace octrees (likely invented long before me), which mapped nicely onto the SIMD vectors. My math and programming knowledge was barely enough for that. Now with a proper BVH implementation, I can probably start converting The Spell of Mastery to use the voxel engine. I will leave the 2d character sprites, but all the tiles will have to be converted to facilitate camera rotation and illumination. It will also need some new algorithm to remove the occluding items between the camera and the cursor. No idea how to properly draw 2d sprites in a 3d engine. Likely it will require to stay with the orthogonal camera (i.e. final fantasy tactics style), so no full motion cutscenes. Although I remember Diablo 2 having this "perspective mode". BTW, people are working to decompile Diablo 2: https://github.com/OpenDiablo2/OpenDiablo2 (they have already managed to de-compile Diablo 1 completely).

Anyway, voxel objects can actually be scaled along x,y,z axis in a non-destructive way. Say you can extrude a very long column from a tiny voxel circle, and it wont take that much memory, but one will have to find some other way to texture it into something other than a single color.

« Last Edit: August 12, 2020, 06:32:57 pm by NashGold »

Offline NashGold

  • Colonel
  • ****
  • Posts: 107
    • View Profile
Re: XCOM Inspired Fantasy Game
« Reply #332 on: August 28, 2020, 12:29:55 pm »
A bit more progress. Now it takes a few minutes to paint the scenes like below. Which makes me believe than one can indeed have Minecraft with with more continuous voxel worlds, without making it look like a professional 3d package. Then again, it all comes down to good metaphors. Computers were once controlled with switch boards, completely obscure to the untrained people. And voxels are probably the easiest way to create any graphics. I have also got rid of the 4-projections layout, since it is the artifact of polygonal graphics and is not really required for voxel editing.

Anyway, now I have a few ideas for a minimap for The Spell of Mastery, since the current minimap shows only the top level. With a properly optimized voxel structure one can have a 3d minimap. In addition, I can reuse the faster raytracing code, instead of marching the ray to test visibility. That is currently a huge bottleneck, especially I would want to allow realtime-with-pause mode like in the XCOM Apocalypse.

« Last Edit: August 28, 2020, 12:32:17 pm by NashGold »

Offline NashGold

  • Colonel
  • ****
  • Posts: 107
    • View Profile
Re: XCOM Inspired Fantasy Game
« Reply #333 on: September 02, 2020, 01:19:16 am »
Implemented the classic Command & Conquer style voxel shading. Instead of drawing actual cubes, it draws solid color, shaded by a normal. C&C had very efficient code to draw them: first normals were precomputed, second normals quantized as 8-bit indices, similar to paletted bitmap images. Such indices can apparently by efficiently mapped into screen space, without matrix multiplication. Generally such method gives much softer look, than if actual cubes are rendered.

« Last Edit: September 02, 2020, 01:47:57 am by NashGold »

Offline NashGold

  • Colonel
  • ****
  • Posts: 107
    • View Profile
Re: XCOM Inspired Fantasy Game
« Reply #334 on: September 08, 2020, 10:33:42 pm »
Still working on the voxel editor/engine. I've adapted much faster voxel raycasting algorithm from the Nvidia's paper ( https://www.nvidia.com/docs/IO/88889/laine2010i3d_paper.pdf ) it is lightning fast, so raycasts can be used without any hesitation now.

Also, Ukraine has X-COM internet provider. They have appropriated even the X-COM logo :D


Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 9816
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: XCOM Inspired Fantasy Game
« Reply #335 on: September 09, 2020, 01:40:27 pm »
We have a computer chain with that name in Poland, but appropriating the logo is a whole new level. :D