[H5 EDITOR] Troubleshooting topic

Maps and the art of mapmaking.
User avatar
Grumpy Old Wizard
Round Table Knight
Round Table Knight
Posts: 2205
Joined: 06 Jan 2006
Location: Tower Grump

Unread postby Grumpy Old Wizard » 03 Nov 2007, 22:50

You have 2 versions of the map because you have the one in the zipped file and the one you extracted to modify. Have you tried taking the original zipped up file out?

Alternately, remove the single Rise to Power map from the archive and insert the file you modified into the archive.

You could always rename the Rise to Power map that you modified so you would have both the original and modified version to chose from.

GOW
Frodo: "I wish the ring had never come to me. I wish none of this had happened."
Gandalf: "So do all who live to see such times but that is not for them to decide. All we have to decide is what to do with the time that is given to us."

User avatar
Metathron
Round Table Hero
Round Table Hero
Posts: 2704
Joined: 29 Jan 2006
Location: Somewhere deep in the Caribbean...
Contact:

Unread postby Metathron » 03 Nov 2007, 23:06

The problem is not that I have 2 files, it's that the modified one does not want to fully bend to my wishes. :)

I just wanted increased choke point armies so that the AI would not barge out of its area and let me explore my bit of land at leisure. I increased that successfully but when I wanted to play the map with either the dwarves or the barbarians, I could not choose a hero to match nor get one at the start of the game a.k.a. the same problem that occured with HoF if you wanted to play original HoMM V vanilla maps with the dwarves, you could not choose a dwarven hero.
Jesus saves, Allah forgives, Cthulhu thinks you'd make a nice sandwich.

User avatar
Grumpy Old Wizard
Round Table Knight
Round Table Knight
Posts: 2205
Joined: 06 Jan 2006
Location: Tower Grump

Unread postby Grumpy Old Wizard » 03 Nov 2007, 23:25

Metathron wrote:The problem is not that I have 2 files, it's that the modified one does not want to fully bend to my wishes. :)

I just wanted increased choke point armies so that the AI would not barge out of its area and let me explore my bit of land at leisure. I increased that successfully but when I wanted to play the map with either the dwarves or the barbarians, I could not choose a hero to match nor get one at the start of the game a.k.a. the same problem that occured with HoF if you wanted to play original HoMM V vanilla maps with the dwarves, you could not choose a dwarven hero.
Well, I haven't unzipped the files yet but have you tried

View --> Map Properties --> Heroes and checking all of the boxes and then unchecking any you don't want? Maybe also use the Reset button and check them again?

GOW
Frodo: "I wish the ring had never come to me. I wish none of this had happened."
Gandalf: "So do all who live to see such times but that is not for them to decide. All we have to decide is what to do with the time that is given to us."

User avatar
Metathron
Round Table Hero
Round Table Hero
Posts: 2704
Joined: 29 Jan 2006
Location: Somewhere deep in the Caribbean...
Contact:

Unread postby Metathron » 04 Nov 2007, 01:09

View --> Map Properties --> Heroes and checking all of the boxes and then unchecking any you don't want? Maybe also use the Reset button and check them again?
That did the trick. So simple, too! 8|

Thank you, kind sir.
Jesus saves, Allah forgives, Cthulhu thinks you'd make a nice sandwich.

King Imp
Swordsman
Swordsman
Posts: 570
Joined: 06 Jan 2006

Unread postby King Imp » 08 Nov 2007, 18:54

I have a couple of questions since asking on the official forums is like pulling teeth to get an answer.

1) Does anyone know if there is any way to shut off the Map Properties Tree box from opening every time you load a map?

This is really getting annoying because it makes it harder for maps to load up because it has to also load that as well. I've looked everywhere, but I can't find any way to tell the editor not to start with it open every time.

2) Is there any way to change the properties of the new Outpost? I'm not talking about the properties when you place creatures inside it to guard. I'm talking about the type of Outpost it is.

I was hoping that it would automatically change based upon the type of terrain it was on, but unfortunately no matter where you place it, it still looks like you are fighting in a Haven siege on the grass. Would be nice if there was a way to change this since Nival obviously didn't think to either A) give us 8 different Outposts, or B) make it so it changed based upon the terrain.

