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 > Heroes 4 - Lands of Axeoth > Thread: Campaign Editor - Building conditions
Thread: Campaign Editor - Building conditions
TheUnknown
TheUnknown


Known Hero
posted May 13, 2016 05:53 AM

Campaign Editor - Building conditions

Hi all,

I was going trough the campaign editor and I was trying to disable the player to build the Order of Paladins, but I want him to be able to build Knight's Chapter. The problem is there is no condition to check if the Monastery or Barracks have been build. I can check if his army has Monks or Crusaders but that is not how I want to solve it.

So is there a way to achieve this? Can I check if a building has been built?

P.S. I also found out there is a way to solve this if I manage creature buildings from level 1 trough the script, but I still wonder if it's possible to avoid the hassle of scripting the first three levels.

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


Responsible
Supreme Hero
posted June 09, 2016 11:09 PM

Well you can build (give) buildings via scripts, but it's true that there's no real way to check if a building has been constructed. If you limit players access to e.g Monks, by not having any monk dwellings on the adventure map, and also knows that the player can't get access to e.g. Monks via skills like Charm or Diplomacy, checking for Monks presence could be a solution.
A final option is to check and set the players amount of resources at the start of each day and do a continuous check (in case of resources being spend or resource piles being collected), then if you know the exact cost of the building you wish to check for, you subtract the building costs (gold, wood, ore etc) from the players treasury (set by variables). If the subtraction matches the costs you've set up, you can conclude the building have been build. But this assumes that it doesn't matches the cost of other buildings. Somewhat complicated, but there's no easy way to to do such check, sadly.
Hope this was helpful.

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


Legendary Hero
President of MM Wiki
posted June 09, 2016 11:21 PM

I don't believe it is able in other Heroes installments, to do that. That'd require tampering with the game data - aka modding it.
____________
Come and visit the Might and Magic Wikia!

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


Known Hero
posted June 12, 2016 11:47 PM

Well I guess I should script the buildings from zero because it's very hard to determine if a building has been build. This way the map would end up asking too much questions (at least one for each building) and it might me too boring to develop a town in such a way for a player. Luckily on this map it's only one town so it shouldn't be too bad.

On the other hand it will be a new experience and some players might be willing to try and enjoy it.

I plan on banning the potion building, caravan, shipyard, the grail building and from the specific ones, the magic dampener, necromancy amplifier, battle academy, rainbow, seminary and university.

I plan on leaving the other buildings but I am not sure about the costs as some of them like the citadel and castle may be too expensive. I will most likely follow equilibris on that one.

If anyone has an advice on the buildings choice let me know
Thanks

 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.0191 seconds