Minus One - W4 to W3D map converter.

Whatever you're working on - be it Art, Music, a Fan-Game or a program for use with existing Team17 games - we want to hear about it.

Moderator: Dream17 Staff

K^2
Regular
Posts: 216
Joined: Thu May 26, 2005 4:02 am

Minus One - W4 to W3D map converter.

Post by K^2 » Fri May 27, 2005 8:18 pm

This is a little tool for converting W4 maps (.XAN, .HMP) that you might come by into the format supported by W3D (.XOM). Just make sure that both the .XAN and .HMP files of the map you want converted are in the same directory as the WMinusOne.exe, run the program, and enter the file name of the map that you want converted when prompted for input.

Edit: Just noticed an error in the title. Fixed.

Edit by S-2K - This program is being left on the forum for the time being, however I need to make it clear that Dream17 do not endorse this program.
Attachments
WMinusOne.zip
(7.23 KiB) Downloaded 872 times
Last edited by K^2 on Sat Jul 02, 2005 6:12 am, edited 1 time in total.

User avatar
Zeor
Senior
Posts: 737
Joined: Thu May 26, 2005 3:21 am
Location: Science and Outer Space

Post by Zeor » Sat May 28, 2005 12:30 am

Yeah, I'll just keep this in mind for the next time a W4 map materializes into existance in front of me and lands in my lap. =P
Zero72, Team17 Forum member (and former Cartoonist), June 2002 - June 2013.

Zeor TV - [fart noise]!

K^2
Regular
Posts: 216
Joined: Thu May 26, 2005 4:02 am

Post by K^2 » Sat May 28, 2005 9:20 am

Yes, I know. It is a bit difficult to come by in US. I'll look more into the copyright rules, and see if there is any legal way to just put out the entire image of the XBox demo disk somewhere on the web.

However, if you do have an access to the XBox demo of W4, you can get all of the maps by extracting the files (You'll have to search the web for this. I'm not familiar with procedure. Had help on this part.), and then looking for the Maps directory, which might be located in a compressed folder. I believe, it contains arround 100 maps.

User avatar
Run
Fan of Excellence
Posts: 92
Joined: Fri May 27, 2005 7:30 pm
Location: Exeter Uni / Balsall Common
Contact:

Post by Run » Sat May 28, 2005 9:30 am

Zero72 wrote:Yeah, I'll just keep this in mind for the next time a W4 map materializes into existance in front of me and lands in my lap. =P
Quantum theory suggests that that is possible, though unlikely.
Hofstadter's Law: "It always takes longer than you expect, even when you take into account Hofstadter's Law"

User avatar
Squirminator2k
Dream17 Founder
Posts: 573
Joined: Mon Feb 28, 2005 2:07 pm
Location: Los Angeles, CA
Contact:

Post by Squirminator2k » Sat May 28, 2005 2:14 pm

I was under the impression that XBox DVDs are burnt in a different manner from standard DVDs...
PortsCenter - Gaming's forgotten history. A show all about unique video game ports.

K^2
Regular
Posts: 216
Joined: Thu May 26, 2005 4:02 am

Post by K^2 » Sun May 29, 2005 6:42 am

They are, so you can't just pop one into your DVD drive and extract the files. You can do one of the following:
1) You can download special firmware for your DVD-ROM, which will allow it to read XBox DVDs, but such firmware exists for very few models of DVD-ROM drives.
2) You can put the disk into the XBox, copy the files to the hard drive, and download them from the XBox via FTP. You would probably need a moded XBox and some special software for it. I think I've seen instructions on how to do that somewhere on the web.
Last edited by K^2 on Sun May 29, 2005 10:37 am, edited 1 time in total.

User avatar
Run
Fan of Excellence
Posts: 92
Joined: Fri May 27, 2005 7:30 pm
Location: Exeter Uni / Balsall Common
Contact:

Post by Run » Sun May 29, 2005 7:53 am

K^2 wrote:FTP.
What an odd link.
Hofstadter's Law: "It always takes longer than you expect, even when you take into account Hofstadter's Law"

K^2
Regular
Posts: 216
Joined: Thu May 26, 2005 4:02 am

Post by K^2 » Sun May 29, 2005 10:39 am

I can't do anything about it. The forum insists on parsing "FTP" as a URL. I wonder why it parses into an HTTP URL, though.

Edit: I see. It only happens if "FTP" is followed by a dot.

