Z Coordinates ...

Discussions on various DOL development features

Moderator: Support Team

Re: Z Coordinates ...

Postby Blue » Tue Jun 28, 2011 1:29 pm

Metty already implemented a getZ function for Uthgard but we never used it because it was often inaccurate. Dont know why. Also it can only be used in plain maps with 1 height level. I suggest we should try again to make an accurate getZ function but I see the problems in multi level dungeons like DF.
ex DOL Lead Developer
Blue
Uthgard Admin
 
Posts: 961
Joined: Wed Jan 21, 2004 11:07 pm
ICQ: 63977313

Re: Z Coordinates ...

Postby Dinberg » Tue Jun 28, 2011 1:52 pm

You can unload the dungeon .place files and their related nifs to create a 3d structure of the dungeon's collision mesh in memory, then use detour & recast (http://code.google.com/p/recastnavigation/) to create the navigation meshes and traverse them.

However, this isnt the problem. It's easy to suggest ideas, but ideas are cheap; I don't have the time these days to implement something like this, nor can I imagine anyone else with this time on their hands.
The Marvelous Contraption begins to stir...
User avatar
Dinberg
Inactive Staff Member
 
Posts: 4695
Joined: Sat Mar 10, 2007 9:47 am
Yahoo Messenger: dinberg_darktouch
Location: Jordheim

Re: Z Coordinates ...

Postby Blue » Tue Jun 28, 2011 1:56 pm

It wasnt about pathing. I think Z coordinates are a different story.
ex DOL Lead Developer
Blue
Uthgard Admin
 
Posts: 961
Joined: Wed Jan 21, 2004 11:07 pm
ICQ: 63977313

Re: Z Coordinates ...

Postby Tolakram » Tue Jun 28, 2011 2:07 pm

Maybe it helps to define the most annoying behavior due to lack of z coordinates?

- pets / mobs can climb walls to attack guards / mobs / players

Even if keep guards had their Z adjusted for wall heights this problem would still exist without some logic as to how steep an incline a mob / pet can climb (how fast can Z increase). This is partly a keep structure issue, but also happens on client side structures like milegates.

Just off the top of my head it seems to me the server needs to make a quick decision prior to letting an npc attack. It needs the route to the target and it needs to quickly determine if any height rise will prevent an attack.

      y
    /
  /
/
x

will be ok

y
|
|
|
x

will not be allowed.

Fear my ascii dominance.
- Mark
User avatar
Tolakram
Storm / Storm-D2 Admin
 
Posts: 9189
Joined: Tue Jun 13, 2006 1:49 am
Location: Kentucky, USA

Re: Z Coordinates ...

Postby Dinberg » Wed Jun 29, 2011 11:09 am

It wasnt about pathing. I think Z coordinates are a different story.
Sorry blue i meant to reply to mgx, didnt see how old this thread is ;)

RE: z coordinates - Tola, you will be unable to parse the z heights for keeps without hitting some complexities. These will be based on fixture and terrain, so its not a case of reading heightmaps, and you will also need to be able to use multiple height 'layers' if you design with keeps in mind. I think Z-coordinates and pathing are one and the same beast - for both to work well I think your going to have to parse the client and create a simplified navmesh version of the world in memory.
The Marvelous Contraption begins to stir...
User avatar
Dinberg
Inactive Staff Member
 
Posts: 4695
Joined: Sat Mar 10, 2007 9:47 am
Yahoo Messenger: dinberg_darktouch
Location: Jordheim

Re: Z Coordinates ...

Postby Etaew » Wed Jun 29, 2011 11:17 am

Pathing craving has stepped up momentum these last few weeks, I'm almost ready to start discussing it.

Step 1: Rewrite my C# A* algorithm that will generate path points and create the methods needed to have NPCs walk along the generated points via WalkTo.
Step 2: Fill nodes with terrain objects (trees etc) - 2D
Step 3: Design a 3D mesh that can be applied to dungeons.
Step 4: Address this issue with fixtures (nif objects)
Retired DOL Enthusiast | Blog
User avatar
Etaew
Inactive Staff Member
 
Posts: 7602
Joined: Mon Oct 13, 2003 5:04 pm
Website: http://etaew.net
Location: England

Re: Z Coordinates ...

Postby Blue » Wed Jun 29, 2011 12:30 pm

