IPB

Welcome Guest ( Log In | Register )

Dnamro Navmeshing script v3
Dnamro
post Oct 8 2017, 01:52 PM
Post #1


CinC (for now)
Group Icon

Group: Mr. Admin
Posts: 6,934
Joined: 28-December 03
From: Fort Hood, TX
Member No.: 46



This is menu based version much improved version of the navmeshing script provided by DICE. This one tool combines the functions that 4 scripts were previously needed.

https://drive.google.com/open?id=0B_o_kOaz7...SWFaQmd2UGZzMEE

Download and unzip into your Navmesh folder (Edit 2 - 12 Oct 2017 - Fixed a bug trying to create the logfile if the navmesh\map_name folder was not already created and fixed a bug that if the logfile already existed):

If you are installing for the first time, these are all new files, so there is nothing to replace or overwrite.

It includes a PDF tutorial.

Website tutoral is here: http://classic-battlefield-modding.wikia.c...ing_the_Navmesh

What is new in Navmesh Tool Ver 3.0:

- The Updated navmesh tool is now one menu based consolidated tool.

- The navmesh tool now reads the mod folder and displays a list of maps to select from.

- Fix Navmesh now cleans the navmesh file to a format that works with the navmesh tool. This fixes most known issues with exporting from from 3d modeling software -- specifically from 3ds Max and Blender. Previously this has been a big headache to manually fix the navmesh file after exporting.

- There is now an advanced option to use the largest navmesh islands - for those that are not into 3d modeling and also for quick testing purposes.

- There is another advanced option to use the clean the navmesh files, however this is done as part of the Fix Navmesh process.

- Navmesh files are automatically backed up with date -time stamp in the file name to maintain a copy of the orginal navmeshes. The file location is \navmesh\work\[map name]\GTSdata\Backup\

Additional Features:

- Automatically set up the Navmesh work files for the specific map.

- Automatically copy the GTSdata from the map to the navmesh work area prior to generating the navmesh files.

- Automatically copy the Output files from the navmesh work area to the map after running "Fix Navmesh" routine.

- Option to Choose to work on only infantry, vehicle or both navmeshes.

- Option to select a different map to work on.

- Option to launch the BF2 Editor with the selected mod and map


--------------------
No, my Avatar is not my dog.
Go to the top of the page
 
+Quote Post
2 Pages V  < 1 2  
Start new topic
Replies (15 - 18)
clivewil
post Oct 18 2017, 12:29 AM
Post #16


meh.
Group Icon

Group: Mr. Admin
Posts: 2,008,267
Joined: 24-July 07
From: Perth, Western Australia
Member No.: 3,545



QUOTE (Dnamro @ Oct 18 2017, 09:35 AM) *
The other thing I am working on is to check the SA file for neighbors and if there are none, then to neighbor all to each other. I do this a lot manually when I am working on the navmesh and automating it would be very helpful.

wow yeah, trying to select some of those small SA's can be painful, it'd be great if it was automatically neighboured

i'm happy to run off a navmesh for some map, i don't know what yet, if you want another live field test for your script

---> btw Dnamro, are you aware of any way of using a redirect both to the screen AND to a file? it would be handy to have a hard copy of the output while still being able to see what's happening in real time.

all the so called solutions i've seen involve running the command twice, which is cool for a weeny little Dir command etc, but not so cool for a navmesh that takes hours


--------------------
Go to the top of the page
 
+Quote Post
Dnamro
post Oct 18 2017, 08:03 PM
Post #17


CinC (for now)
Group Icon

Group: Mr. Admin
Posts: 6,934
Joined: 28-December 03
From: Fort Hood, TX
Member No.: 46



Clive,

Do you want to wait until I finish the auto neighbor function to test or I can send you the current version if you want? From what I have learned to do with python so far, it should be fairly easy.

Yes, I have taken a deep look into logging and have not found any way to stream the output to both the screen and a logfile from the navmesh generator using python. I actually spent a lot of time researching and testing to see if I could figure anything out. What I did find is that the reason that when creating the navmesh, the output goes to both screen and logfile, but when running the fixnavmesh routine, it only goes to the screen. It looks like If I could get set up to recompile the code, I could fix that.

Another thing is that since the create navmesh process is divided in the following sections, Manifold, then stitch and finally creating the infantry and or vehicle navmeshes, I would like to test starting from either the infantry or vehicle navmesh step. This would be the case where either the process stopped because of a power failure, system restart or something else and it has to be restarted. The Manifold and stitch steps should not need to be repeated if the process needs to be restarted.




--------------------
No, my Avatar is not my dog.
Go to the top of the page
 
+Quote Post
clivewil
post Oct 18 2017, 10:08 PM
Post #18


meh.
Group Icon

Group: Mr. Admin
Posts: 2,008,267
Joined: 24-July 07
From: Perth, Western Australia
Member No.: 3,545



ok, i'll wait for the auto-neighbour because i'd like to see that in action too. in the meantime i'll look at fixing up my BF2 install, it has been dead for a while now. somebody's custom object killed it and i never got around to rectifying it


--------------------
Go to the top of the page
 
+Quote Post
Dnamro
post Today, 05:22 PM
Post #19


CinC (for now)
Group Icon

Group: Mr. Admin
Posts: 6,934
Joined: 28-December 03
From: Fort Hood, TX
Member No.: 46



Sounds good. I have the code written to check for and add neighbors. I am debugging and testing now.

Here is the basic process overview:

Check Neighbor routine:

Check for that the SA file exists - if not abort.

- Read the SA file and check for a neighbor line.
if no neighbor lines found then go to the add neighbor routine
if a neighbor line is found then give the option to overwrite or cancel

Add neighbor routine:

- make a backup of the SA file and delete the SA file.

- Start reading from the SA backup file and start writing to a new SA file (This way there is a backup that you can go back to if you don't like the new SA file or the routine crashes in the middle).

- while reading each line look for these words and do the following action:

createFromControlPoint - get the next word in the line and add it to a list of SA names
write the line out to the SA file
setActive - get the next word in the line and add save it as the current SA name
write out the line
Go through the list of SA names writing out a neighbor line for each one, except the one that matches the current SA name

write out all other lines to the SA file with no action









--------------------
No, my Avatar is not my dog.
Go to the top of the page
 
+Quote Post

2 Pages V  < 1 2
Reply to this topicStart new topic
2 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
1 Members: Dnamro

 



RSS Lo-Fi Version Time is now: 20th October 2017 - 05:22 PM