New way Editor!
New way Editor!
Hi all. I'm writing version2 of my editor, based upon new knowledges.
The code will be much more clear, so I'll can share sources with those are interested.
The .bin files will be read as a tree structure, so modifing a .bin will be easier and more error proof.
The functions that create, save as .bin, modify, etc. this tree will be in a package by itself, so they could be used as a base to other editors. If some of you want them, just contact me.
I'm planning to add (beyond the old interface) also a DC|ED-style inteface, to modify directly every value in files, with a correct handling of byte-counts and definitions. Here some screens:
[img width=351 height=600]http://malgolan.altervista.org/forumIma ... 2tree1.jpg[/img][img width=394 height=600]http://malgolan.altervista.org/forumIma ... 2tree2.jpg[/img]
Because of the recursive nature of .bin files (ID, length-of-block, data-block, where data-block again contains a list of ID-len-data, until leafs are reached) the .bin reader can skip whole unknown blocks of data, storing them as raw bytes, and then writing them identically when the tree is saved. In this way, not all the IDs must be known. Just the ones we want to modify.
Here is a list of IDs I've considered by now:
[img width=469 height=600]http://malgolan.altervista.org/forumImages/treeIDs.jpg[/img]
If you know the meaning of some IDs I've marked with "Unknown" just tell me. And if you want me to handle other IDs, idem.
Bye.
The code will be much more clear, so I'll can share sources with those are interested.
The .bin files will be read as a tree structure, so modifing a .bin will be easier and more error proof.
The functions that create, save as .bin, modify, etc. this tree will be in a package by itself, so they could be used as a base to other editors. If some of you want them, just contact me.
I'm planning to add (beyond the old interface) also a DC|ED-style inteface, to modify directly every value in files, with a correct handling of byte-counts and definitions. Here some screens:
[img width=351 height=600]http://malgolan.altervista.org/forumIma ... 2tree1.jpg[/img][img width=394 height=600]http://malgolan.altervista.org/forumIma ... 2tree2.jpg[/img]
Because of the recursive nature of .bin files (ID, length-of-block, data-block, where data-block again contains a list of ID-len-data, until leafs are reached) the .bin reader can skip whole unknown blocks of data, storing them as raw bytes, and then writing them identically when the tree is saved. In this way, not all the IDs must be known. Just the ones we want to modify.
Here is a list of IDs I've considered by now:
[img width=469 height=600]http://malgolan.altervista.org/forumImages/treeIDs.jpg[/img]
If you know the meaning of some IDs I've marked with "Unknown" just tell me. And if you want me to handle other IDs, idem.
Bye.
http://malgolan.altervista.org/
Italian politicians - Not in my name!
Italian politicians - Not in my name!
Re: New way Editor!
Yeah, amazing work!
I've sent you a message with a link to the scene2.bin documentation by the Mafia Modding Crew. It contains all the knowledge of the makers of DC||ED about the .bin files. Very useful stuff for you![Wink ;)](./images/smilies/icon_wink.gif)
Also here's a list with all IDs (+ description) which appear in the 0x1140 block. The IDs apply to the .4ds files too, so not all are used inside the bin files. Because I've taken them from the disassembled HD2.exe, they are 100% correct![Wink ;)](./images/smilies/icon_wink.gif)
1 Visual
2 Light
3 Camera
4 Sound
5 Sector
6 Dummy
7 Target
8 User
9 Model
10 Joint
11 Volume
12 Occluder
13 Scene
14 Area
15 Shadow
16 Landscape
I've sent you a message with a link to the scene2.bin documentation by the Mafia Modding Crew. It contains all the knowledge of the makers of DC||ED about the .bin files. Very useful stuff for you
![Wink ;)](./images/smilies/icon_wink.gif)
Also here's a list with all IDs (+ description) which appear in the 0x1140 block. The IDs apply to the .4ds files too, so not all are used inside the bin files. Because I've taken them from the disassembled HD2.exe, they are 100% correct
![Wink ;)](./images/smilies/icon_wink.gif)
1 Visual
2 Light
3 Camera
4 Sound
5 Sector
6 Dummy
7 Target
8 User
9 Model
10 Joint
11 Volume
12 Occluder
13 Scene
14 Area
15 Shadow
16 Landscape
Re: New way Editor!
Works adavance. Some more screenshots..
This is the main interface. In the big area in center will be displayed the map. On the right there are some icons (temporary images!) to activate several layers (respawns, actors, zones, number of flags, etc.)
[img width=797 height=600]http://malgolan.altervista.org/forumIma ... 2main1.jpg[/img]
Also the DC|ED style editor has been improved. Here some screens of it.
[img width=797 height=600]http://malgolan.altervista.org/forumIma ... 2tree3.jpg[/img]
[img width=797 height=600]http://malgolan.altervista.org/forumIma ... 2tree4.jpg[/img]
And finally, for those who care, here is the design for interface:
http://malgolan.altervista.org/forumImages/H&D2 RevEngEd 2.pps
If you have suggestions, just tell me!
This is the main interface. In the big area in center will be displayed the map. On the right there are some icons (temporary images!) to activate several layers (respawns, actors, zones, number of flags, etc.)
[img width=797 height=600]http://malgolan.altervista.org/forumIma ... 2main1.jpg[/img]
Also the DC|ED style editor has been improved. Here some screens of it.
[img width=797 height=600]http://malgolan.altervista.org/forumIma ... 2tree3.jpg[/img]
[img width=797 height=600]http://malgolan.altervista.org/forumIma ... 2tree4.jpg[/img]
And finally, for those who care, here is the design for interface:
http://malgolan.altervista.org/forumImages/H&D2 RevEngEd 2.pps
If you have suggestions, just tell me!
http://malgolan.altervista.org/
Italian politicians - Not in my name!
Italian politicians - Not in my name!
great news.
i hope you have plenty of paracetamol and black coffee, because their is so much to learn and do, i can imagine the headaches, one gets figuring all this hd2,
I have been trying the past week for map making, i am very pleased with your work and see the effort you have done for everyone, i can not wait to try it out, your editor.
will this editor also have plugin support for other appz ??
one need to jack that petition for hd2, editor is born.
I have been trying the past week for map making, i am very pleased with your work and see the effort you have done for everyone, i can not wait to try it out, your editor.
will this editor also have plugin support for other appz ??
one need to jack that petition for hd2, editor is born.
Re: New way Editor!
New feature implemented.
When loading an "actors.bin" file, now the editor checks for some byte counts integrity.
In fact, to manually modify files (using an hex editor) can introduce errors that H&D2 apparently can handle.
For istance, adding a "definition block" at end of file usually works, despite two byte counts should be changed according to the new byte length.
Here are some screens (the italian "s?" for "yes" will be fixed soon):
![Image](http://malgolan.altervista.org/forumImages/rev2actchk1.jpg)
![Image](http://malgolan.altervista.org/forumImages/rev2actchk2.jpg)
Also, graphic for layer icons has been improved, thanks to "Sonny":
![Image](http://malgolan.altervista.org/forumImages/rev2main2.jpg)
Do any of you knows if an actor.bin file can have different blocks AFTER the end of the definitions block? If so, could you make me an example among the vanilla missions?
When loading an "actors.bin" file, now the editor checks for some byte counts integrity.
In fact, to manually modify files (using an hex editor) can introduce errors that H&D2 apparently can handle.
For istance, adding a "definition block" at end of file usually works, despite two byte counts should be changed according to the new byte length.
Here are some screens (the italian "s?" for "yes" will be fixed soon):
![Image](http://malgolan.altervista.org/forumImages/rev2actchk1.jpg)
![Image](http://malgolan.altervista.org/forumImages/rev2actchk2.jpg)
Also, graphic for layer icons has been improved, thanks to "Sonny":
![Image](http://malgolan.altervista.org/forumImages/rev2main2.jpg)
Do any of you knows if an actor.bin file can have different blocks AFTER the end of the definitions block? If so, could you make me an example among the vanilla missions?
http://malgolan.altervista.org/
Italian politicians - Not in my name!
Italian politicians - Not in my name!
Re: New way Editor!
Here a few things that might be of interest:
The 3 float values in a 0x0032 block represent the color (RGB) of the ground plane in a scene (the one you see when you fall through the map)
I saw in one of your logs that you read the content of 0x24AE blocks as raw data, but these also have son datablocks (0x0100 up to 0x0900).
I've changed the value of a 0x00B6 block from 32 to zero on Normandy3_mp and the barbed wire around the first spawnpoints had no alpha anymore. The value in that block seems always to be 32 or 64
The 3 float values in a 0x0032 block represent the color (RGB) of the ground plane in a scene (the one you see when you fall through the map)
I saw in one of your logs that you read the content of 0x24AE blocks as raw data, but these also have son datablocks (0x0100 up to 0x0900).
I've changed the value of a 0x00B6 block from 32 to zero on Normandy3_mp and the barbed wire around the first spawnpoints had no alpha anymore. The value in that block seems always to be 32 or 64
Re: New way Editor!
Thank you! :)
Help is always appreciated!
I'll fix 0x0032 (just a label rename is needed).
I read as raw data all those blocks that are not worthing to modify (or I did not understand).
For example, the 0x24AE of ladder definitions is always the same (I suppose) and there is no need to change or understand its values. It's presence in the correct place it's enough.
Instead, the 0x24AE of zone definitions will be explored more, because it's needed to change flags owner and order.
If you have need for accessing some 0x24E block data, tell me which ones, and I'll add them to the editor.
And thank you again!
Help is always appreciated!
I'll fix 0x0032 (just a label rename is needed).
I read as raw data all those blocks that are not worthing to modify (or I did not understand).
For example, the 0x24AE of ladder definitions is always the same (I suppose) and there is no need to change or understand its values. It's presence in the correct place it's enough.
Instead, the 0x24AE of zone definitions will be explored more, because it's needed to change flags owner and order.
If you have need for accessing some 0x24E block data, tell me which ones, and I'll add them to the editor.
And thank you again!
http://malgolan.altervista.org/
Italian politicians - Not in my name!
Italian politicians - Not in my name!
Re: New way Editor!
Ikaros,,
you have much understanding of the files of hd2,
can you put a bik into walls and have them playing like they do on billboards, it be nice to see video playing on maps, n2_b, any were were their a wall.
Some old war movie cuts, and may be voice in the bik playing, or not ! so ikaros, is their any way to change a .bmp to a bik or place the module of voda, in side a wall to play a bik, ??? No one has even made this possible to play bik in a wall, i think you could achieve this and have built in your editor bik playing in walls, i like to know how you do this playing bik in other places on a map.![Rolling Eyes :roll:](./images/smilies/icon_rolleyes.gif)
you have much understanding of the files of hd2,
can you put a bik into walls and have them playing like they do on billboards, it be nice to see video playing on maps, n2_b, any were were their a wall.
Some old war movie cuts, and may be voice in the bik playing, or not ! so ikaros, is their any way to change a .bmp to a bik or place the module of voda, in side a wall to play a bik, ??? No one has even made this possible to play bik in a wall, i think you could achieve this and have built in your editor bik playing in walls, i like to know how you do this playing bik in other places on a map.
![Rolling Eyes :roll:](./images/smilies/icon_rolleyes.gif)
Re: New way Editor!
I've never tried such a thing ![Suprised :eek:](./images/smilies/icon_surprised.gif)
Maybe hdmaster knows more than me.
If you can give me an example (a mission where this is achieved)
I could try to reverse engineer
and replicate it....
![Suprised :eek:](./images/smilies/icon_surprised.gif)
Maybe hdmaster knows more than me.
If you can give me an example (a mission where this is achieved)
I could try to reverse engineer
and replicate it....
http://malgolan.altervista.org/
Italian politicians - Not in my name!
Italian politicians - Not in my name!
Re: New way Editor!
Hi!
I've added "delete" and "duplicate" functionalities to my DC-ED-like editor.
If someone would you like to do some beta testing, please contact me!
I've added "delete" and "duplicate" functionalities to my DC-ED-like editor.
If someone would you like to do some beta testing, please contact me!
http://malgolan.altervista.org/
Italian politicians - Not in my name!
Italian politicians - Not in my name!
Re: New way Editor!
When a definition is missing its specification (a specification with the same label),
it's pointed out with a red exclamation mark:
![Image](http://malgolan.altervista.org/forumImages/rev2tree5.jpg)
Do you think it's sufficient? Would you like also a pop-up on loading the file, or would it be too invasive?
Or, maybe, a completely different icon, more clearly visible? (for example, a big red disc...)
Which other marks would you suggest?
Model specifications which miss a relative definition? What else?
Bye.
it's pointed out with a red exclamation mark:
![Image](http://malgolan.altervista.org/forumImages/rev2tree5.jpg)
Do you think it's sufficient? Would you like also a pop-up on loading the file, or would it be too invasive?
Or, maybe, a completely different icon, more clearly visible? (for example, a big red disc...)
Which other marks would you suggest?
Model specifications which miss a relative definition? What else?
Bye.
http://malgolan.altervista.org/
Italian politicians - Not in my name!
Italian politicians - Not in my name!
Re: New way Editor!
It's possiblefinnlayer wrote: can you put a bik into walls and have them playing like they do on billboards, it be nice to see video playing on maps, n2_b, any were were their a wall.
![Wink ;)](./images/smilies/icon_wink.gif)
But only with changes in game or with plugin for 3ds max.
Max can use movie like texture in format .avi or .mpeg.We may add new movie format to hd2(hd2 engine can't play avi format any way).Not only .bik.[hard way]
Or get bik plugin for 3ds max.This will allow .bik [import/export](not .avi and .mpeg only).[easier way]
![Nods nods01](./images/smilies/045.gif)
Hey Ikaros will you publish an editor or tease us?
![Laughing :lol:](./images/smilies/icon_lol.gif)
Last edited by Mator on Tue Jul 05, 2011 12:07 pm, edited 1 time in total.
Re: New way Editor!
must give him time he makes a very good job
bravo ikaros good joob
![Thumbs Up thup01](./images/smilies/023.gif)
Re: New way Editor!
I think that HD2 must be able to read BIK files internally, the cutscenes are in BIK files.
Also I think it is possible to make animated surface in a map. Look at rivers or sea surfaces.
The question is if they use the BIK files from "gamemovie" folder or BMP textures (saved as frames) from "maps" folder.
Also I think it is possible to make animated surface in a map. Look at rivers or sea surfaces.
The question is if they use the BIK files from "gamemovie" folder or BMP textures (saved as frames) from "maps" folder.
Who is online
Users browsing this forum: No registered users and 91 guests