Opened 9 months ago

Last modified 6 months ago

#12182 new defect

ULTIMA8: Trolls do not drop items

Reported by: bliznik Owned by:
Priority: normal Component: Engine: Ultima
Version: Keywords: Troll money coins drop
Cc: Game: Ultima VIII: Pagan


In the original Ultima VIII, Trolls were one of the only Foes that would drop items. Gems, Money, sometimes useless items like Poison potions. But in the ScummVM version, I haven't been able to find a single troll that drops an item. Their corpses don't seem to have anything on them.

This is a bit problematic since Troll-killing is pretty much the only way to grind money in the game, which is necessary to purchase Mythran's most powerful spellbook.

Attachments (11)

Screenshot_1.jpg (134.9 KB ) - added by bliznik 9 months ago.
Screenshot_2.jpg (134.4 KB ) - added by bliznik 9 months ago.
Screenshot_3.jpg (146.4 KB ) - added by bliznik 9 months ago.
Screenshot_4.jpg (196.9 KB ) - added by bliznik 9 months ago.
scummvm-2021-04-30.png (134.6 KB ) - added by mduggan 7 months ago.
Screenshot_1.2.jpg (126.5 KB ) - added by bliznik 7 months ago.
Screenshot_2.2.jpg (191.1 KB ) - added by bliznik 7 months ago.
Screenshot_3.2.jpg (142.9 KB ) - added by bliznik 7 months ago.
Screenshot_4.2.jpg (89.3 KB ) - added by bliznik 7 months ago.
Screenshot_5.jpg (78.9 KB ) - added by bliznik 7 months ago.
Screenshot_6.jpg (176.9 KB ) - added by bliznik 7 months ago.

Download all attachments as: .zip

Change History (23)

comment:1 by bliznik, 9 months ago seems like the loot tables for all Foes have been broken. The only items that Trolls seem to drop are daggers, none of the Skeletons drop items (before they resurrect), and none of the Changelinks drop obsidian coins either

comment:2 by mduggan, 9 months ago

Thanks for the report. Looks like I'll have to dive into the code a bit deeper to check the original behavior.

Update: actually the config should already drop coins for trolls, so something about that is broken. Will need to debug that bit.

Last edited 9 months ago by mduggan (previous) (diff)

by bliznik, 9 months ago

Attachment: Screenshot_1.jpg added

by bliznik, 9 months ago

Attachment: Screenshot_2.jpg added

by bliznik, 9 months ago

Attachment: Screenshot_3.jpg added

by bliznik, 9 months ago

Attachment: Screenshot_4.jpg added

comment:3 by bliznik, 9 months ago

OK, here are a few screenshots of what the loot looks like when the game is run in DOSBox

comment:4 by sev-, 8 months ago

Priority: highnormal
Summary: Ultima VIII - Trolls do not drop itemsULTIMA8: Trolls do not drop items

by mduggan, 7 months ago

Attachment: scummvm-2021-04-30.png added

comment:5 by mduggan, 7 months ago

Playing with the latest version, it seems to work fine for me locally now - I uploaded a screenshot of the drop I got. This is with no particular changes to ultima.dat or any other code changes. Could you check again with the latest version?

by bliznik, 7 months ago

Attachment: Screenshot_1.2.jpg added

by bliznik, 7 months ago

Attachment: Screenshot_2.2.jpg added

by bliznik, 7 months ago

Attachment: Screenshot_3.2.jpg added

by bliznik, 7 months ago

Attachment: Screenshot_4.2.jpg added

comment:6 by bliznik, 7 months ago

Hmm, I just installed version "windows-x86-64-master-ac1d5352", loaded an old save, killed 4 trolls, and only one of them had items (a single mace).

However, it's possible that it's something with my savegame that is corrupted.

Later this weekend, I'll start a new game and will grab slayer to do some Troll killing and will report back!

by bliznik, 7 months ago

Attachment: Screenshot_5.jpg added

by bliznik, 7 months ago

