Author Topic: Pathnodes...  (Read 534 times)

Legacy_TheOneBlackRider

  • Hero Member
  • *****
  • Posts: 512
  • Karma: +0/-0
Pathnodes...
« on: September 20, 2012, 09:42:22 pm »


               This one is related to:
Tile - walkmesh-issue: Partly only one-way-walk possible
http://social.biowar...1751/1#13925044

Pathnodescreens and additional info on pathnodes from:
http://harvestmoonco...php?f=59&t=2074

OK, I finally managed to check my tiles regarding pathnodes. I will have to change the entries in the set-file. But checking out pathnodes, a stumbled again! '<img'>

Quote Bannor Bloodfist:
"Black is walkable though, and intersections to the edges are where most toons will attempt to walk onto a given tile. If there are not fairly direct connections to any other tile across an area, then the toon will get stuck and just stand around trying to figure out how to move around."

 So, if I got it right, then:

'Image

The full tile platform should get pathnode A
'Image

The half platform should get pathnode C
'Image

And the quart platform should get pathnode B
'Image
(Note: The mdls are not rotated in a larger degree - only slightly to show the shape a bit better! This is the way, they load into gmax.)

But how is the pathnode aligned to the tile direction? For example, one version of the half platform runs left to right (towards the back half) by default (see screen above). And I have a second variation, which runs from the front to the back (towards the left half).
Variation:
'Image

--> Do I just use the same pathnode or do I have to rotate the pathnode according to the layout of the tile?

(P.S. Nevermind the coloring on the mdls shown - just took those to show the shape/layout.)
               
               

               


                     Modifié par TheOneBlackRider, 20 septembre 2012 - 08:49 .
                     
                  


            

Legacy_TheOneBlackRider

  • Hero Member
  • *****
  • Posts: 512
  • Karma: +0/-0
Pathnodes...
« Reply #1 on: September 20, 2012, 09:57:31 pm »


               ... I think, I just found the answer here:
http://social.biowar...1701/1#14187940
Quote Bannor Bloodfist:
"When a path node gets assigned, it must also be correctly rotated to match the physical tile.  If either is wrong, then NPC's get stuck, and sometimes PC's when attempting to move long distances. (...)"

--> But how do I rotate the pathnode? ... ':whistle:'
               
               

               


                     Modifié par TheOneBlackRider, 20 septembre 2012 - 08:58 .
                     
                  


            

Legacy_Michael DarkAngel

  • Hero Member
  • *****
  • Posts: 627
  • Karma: +0/-0
Pathnodes...
« Reply #2 on: September 20, 2012, 11:17:49 pm »


               Pathnodes are rotated in the tilesets corresponding .SET file.

For each particular tile look for:

PathNode=
Orientation=

Orientation determines the amount of rotation for the pathnode designated above it.  Pathnodes can only be rotated in 90 degree increments.  For each 90 degrees the pathnode will be rotated counter-clockwise.

HTH

'Image
  MDA
               
               

               


                     Modifié par Michael DarkAngel, 20 septembre 2012 - 10:19 .
                     
                  


            

Legacy__six

  • Hero Member
  • *****
  • Posts: 1436
  • Karma: +0/-0
Pathnodes...
« Reply #3 on: September 20, 2012, 11:55:07 pm »


               Both MDA's (here) and the original jlen Set Editor programs give you a nice visual interface for aligning the path node. It assumes that the Y axis runs vertically upwards from a top down perspective, so shouldn't be hard to figure out.

Note also that MDA's set editor supports additional path nodes that were added later in the patching process.
               
               

               


                     Modifié par _six, 20 septembre 2012 - 10:57 .
                     
                  


            

Legacy_Bannor Bloodfist

  • Hero Member
  • *****
  • Posts: 1578
  • Karma: +0/-0
Pathnodes...
« Reply #4 on: September 21, 2012, 12:48:04 am »


               Personally, I only use Velmars Tileset Creator which is a VERY powerful set of scripts that run inside of 3dsmax.  (I always have NWMax, Veltools, AND the TSC loaded in 3ds).