User avatar
Grumpy Old Wizard
Round Table Knight
Round Table Knight
Posts: 2205
Joined: 06 Jan 2006
Location: Tower Grump

Unread postby Grumpy Old Wizard » 08 Nov 2007, 23:27

King Imp wrote: 1) Does anyone know if there is any way to shut off the Map Properties Tree box from opening every time you load a map?

This is really getting annoying because it makes it harder for maps to load up because it has to also load that as well. I've looked everywhere, but I can't find any way to tell the editor not to start with it open every time.
I don't know about this one.
King Imp wrote:I have a couple of questions since asking on the official forums is like pulling teeth to get an answer.

2) Is there any way to change the properties of the new Outpost? I'm not talking about the properties when you place creatures inside it to guard. I'm talking about the type of Outpost it is.

I was hoping that it would automatically change based upon the type of terrain it was on, but unfortunately no matter where you place it, it still looks like you are fighting in a Haven siege on the grass. Would be nice if there was a way to change this since Nival obviously didn't think to either A) give us 8 different Outposts, or B) make it so it changed based upon the terrain.
1) Click on the outpost to highlight it. Click on the Object Properties Tree Button.

2) Click on the "Shared" field. Click the "new" button. Type anything in the name field. Click OK. This creates a folder and a file that we will talk about below.

3) Click the "..." button. Now on the left hand side you see a folder that has the name of your map and the name of the dummy file you just created (that was needed to create the folder.)

4) If the MapObjects folder is not expanded, click on the "+" sign in front of it to expand it. You see a folder H5A2. Expand the folder if necessary. The file inside it is the outpost, "Fopost" Right-click on Fopost and choose "copy."

5) Go down to the folder that has the name of your map. Right-click on it and chose paste. Now right click on the dummy file above it and chose delete. It will still show as being there, but will disappear when we are done.

6) Now left click on the file you just copied, the one in the folder with the name of your map. This is the file that you will be altering in order to avoid changin all outposts in this map and in every map in your TOTE folder.

7) You will notice there are a number of things over to the right that make up the outpost. You can change the model to make it look like anything you want it to look like for example. If you change the model you may need to change the blocked tiles to make it accessable. You can alo change the messages to customize your new outpost, which is highly recommended.

8) Now click on "OK" at the bottom right hand corner of the window. If you don't see the button, drag the window up a little or contract it by putting your mouse at the top of the window, left clicking, and dragging down.

That dummy file you deleted will continue to show up (if you happen to take a peek) until you save and close the map file.

You can use this same method to altar many things in the game. Just make sure you create the dummy file that creates a new folder (as in step 2) and that you work with a file you copy to that new folder so you don't create a mod that affects all the maps in your game folder.

GOW
Frodo: "I wish the ring had never come to me. I wish none of this had happened."
Gandalf: "So do all who live to see such times but that is not for them to decide. All we have to decide is what to do with the time that is given to us."

King Imp
Swordsman
Swordsman
Posts: 570
Joined: 06 Jan 2006

Unread postby King Imp » 09 Nov 2007, 06:09

Grumpy Old Wizard wrote:
King Imp wrote:I have a couple of questions since asking on the official forums is like pulling teeth to get an answer.

2) Is there any way to change the properties of the new Outpost? I'm not talking about the properties when you place creatures inside it to guard. I'm talking about the type of Outpost it is.

I was hoping that it would automatically change based upon the type of terrain it was on, but unfortunately no matter where you place it, it still looks like you are fighting in a Haven siege on the grass. Would be nice if there was a way to change this since Nival obviously didn't think to either A) give us 8 different Outposts, or B) make it so it changed based upon the terrain.
1) Click on the outpost to highlight it. Click on the Object Properties Tree Button.

2) Click on the "Shared" field. Click the "new" button. Type anything in the name field. Click OK. This creates a folder and a file that we will talk about below.

3) Click the "..." button. Now on the left hand side you see a folder that has the name of your map and the name of the dummy file you just created (that was needed to create the folder.)

4) If the MapObjects folder is not expanded, click on the "+" sign in front of it to expand it. You see a folder H5A2. Expand the folder if necessary. The file inside it is the outpost, "Fopost" Right-click on Fopost and choose "copy."

