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 5 - Temple of Ashan > Thread: Heroes 5 Campaigns: Sylvan Walkthrough
Thread: Heroes 5 Campaigns: Sylvan Walkthrough This thread is 17 pages long: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 · «PREV / NEXT»
dale
dale


Known Hero
posted September 13, 2007 09:14 AM

Mission 5 problem:
I have done just about everything, but do not see how to end this mission.

I have destroyed six stacks of spectral dragons -- and turned the light on.

I have gotten the four dwarf artifacts, took them to the seer's tent and got a cut scene (but no phoenix).

I have taken every town, above and below ground.

Normal difficulty, my hero is level 33 with everything maxed out.

I am supposed to kill Nicolai for good -- but he is no where to be found.   In fact, blue no longer even gets a bar showing progress.


I did kill Nicolai a good while ago, before getting all the dragons.  Supposedly, he was supposed to respawn -- but I haven't seen him since.

Any ideas?   What happens if I open the console and force a win?
____________
Grey Beards of the world, Unite :-}}

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

Hero of Order
Part of the furniture
posted September 17, 2007 11:55 PM
Edited by Maurice at 00:04, 18 Sep 2007.

Seems the bug on mission one still exists in v1.5. I just played it through, and saw no Biara. I finally got bored and finished the mission through a console cheat (I didn't feel like replaying it). Then I decided to take a look at the script of that particular mission, to see what's up. This is what I found:

- Biara is supposed to spawn on different days, depending on difficulty:
Easy = 43 days
Normal = 39 days
Hard = 34 days
Heroic = 30 days
Once spawned, she will try and make a straight run for Damlad, the Sylvan town;
- Experience of Biara depends on the experience of Findan, at the time she's generated;
- Number of creatures she has depends on difficulty (as expected);
- Every week, there is a chance that an enemy Hero is spawned, the chance increases every day. Interesting bit of code that does this:
if GetDate(WEEK) > time and GetDate(DAY_OF_WEEK) > random(6) then ...
As such, it's possible to get an enemy Hero on day 7 of one week, and right away again on day 2 of the next week - just 2 days later;
- Interesting bit of info: Each enemy Hero can spawn only once, and each Border guard will only be attacked once (after an attack, the Border guard will be removed from the viable attack targets for the Red player - only Blue could then try to capture it). The enemy Heroes are only after the Border guards, they have no further specific targets;
- The cutscene with Findan and the infernal critters is played 2 days after Biara has been spawned;
- The check on whether to spawn Biara, and/or another enemy Hero is performed every new day.

From the script, I cannot see why it fails. It sets a few variables at the start (like the days at which Biara is supposed to spawn), so I guess it is possible that after loading a save game, the game actually forgets those values. If that happens, no enemy Heroes will spawn anymore. It will be interesting to examine this script a little further.

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


Honorable
Undefeatable Hero
of Gold Dragons
posted September 18, 2007 08:45 AM

Wow, it's kind of interesting to have these scripts uncovered. I'm not sure I get this line:

GetDate(WEEK) > time - what parameter is "time"?

And no, it's not obvious why Biara doesn't spawn, but if the counter for day # from beginning is reset at load, at least that would mess things up.
____________
What will happen now?

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

Hero of Order
Part of the furniture
posted September 18, 2007 10:17 AM
Edited by Maurice at 10:19, 18 Sep 2007.

Time is a parameter that is initially taken as 0. In the IF-statement that follows the GetDate command, "time" is increased by 1 each time it is executed. As such, an enemy Hero spawns only once every week, but within a particular week at a random day.

I did a testrun last night just before heading to bed, where I made a slight alteration to the script: whenever it would execute the "NEW_DAY" trigger, I had it print info on the variables to the console. However, in single map mode I didn't experience the problem - but in addition, I didn't get the starting bonus option there either.

I suspect that the bug is caused with the hard-coded stuff around the actual campaign, and not the script itself. Or at most the interaction of the hard-coded stuff and the script. I can't tell, but it's fishy anyway. When I have time, I'll also take a peek at the script of mission 3 (or 4? The one where you need to rescue the 2 other Heroes).

Actually it's quite funny to examine these scripts. Remember the third mission of Inferno, where a Shadow Dragon asks for 100 Elven Archers? By looking at the script I saw that if you bring more than 500, you will get the quest bonus and a Dragon Flame Tongue artifact on top of that.

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

Hero of Order
Part of the furniture
posted September 19, 2007 11:10 AM bonus applied.
Edited by Maurice at 11:14, 19 Sep 2007.

While looking at it some more, I found out that not only can you issue standard commands on the command line of the console (like @OpenCircleFog, etc ...), but you can also use a command like @print(<variable name> ) to have the game print the value of the variable to the console output. You can even do stuff like @print(GetDate(DAY)) to see the number of days since the game started. But more importantly, you can explicitely execute scripted functions.

In mission 1 of the Sylvan campaign, there is a function called "timer()". The script is set up in such a way to trigger that function every day: Trigger (NEW_DAY_TRIGGER,"timer()") (or something like that).

The timer function starts off as:
if GetDate(WEEK) > time and GetDate(DAY_OF_WEEK) > random(6) then
time = time + 1

(checks on which Hero to spawn and what object to attack)

Small caveat: the random(number) function randomly selects a value between 0 and one value below the number in brackets. As such, the random(6) call will randomly pick a number from 0, 1, 2, 3, 4 and 5. The value of 6 itself is excluded from the range. Weeks are counted starting from 1, and days of the week range from 1 to 7. As such, if no enemy hero has been spawned by day 6 of the week, then the chance that it spawns on day 6 is 100%.

I used the @print command to see the values of the starting variables - m (which is the number of days at which Biara spawns), n (which is the number of heroes that still need to spawn) and time (the number of the week); they were all properly initialised.

By printing them every day and just ending my turns, I noticed that the time variable is never increased. Conclusion: it never evaluates the if-statement that I detailed above, even though it *has* to pass through it by day 6. Further conclusion: the Trigger is never fired, once you load the game before it has at least triggered once. Why this happens, is totally unclear to me. However, if I manually triggered the timer() function (@timer() on the console) at day 6 or 7, the enemy Hero would spawn properly and time would be increased by 1. Still, the Trigger would not fire on later turns.

Three side notes:
- In the map object properties I finally noticed an entry "ReserveHeroes" for each player. PLAYER_2 (Teal) has the 5 Necromancer that the script spawns specified there, including their spells and abilities. When I saw that, I noticed that PLAYER_2 has Straker as one of those 5 Heroes (Straker is known as Orson ingame), while he starts off with Orson. Heroes are unique, so when the script selects Straker to spawn while PLAYER_2 still has him up and running from the start, the script generates an error (it mentions how it cannot spawn Straker), but then applies further scripted commands to the *existing* Straker: adding experience, adding creatures, issueing the attack command. Not sure if it is intended or an oversight that Straker is the starting Hero as well as one of the reinforcements.
- When checking the ReserveHeroes for PLAYER_2, I noticed that each of those Heroes was also set to owned by PLAYER_2, except one: Pelt (known as Vladimir). Pelt was still set to PLAYER_NONE. I am not sure if this matters; since it is in the reserve of PLAYER_2, once he gets deployed he is probably assigned to PLAYER_2 anyway. I didn't check enough (yet) to see him spawn.
- The fact that you can use the @-symbol to explicitely execute a scripted function could open a pandora's box in multiplayer games with selfmade maps, if it is possible to use the @-commands on the console there. Not sure if that possibility exists, as I don't play multiplayer.

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


Honorable
Undefeatable Hero
of Gold Dragons
posted September 19, 2007 01:01 PM

Wow ... I'm quite impressed Maurice, Nival should emply you as a bug-finder/troubleshooter to make the game run more smoothly.

I think it's very interesting to get insight into these scripts, and perhaps we will be able to use this knowledge to improve the game some way or the other.
____________
What will happen now?

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

Hero of Order
Part of the furniture
posted September 19, 2007 01:19 PM

Heh, I'm a software tester for a living ... but that's not for games, unfortunately. . Anyway, I haven't been done yet with script examinations, so I wonder what nice little trinkets can be found in there yet.

Yesterday I found out that in C1M3 (Isabel facing the first enemy Hero) there is a function in the script that is never executed during normal gameplay. However, if you open the console and type @vspomothize(), you will find you have 10000 of every resource. Well, the limit is 9999 on the non-gold resources, but that's a minor detail.

I guess that the function was inserted for map testing, but never cleared from the final product.

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


Famous Hero
the guy with the dragon golem
posted September 19, 2007 02:37 PM

I replayed the C5M1 mission recently, but never experienced that bug. Are you saying not even the Necro heroes spawn by themselves? Or is that just if you reload?

One strange thing about that mission is that there are 5 heroes to spawn, but according to that script only 4 of them will ever spawn.
The timer function compares GetDate(WEEK) to time, but GetDate(WEEK) can only return values from 1 to 4, which means once the time variable is reaches 4, no more heroes can spawn...
It could also be that the remaining garrision should be attacked by Biara, but it still doesn't explain why there are 5 necros to spawn

Anyway that's all nice stuff you discovered, interesting to read

About multiplayer scripting, at the moment this is not possible, but in the developer diary someone said it will be in ToE Probably not with the console, though... otherwise you could cheat there.

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

Hero of Order
Part of the furniture
posted September 19, 2007 03:49 PM
Edited by Maurice at 15:49, 19 Sep 2007.

The bug occurs when you save the game and reload, before the first enemy Hero has spawned. After the reload, the NEW_DAY_TRIGGER doesn't fire anymore. If you save after the first Hero has spawned, then you should be safe from this bug (at least, I think you are).

Regarding the GetDate(WEEK), I think it returns the actual week number since the start of the game, rather than the week in the month. I would need to look into it a bit more, but since you have a DAY and a DAY_OF_WEEK, I suspect there is something like a WEEK_OF_MONTH option as well, next to WEEK. As such, GetDate(WEEK) will return the value of 5 during the first week of the second month.

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


Famous Hero
the guy with the dragon golem
posted September 19, 2007 06:58 PM
Edited by dschingi at 18:59, 19 Sep 2007.

I just tested both. You're right about the trigger, it's gone after a load like you described, however I restarted the scenario a few times and a load did not lead to the bug everytime. Hard to tell why ...

GetDate(WEEK) does return the week of the current month, unlike GetDate(DAY) which returns the number of days in the whole game. Nival logic

Btw I noticed that in the console you can scroll up and down with the page up and page down keys... in case anyone didn't know

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


Honorable
Undefeatable Hero
of Gold Dragons
posted September 19, 2007 08:00 PM

Quote:
Btw I noticed that in the console you can scroll up and down with the page up and page down keys... in case anyone didn't know


*lol* That's helpful - didn't know that, last time I recorded events off the consol, I had to be really really quick to recognize all the things that happened during AI turns.
____________
What will happen now?

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

Hero of Order
Part of the furniture
posted September 19, 2007 09:19 PM

Lol! That was one of the first things I found out about the console .

Thanks for checking, so much for that idea.

Anyway, as far as I can tell, it's beyond the scope of the mere script alone. It's something hard-coded that somehow causes the script to (apparently only sometimes) disappear beyond the veils of mystery, never to be seen again.

That is one for Nival to crack, I guess.

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

Hero of Order
Part of the furniture
posted September 22, 2007 10:54 PM
Edited by Maurice at 23:04, 22 Sep 2007.

Well, I just finished the Sylvan Campaign and I did find a bunch of scripting bugs there. Let me start off by giving some initial variables:

towns={'town1','town2','town3','town4','town5','town6'}
respawns_x={37,84,41,160,95,26}
respawns_y={39,86,152,31,92,21}
respawns_z={GROUND,GROUND,GROUND,GROUND,UNDERGROUND,UNDERGROUND}

These are the 6 Necropoli, along with several arrays of coordinates, which are just outside these very Necropoli. When Nikolai is slain, but dawn hasn't broken yet and no Phoenix was there to shed some light on his death, he will respawn on one of these six locations - but more of that further down.

When he does respawn, he gets an initial number of troops. These troops depend on the difficulty level and are initialised as follows:

kolyan_army_normal={30,25,20,15}
kolyan_army_hard={50,40,30,25}
kolyan_army_heroic={70,55,40,35}

Only 4 numbers, but they indicate the amount to add of Tier 4 through 7. For some reason, they don't specify Tier 1, 2 and 3. Keep in mind, these are added on top of his starting units. Now, the code that respawns him, determines which of these to take:

function army()
if GetDifficulty()==DIFFICULTY_NORMAL then
give_creatures(kolyan_army_normal)
 else
   if GetDifficulty()==DIFFICULTY_HARD then
     give_creatures(kolyan_army_hard)
   else
     give_creatures(kolyan_army_heroic)
   end;
 end;
end;


Anyone with a bit of programming experience under his (or her) belt, can figure out what happens when the game finds out that GetDifficulty() results in DIFFICULTY_EASY ...

Anyway, you are supposed to defeat the Shadow Dragons, before The Great Night happens, after which Nikolai is virtually undefeatable. You are supposed to get a warning for this on the first day of the second month. Here's how they programmed that:

function day_check()
great_night_progress=great_night_progress+dragons_count()*diff
print ("zlo = ", great_night_progress);
power=great_night_progress/1008
print('power= ',power)
if power>1 then
 ownage()
 return
end;
if GetDate(MONTH) == 2 and GetDate(DAY) == 1 and GetDate(WEEK) == 1 then
 StartDialogScene('/DialogScenes/C5/M5/D1/DialogScene.xdb#xpointer(/DialogScene)');
end;
end


I've bold-ed the relevant part. This scene *never* plays, for one single reason: the GetDate(DAY) command takes the total number of days since the start of the game. The days in month 2 range from day 29 to day 56. The only time when GetDate(DAY) is equal to 1 is on the first day of the game, but then GetDate(MONTH) is equal to 1 as well. As such, the if-statement will never result in a "true", and thereby never play the scene. (Side note: the scene shows Findan sending off a scout to visit Zehir).

Then there's a bogus function, which could be cut down to a single line. It is the function that determines *where* Nikolai will respawn.

function check_place()
local fake_array={};a=6
for i,h in towns do
 if GetObjectOwner(towns[i ])==PLAYER_2 then
   fake_array[i ]=towns[i ]
 end
end
if a==0 then
 a=length(fake_array[i ])
end
b=random(a)+1
return respawns_x[b ],respawns_y[b ],respawns_z[b ]
end


Here you see the coordinates again, that I detailed above. The initial part seems to perform a check as to which Necropoli still belong to PLAYER_2 (Teal, the enemy). The array fake_array takes on the names of all towns still owned by PLAYER_2 -> towns owned by PLAYER_1 are not filled out; I guess the default array initialisation leaves it blank.

The next if-statement then evaluates the length of the array. I don't know what the functionality is. Is it to determine how many towns are still owned by PLAYER_2? In any case, the statement "if a==0 then ..." will never evaluate to "true", because a is initialised with a value of 6, and never changed.

Finally, the function concludes by picking a random number from 1 to 6, and then spawning Nikolai there. The entire procedure to see which towns are owned by PLAYER_2 is totally omitted for this last part. The only two really functional lines of code in this function are the final two: the random number and the return value.

I guess they tried to make it so that Nikolai would only spawn outside a Necropolis owned by PLAYER_2 and then realised that it was possible that Nikolai would die before dawn had broken or Phoenices had been acquired (necessiting a respawn of Nikolai) while PLAYER_1 could own all Necropoli at that point (making it impossible for Nikolai to respawn). It's sloppy, in any case.

Few interesting tid-bits about this scenario:
- All Portals and all of the 6 Shadow Dragon clusters are inaccessible to the AI. Since the enemy territory is cut up in three pieces, you don't have to worry about influence from one piece to another; you, the player, are the only one who is capable of using the teleporters;
- The game keeps track of the progress of The Great Night (see the day_check function above). As you can see, progress depends on the number of Shadow Dragon clusters still around on the map. Every day, this number (multiplied by the difficulty factor, which is always 1, except for Heroic) is added to the number of the previous days, until this reaches a total sum of 1008. For the careful observer, with 6 Shadow Dragon Clusters on the map, that equals 6 months (4 for Heroic, since the difficulty factor for Heroic is set to 1,5). If you kill them, the number added each day drops accordingly.

Example:
If you kill your first stack on the first day of the second month, you've had the full first month of 28 days with 6 clusters up. That equals 168 points, leaving you with just 840 until The Great Night completes. With just 5 clusters remaining, however, you have more time; each day only increments it then with just 5 points instead of 6. So, 840 / 5 = 168 days, or 6 months, from that moment onward. Suppose you manage to kill all but one stack on the last day of the first month, you're still down to 840, but with just 1 cluster remaining, you have 840 days left to complete the game. Once they're all gone, dawn has broken and The Great Night interrupted before it became full.

- Once The Great Night has fully progressed, Nikolai gains 666 Shadow Dragons, all Portals (and Shadow Dragon clusters and Artifact sites) become accessible to the enemy and Nikolai receives the command to hunt down Findan.

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


Famous Hero
the guy with the dragon golem
posted September 23, 2007 12:54 PM

That's indeed a little lousy programming, someone should remind the Nival crew that vodka is NOT an instrument that makes you build better heroes maps

The problem with GetDate(DAY) could actually be connected with the fact that there is also an ABSOLUTE_DAY value besides DAY. Both are the same though, so maybe DAY indicated the day of the current month before and they changed it...

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


Famous Hero
Imbued Ballista
posted September 29, 2007 11:34 PM

The great night is actually mentioned in the questlog somewhere, but you're given no idea how it works.

Another thing I found to be odd in this map: there is a Ring of Life in the south-eastern corner of the map, below the necropolis. Which is guarded by 600 (!) Wights(one stack usually being Wraiths in the battle). Whats up with that? Sure, it's a pretty useful artifact considering the low health on many Sylvan units, but I've gotten another one earlier from a much smaller Wight stack and a Ring of Speed guarded by one of the Spectal Dragon stacks. Just seems a bit of an overgrown stack for that one artifact (and some gold and chests).

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

Hero of Order
Part of the furniture
posted September 30, 2007 12:28 AM

No clue. I just checked the map, and it's set at exactly 600 Wights, which doesn't grow over time. The Ring is not random either, it's really placed there.

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

Tavern Dweller
posted October 25, 2007 07:18 PM

Wow, nival sure has a good sense of logic dont they? Thx for the scripting now people may know what bugs may occure, thx
____________

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

Tavern Dweller
posted November 09, 2007 04:07 PM

Can someone give me a save game ending this slyvan campain, im really stuck at third mission with the bug we all alredy know, i tryed EVERYTHING and just dont work, i really hate this faction now, i think its the worst campaing in the game, thanks.

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

Tavern Dweller
posted November 10, 2007 04:35 PM

Mission 1

Hey I have patch 1.6 and I have tried to beat mission 1 7-8 times and

either no Biara, or necro don't attack garrison, it is getting on my
nerves

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

Hero of Order
Part of the furniture
posted November 10, 2007 06:46 PM

Don't save the game until you've had at least one attack.

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

Page compiled in 0.0952 seconds