User avatar
Blinx
Newbie
Posts: 32
Joined: Wed Jun 01, 2005 1:08 pm
Location: Not a by-product of animal buggery

Post by Blinx » Wed Jun 01, 2005 1:20 pm

I think Team 17 are very foolish for banning you K^2. This is certainly an intresting programme.

You genius, you. :)

User avatar
Alien King
Regular
Posts: 146
Joined: Thu May 12, 2005 4:21 pm
Location: somewhere...

Post by Alien King » Wed Jun 01, 2005 2:05 pm

i'll download this interesting program despite the fact i havn't actually got W3D. i may get it someday tho

do u think it would be possible to make the program run in reverse, and convert W3D maps to W4?

User avatar
Squirminator2k
Dream17 Founder
Posts: 573
Joined: Mon Feb 28, 2005 2:07 pm
Location: Los Angeles, CA
Contact:

Post by Squirminator2k » Wed Jun 01, 2005 2:08 pm

Blinx wrote:I think Team 17 are very foolish for banning you K^2.
I can understand Team17's point of view - they need to protect their information and the work that they have spent so long creating. My view is that as long as K^2 doesn't attach or post links to Worms4/Worms3D Map Files, I'm content for this program to remain on the forum. As I have previously stipulated however, this is not an endorsement of the program. Team17 have made their feelings clear regarding K^2's work.
PortsCenter - Gaming's forgotten history. A show all about unique video game ports.

K^2
Regular
Posts: 216
Joined: Thu May 26, 2005 4:02 am

Post by K^2 » Thu Jun 02, 2005 1:30 am

Alien King wrote:do u think it would be possible to make the program run in reverse, and convert W3D maps to W4?
There is no need for that. The basic format of W3D and W4 maps is identical. The program just does two things: Stripps the map of the entities, which prevents the entities unknown to W3D from crashing it, and adds the height map. The height map is only added if .HMP file exists. Otherwise, the program quits after stripping the map of entities. I would assume that W4 supports all W3D entities, so to run a W3D map on W4 you just have to rename the .XOM file into a .XAN file. If that, however, crashes W4, you might need to run the .XAN file you got by my converter, which will produce a .XOM file without any entities. Now you can rename that .XOM into .XAN, and then it will run for sure.
My view is that as long as K^2 doesn't attach or post links to Worms4/Worms3D Map Files, I'm content for this program to remain on the forum.
Thanks. And don't worry, I'm not going to post or link to anything that contains any of T17 copyrighted data.

User avatar
Cyclaws
Former Staffmember
Posts: 83
Joined: Wed Mar 02, 2005 12:33 pm
Location: London, England
Contact:

Post by Cyclaws » Thu Jun 02, 2005 1:36 am

I think that it was silly that you were banned from Team17, for improving their game. They said they might release a map editor, but never did. So you made one. I can understand that they might be unhappy that your taking W4 maps, but the maps in Worms 3D get boring after you've played them for the 100th time, and it would be nice to get some new onees.

In short, I would like to use programs that you make, so long as no copyrighted Team17 material is used, which you've said you won't do.
Webmaster of WormsTournaments: http://www.wormstournaments.co.uk
Creator of my blog: http://www.kevinstreetonline.com
Worms Corrispondent for Dream17: cyclaws@dream17.info

User avatar
Blinx
Newbie
Posts: 32
Joined: Wed Jun 01, 2005 1:08 pm
Location: Not a by-product of animal buggery

Post by Blinx » Thu Jun 02, 2005 8:04 am

Personally I dont think Team 17 actually care for their forum anymore. I remeber the amount of participation there way on the forum when I joined. It was good. Perhaps too much time on the forum resulted in the crap that was W3D (imo)
"I never think of the future - it comes soon enough." - Albert Einstein

Ben and Liam eat incontinent fish.

User avatar
Squirminator2k
Dream17 Founder
Posts: 573
Joined: Mon Feb 28, 2005 2:07 pm
Location: Los Angeles, CA
Contact:

Post by Squirminator2k » Thu Jun 02, 2005 10:48 am

Spadge has said that the company aren't spending so much time on the forum as they used to because it became somewhat of an obsession during the development of Worms3D, eating not only into development time but also into personal time, both at work and at home. It's understandable that they would spend less time on the forum now, but the Team17 Forum is starting a downward slide.
PortsCenter - Gaming's forgotten history. A show all about unique video game ports.