Schaf gave me infos that we can generate the mesh from client files. Darkness Falls gets easy then. It consists of tile pieces which are connected.
ex DOL Lead Developer
Blue
Uthgard Admin
 
Posts: 961
Joined: Wed Jan 21, 2004 11:07 pm
ICQ: 63977313

Re: Z Coordinates ...

Postby Etaew » Wed Jun 29, 2011 12:31 pm

Schaf gave me infos that we can generate the mesh from client files. Darkness Falls gets easy then.
That's good. Please make sure any info gets noted down on these forums. It's nice to find gems when searching like these old threads with proper discussion.
Retired DOL Enthusiast | Blog
User avatar
Etaew
Inactive Staff Member
 
Posts: 7602
Joined: Mon Oct 13, 2003 5:04 pm
Website: http://etaew.net
Location: England

Re: Z Coordinates ...

Postby Blue » Wed Jun 29, 2011 12:42 pm

ex DOL Lead Developer
Blue
Uthgard Admin
 
Posts: 961
Joined: Wed Jan 21, 2004 11:07 pm
ICQ: 63977313

Re: Z Coordinates ...

Postby Graveen » Wed Jun 29, 2011 1:16 pm

Etaew, you implemented an A star, even simplified, into DOL ? or you have a mock up on your computer ?

Darwin worked on a A* implementation, and iirc he stored his own client map. Not sure if he succeeded or not, but he worked on this for some weeks. 'll ask him how it worked in fine.
Image
* pm me to contribute in Dawn of Light: code, database *
User avatar
Graveen
Project Leader
 
Posts: 12660
Joined: Fri Oct 19, 2007 9:22 pm
Location: France

Re: Z Coordinates ...

Postby Graveen » Wed Jun 29, 2011 1:18 pm

On another topic, Holy started to work on OpenCL-based path computation. Not especially an A* implementation, but something i was considering like a very good idea for heavy calculations like we could finally have to solve (including server-side LOS computing)
Image
* pm me to contribute in Dawn of Light: code, database *
User avatar
Graveen
Project Leader
 
Posts: 12660
Joined: Fri Oct 19, 2007 9:22 pm
Location: France

Re: Z Coordinates ...

Postby Etaew » Wed Jun 29, 2011 2:17 pm

Etaew, you implemented an A star, even simplified, into DOL ? or you have a mock up on your computer ?.
I did, and I had it actually making the pathing changes with WalkTo, it would calculate the route, then generate a set of pathpoints and then use the usual DOL pathing system, but I lost the code.
Retired DOL Enthusiast | Blog
User avatar
Etaew
Inactive Staff Member
 
Posts: 7602
Joined: Mon Oct 13, 2003 5:04 pm
Website: http://etaew.net
Location: England

Re: Z Coordinates ...

Postby Etaew » Wed Jun 29, 2011 2:24 pm

Oh actually, going to page 3 of this thread shows my design, and my code source inspiration. Awesome...

Shame these screenshots and pastebin doesn't work anymore.
Retired DOL Enthusiast | Blog
User avatar
Etaew
Inactive Staff Member
 
Posts: 7602
Joined: Mon Oct 13, 2003 5:04 pm
Website: http://etaew.net
Location: England

Re: Z Coordinates ...

Postby Etaew » Wed Jun 29, 2011 2:28 pm

Image
Image
Image
Retired DOL Enthusiast | Blog
User avatar
Etaew
Inactive Staff Member
 
Posts: 7602
Joined: Mon Oct 13, 2003 5:04 pm
Website: http://etaew.net
Location: England

Re: Z Coordinates ...

Postby Dinberg » Wed Jun 29, 2011 8:26 pm

I discussed this with him quite a bit about early january of this year - its definately possible, the nif collision meshes can be used with recast to create the required nav meshes. I also noticed WCell has a C# implementation of recast already in place that could be used for inspiration.

I think nav mesh is definately the way - Etaew's grid based system is nice for open world areas, but is limited by resolution factors (eg thin doorways) and multiple layers (required for most dungeons)
The Marvelous Contraption begins to stir...
User avatar
Dinberg
Inactive Staff Member
 
Posts: 4695
Joined: Sat Mar 10, 2007 9:47 am
Yahoo Messenger: dinberg_darktouch
Location: Jordheim


Return to “%s” DOL Development Discussion

Who is online

Users browsing this forum: No registered users and 1 guest