With the TSC, you can directly edit every setting for any tile in a .set file.  It will allow you to set the rotation of a pathnode, allow you to pick the pathnode type, allow you to set intersections on the tile with other tiles, ie to set whether it connects to a road or any other crosser AND to set if it connects to a different terrain type.

On that linked page is a brief tutorial, but that tutorial does not cover all the real power of the script set.
You will also find TWO different versions, one has an installer, the other has an updated set of sripts.  I typically install first, then manually copy the updated scripts on top of the installed version.

I am typing this while in the hospital on a borrowed laptop, so I can't give the exact files that need to be copied or their locations, but it should be fairly obvious.

1) Default height for all four corners is set to have one corner raised.  This can be fixed by editing an .INI file, but again, I am not on my main computer so I can't tell you file name or location.

2) Neither version will actually allow you to add NEW groups to a given tileset.  There are buttons for it, but they don't appear to work.  Likely there is a way to enable that, but I have not investigated why it doesn't work, I just manually add group entries by editing the tileset.set file in a text editor.

3) One neat feature of the TSC, is that it WILL load a group.  IE, it will properly load all the tiles in a given group.  Proplerly located within 3dsmax.   So a 3 by 3 group (actually any size) will load with all 9 tiles in the correct position and correct rotations etc, so you can actually see the whole group and edit any tile in the group.

4) Another neat feature is that it WILL allow you to add NEW tiles to the .set file, and allow you to set all the necessary features of that tile in the .set, pathnodes, name, name of minimap, orientation, crossers, terrain connections etc.  It always creates the new entry at the very bottom of the .set file to avoid renumbering the tileset and possibly breaking existing groups etc.

5) The TSC, has many features, one of which is the ability to create minimaps for a given tile, range of tiles (ie 1-210 in a tileset that has 400 tiles) or create minimaps for all tiles, or just for all groups.  A VERY useful feature, but you may need some help figuring out how to get that feature working for you.

Jlen's set editor will break any tileset that was created or uses 1.69 features.  Don't use it.  It will remove all settings for grass height etc, and will not recognize the difference between a path node named "a" and one named "A", so it won't work with the new pathnodes added in the 1.67 patch.  It has many other bugs too.  While useful for OLD tilesets, it just breaks too much in newer tilesets.

MDA's seteditor recognizes the updated pathnodes etc, but doesn't have the same power as Velmar's TSC once you get used to using it inside of 3dsmax. MDA's seteditor will work with groups better.  I think MDA was originally intending to fix those issues, but I don't think he has updated or finished it yet.  The other "feature" of MDA's seteditor is that it is a completely seperate program and does NOT require you to have 3dsmax running to use it.  So between those two programs, you sorta have to choose how you want to work.

Note, most of what I am stating above is a personal opinion and that opinion is based on how I work with tiles and tilesets.  I have no issues with using any of the programs except Jlen's which I mentioned breaks all tilesets since 1.67 (yes, 1.67 AND 1.69)
               
               

               
            

Legacy_OldTimeRadio

  • Hero Member
  • *****
  • Posts: 2307
  • Karma: +0/-0
Pathnodes...
« Reply #5 on: September 21, 2012, 05:20:13 pm »


               Just wanted to chime in and support Bannor's endorsement of the TSC.  TSC is...a pretty amazing thing.  I found it required several careful watchings of the tutorial videos (included at the link Bannor provided) to "get" the paradigm of how the helpers work and how they're related, but once I did it made life quite a bit easier.  Nothing is perfect but TSC is really good, IMO.  The only time I use anything other than TSC when working on a tileset is to use JLen's set editor to make the palette (.ITP) from the .set file.

I haven't had the issues that Bannor did with adding groups but most of the tilesets I make are "from scratch" and so there might be some kind of difference there.

Edit: Oh, and another nice thing about TSC that I don't think Bannor touched on is the fact that when you're setting path nodes, it'll overlay a pathnode graphic over your ground plane so you can actually see what the orientation is.  Very handy.
               
               

               


                     Modifié par OldTimeRadio, 21 septembre 2012 - 04:23 .
                     
                  


            