5) Go down to the folder that has the name of your map. Right-click on it and chose paste. Now right click on the dummy file above it and chose delete. It will still show as being there, but will disappear when we are done.

6) Now left click on the file you just copied, the one in the folder with the name of your map. This is the file that you will be altering in order to avoid changin all outposts in this map and in every map in your TOTE folder.

7) You will notice there are a number of things over to the right that make up the outpost. You can change the model to make it look like anything you want it to look like for example. If you change the model you may need to change the blocked tiles to make it accessable. You can alo change the messages to customize your new outpost, which is highly recommended.

8) Now click on "OK" at the bottom right hand corner of the window. If you don't see the button, drag the window up a little or contract it by putting your mouse at the top of the window, left clicking, and dragging down.

That dummy file you deleted will continue to show up (if you happen to take a peek) until you save and close the map file.

You can use this same method to altar many things in the game. Just make sure you create the dummy file that creates a new folder (as in step 2) and that you work with a file you copy to that new folder so you don't create a mod that affects all the maps in your game folder.

GOW


Holy Christ! Was it really that hard for Nival to just give us Outposts already set up? I'm sorry, but it is truly ridiculous that they expect us to go through all of this and risk messing something up just to get a simple result.

User avatar
Grumpy Old Wizard
Round Table Knight
Round Table Knight
Posts: 2205
Joined: 06 Jan 2006
Location: Tower Grump

Unread postby Grumpy Old Wizard » 09 Nov 2007, 06:55

It is not quite as complicated as it seems. I just tried to spell out the steps in detail. Once you change a couple of buildings you'll be doing it easily.

