Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > King's Bounty > King's Bounty: The Legend > Mods

Mods Everything about mods

Reply
 
Thread Tools Display Modes
  #1  
Old 01-27-2013, 05:37 PM
MattCaspermeyer MattCaspermeyer is offline
Approved Member
 
Join Date: Aug 2010
Posts: 553
Exclamation Critical Update V2013-01-27

***EDIT***

I've found a critical error with this version. If you started a new game with this version and want to marry Neoka, there is a strong possibility that the game will crash because of an error in the unit list when marrying her.

The error is that I specified "druids" instead of "druid" in the unit shop list and so it is looking for DRUIDS.ATOM. So the fix (provided below) is to copy DRUID.ATOM to DRUIDS.ATOM and put it into the mods folder. This is what is included in the ZIP file.

You can then marry Neoka, but don't buy the DRUIDS.ATOM units (their picture will be blank). This is the only way I can fix this problem since the unit shop data is in the save game file. You can continue your game after this (this is exactly what I've done) with Neoka and everything should be okay.

If you restart your game with the newer release, this problem is fixed.

I'm hoping that there are no more of these crashing type errors, but I'll do my best to review the changes I made to the *.LOC files and look for errors that might cause a crash during certain events.

***EDIT***

Okay I've found the problem and fixed it.

I want to apologize for releasing the mod in that state, I guess I got in too much of a hurry to release it last night.

Okay, the error was I had incorrectly implemented a couple of the Griffin Egg possibilities in ISLAND_1.EMBRYOS.LOC. Those errors have been fixed!

I also added one more change that I had forgotten to implement and that was to give the Necromancer Dwarf a chance to sell Skeleton Graves and Vampire Coffins.

Here is the detailed list of changes:

Version: Beta 2013-01-27 - ***CRITICAL UPDATE***
  • *.LOC
    • ISLAND_1_EMBRYOS.LOC (Western Islands) - ***CRASH TO DESKTOP*** fixed error of Griffin Eggs improperly implemented (thanks to Sir Whiskers for pointing this out!)
    • KORDAR_2.EMRYOS.LOC (Kordar)
      • Now has a 50% chance to sell Skeleton Graves (30:60)
      • Now has a 25% chance to sell Vampire Coffins (10:25)
  • *.LUA
    • SPECIAL_ATTACKS.LUA
      • ***BUG*** Fixed duration being string in special_bless_attack (thanks Windows 8!)
Short list for a change!

Thanks again to Sir Whiskers for promptly listing the problem!

I've removed the update since it includes a crashing problem, but provide a temporary fix here:
Attached Files
File Type: zip fix_neoka_crash.zip (2.1 KB, 2 views)

Last edited by MattCaspermeyer; 02-10-2013 at 08:02 AM. Reason: Removed Link Due to New Update, but provide fix for Neoka Crash
Reply With Quote
  #2  
Old 01-27-2013, 09:49 PM
Sir Whiskers Sir Whiskers is offline
Approved Member
 
Join Date: Dec 2008
Posts: 149
Default

Quote:
Originally Posted by MattCaspermeyer View Post
Okay I've found the problem and fixed it.
Yep, the mod works now. Thanks.

I'm not sure the creature containers are working as intended. I modified the hero.txt file to add some to my start and none showed any variability (no twins, no different results). To further test, I tried:
1) after finding/buying several in Greenwort
2) after traveling to a new area on the first island

But the results didn't change.

Thorn Seed = Thorn Hunter (or Royal Thorn, if using multiple)
Dragonfly Egg = Fire Dragonfly
Spider Egg = Venomous Spider
Snake Egg = Snake
Coffin = Skeleton
Carved Coffin = Vampire
Reply With Quote
  #3  
Old 01-27-2013, 11:18 PM
MattCaspermeyer MattCaspermeyer is offline
Approved Member
 
Join Date: Aug 2010
Posts: 553
Lightbulb Try this...

Quote:
Originally Posted by Sir Whiskers View Post
Yep, the mod works now. Thanks.
Thank goodness!

Quote:
Originally Posted by Sir Whiskers View Post
I'm not sure the creature containers are working as intended. I modified the hero.txt file to add some to my start and none showed any variability (no twins, no different results). To further test, I tried:
1) after finding/buying several in Greenwort
2) after traveling to a new area on the first island

But the results didn't change.

Thorn Seed = Thorn Hunter (or Royal Thorn, if using multiple)
Dragonfly Egg = Fire Dragonfly
Spider Egg = Venomous Spider
Snake Egg = Snake
Coffin = Skeleton
Carved Coffin = Vampire
I've been getting variability, but can you do me a favor and add, say, 10 Spider Eggs and 10 Snake Eggs to your HERO.TXT and then start a new game and try to use them, but only 1 at a time and 1 after another.