Legacy_Michael DarkAngel

  • Hero Member
  • *****
  • Posts: 627
  • Karma: +0/-0
Pathnodes...
« Reply #6 on: September 21, 2012, 07:24:25 pm »


               I do agree that TSC is a very powerful tool, it does however have a downside.  It will only work with 3DSMax.  And if I'm not mistaken, based on your screenshots you are using GMax and unfortunately will not be able to benefit from all that TSC has to offer.

'Image
  MDA 
               
               

               
            

Legacy_TheOneBlackRider

  • Hero Member
  • *****
  • Posts: 512
  • Karma: +0/-0
Pathnodes...
« Reply #7 on: September 22, 2012, 10:23:37 am »


               Thanks people!
Yes, MDA, I "only" have Gmax. You wrote, that TSC won't work with Gmax and I confirm. Sad, because I was going to ask, if there is a way to get the rotation of the pathnodes right without checking every mdl within Gmax (or 3dMax), when OTR wrote of the overlay feature to see the orientation. But it won't work for me, I guess. '<img'>

But, (correct me, if I'm wrong), the minimaps use the same orientation as the mdl/tile. So when using MDA's Set Editor, which also shows the assigned minimap, one can use that for orientation regarding the pathnodes.

Questions:
1. Since nobody opposed my chosen pathnodes and my chosen assigning to the mdl/tile, these seems to be the right ones, right?

2. What if a tile shows the pathnode "removed" (in MDA's Set Editor)? Does that tile not have a pathnode or is just the image missing? (Well, ok, I should look that up right within the set-file... '<img'>

3. Is there an easy way to test pathnodes IG? Like setting up 2 waypoints for a NPC far appart in a straight line (across a tile, which does not use the + as a node) and see, if the NPC finds its way? Would that work?

P.S. All the best, Bannor. Get well.
               
               

               


                     Modifié par TheOneBlackRider, 22 septembre 2012 - 09:26 .
                     
                  


            

Legacy_Bannor Bloodfist

  • Hero Member
  • *****
  • Posts: 1578
  • Karma: +0/-0
Pathnodes...
« Reply #8 on: September 22, 2012, 11:23:38 am »


               Quick answers:

Yes, sorry, TSC only works inside of 3ds max, not gmax.  I did mention that in my post.

1) yes, those particular pathnodes are correct.

2) There are no utils that tell you explicitly if a pathnode is assigned.  The game engine will auto-assign that "A" pathnode (without making any changes to the .set file) automatically at run time... same with visibility node and door visibility... all default to "A" if not assigned directly in the .SET file.

3)  Nope.  No automatci testing has ever been created.  This, so far, can only be accomplished by manually testing in game and toolset.

I can tell you that finding someone willing to spend the hours necessary to test that in game is very difficult.  That is how I got started in dev work for NWN... testing, to help the other folks that were fixing things find and fix the bugs.  Ended up that there just are not enough folks willing to take the time to fix everything.... everyone wants a shortcut.  There simply are not any available shortcuts for true, error free, releases.  Everything has to be manually tested both in Game AND in Toolset.  This seldom happens.

I can also tell you that as a creator of tilesets, or at least a modifier of same, it is common to assume since I "know" what I am doing, that I am not going to make mistakes... yet I do, all humans do, it is part of our nature.
               
               

               
            

Legacy_OldTimeRadio

  • Hero Member
  • *****
  • Posts: 2307
  • Karma: +0/-0
Pathnodes...
« Reply #9 on: September 22, 2012, 04:00:05 pm »


               

