This is a read only copy without any forum functionality of the old Modcraft forum.
If there is anything that you would like to have removed, message me on Discord via Kaev#5208.
Big thanks to Alastor for making this copy!

Menu

Author Topic: [REQUEST] ADT Repairer  (Read 7554 times)

Keta

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 210
    • View Profile
[REQUEST] ADT Repairer
« on: January 21, 2012, 08:16:50 pm »
Hey Developers. Yes, and all the rest of Modcraft too :p

So, my request is for someone to make a tool that can fix ADTs. so they work completely fine again. Here is how I think it should work:

You have a completely empty ADT, as well as your corrupt BUT BEAUTIFUL ADT.
The program should read the corrupted ADT's Heightmap, Texture map, WMO and M2 paths+locations and holes. (And more, if I forgot something). And this data, it should copy and replace the data on the empty ADT with.
This way, it would make a completely new CLEAN ADT, with the same ground and models!

That is, assuming my theory is correct. If not, maybe just a program that can do as much of the ADT as possible? xP

Thanks
Keta
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Steff

  • Administrator
  • Creator of Worlds
  • *****
  • Posts: 4551
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #1 on: January 22, 2012, 12:18:09 am »
Noggit write every time you save an ADT from scratch.
If we build in some error correction during loading then we have this tool. In the moment noggit stop to load if it find errors. Because we want only clean stuff. But in future we could clean up on loading and just show an overview what has got fixed. So the user know whats going on.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Please mark as solved if solved.
Don't ask if you could ask a question... JUST ask the Question.
You can send me also offline messages. I will answer if I get online.
Skype: project.modcraft
Discord: steff#6954

Keta

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 210
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #2 on: January 22, 2012, 01:29:34 am »
Uhm... I don't understand exactly how that is affecting the matter at hand. Well, I mean sure, it builds the ADT from scratch, but then how come my Wow crashes every time I try to go to my custom ADTs, no matter how many times I try to re-save it. And yes, I've tried without models. Didn't do any differenec.
Btw. Its not as soon as it loads the ADTs it crashes. Its when I actually look at it. I can walk very near it, but not exaclty look straight at it.
And I've tried building from scratch again, and that time it worked. So... I mean, a simple Height, Texture and Model export/import tool should pretty much fix it I think :o

Thanks
Keta
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Steff

  • Administrator
  • Creator of Worlds
  • *****
  • Posts: 4551
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #3 on: January 22, 2012, 11:57:07 am »
The only problems i have seen in the last time where doodad paths that crash wow. Or if you don´t start from 0 with a clean adt and use blizzards once with stuff noggit don´t support. Or if you use no a 335a as source. I had now for month not one adt that crash my wow. And i used nearly every beta on my maps.

But the point is if we implement more functions into load and perhaps save that validates the data we need no repair function in an separated app. My try is to reduce the amount off apps wee need to.... perhaps someday only one.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Please mark as solved if solved.
Don't ask if you could ask a question... JUST ask the Question.
You can send me also offline messages. I will answer if I get online.
Skype: project.modcraft
Discord: steff#6954

Keta

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 210
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #4 on: January 23, 2012, 07:57:21 am »
Yea you know that would be really nice ^.^ So you're actually saying that the Blizzard ADTs from Stranglethorn Vale which I'm editing, isn't fully 3.3.5a ADTs, and therefor there may be a part which gets saved weird when Noggit tries to save the ADTs as 3.3.5a ADTs. And that's why it wont work in-game?

In that case, is it possible to impliment a converter in Noggit that converts older ADT types to 3.3.5a and removes whatever invalid information they may contain? :p

Thanks
Keta
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Steff

  • Administrator
  • Creator of Worlds
  • *****
  • Posts: 4551
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #5 on: January 23, 2012, 08:45:11 am »
Yes it is :)
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Please mark as solved if solved.
Don't ask if you could ask a question... JUST ask the Question.
You can send me also offline messages. I will answer if I get online.
Skype: project.modcraft
Discord: steff#6954

Keta

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 210
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #6 on: January 23, 2012, 10:44:59 am »
In that case... Is there any template like the 010 ones for Vanilla ADTs? (I'm guessing its Vanilla ADTs, but I'm actually not sure). Otherwise, is there any other way I can manually convert it like hex editing or something?

Thanks
Keta
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Steff

  • Administrator
  • Creator of Worlds
  • *****
  • Posts: 4551
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #7 on: January 23, 2012, 11:17:08 am »
No you have to write a tool i think. This whould be the easyest way. Like the one for 335a to 4. Ask Mjollna Perhaps he share the source and you can build a converter for any format to any other. Whould be nice :) as CMD tool.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »
Please mark as solved if solved.
Don't ask if you could ask a question... JUST ask the Question.
You can send me also offline messages. I will answer if I get online.
Skype: project.modcraft
Discord: steff#6954

Keta

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 210
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #8 on: January 23, 2012, 11:50:19 am »
Well then I think the most essential question is, the
Code: [Select]
struct MVER {
  uint32_t version;
};
different for all ADT types, so I can determine what to convert and such based on that result? Cause otherwise, I dunno how I'd get started.

And yes, I will try to contact and talk to Mjollna about it ^^

Thanks
Keta
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Mjollna

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 254
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #9 on: January 23, 2012, 12:06:48 pm »
Hi :)

As for the ADT Converter, I put the source online a few days ago and I was planning to add it to the meta repository, but I didn't have the time to finish the sharing before leaving home.

I don't feel like playing with the meta repository from the hotel where I am now, but I've made the converter public in the meantime, it should be available here :

https://bitbucket.org/Mjollna/adtconverter

Remember it was my first program, so about the code, well... It's not clean at all >.<

About the adt versions : ADTs are v18 (0x12) from wow alpha to Cataclysm included, really, MVER is just not the chunk you want to use to determine which version it is.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Keta

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 210
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #10 on: January 23, 2012, 01:29:10 pm »
So you're saying I would have to determine the template I'd need to use on an ADT, based upon a unique thing in each of the ADT formats? o_O That seems very... Risky... :s No other safer way to do this?

Thanks
Keta
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Mjollna

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 254
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #11 on: January 23, 2012, 01:43:40 pm »
In wow alpha adt are included into wdt, from wow beta to lk they work the same (though more different chunks in lk than vanilla, of course), and for Cata you have 3 files instead of one.
So I guess it's not as hard to check as it could be... ?
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Keta

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 210
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #12 on: January 23, 2012, 02:08:36 pm »
Well either I've lived on a lie regarding knowedge of WDT files, or I am just unaware of small parts about them but... I have not touched the WDT file at all xP I edited existing ADT files, saved, and continued to do this some times till I wanted to see it ingame. and thats when it crashes.

Thanks
Keta
« Last Edit: January 01, 1970, 01:00:00 am by Admin »

Mjollna

  • Contributors
  • Model Change Addict
  • *****
  • Posts: 254
    • View Profile
Re: [REQUEST] ADT Repairer
« Reply #13 on: January 23, 2012, 02:44:51 pm »
My point was : it doesn't look that hard to see which adt is which major version.
You don't have to care about wdt for adt parsing, as long as you don't care about 2003 alpha.
« Last Edit: January 01, 1970, 01:00:00 am by Admin »