You can do things like make dwellings for wolves (which I did in Shadow Dreams using the cyclops stockpile) or make a town that looks like a light house (which is also in Shadow Dreams as a wizard's tower.) The editor is really pretty powerful but, yeah, it could be a lot more friendly.

GOW
Frodo: "I wish the ring had never come to me. I wish none of this had happened."
Gandalf: "So do all who live to see such times but that is not for them to decide. All we have to decide is what to do with the time that is given to us."

User avatar
rdeford
Assassin
Assassin
Posts: 299
Joined: 17 Apr 2007
Location: Sequim, USA
Contact:

Unread postby rdeford » 17 Nov 2007, 15:37

Thanks GOW. It is good to see the steps in this process documented with such clarity. Each time I have created a custom object, I have just floundered around until I got it done. Due to the time lag between my map creations, I've had to reinvent the process several times.

Oh, and I agree that all objects in the map editor should automatically mutate to reflect the terrain they are placed on. It is a break in the player's immersion experience to have the battle arena not be correct for the terrain or an object's appearance match its surroundings. I believe that, given the current state of the editor's power and the limited property set for map objects, it is impossible to completely eliminate this problem, no matter how many hours of time the mapmaker spends. However, I must add that it is possible to create great maps in HOMM5 that give a player experience that goes beyond anything possible in previous HOMM games, it just takes a lot of work. Good thing it's fun, eh?
rdeford, Mage Of Soquim

“Forgiving and being forgiven, loving and being loved,
living and letting live, is the simple basis for it all."

Ernest Holmes 1984

King Imp
Swordsman
Swordsman
Posts: 570
Joined: 06 Jan 2006

Unread postby King Imp » 18 Nov 2007, 08:02

Okay, I really need your help on this one guys. I have no clue where I would even look to fix this.

I recently went in to edit a bunch of maps I downloaded from here, but after saving and then playing a map, I am getting this problem on all maps.

Image

Image


The message box that used to be small is now huge like you can see. I have no idea what the hell changed these settings or how to revert them back to normal.


For as powerful as this editor is, I really find it pathetic and annoying that they didn't safeguard against stuff like this. Editing a map should not change the settings for all maps.

User avatar
Pitsu
Round Table Hero
Round Table Hero
Posts: 1848
Joined: 22 Nov 2005

Unread postby Pitsu » 18 Nov 2007, 11:56

King Imp, one of the maps that you downloaded must contain "large message boxes" mod. To get the messageboxes back to tiny ones remove the map from your H5 directory.
Avatar image credit: N Lüdimois

User avatar
Mnc
Leprechaun
Leprechaun
Posts: 21
Joined: 15 Oct 2007

allied teams

Unread postby Mnc » 19 Nov 2007, 11:36

hey there, im making allied map and i want it that way so you cant swap team color flag like, you got red + blue against orange + green, but you can swap red + green if you want, and i dont want that :disagree: coz the map placed things suffer and its akward.

what should i do? i tryed many tricks already but no result :(
Making maps is Art and true beuty lies in them..

User avatar
rdeford
Assassin
Assassin
Posts: 299
Joined: 17 Apr 2007
Location: Sequim, USA
Contact:

Unread postby rdeford » 19 Nov 2007, 13:07

@ Mnc

I just created a test multi-player map from scratch that works as you wish. Here is what I did:
  • 1. Placed 4 towns on the map.

    2. Selected a town, pressed the Space Bar, and set the player-owner to player_1.

    3. Repeated for each of the other towns to give each town a unique player-owner (player_2, player_3, or player_4).

    4. Viewed map properties, selected the Teams tab, set 2 teams, then set player_1 and player_2 on team-1, and then player_3 and player_4 on team-2.

    5. Viewed map properties, selected the Players tab, and set player_1 to have a main town, be human playable only, and set the Race to match the town.

    6. Repeated for player_2, player_3, and player_4.
The map worked as you desire. I could not change the flag for any player, and I could not change the membership for either team.

I have had a problem with the editor not saving the teams settings correctly. When this problem happens, I open the map with the editor a second time and set up the teams correctly. It seems to save the settings correctly the second time. So, if your map does not work as you desire, open it up again and redo your settings if necessary.
rdeford, Mage Of Soquim

“Forgiving and being forgiven, loving and being loved,
living and letting live, is the simple basis for it all."

Ernest Holmes 1984

User avatar
Mnc
Leprechaun
Leprechaun
Posts: 21
Joined: 15 Oct 2007

Unread postby Mnc » 19 Nov 2007, 14:17

rdeford wrote:
  • 1. Placed 4 towns on the map.

    2. Selected a town, pressed the Space Bar, and set the player-owner to player_1.

    3. Repeated for each of the other towns to give each town a unique player-owner (player_2, player_3, or player_4).

    4. Viewed map properties, selected the Teams tab, set 2 teams, then set player_1 and player_2 on team-1, and then player_3 and player_4 on team-2.

    5. Viewed map properties, selected the Players tab, and set player_1 to have a main town, be human playable only, and set the Race to match the town.

    6. Repeated for player_2, player_3, and player_4.
That what i thought i done already, i better try look if something is out of order here, but since you got your test map working thats one good news for me, maybe I success too

<working>

edit: hurrey i got it working, i changed at map properties tree each players flag color speficly and took off from each players setting "CanBeDisabled" its working now as i wanted, thanks rdeford must had been something very little i didnt notice, i also had on few player settings "NO_TYPE_TOWN" but i switched it to random_town. ;)
Making maps is Art and true beuty lies in them..

King Imp
Swordsman
Swordsman
Posts: 570
Joined: 06 Jan 2006

Unread postby King Imp » 19 Nov 2007, 23:22

Pitsu wrote:King Imp, one of the maps that you downloaded must contain "large message boxes" mod. To get the messageboxes back to tiny ones remove the map from your H5 directory.


Yup, that fixed it. Thanks Pitsu.

I'm still annoyed though that the editor has the ability to mess up other maps simply from being in the directory. That and it is so annoying when it decides to change maps by itself from no teams to teams and vice versa.

User avatar
Pitsu
Round Table Hero
Round Table Hero
Posts: 1848
Joined: 22 Nov 2005

Unread postby Pitsu » 13 Jan 2008, 20:02

Objectives that are not MANUAL type can have several types of rewards. Is it possible to have several of them simultaneously? For example experience and resource? I could not get it working in testing, but the editor guide hints otherwise and i do not see why not.
Avatar image credit: N Lüdimois

Franzy
War Dancer
War Dancer
Posts: 362
Joined: 07 Sep 2007
Location: Moscow, Russia
Contact:

Unread postby Franzy » 14 Jan 2008, 18:52

I'm making a series of demo maps that contain various interesting scripting examples. The first one is called "Watchers". Monsters on this map constantly turn to face the hero. Note that the angle is accurate, not with a step of 90 or 45 degrees. This is to show that it's possible to survive without any mathematical functions like sin, cos, exp or, like in this case, without arctan.

The map is here: http://dreamforge.by.ru/files/WatchersDemo.rar (10 kb)

User avatar
rdeford
Assassin
Assassin
Posts: 299
Joined: 17 Apr 2007
Location: Sequim, USA
Contact:

Unread postby rdeford » 14 Jan 2008, 22:15

@ Franzy,

I am totally impressed! This is mighty fine scripting. I wish the comments were in English, but the code is a so logically organized that I think I could use it without being able to read the comments. Thanks for the inspiring example.
rdeford, Mage Of Soquim

“Forgiving and being forgiven, loving and being loved,
living and letting live, is the simple basis for it all."

Ernest Holmes 1984

User avatar
rdeford
Assassin
Assassin
Posts: 299
Joined: 17 Apr 2007
Location: Sequim, USA
Contact:

Unread postby rdeford » 14 Jan 2008, 23:25

Pitsu wrote:Objectives that are not MANUAL type can have several types of rewards. Is it possible to have several of them simultaneously? For example experience and resource? I could not get it working in testing, but the editor guide hints otherwise and i do not see why not.
I couldn't get it to work by setting the objective parameters. But, using the script, I was able to get the desired effect by adding this function:

Code: Select all

-- objective type = AWARD_EXPERIENCE, Experience parameter = 1000
-- function grants an additional reward of crystal resource when objective is completed
function objGiftTest()
	if GetObjectiveState("multRewardTest", PLAYER_1) == OBJECTIVE_COMPLETED then
		local qty = GetPlayerResource(PLAYER_1, CRYSTAL);
		SetPlayerResource(PLAYER_1, CRYSTAL, qty + 30);
	end;
end;
  Trigger(OBJECTIVE_STATE_CHANGE_TRIGGER, "multRewardTest", "objGiftTest");
Of course, the award given by the function could be expanded to include just about any type of multiple reward desired.
rdeford, Mage Of Soquim

“Forgiving and being forgiven, loving and being loved,
living and letting live, is the simple basis for it all."

Ernest Holmes 1984

Franzy
War Dancer
War Dancer
Posts: 362
Joined: 07 Sep 2007
Location: Moscow, Russia
Contact:

Unread postby Franzy » 15 Jan 2008, 00:57

Well those comments just describe the idea of how to compute angle without having any arc-function :) If you are interested, here is what I did (get prepared for a load of maths):

