Heroes of Might and Magic Community
visiting hero! Register | Today's Posts | Games | Search! | FAQ/Rules | AvatarList | MemberList | Profile


Age of Heroes Headlines:  
5 Oct 2016: Heroes VII development comes to an end.. - read more
6 Aug 2016: Troubled Heroes VII Expansion Release - read more
26 Apr 2016: Heroes VII XPack - Trial by Fire - Coming out in June! - read more
17 Apr 2016: Global Alternative Creatures MOD for H7 after 1.8 Patch! - read more
7 Mar 2016: Romero launches a Piano Sonata Album Kickstarter! - read more
19 Feb 2016: Heroes 5.5 RC6, Heroes VII patch 1.7 are out! - read more
13 Jan 2016: Horn of the Abyss 1.4 Available for Download! - read more
17 Dec 2015: Heroes 5.5 update, 1.6 out for H7 - read more
23 Nov 2015: H7 1.4 & 1.5 patches Released - read more
31 Oct 2015: First H7 patches are out, End of DoC development - read more
5 Oct 2016: Heroes VII development comes to an end.. - read more
[X] Remove Ads
LOGIN:     Username:     Password:         [ Register ]
New Server | HOMM1: info forum | HOMM2: info forum | HOMM3: info forum | HOMM4: info forum | HOMM5: info forum | MMH6: wiki forum | MMH7: wiki forum
Heroes Community > Heroes 4 - Lands of Axeoth > Thread: H4ResourceEditor
Thread: H4ResourceEditor This thread is 11 pages long: 1 2 3 4 5 6 7 8 9 10 11 · «PREV / NEXT»
NimoStar
NimoStar


Promising
Supreme Hero
Modding the Unmoddable
posted November 23, 2018 10:08 PM

Se discussion here for some found limitations of .ora file in GIMP regarding 0x0 layers, and why it may be best to use PNG folders instead.

http://heroescommunity.com/viewthread.php3?TID=45442&pagenumber=1
____________
Discover H4 Greatest Mod!
https://www.moddb.com/mods/greatest-mod/downloads
(Also biggest of only two 2 mods for HOMM IV)

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Famous Hero
posted November 25, 2018 01:44 PM
Edited by Karmakeld at 15:36, 25 Nov 2018.

NimoStar said:
Se discussion here for some found limitations of .ora file in GIMP regarding 0x0 layers, and why it may be best to use PNG folders instead.

http://heroescommunity.com/viewthread.php3?TID=45442&pagenumber=1


Keep in mind the issue is related to animation files, not objects.
As of now, the ResourceEditor can't open the animation.xx.h4d or layer files.
You can import the animation.xx.ora file, but you'll be importing the animation into an object.

Also keep in mind that the ResourceEditor is able to handle both PNG and ora.

So really this should be a request to make the Resource Editor be able to read and handle the animation files and layers for viewing and importing.
----------
Derrick, I just tried out reading my object package h4r file, haven't tried that out yet.
I can open the file and get the inventory list just fine, being displayed in alphabetic order, though I noticed that it differ betweeen capital letters and small, meaning it goes from S, T to c, d etc.. Not a big deal, though.

Minor things:
I can't open new files or close the current one, meaning you'll have to close the program and restart it to open another h4r file.

I encountered a few objects I couldn't view in the H4RE, but they work in the editor:
dead creatures.unicorn.sw
Mir.pumkin_s_L and R
prison mirror is just a blank image.

Another occasional issue - if you try opening any of the 'seer's hut.creatures.' files, the top options bars is not viewable and I can't drag it in anyways to display them.



edit: Oh and it seems the ResouceEditor can't export shadows?? Is that true??

-----
radmutant69 said:
Karmakeld said:
So when you have the time Radmutant, could you look into these files and see if you can repeat the Magic Lamp fix? Bush 05 is the issue, the others works fine.


The short answer is: I can't repeat. I don't even know what was the problem with this one as the other 4 bushes also have different canvas sizes and frame sizes from the original tree that you used to import. After some attempts to fix it, I recreated the object from scratch instead.