So use only 1 egg at a time and let me know if it is the same every time.

I actually was using the code that they had setup for this, but there wasn't variability and so I changed it and it seemed like it was working, but I'm still using a part of the original code that doesn't quite seem totally random to me.

So try that, note that for twins the possibility is really low (3% for Dragons and 6% for Griffins).

/C\/C\
Reply With Quote
  #4  
Old 01-28-2013, 10:52 AM
Sir Whiskers Sir Whiskers is offline
Approved Member
 
Join Date: Dec 2008
Posts: 149
Default

Quote:
Originally Posted by MattCaspermeyer View Post
I've been getting variability, but can you do me a favor and add, say, 10 Spider Eggs and 10 Snake Eggs to your HERO.TXT and then start a new game and try to use them, but only 1 at a time and 1 after another.

So use only 1 egg at a time and let me know if it is the same every time.

I actually was using the code that they had setup for this, but there wasn't variability and so I changed it and it seemed like it was working, but I'm still using a part of the original code that doesn't quite seem totally random to me.

/C\/C\
I performed such testing in my first game and no variability/twins after using a couple hundred containers. However...

I started a new game and some of the containers gave different results (fire spiders, lake dragonflies). I started a third game, and again some containers gave different results (skeleton archers). But within a specific game, the results never varied.

So, it appears the random function is working fine when the game starts. I suspect it will also kick in whenever I find a container (not buy). That would match what I saw in AP/CW, where modifications to the Item_Monster file would not take until I found a container of the type I had modded. If that's the case, then I would guess that the random value is being saved in the game and not changing until certain trigger events.

I'll keep testing the containers at various points to see if they change within the same game and let you know.

Last edited by Sir Whiskers; 01-28-2013 at 10:56 AM.
Reply With Quote
  #5  
Old 01-28-2013, 03:34 PM
MattCaspermeyer MattCaspermeyer is offline
Approved Member
 
Join Date: Aug 2010
Posts: 553
Question Interesting...

Quote:
Originally Posted by Sir Whiskers View Post
I performed such testing in my first game and no variability/twins after using a couple hundred containers. However...
Right. You must either reacquire the container or restart.

Quote:
Originally Posted by Sir Whiskers View Post
I started a new game and some of the containers gave different results (fire spiders, lake dragonflies). I started a third game, and again some containers gave different results (skeleton archers). But within a specific game, the results never varied.
Hmmm... I've been experiencing different results here, but I was level 6 (unsure if that matters) after starting a new game with the new variants.

I used 22 Spider Eggs (1 at a time) and I was able to get each type of unit (although the percentages didn't appear to match the percentages that I have listed). I also got a pretty good split between Thorns and Thorn Warriors (biased towards Thorn Warriors) when I used 12 seeds individually. I only had 2 Skeleton Graves, but got one of each and 3 Vampire Coffins and 2 instances of Vampires and 1 of Ancient Vampires.

Quote:
Originally Posted by Sir Whiskers View Post
So, it appears the random function is working fine when the game starts. I suspect it will also kick in whenever I find a container (not buy). That would match what I saw in AP/CW, where modifications to the Item_Monster file would not take until I found a container of the type I had modded. If that's the case, then I would guess that the random value is being saved in the game and not changing until certain trigger events.
When I was testing initially in TL, buying the container reset the item's item parameter list and allowed the objuse_spawn_troop function to work on the new data therein. I'm not sure if they've changed this in AP/CW, but to me it shouldn't matter whether you pick one up or buy in TL.

Incidentally, if you don't restart a new game, and you use the item, the new item parameters will not show up when using the objuse_spawn_troop function. The item parameter data is only refreshed when reacquiring the item, hence why it doesn't work with a current save. Believe it or not, that function was already setup for random functions, but as you so astutely note it only changed with each new game (as they were using the Game.Mutate function which is a random function, but only for each game). There is another function, diap that is in LOGIC_HERO.LUA that is used for certain hero things and that's what objuse_spawn_troop is set up to use. The number I'm sending to diap is random (Game.Random( 1, total_prob)), but diap also uses Game.Mutate.

So therein may be the issue, I may try to use another of their built-in random selection functions as it seems that I need to work on this part of the code more.

Quote:
Originally Posted by Sir Whiskers View Post
I'll keep testing the containers at various points to see if they change within the same game and let you know.
Well that sounds great! I'll keep fiddling, too, and hopefully we'll get to the bottom of this!

/C\/C\
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 06:33 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.