H4ResourceEditor

The old Heroes games developed by New World Computing. Please specify which game you are referring to in your post.

Moderator: Moderators

User avatar
Karmakeld
CH Staff
CH Staff
Posts: 1087
Joined: 12 Nov 2011

Re: H4ResourceEditor

Postby Karmakeld » Mar 24 2018, 21:19

Just sharing some of my wishes for features for the ResourceEditor.

- Beside the ability to easily edit passability and entrance info, it would be nice to be able to edit/move passability placement based on object placement - I'm wondering if you would be able to display objects in isometric view (similar to Reshelper)? That would make it easier to align new objects with passability info.
I support using red for impassable, yellow for entrance and green for passable. Also grid display is nice.

- Possibility to edit an objects type, e.g from Dwelling or Creature to Quest Hut or Interactive object to Decorative.
Dropdown menu would likely be a good solution. Your current Major, Minor and Sub type gives a good overview.

- Ability to decide/edit if object should always appears infront of others or in the back.

- The ability to import new images (ora format?) and then setup type, passability etc. and save them as new objects.

- possibility of editing objects animation speed.
I'm silent in seven languages - and I got all my familys fear.
Everytime you throw dirt, you loose a little ground

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Mar 26 2018, 0:09

Here is displaying of the entrance info on the H4 Resource Editor.

Image

and

Image

Now onto editing this information :D

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Mar 26 2018, 2:52

Anddddddd, the entrance info is editable :D See below.

Image

And then when viewing in the editor:

Image

Steven Aus
Demon
Demon
Posts: 324
Joined: 08 Feb 2006
Location: Australia

Re: H4ResourceEditor

Postby Steven Aus » Mar 27 2018, 23:33

How are your H4MG and the EquilibrisHD Widescreen Mod going?

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Mar 28 2018, 15:54

H4MG is in the same spot I left it at, unfortunately. I think there actually has been progress since the last update here, but I don't remember for sure. It looks like I was last working on renaming variables, and I do vaguely remember that being pretty much finished, but I would have to go back and do some testing. Now that I'm thinking of it, I think I recall issues if you have two variables with the same name, one bool and one number.