TheOneBlackRider wrote...
2. What if a tile shows the pathnode "removed" (in MDA's Set Editor)? Does that tile not have a pathnode or is just the image missing? (Well, ok, I should look that up right within the set-file... '<img'>

If you're talking about what I think you're talking about, when Bioware released their tileset cretion pack back in 2003, they provided some documentation which included graphics of what the pathnodes looked like.  A few of the pathnodes simply had "removed" as their graphic.  Even though they aren't really used, any time you see those in a set editor it's probably an attempt to completely expose as much as possible.  See page 21 in this.  What Bannor said was accurate but I suspect you're talking about those graphics specifically. (?)

TheOneBlackRider wrote...
3. Is there an easy way to test pathnodes IG? Like setting up 2 waypoints for a NPC far appart in a straight line (across a tile, which does not use the + as a node) and see, if the NPC finds its way? Would that work?

Best way to test pathnodes in game, IMO, is always with a player.  You pointing and clicking yourself.  In an area with no placeables, starting at least 2 tiles away, and starting in such a way that, as the crow files, you'd be coming into the tile you want to test diagnally.  Diagnally, as in coming in from a corner as opposed to an edge.  This should put the most strain on the pathing system and expose any problems with your path nodes. 

So:
###
#B#
###
##A

The hash marks and letters represent tiles.  If you want to test tile B, start from someplace in the center of tile A and click where you want to go in B.  This is pointless when you have all pathnode A, but a really good way to
test if you have some non-simple pathnodes in and between A and B.  If for instance tile B was pathnode N and it was oriented facing up/north from where you were in tile A, you'd really start to see the way path nodes affect movement.

Remember this is all about pathnodes and pathnodes are all about moving between tiles, not moving inside them.  That's handled by WOK, although which edge you enter and which edge you leave is determined by the pathnode.

BTW, there is a console command called rendertilepathnodes 1 which will give you a visual estimate of the pathing NWN will use with pathnodes.  Easier to explain with pics.  Here I am in the toolset with the player start location painted at the intersection of 4 tiles.  Here I am in-game, not having moved at all and with rendertilepathnodes 1.  Because tile path nodes are edge based, here's a composite of the path in relation to the tiles.  It's very easy to get confused and think rendertilepathnodes is showing you edges of tiles, when it's really invisible center paths.  The actual path you take when clicking, say, two tiles away, won't be the exact one rendertilepathnodes shows you, because there's a further, unseen, optimization to the path which takes place A) moving through obstacles in the WOK, 'B)' moving around obstacles like PWK and (if neither of those are present or if there only a few obstacles) C) an "as the crow flies" optimzation which makes the path look more natural when the character is walking.  The more obstacles there are, though, the less pretty it'll look and the more clearly you'll be able to see how it adheres to the instruction from the pathnodes, such as my examble earlier with destination B on my little hash graph above using pathnode N.
               
               

               


                     Modifié par OldTimeRadio, 22 septembre 2012 - 03:06 .
                     
                  


            

Legacy_Bannor Bloodfist

  • Hero Member
  • *****
  • Posts: 1578
  • Karma: +0/-0
Pathnodes...
« Reply #10 on: September 22, 2012, 05:29:11 pm »


               Yeah, what OTR said!

I typically just test with a character and do basically what he suggests, but it requires you to 1) build the area with the specific tiles you want, and have them far enough apart to actually engage the pathing engine as OTR suggested.

That is why I said it takes an enormous amount of time to test things.  It is also why I use the TSC inside of 3dsmax... by the way, check this forum a few weeks, maybe as much as 2 months back, someone posted a link to the "free for students" download of 3dsmax 2012... likely they have updated that to the 2013 version of 3dsmax. (Which I have NOT tried, nor am i sure the various tools for NWN will work with 2013, but likely they will)
               
               

               
            

Legacy_TheOneBlackRider

  • Hero Member
  • *****
  • Posts: 512
  • Karma: +0/-0
Pathnodes...
« Reply #11 on: September 22, 2012, 09:14:58 pm »


               Again, thanks for all your efforts. Thanks for the screen-tut and the link, OTR. I'll follow the procedure suggested by you 2. Yes, testing is quiet time consuming!

Me wants 3ds! <runs of to check out the price... '<img'>:blink:':sick:'... decides to have 20 or even more nice evening dinners with his wife instead! '<img'>> (Homage to Rolo - welcome back!)

I noticed that "student"-version, but I'm no student anymore... (It's been a greater while! ':whistle:')
So, I will have to stick to Gmax, which is quiet ok. It's amazing, that they have this tool for free, anyways!
               
               

               


                     Modifié par TheOneBlackRider, 22 septembre 2012 - 08:18 .