WoWMapper info to Recast... menu

Shout-Out

User Tag List

Page 1 of 3 123 LastLast
Results 1 to 15 of 34
  1. #1
    sPeC!'s Avatar Member
    Reputation
    23
    Join Date
    Jun 2009
    Posts
    20
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    WoWMapper info to Recast...

    Hello, long time reader first time poster

    Seeing all the amazing stuff that people has been making for WoW, i decided to give a try and make my own bot, mainly for learning purposes since i don't even play the game.

    I am starting with the navigation since it looks the hardest part, only because with all the info already available on those forums about all the other topics is just a matter of time and patience to absorb the info and code on..

    I was amazed with recast and detour and the possibilities they allow, and i have no doubt that its the best route to take for a NavMesh, pendra also seems to be doing great with is project, but i recon that i still don't have what it takes for something like that .
    I guess it shouldn't be that hard implementing a parser for the data using the info from WoW Dev. Wiki, but with the existance of WoWMapper wowmapper - Project Hosting on Google Code from Flowerew (thanks for that btw, amazing job), i don't feel like "reinventing the wheel".

    So anyway, my first step was trying to export some data from WoWMapper into Recast, that would seem easy enough with the posts i found with people having success...

    What i'am doing is just create a .obj file based on the vertices and indices WoWMapper provides, and then load it into recast. The problem is that i'am getting very weird results...

    I'am using the following to create the .obj file from inside the sample_meshexporter file, assuming that x, y, z are already transformed from WoW sytem:
    Code:
    	
              // Write the vertex's  
              for (int i = 0; i < mesh.vertices().size(); i++)
    	  {
    		  fs1 << "v " << (mesh.vertices()[i].x) << ' ' << mesh.vertices()[i].y << ' ' << (mesh.vertices()[i].z) << '\n';
    	  }
    
              // Create faces based on the indices
    	  for (int i = 0; i < mesh.indices().size();)
    	  {
    		  fs1 << "f " << mesh.indices()[i++];
    		  fs1 << ' ' << mesh.indices()[i++];
    		  fs1 << ' ' << mesh.indices()[i++] << '\n';
    	  }
    The result being:


    Any idea on what i'am doing wrong?

    Cheers,

    WoWMapper info to Recast...
  2. #2
    MaiN's Avatar Elite User
    Reputation
    335
    Join Date
    Sep 2006
    Posts
    1,047
    Thanks G/R
    0/10
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Indices are 1-based, not 0-based.
    You also need to convert into a correct coordinate system; from WoW to Recast (OpenGL) this goes:
    Code:
    public static void ConvertToOpenGLCoordinates(ref Vector3 v)
    {
        float z = -v.X;
        v.X = -v.Y;
        v.Y = v.Z;
        v.Z = z;
    }
    [16:15:41] Cypher: caus the CPU is a dick
    [16:16:07] kynox: CPU is mad
    [16:16:15] Cypher: CPU is all like
    [16:16:16] Cypher: whatever, i do what i want

  3. #3
    sPeC!'s Avatar Member
    Reputation
    23
    Join Date
    Jun 2009
    Posts
    20
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the prompt reply MaiN!

    Based on your answer it now works, the problem was caused from using 0 based indices (it would be very hard for me to find that...). The coord's are already converted by WoWMapper, but is allways good to know how!

    Cheers,

  4. #4
    FenixTX2's Avatar Active Member
    Reputation
    23
    Join Date
    Mar 2009
    Posts
    125
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I was playing around with wowmapper myself last night. Is it meant to take 2~3 hours to read the ADT's for Azeroth? And the same again to write the .mesh files?

  5. #5
    Xarg0's Avatar Member
    Reputation
    61
    Join Date
    Jan 2008
    Posts
    389
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    2 to 3 hours sounds like a reasonable amount of time to create meshes for azeroth, there's some heavy computation involved.
    I hacked 127.0.0.1

  6. #6
    Flowerew's Avatar Master Sergeant
    Reputation
    72
    Join Date
    Oct 2009
    Posts
    134
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by FenixTX2 View Post
    I was playing around with wowmapper myself last night. Is it meant to take 2~3 hours to read the ADT's for Azeroth? And the same again to write the .mesh files?
    Sounds strange. Seems like you use a debug build instead of release build, like some other guy that reported that behaviour to me. Reading Azeroth's ADTs should finish in under 30s on most PCs. So the whole process should take at max 10 min to extract the mesh information and write it to your HDD. Recast is another story, I've seen everything from 30 mins to 2 days.

  7. #7
    MaiN's Avatar Elite User
    Reputation
    335
    Join Date
    Sep 2006
    Posts
    1,047
    Thanks G/R
    0/10
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Flowerew View Post
    Sounds strange. Seems like you use a debug build instead of release build, like some other guy that reported that behaviour to me. Reading Azeroth's ADTs should finish in under 30s on most PCs. So the whole process should take at max 10 min to extract the mesh information and write it to your HDD. Recast is another story, I've seen everything from 30 mins to 2 days.
    30 seconds per tile? That's horribly slow!
    [16:15:41] Cypher: caus the CPU is a dick
    [16:16:07] kynox: CPU is mad
    [16:16:15] Cypher: CPU is all like
    [16:16:16] Cypher: whatever, i do what i want

  8. #8
    Bananenbrot's Avatar Contributor
    Reputation
    153
    Join Date
    Nov 2009
    Posts
    384
    Thanks G/R
    1/3
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I think he meant 30 seconds for the whole continent and / or 30 tiles per second:



    (from wowmapper - Project Hosting on Google Code)

  9. #9
    sPeC!'s Avatar Member
    Reputation
    23
    Join Date
    Jun 2009
    Posts
    20
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    True. It will be be a big, and i mean really big difference between the time needed by a release build and a debug build. You should allways use the release build... Offcourse the processor where you run the app will also make the difference.

    One thing that i noticed is that the ground that contains water, like the rivers and the lake in Elwynn Forest is not being removed even if i set the flag for it...

    Cheers,

  10. #10
    Viano's Avatar Active Member
    Reputation
    37
    Join Date
    May 2008
    Posts
    172
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It's that simple with WoWMapper and Recast. At last decent navigation for my bot (thanks Flo!).

    WoWMapper info to Recast...-stormwind-jpg
    Viano

  11. #11
    Flowerew's Avatar Master Sergeant
    Reputation
    72
    Join Date
    Oct 2009
    Posts
    134
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by sPeC! View Post
    One thing that i noticed is that the ground that contains water, like the rivers and the lake in Elwynn Forest is not being removed even if i set the flag for it...
    While working on wowmapper it seemed like only areas where you could actually swim and drown is marked as water. So shores and shallow rivers where you can walk/stand in are not considered water, thus it isn't removed (that's atleast what my experience was back then). Water is something I wanted to invest more time on once I released the lib, but never got around to do it 100% accurate because work consumed all my time. If you look at the code in Adt_c::BuildTerrain function (adt_c.cpp - wowmapper - Project Hosting on Google Code) you notice a little workaround specifically for Azeroth and some other maps, that removes all faces below Y(0) which was used to remove the ocean.

    If you want you can try to re/write the water chunks which shouldnt be that hard and see if you can do it it right... I would appreciate that. But right now I don't have the time and commitment to do it, especially when it looks like Cataclysm is changing its map format again.

    Best regards

    p.s.:
    Viano & sPeC!: Nice screens, wish I had the time to some nav stuff myself right now. Keep up the good work guys!
    MaiN:

  12. #12
    vkyii's Avatar Private
    Reputation
    1
    Join Date
    May 2009
    Posts
    2
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hello
    i have got wowmapper_v0.1.7z from (Downloads - wowmapper - Project Hosting on Google Code), when run run.bat (Sample_MeshExporter . World\maps\Azeroth\Azeroth),it crashed:
    HTML Code:
    Open MPQ: L:\MFWOW\Data\patch.MPQ
    Open MPQ: L:\MFWOW\Data\patch-3.MPQ
    Open MPQ: L:\MFWOW\Data\patch-2.MPQ
    Open MPQ: L:\MFWOW\Data\lichking.MPQ
    Open MPQ: L:\MFWOW\Data\expansion.MPQ
    Open MPQ: L:\MFWOW\Data\common.MPQ
    Open MPQ: L:\MFWOW\Data\common-2.MPQ
    Files in MPQs available: 179295
    
    This application has requested the Runtime to terminate it in an unusual way.
    Please contact the application's support team for more information.
    i think "World\maps\Azeroth\Azeroth" is the wdt file, but didn't find it anywhere, maybe i have got something important missing. How do i let it run correctly?

  13. #13
    Viano's Avatar Active Member
    Reputation
    37
    Join Date
    May 2008
    Posts
    172
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by vkyii View Post
    ...
    World\\Maps\\Azeroth\\Azeroth is the path inside the .MPQ files so you should be fine.
    Here is how I am calling it.

    Code:
    std::string mpq_dir("C:\\WoW\\Data"); // ex.: .
    std::string wdt_dir("World\\Maps\\Azeroth\\Azeroth");
    Viano

  14. #14
    vkyii's Avatar Private
    Reputation
    1
    Join Date
    May 2009
    Posts
    2
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    thank you Viano. it works now

  15. #15
    sPeC!'s Avatar Member
    Reputation
    23
    Join Date
    Jun 2009
    Posts
    20
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Flowerew View Post
    While working on wowmapper it seemed like only areas where you could actually swim and drown is marked as water. So shores and shallow rivers where you can walk/stand in are not considered water, thus it isn't removed (that's atleast what my experience was back then). Water is something I wanted to invest more time on once I released the lib, but never got around to do it 100% accurate because work consumed all my time. If you look at the code in Adt_c::BuildTerrain function (adt_c.cpp - wowmapper - Project Hosting on Google Code) you notice a little workaround specifically for Azeroth and some other maps, that removes all faces below Y(0) which was used to remove the ocean.

    If you want you can try to re/write the water chunks which shouldnt be that hard and see if you can do it it right... I would appreciate that. But right now I don't have the time and commitment to do it, especially when it looks like Cataclysm is changing its map format again.

    Best regards

    p.s.:
    Viano & sPeC!: Nice screens, wish I had the time to some nav stuff myself right now. Keep up the good work guys!
    MaiN:
    Ah, that explains it. Yes i had already seen the way how you removed the ocean, it seem to do what it is supposed to, although i didn't tested any other area than the one i refered above

    I'am on the quest to follow wiki .dev and your code to really understand what's going on. But it's like you say, it's time consuming and needs some commitment, and you are also right about Cataclysm, and i don't feel like to invest too much on this until the expansion gets out. Your code is still and in anyway a good overal way to get into the things.

    Cheers,

Page 1 of 3 123 LastLast

Similar Threads

  1. Path Generator – Recast/Detour and WowMapper – Step
    By RivaLfr in forum WoW Memory Editing
    Replies: 32
    Last Post: 05-13-2022, 05:38 AM
  2. Free World of Warcraft (10 days not playing with payment info)
    By Fakeskuh in forum World of Warcraft General
    Replies: 5
    Last Post: 06-15-2006, 12:20 PM
  3. Collected Naxx info
    By impulse102 in forum World of Warcraft General
    Replies: 1
    Last Post: 06-04-2006, 01:44 AM
  4. Info on taking Ragnaros (And other MC general info)
    By Cush in forum World of Warcraft Guides
    Replies: 4
    Last Post: 05-28-2006, 03:53 AM
All times are GMT -5. The time now is 09:02 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search