As far as the widescreen mod, I have no idea. Dalai is still absent at the moment :(

Steven Aus
Demon
Demon
Posts: 324
Joined: 08 Feb 2006
Location: Australia

Re: H4ResourceEditor

Postby Steven Aus » Mar 28 2018, 21:38

I call him back with love, honour, commitment and shared ideals and interests.

As to your H4MG Project, if you are still around and you still have free time to put in, it will happen! I mean, after all, HOMM4 was from 2003 or something, I mean, if it has lasted 15 years then it is a survivor, just like You, CH and JVC And Team!

I mean, you can't go backwards unless you lost your only copy, or your copy and all your backups, and of course I know it is backed up in a number of places, plus you have it saved on the Internet. :)
Last edited by Steven Aus on Mar 28 2018, 21:39, edited 1 time in total.

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Mar 28 2018, 21:43

Haha yeah the code from the last update is all online, but I should probably get the rest of it committed and pushed there as well. Especially now that I have all of the H4 Resource Editor code that needs to get saved online as well.

I do plan on doing some more work for the H4MG now that I have a little more time, but I'd like to get things further along and to a good state with the H4 Resource Editor before switching back. The H4MG, though unfinished, is still in a relatively good spot and has a lot of utility already.

In a few months I should have a LOT of extra time and will likely devote it to these, and other, projects :D

User avatar
Karmakeld
CH Staff
CH Staff
Posts: 1087
Joined: 12 Nov 2011

Re: H4ResourceEditor

Postby Karmakeld » Mar 29 2018, 9:18

Man, I can hardly remember which features the H4MG is still lacking, besides the RMG feature.
Nice of Steven to revive the topic, but for now, being a bit selfish here, I think you should focus on the Resource Editor. This is where community focus is currently strongest, with the modding possibilities finally beginning to expand. In my optic, it's basically the stepping stone for future projects as well as the continuation of existing ones.
I'm silent in seven languages - and I got all my familys fear.

Everytime you throw dirt, you loose a little ground

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Mar 29 2018, 15:49

Haha yeah, don't worry I agree. I won't pick up the H4MG again until we are able to create new objects from scratch, which is actually looking pretty good right now.

On the thread on the Heroes Community forum I wrote this last:

"Hmm, so I un-commented out my code for reading in the image data, without actually making any changes (I made some very minor changes that shouldn't have affected anything), and I'm able to completely read in the objects I've been testing with.. Maybe I was trying to open objects that Namerutan hadn't finished working on yet?

Well, I'll go ahead and start working on getting the image data into the Java image constructs and continue testing other objects and see where it goes:D"

So, it seems I will be able to move onto getting the image data, at least from the several objects I have been testing with, into Java constructs and work on getting them displayed.

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Apr 2 2018, 19:55

I am able to display an ugly image of adventure objects. Should be ugly because I'm not yet applying the alpha data, which is up next for me to work on!

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Apr 9 2018, 21:13

So it seems that the ugly picture was due to me not converting the pixel index to an unsigned byte.. After fixing that, we have the following:

Image

I'm also now parsing the alpha channel but I need to get a better grasp on what to do with it.

I also realized that I can use the pixel index to determine whether a particular pixel should be fully transparent, since if the image has transparency then the first index of the color palette is the transparent one (index == 0).

I'm doing some slight reorganizing of my overlay which actually draws the images on the screen so that I can set up drawing animations or non-animations, but things are coming along :D

User avatar
Karmakeld
CH Staff
CH Staff
Posts: 1087
Joined: 12 Nov 2011

Re: H4ResourceEditor

Postby Karmakeld » Apr 11 2018, 12:55

Really I can't be the only one who's cheerful...? :|
I'm silent in seven languages - and I got all my familys fear.

Everytime you throw dirt, you loose a little ground

User avatar
Pol
Admin
Admin
Posts: 8812
Joined: 29 Nov 2005
Location: IN SOMNIS VERITAS
Contact:

Re: H4ResourceEditor

Postby Pol » Apr 11 2018, 15:01

I'm too. :butterfly:
"We made it!"
The Archives | Collection of H3&WoG files | Older albeit still useful | CH Downloads
PC Specs: A10-7850K, FM2A88X+K, 16GB-1600, SSD-MLC-G3, 1TB-HDD-G3, MAYA44, SP10 500W Be Quiet

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Apr 11 2018, 18:34

Currently doing a little reading on blending pixels so I can properly display the images and work on showing animations. Not really necessary for actual modding, so if I find it's taking me too long for the amount of progress I make, I will probably move onto other things, such as work to lineup the base image with the passability and entrance info and display the flag location.

I'll have to play around with that to determine the pixel width and height of the grid squares, as well as figure out exactly how it is determined where the grid is placed on the image (or vice versa).

Steven Aus
Demon
Demon
Posts: 324
Joined: 08 Feb 2006
Location: Australia

Re: H4ResourceEditor

Postby Steven Aus » Apr 14 2018, 2:28

All The Best. Thanks for Your Free Will Creation Of Happiness, Joy, Abundance and Love. :yes: :tsup: :hug:

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Apr 16 2018, 18:19

Just a small update: I've had to look elsewhere for displaying the animations because there seems to be a bit more work / optimization for me to do with my libraries before my code can be fast enough, so I've done some research for creating and displaying gifs.

I have the code for creating a gif in place and I'm in the process of actually using the code and then displaying the result.

User avatar
Pol
Admin
Admin
Posts: 8812
Joined: 29 Nov 2005
Location: IN SOMNIS VERITAS
Contact:

Re: H4ResourceEditor

Postby Pol » Apr 16 2018, 18:53

I'm starting to be a little curious, what was the catch here..?
"We made it!"
The Archives | Collection of H3&WoG files | Older albeit still useful | CH Downloads
PC Specs: A10-7850K, FM2A88X+K, 16GB-1600, SSD-MLC-G3, 1TB-HDD-G3, MAYA44, SP10 500W Be Quiet

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Apr 16 2018, 19:03

Pol wrote:I'm starting to be a little curious, what was the catch here..?


The way my code works is it uses Java's BufferedImage class to draw images onto each other. Sometimes the drawImage methods can take some time, especially if the image contains transparency. I haven't looked into the timing, so I'm not sure where there is a slow down (if there is one), I'm just guessing that is the problem based on what I see when I increase the speed of the animation.

With 1 second or .5 seconds between animation frames, everything looks fine, just slow. When I speed things up, the animation appears to be missing frames so maybe my timer gets ahead of what is being drawn, which means my code for drawing may be a little slow, or something else weird is happening.

Either way, there is code out there for creating gif files and then I just stick the gif on a JLabel and they should be displayed.

Basically, I tried to write my own code to display an animated gif, but it might be too slow and need some work, so I did some research for built-in Java libraries that could do this :D Is that what you were asking Pol?

User avatar
Pol
Admin
Admin
Posts: 8812
Joined: 29 Nov 2005
Location: IN SOMNIS VERITAS
Contact:

Re: H4ResourceEditor

Postby Pol » Apr 16 2018, 19:18

Yes. I was curious why you are not using libraries supplied with Java.

Now I'm thinking about previous Java volunteer, though he worked on h3 game & editor. Perhaps, I will re-call him later. Sigh, that's at least ten years back. Myself I'm Java illiterate.

Edit1
His name was insanewallaby
Last edited by Pol on Apr 16 2018, 19:36, edited 1 time in total.
"We made it!"
The Archives | Collection of H3&WoG files | Older albeit still useful | CH Downloads
PC Specs: A10-7850K, FM2A88X+K, 16GB-1600, SSD-MLC-G3, 1TB-HDD-G3, MAYA44, SP10 500W Be Quiet

User avatar
iLiVeInAbOx05
Equilibris Team
Equilibris Team
Posts: 556
Joined: 21 Jul 2014

Re: H4ResourceEditor

Postby iLiVeInAbOx05 » Apr 16 2018, 20:01

I didn't just go straight to built-in Java libraries because I already have libraries that I've written for overlaying various types of drawing on a single canvas, which are actually pretty good and very flexible. I can easily have multiple drawings overlaid on top of each other, and adding another is super simple. Each overlay is its own class and has to have certain methods, such as draw(). All I have to do is implement the draw method - for the most part - and then I'm all done.


Return to “Heroes I-IV”

Who is online

Users browsing this forum: Google [Bot] and 6 guests