User avatar
Alien King
Regular
Posts: 146
Joined: Thu May 12, 2005 4:21 pm
Location: somewhere...

Post by Alien King » Thu Jun 02, 2005 2:20 pm

K^2 wrote:
Alien King wrote:do u think it would be possible to make the program run in reverse, and convert W3D maps to W4?
There is no need for that. The basic format of W3D and W4 maps is identical. The program just does two things: Stripps the map of the entities, which prevents the entities unknown to W3D from crashing it, and adds the height map. The height map is only added if .HMP file exists. Otherwise, the program quits after stripping the map of entities. I would assume that W4 supports all W3D entities, so to run a W3D map on W4 you just have to rename the .XOM file into a .XAN file. If that, however, crashes W4, you might need to run the .XAN file you got by my converter, which will produce a .XOM file without any entities. Now you can rename that .XOM into .XAN, and then it will run for sure.
ah, so ur program just removes anything that may not work on W3D. nice work

K^2
Regular
Posts: 216
Joined: Thu May 26, 2005 4:02 am

Post by K^2 » Thu Jun 02, 2005 3:35 pm

That is the oversimplified way of saying it, but basically, yes.

What it actually does:
1) Skip the file header and go directly to TYPE headers.
2) Find the headers for lattices and entities and get the number of both.
3) Go back to the beginning. Read in the file header. Decrement the CTNR count and the pointer to Root lattice by the number of entities. Add 16 to CTNR count if height map is going to be added. Write the header to the new map.
4) Go to the TYPE headers. Decrement the number of entities to 0, and increment the number of lattices by 16 if the height map is going to be added. Write TYPE headers to the new map.
5) Copy GUID, SCHM, and STRS chunks to the new map.
6) Skip the entity CTNRs.
7) For each lattice CTNR, read in the CTNR, decrement the number of attached entities to 0 and decrement the pointers to each lattice by the total number of entities. If the current CTNR is the Root lattice and the height map is going to be added, attach the pointer to the first lattice in the height map. Write the resulting CTNR into the new map.
8 ) If there is a height map, generate 16 new CTNR chunks for each lattice in the height map with proper coeficients, offsets, and attachments. Write these CTNRs to the new map.



Edit: Gah! T17 have delleted my W3D Map Viewer thread. Now, what harm did that do to anyone? It isn't even a tool. It just lets you LOOK at the maps. W3D Map Editor is now officially my #1 priority.
None of my projects (Minus One converter, W3D/W4 Map Viewer, and WMapEditor) are endorsed, supported or otherwise affiliated with Dream17. I just find Dream17 forums to be a nice place to share and discuss my work with others.

User avatar
Paul.Power
He Rocketh So
Posts: 99
Joined: Thu May 12, 2005 12:09 pm
Location: Swansea

Post by Paul.Power » Sat Jun 04, 2005 11:16 pm

K^2 wrote:Edit: Gah! T17 have delleted my W3D Map Viewer thread. Now, what harm did that do to anyone? It isn't even a tool. It just lets you LOOK at the maps. W3D Map Editor is now officially my #1 priority.
Go for it. I don't entirely agree with the W4 to W3D converter thingy (although I admire the fact you can do it), but if you can fully crack the map editor, I can't see what other than good that can do.
"Spam is the filling in the sandwich of forum life"

Here, have some Let's Plays: Advance Wars 2 | Advance Wars

User avatar
AndrewTaylor
Regular
Posts: 157
Joined: Tue Mar 01, 2005 11:01 am
Location: Leeds UK
Contact:

Post by AndrewTaylor » Sun Jun 05, 2005 2:47 am

K^2 wrote:Edit: Gah! T17 have delleted my W3D Map Viewer thread. Now, what harm did that do to anyone? It isn't even a tool. It just lets you LOOK at the maps. W3D Map Editor is now officially my #1 priority.
Maybe they just flipped down the list and deleted everything that looked relevant.

User avatar
Alien King
Regular
Posts: 146
Joined: Thu May 12, 2005 4:21 pm
Location: somewhere...

Post by Alien King » Sun Jun 05, 2005 4:34 pm

K^2 wrote:Edit: Gah! T17 have delleted my W3D Map Viewer thread. Now, what harm did that do to anyone? It isn't even a tool. It just lets you LOOK at the maps.
that's a bit too much i think

Post Reply