Let's say we have a radius-vector from the monster to the hero. It has two components: dx and dy. We know that tan(alpha) = dy/dx (alpha is the angle we need). Unfortunately, HOMM5 script language does not know any math functions except for square root. That's why one has to use series decompositions.
I used a series decomposition of arctan:
arctan(x) = x - x^3/3 + x^5/5 - x^7/7 ...
The trouble is this series converges only if -1<x<1, and it converges really slow when x is close to 1 or -1.
I came to the following solution: I simply turn the radius-vector for such an angle beta that it would fall into the sector (-pi/6,pi/6) by multiplying it on a rotation matrix T=[cos(beta),-sin(beta); sin(beta),cos(beta)]. Of course I remeber the angle beta (it's called "addangle" in the script) to add it later. Why I used sector (-pi/6,pi/6) though (-pi/4, pi/4) would seem a more logical choice? Because of the slow convergence I mentioned earlier. This series converges quite fast in this sector, you only need 4-5 members of the series to achieve a precision of 5-6 digits.

After I compute angle (in radians) and add angle beta, I simply translate it into degrees (cause homm5 function require angles in degrees, not radians). Then I add another 90 degrees, cause 0 degrees for Nival means facing south, while all humanity believes that 0 means facing east :)

That's all. Other parts of the script are quite conventional - cycling thru monsters and turning them every n time segments...


Return to “Mapmaking Guild”

Who is online

Users browsing this forum: No registered users and 0 guests