Attachment: Screenshot_6.jpg added

comment:7 by bliznik, 7 months ago

Hmm, I just started a new game using this version: 2.3.0git15849-gac1d5352be (Apr 30 2021 05:40:01), grabbed Slayer, killed a troll (the one in West of Tenebrae, inside the arena where you fall down to enter), and still no items.

I completely removed Ultima VIII from Scumm, moved all savegames to another directory (so I could start a fresh game instead of only being able to load a previous one), and added Ultima VIII (this is the GOG version, found in my install directory of D:\Games\GOG Games\Ultima 8\ENGLISH)

I also tried to run ScummVM using the console, but didn't see any suspicious error messages.

comment:8 by mduggan, 7 months ago

Thanks for taking the time to test in such detail. That's strange, but clearly something is still broken.

I suspect that the treasure info is not getting loaded correctly, but not sure why. To check that it's loading it at all, could you try this?

  • Find ultima.dat in the scummvm install dir
  • It's just a zip file, so rename to .zip and open it
  • Modify the ultima8/u8monsters.ini file to be invalid - just add a junk line like asdf to the start of the file.
  • Rename back to ultima.dat and open scummvm

When you open Ultima8, scummvm should throw an error when it's trying to load the monsters file. If it's not, then the problem is that the file is not getting loaded at all, which would probably explain the problem.

Could you also check whether you have an extrapath defined in your scummvm ini file? Some notes on that are here:

The dat file needs to be in that search list somewhere.

For reference, I'm using MacOS so there could easily be something wrong with the loading code that only happens on Windows.

Last edited 7 months ago by mduggan (previous) (diff)

comment:9 by bliznik, 7 months ago

OK, I think we're getting somewhere! This is definitely a PC vs. Mac thing.

First, you're correct, ScummVM on a PC (I'm running Windows 10, 64-bit) does not load the ultima.dat file correctly. I found this out when I was trying to edit the ultima.dat file for something I wanted to do in Ultima IV, and I needed to use "Extra Path" to get it to work. (You can see my work here:

Second, it does not seem like the "extrapath" variable works as expected. It's not in the scummvm.ini file, and when I try to add it to the file, I get an error message "Could not located engine data ultima.dat"

Third, even using the "Extra Path" hack, there is something funny with how ScummVM uses the u8monsters.ini file on the PC. It does a few things correctly:

  • It uses the u8monsters.ini file, since if I add "asdf" I will get an error when I try to start Ultima 8
  • It uses parts of the u8monsters.ini file correctly, since I was able to set a Troll's HP to 1 by setting hp_min=1 and hp_max=1
  • But it didn't seem to use the "treasure" field correctly. It works fine if I delete everything except for "treasure=type=weapon" but things like "treasure=type=obsidian mult=30-75" or "type=oilflask mult=1-8" don't work.

So...a few things not working here.

comment:10 by bliznik, 7 months ago

I did a few more experiments with ultima.dat, and it looks like I might just be using a different zipping algorithm than ScummVM, since my zip file is 16,821 bytes while the original ultima.dat file is 16,863 bytes. So it's possible that ScummVM just can't unzip my ultima.dat file.

Well, in either case, the other issues with u8monsters.ini still seem to persist, namely that the loot table doesn't seem to work properly with "type=" when there is a space. I can change the loot table for the troll to read "treasure=type=meat" or "treasure=type=meat;type=weapon" without a problem, but "treasure=type=firegem mult=1-8;type=meat;type=weapon" is broken.

comment:11 by mduggan, 7 months ago

Thanks for all the extra info. With help from @OMGPizzaGuy we think we narrowed down the difference to a random number diff between MacOS and Windows, and I think it should be fixed in 61d9789.

comment:12 by bliznik, 6 months ago

Were you able to get to this with help from @OMGPizzaGuy? I just loaded a save with the latest daily build and it still seems like this is an issue in Windows 10 6(4-bit)?

Note: See TracTickets for help on using tickets.