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 ]
HOMM1: info forum | HOMM2: info forum | HOMM3: info mods forum | HOMM4: info CTG forum | HOMM5: info mods forum | MMH6: wiki forum | MMH7: wiki forum
Heroes Community > MapHaven Guild > Thread: [H5] How to test maps easier
Thread: [H5] How to test maps easier
Asheera
Asheera


Honorable
Undefeatable Hero
Elite Assassin
posted December 12, 2008 02:10 PM

[H5] How to test maps easier

Hi, I wrote this short guide because I've seen a lot of players doing some tricks with the map script to remove the Fog of War for testing, when it is so easy if you do a little effort once to activate the Console. The console also opens the path to other cheats as well (such as teleporting your hero anywhere, anytime) which are excellent for testing a map



The most important thing for easy testing map-related stuff is the Console. To activate it, do the following:

Go to the directory where you installed Heroes 5. Then enter the profiles folder, and open the autoexec_a2.cfg file with Notepad (if you don't have Tribes of the East, open autoexec.cfg)

Add the following line at the beginning of this file:
setvar dev_console_password = schwinge-des-todes

Now go to your My Documents directory (Documents and Settings\user name\My Documents), enter the My Games\Heroes of Might and Magic V - Tribes of the East\profiles folder (without TotE you should enter My Games\Heroes of Might and Magic V\profiles). Now enter the folder with your profile name in the game. Open input_a2.cfg (input.cfg without TotE) with Notepad.

Add the following lines at the beginning of this file:
bind show_console '`'
bind fog_of_war 'CTRL' + 'SHIFT' + 'F'
bind adventure_teleport 'CTRL' + 'SHIFT' + 'T'


Now you activated the console! (you never have to do this again - unless you change your game profile)


To open the Console in game, press the key right to the left of your 1 key (the ` or ~ key). To hide the console, press it again when it is opened.

With the console you can do lots of interesting stuff. First, it shows you errors and some other things (like what AI does each turn). Second, you can execute all functions available in the scripts as well. However, you need to type @ at the start of the line if you want to execute scripting functions.

Here are some examples:

WRONG:
print(GetCurrentPlayer())
@print(@GetCurrentPlayer())

CORRECT:
@print(GetCurrentPlayer())


With the Console you can also cheat. There are many useful cheats described in the .pdf dedicated to cheats (in the same folder where there are the editor documentation ones). However, there are also two more very important cheats (VERY useful when testing a map) that I'll explain below.

In order to cheat, you need to type enable_cheats in the Console after you start the Map. Then you can enter any cheats you like (from that .pdf) and they will work. As for the other 2 very important cheats, here's how to do them and what they do:

Try holding your CTRL and SHIFT keys while pressing F, and you should deactivate the Fog of War on the map.
And for teleporting your hero: select the hero you want to teleport, move the cursor on the place you want him/her to be teleported and then press the T key while holding the CTRL and SHIFT keys. Note that you can't teleport your hero someplace where (s)he can't, e.g. in an unwalkable tile or near an enemy creature or hero.

Those CTRL+SHIFT+R or CTRL+SHIFT+T were actually defined in that file you customized for the cheats, check it again and you'll see the resemblance.



No more headaches, you can use the variety of cheats to test almost anything without having to modify the map temporarily for tests. You can even type scripting commands in the Console to test how they work!
____________

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


Hired Hero
posted January 23, 2009 03:49 PM

Thanks, thats a great Idea

 Send Instant Message | Send E-Mail | View Profile | Quote Reply | Link
Jump To: « Prev Thread . . . Next Thread »
Post New Poll    Post New Topic    Post New Reply

Page compiled in 0.0239 seconds