Fix: King's Bounty Ice Dragon Bug

HiddenX

The Elder Spy
Staff Member
Original Sin Donor
Original Sin 2 Donor
Joined
October 18, 2006
Messages
20,092
Location
Germany
Fix: King's Bounty - Warriors of the North Bugs

Ice Dragon Bug

In the Verlon Wasteland at the Dragon Castle:

Killing the Ice Dragon defender -> Crash to the desktop.

Search in this folder:

\SteamApps\common\King's Bounty - Warriors of the North\sessions\addon\ses.kfs

Open the ses.kfs file with an unzip-program,
and edit the script unit_features_ondamage.lua with notepad.


The error is in line 390 :
just comment it out with - - (without blank)

Code:
function features_ondamage_dragon_ice(wnm, ts, dead)
if dead then
local ahc = Attack.act_after_hit_cell(0)
local initsize = Attack.act_initsize(ahc)
local manaval, rageval = Game.CurLocRand(initsize, 5*initsize), 0
local dmgts = 1 + Game.Random(0, 10)/100
spawn_energetic_attack(ahc, dmgts, manaval, rageval)

if initsize == 1 then
Attack.log(dmgts, "add_blog_ice_dragon_death_1", "name"," "..blog_side_unit(0), "special", mana_count)
else
- - Attack.log(dmgts, "add_blog_ice_dragon_death_1", "name"," "..blog_side_unit(0), "special", mana_count)
end
end
return true
end
 
Last edited:
Joined
Oct 18, 2006
Messages
20,092
Location
Germany
Odin's Banner Quest:

You cannot give Odin's Banner to the viking king on the Riftlands to complete the quest?

a) open the console (SHIFT ^)
b) type item addon2_quest_odin_banner
 
Joined
Oct 18, 2006
Messages
20,092
Location
Germany
Plundered Stylist Quest:

You cannot return the stolen goods to the stylist?
(Quest book says you have 5/5 but the inventory says you have 2)

a) open the console (SHIFT ^)
b) type item cloth_pack
c) repeat b) until you have 5 in the inventory
 
Joined
Oct 18, 2006
Messages
20,092
Location
Germany
About ice dragon crash bug… I've written about it here:
http://www.rpgwatch.com/forums/showthread.php?p=1061169382
The game will crash in every single fight where you kill an ice dragon stack.

Since noone reacted on it, I assumed noone is playing the game or noone got to that part yet. I didn't write more details, but since now you're mentioning it, I will.

1. The best packer to use for editing the script is 7-zip. Why? Because it will repack (zip) the edited file back in the container file when you close the notepad after editing any file in the container. It's freeware and is available here:
http://www.7-zip.org/

2. When you open the sctipt unit_features_ondamage in Notepad you don't need to activate/check lines number, just use search and find the line with "dragon_ice" and you'll get to start of the sequence you need to change.

3. The displayed fixed code in the first post is not complete. You need to put doubledash in both lines as the initsize is not always the same, so it'll still crash somewhere if you put only "on ignore" the part with initsize different than 1! The correct if-then code must look like this:
Code:
if initsize == 1 then
-[COLOR="darkslategray"]-[/COLOR] Attack.log(dmgts, "add_blog_ice_dragon_death_1", "name"," "..blog_side_unit(0), "special", mana_count)
else
-[COLOR="DarkSlateGray"]-[/COLOR] Attack.log(dmgts, "add_blog_ice_dragon_death_1", "name"," "..blog_side_unit(0), "special", mana_count)
Based on this it means that complete removal of the if-the-else block would solve the problem. Since I'm not into modding of KB games, I'm not sure if the engine calculates lines of script files to make sure those are not corrupted. So declaring that commands are just comments what we're doing here is a better choice as we're keeping the original code intact but are telling the game to do nothing when ice dragon stack dies.

Two other mentioned bugs (banner, stylist) didn't happen in my game, I've solved those quests without any problems.
 
Last edited:
Joined
Apr 12, 2009
Messages
23,459
I'm playing KB only an hour or two a day, so I haven't seen them. I only just recently moved into the island with the magic shield whatever the name is, haven't seen an ice dragon yet.
 
Joined
Sep 23, 2008
Messages
5,645
Location
Tardis
@wolfing

If you have started the game after the last patch, there's is a good chance that the above fixes are already included. Unfortunately old saves are not fixed.

PS.: I have finshed the game (after 100 hours):
 

Attachments

  • KB_HiddenX.jpg
    KB_HiddenX.jpg
    133.4 KB · Views: 34
Joined
Oct 18, 2006
Messages
20,092
Location
Germany
@wolfing

If you have started the game after the last patch, there's is a good chance that the above fixes are already included. Unfortunately old saves are not fixed.

PS.: I have finshed the game (after 100 hours):

I have a problem that stop me playing it for a week on the 2nd island during the battle the game crashes and go on the desktop specially when the battle has sklads ..what should i do?? .. has it a special way to fix or just install the patch?
please if there is a patch to fix it give me its link please.thanks.
 
Joined
Dec 3, 2012
Messages
2
I have a problem that stop me playing it for a week on the 2nd island during the battle the game crashes and go on the desktop specially when the battle has sklads ..what should i do?? .. has it a special way to fix or just install the patch?
please if there is a patch to fix it give me its link please.thanks.
First patch fixed that, Steam should do it automatically. Without Steam, I don't know where you can find it, maybe in the official site.
 
Joined
Sep 23, 2008
Messages
5,645
Location
Tardis
The site went down before I've edited…

The only unpatched copies out there are:
- where after the installation PC (Steam) was disconnected from internet to this day
- pirated copies

The best answer on the matter is to contact the site/store where the game was bought. If it wasn't bought but pirated - do suffer the consequences.
 
Joined
Apr 12, 2009
Messages
23,459
Back
Top Bottom