The appearing behind other objects was because both of your bushes.05 objects have a 01 02 in their header where they should have 00 02 (what causes crash BTW, likely because of the different canvas and frames sizes). The 01 from this makes the game ignoring the end code, so your objects can't cover others at all and appear in background anyway..


So is your conclusion that if the header info is preset to 00 02 (or if it isn't, it will correct the code to 00 02) and an end code 'xx ff ff' is added, then we should be able to create objects from scratch??
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
radmutant69
radmutant69


Known Hero
posted November 26, 2018 04:12 PM

Karmakeld said:
So is your conclusion that if the header info is preset to 00 02 (or if it isn't, it will correct the code to 00 02) and an end code 'xx ff ff' is added, then we should be able to create objects from scratch??


I'm not sure, because (as far as I know) we still don't know exactly why causing crash when we import an image with different sizes into an object. The same thing can happen with any brand new object since we don't know how to code the new images' size into the object. Or do we?

Also
Karmakeld said:
[...]the tricky part is that even similar objects like the skeleton dragons or gold veins have different lenght end codes, depending on their direction[...]

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Famous Hero
posted November 28, 2018 02:39 PM
Edited by Karmakeld at 14:41, 28 Nov 2018.

radmutant69 said:
Karmakeld said:
So is your conclusion that if the header info is preset to 00 02 (or if it isn't, it will correct the code to 00 02) and an end code 'xx ff ff' is added, then we should be able to create objects from scratch??


I'm not sure, because (as far as I know) we still don't know exactly why causing crash when we import an image with different sizes into an object. The same thing can happen with any brand new object since we don't know how to code the new images' size into the object. Or do we?

Also
Karmakeld said:
[...]the tricky part is that even similar objects like the skeleton dragons or gold veins have different lenght end codes, depending on their direction[...]



True, atleast I'm no closer to understanding why those crashes happens. But I've encountered a few more of them - either the import via the ResourceEditor is bad or changing the 01 02 to 00 02 doesn't help.

I could give Namerutans tool a try. Simply import some new images and see if I can add various header and footprint infos and also in different combos. We had success with this back in the early stage.
Tbh. I haven't looked at the imported size code, - except I just did...
Quite interesting. I worked with bushes.05 (the one Radmutant just helped me with) imported into trees.green.04.
Now comparing the imported bushes05 with the original bushes05 the image is enlarged by W 22 and H 19 pixels. The ResourceEditor reads these data just fin3 matching the enlarged image size. The frame remains the size of that which was imported into.
Radmutant, did ypu insert the images into another image file before importing it?

About the lengt of the end code, then Derrick needs to test his 'blocks' theory and see if that leads us further..
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
radmutant69
radmutant69


Known Hero
posted November 28, 2018 03:55 PM

Hmmm... I resized both the image and the frame to the sizes of that Magnolia tree that you tried to use to import it, and I made the object finally with the ResHelper and hex editing.

"changing the 01 02 to 00 02 doesn't help." Yeah, that doesn't helps. The opposite of this would 'help' because in that way you can import the image without crashing but your object will be a background object. You still can't change the 01 to 00 without writing a correct end code, what isn't that easy since we don't know how to do that. I think

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Famous Hero
posted November 28, 2018 06:45 PM

radmutant69 said:
Hmmm... I resized both the image and the frame to the sizes of that Magnolia tree that you tried to use to import it, and I made the object finally with the ResHelper and hex editing.

"changing the 01 02 to 00 02 doesn't help." Yeah, that doesn't helps. The opposite of this would 'help' because in that way you can import the image without crashing but your object will be a background object. You still can't change the 01 to 00 without writing a correct end code, what isn't that easy since we don't know how to do that. I think


Odd, coz it doesn't match the image size of the tree. I'll upload them, then you can look at them, not that I think this holds any answers unless the image should somehow be enlarged by importing it.

Sorry I should've been specific about the 01 02 to 00 02 - importing the image wasn't the issue - OldGreyWolf asked me to help him with a background object and changing that from 01 02 to 00 02 AND adding a 04 00 00 00 ff ff ff ff ff ff ff ff end code (the same as the tree) didn't work, so I guess I answered my own question from before.
So I guess we do indeed need to understand how the end code length is determined or why these doesn't work (Derrick!! )
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
radmutant69
radmutant69


Known Hero
posted November 29, 2018 12:50 PM

Well, okay, so I resized it to that Magnolia tree's sizes what you uploaded into your 'test objects' folder along with the bushes. Its image size is 405x356 and the frame 001 is 82x75. Also, the object I made is probably off-centered as I see now from the images

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
iliveinabox05
iliveinabox05


Known Hero
posted November 30, 2018 09:12 PM

I know, I know! I was on vacation (but kept up with the forums) and then I had to travel for work (sitting in the airport waiting to get home), so I haven't been doing much recently.

When I get home though I should be able to get back to things

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Famous Hero
posted November 30, 2018 09:46 PM
Edited by Karmakeld at 15:03, 24 Dec 2018.

Legally excused then
Oh and just reminding you about allowing it to also read/export obj files as well
Infact it might be nice if the load/save/export options contained a full list of ora, png, h4d, h4r, obj or whatever format can be loaded, saved or exported.

Rad, well you had me puzzled there for a while - I did wonder how the import could've enlarged the image size.

EDIT: Hey mate.. How's it going with the updates? Even the minor ones, like obj recognition..?
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
iliveinabox05
iliveinabox05


Known Hero
posted January 07, 2019 05:28 PM

Ugh sorry, no updates. I started trying again to figure out what is going on with the alpha, but still can't figure out that bug yet.

I did start going through this thread again to make a list of the other smaller things I could do, but then I never got the chance to actually make that list.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Roman2211
Roman2211


Adventuring Hero
posted January 08, 2019 08:51 AM

Please, add the programming export to APNG format

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Famous Hero
posted January 08, 2019 08:21 PM

Roman2211 said:
Please, add the programming export to APNG format


Roman have you tried just exporting as .png?
As it reads png I'm pretty sure you can export as png aswell, you just need to type the extension yourself. It works with .ora.
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
iliveinabox05
iliveinabox05


Known Hero
posted January 08, 2019 09:11 PM

I think he may have some AnimatedPNG, which is different than regular PNG, image files. I'm guessing this format supports partial transparency for each of the frames, whereas GIF does not.

There seems to be a small amount of support for APNG with Java (a library that someone else has written), so it may be possible to add support for these types of images at some point.

Since the Resource Editor already supports png, I really just need a class that can handle reading or writing an APNG file, and doing a quick google search I may have found one I can use when I get to it.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Famous Hero
posted January 09, 2019 08:34 PM
Edited by Karmakeld at 17:49, 13 Jan 2019.

iliveinabox05 said:
Ugh sorry, no updates. I started trying again to figure out what is going on with the alpha, but still can't figure out that bug yet.

I did start going through this thread again to make a list of the other smaller things I could do, but then I never got the chance to actually make that list.


Well here's what I could sum up from my memory. Not sure if I missed some from earlier posts, but these are the ones I could think of:

- Option to toggle on/off passability info (blank = display animation only).
- Enable Import/Export all readable game formats.
- Add readable formats to save/export list.
- Autosave last open and save path.
- Drop down options of editable options, like Animation Speed,
Footprint height/width (if possible to change easily), Types.
Types should also include Nothing and Deadbody.
- Could it display the flag, rather than a white dot? (this would make it easier to determine correct position).
- Set the default open/import to 'all formats'.

Edit:
Also some tree view and or no distinction between big and small letters would be useful when looking through files.
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
NimoStar
NimoStar


Promising
Supreme Hero
Modding the Unmoddable
posted January 10, 2019 10:24 PM

Surprising nobody mentions layer renaming when that is what went wrong with namerutan's---
____________
Discover H4 Greatest Mod!
https://www.moddb.com/mods/greatest-mod/downloads
(Also biggest of only two 2 mods for HOMM IV)

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
iliveinabox05
iliveinabox05


Known Hero
posted January 10, 2019 11:18 PM

Nimostar, can you elaborate? Not sure what you mean by layer renaming.

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Famous Hero
posted January 10, 2019 11:32 PM
Edited by Karmakeld at 14:17, 12 Jan 2019.

NimoStar said:
Surprising nobody mentions layer renaming when that is what went wrong with namerutan's---


Well not really, as you seemed to be the only one who encountered that issue
(I owe you a couple of '' and now I had the chance )
-----
Edit (also posted this in the research of how to make new objects as that is also useful knowledge there, though it also very much is related to the use of the ResourceEditor).

I've playing around with the ResourceEditor and Gimp a bit since last and I've found something interesting. The image of Shadows can exceed the canvas amd still be imported and displayed properly. We did have a few attempts at this early on with the mirrored Mausoleum and Knights Chapter but this indeed seems to work. The reason why this is good to know, is that we generally find that you can't import a larger image/canvas size into a smaller one, only the other way around. And in some cases this can affect the placement of shadows (though probably mostly for mirrored objects).

I've also found that in some cases, as encountered and posted earlier - like the Labyrint which we struggled hard to center, there can be issues when moving the image too far from the original position to match the footprint, but I've had succes with reducing the canvas size, to thereby 'force' a new image position, eliminating the need to do these large image movement.

____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
NimoStar
NimoStar


Promising
Supreme Hero
Modding the Unmoddable
posted January 12, 2019 09:40 PM
Edited by NimoStar at 21:42, 12 Jan 2019.

Quote:
Well not really, as you seemed to be the only one who encountered that issue
(I owe you a couple of '' and now I had the chance )


Not at all. The issue is systemic when importing, I have checked in several computers. Of course it won't matter for *objects* (which is what you have mostly done) but it *will* matter for things like Towns and UI elements. Inh fact I seem to recall the UI doesn't work at all if not properly hex-renamed (which the Namerutan tool messed up) and this was what made me fight with Ilive and eventually demonstrated...

Plus renaming layers is necessary for many objectives; as I said to namerutan, for example, spell icons, heroes icons and artifacts etc. are named layers.
____________
Discover H4 Greatest Mod!
https://www.moddb.com/mods/greatest-mod/downloads
(Also biggest of only two 2 mods for HOMM IV)

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
iliveinabox05
iliveinabox05


Known Hero
posted January 13, 2019 12:01 AM

NimoStar said:
Not at all. The issue is systemic when importing, I have checked in several computers. Of course it won't matter for *objects* (which is what you have mostly done) but it *will* matter for things like Towns and UI elements. Inh fact I seem to recall the UI doesn't work at all if not properly hex-renamed (which the Namerutan tool messed up) and this was what made me fight with Ilive and eventually demonstrated...

Plus renaming layers is necessary for many objectives; as I said to namerutan, for example, spell icons, heroes icons and artifacts etc. are named layers.


Nimo, I'm still not exactly sure which layers need renaming that Namerutan's tool had issues with. Could you elaborate for me? Could you give me an example or point me to a thread post, please?

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Karmakeld
Karmakeld


Famous Hero
posted January 13, 2019 12:04 AM

NimoStar said:
Quote:
Well not really, as you seemed to be the only one who encountered that issue
(I owe you a couple of '' and now I had the chance )


Not at all. The issue is systemic when importing, I have checked in several computers. Of course it won't matter for *objects* (which is what you have mostly done) but it *will* matter for things like Towns and UI elements. In fact I seem to recall the UI doesn't work at all if not properly hex-renamed...

Plus renaming layers is necessary for many objectives; as I said to namerutan, for example, spell icons, heroes icons and artifacts etc. are named layers.


Well even objects consists of named layers..
I have made other changes succesfully, like hero portraits, campaign splashscreens, town screen buildings (animations).
Renaming the layers in Gimp is working for me, just saying, but I guess iLiVe could add that option to rename the layers..? The tool already lists the layers and their names.

Could you give a few examples of what has caused you issues or share the images or files, then I think it would be easier for others to help locate the issue. I only vaguely recall something about an additional byte being wrongfully added or something.
____________

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Jump To: « Prev Thread . . . Next Thread » This thread is 11 pages long: 1 2 3 4 5 6 7 8 9 10 11 · «PREV / NEXT»
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.0667 seconds