The spellbook doesn't work

Post here if you need help getting started with Daggerfall Unity or just want to clarify a potential bug. Questions about playing or modding classic Daggerfall should be posted to Community.
PavkataBrat
Posts: 5
Joined: Sat Jun 06, 2020 6:33 pm

The spellbook doesn't work

Post by PavkataBrat »

Whenever I open the spell book I cannot do anything at all - none of the buttons work, nor does the mouse buttons (the cursor is still there). The entire interface is completely uninteractive apart from "E", which closes the spellbook and "S" for sorting spells. I can't select a spell at all and I can't use any magic because of that. I installed some mods, but I tried disabling them all and the bug still occured in exactly the same manner.
This is my first try at daggerfall unity and I remember using spells on my modern machine in the base game, so I guess it ought to be a problem with daggerfall unity specifically.
I searched a bit and the only thing I found is a 2011 gamesas.com basegame thread with a similar problem and no resolution, so apparently it is a bug that might have happened in the basegame as well? Can it be a problem with my machine or maybe I somehow installed daggerfall unity in some wrong way? I'm baffled this isn't a thing that happens to other people.

User avatar
Ralzar
Posts: 2211
Joined: Mon Oct 07, 2019 4:11 pm
Location: Norway

Re: The spellbook doesn't work

Post by Ralzar »

Check that you are using the latest version of DFU and mods.
If everything is up to date, post a savegame.

User avatar
pango
Posts: 3359
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: The spellbook doesn't work

Post by pango »

Maybe your character doesn't know any spell?
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
Ralzar
Posts: 2211
Joined: Mon Oct 07, 2019 4:11 pm
Location: Norway

Re: The spellbook doesn't work

Post by Ralzar »

pango wrote: Sat Jun 06, 2020 8:59 pm Maybe your character doesn't know any spell?
True. If the character was started with RP&R:Items and has no magic schools in primary or major, the character will not start with any spells.

viewtopic.php?f=27&t=3534

PavkataBrat
Posts: 5
Joined: Sat Jun 06, 2020 6:33 pm

Re: The spellbook doesn't work

Post by PavkataBrat »

pango wrote: Sat Jun 06, 2020 8:59 pm Maybe your character doesn't know any spell?
I do certainly know spells and in fact I see them - I just can't click on them
Ralzar wrote: Sat Jun 06, 2020 8:28 pm Check that you are using the latest version of DFU and mods.
If everything is up to date, post a savegame.
I'm pretty sure everything ought to be up to date, I installed everything rather recently - just a day ago.
I started a new test character without mods enabled and everything worked, but when I used the save with mods but disabled them the bug persisted so it must be something with the mods I'm doing wrong.
There is the save with the bug (I hope that's how I post saves anyway)
Attachments
SAVE0.rar
(115.45 KiB) Downloaded 112 times

User avatar
Interkarma
Posts: 7247
Joined: Sun Mar 22, 2015 1:51 am

Re: The spellbook doesn't work

Post by Interkarma »

Thank you for providing save. Your issue here is that one of the spells is invalid (your Jumping spell specifically) as it has no effects. This throws an exception internally making the UI unresponsive.

This isn't a standard starting spell, I can only assume a mod put it there without referencing the correct Effect key, resulting in a broken spell.

I've added some exception handling in spell management so spellbook isn't busted by this kind of broken spell in future versions. To fix issue in your game before next release, you'll need to make the following edit.

First locate the broken Jumping spell entry in SaveData.txt (search for "jumping" until you find the below block of data. Then delete the entire block of data including the enclosing braces { and }, then save file.

Code: Select all

{
	"Version": 1,
	"BundleType": "Spell",
	"TargetType": "CasterOnly",
	"ElementType": "Magic",
	"Name": "Jumping",
	"IconIndex": 1,
	"Icon": {
	    "key": null,
	    "index": 1
	},
	"MinimumCastingCost": false,
	"NoCastingAnims": false,
	"Tag": null,
	"Effects": null,
	"LegacyEffects": null
},
For your convenience, I've attached your SaveData.txt with just that edit for you. Replace your version with this one and spellbook should work OK again.

Alternatively, you could re-create character without mods. Any mods that change character creation have the potential to do things that might break the base game.

All the best!
Attachments
SaveData.zip
(24.66 KiB) Downloaded 126 times

PavkataBrat
Posts: 5
Joined: Sat Jun 06, 2020 6:33 pm

Re: The spellbook doesn't work

Post by PavkataBrat »

Thank you very much for the timely and elaborate answer!
I tried the fix and it works fine with no unforseen issues.

User avatar
Ralzar
Posts: 2211
Joined: Mon Oct 07, 2019 4:11 pm
Location: Norway

Re: The spellbook doesn't work

Post by Ralzar »

Interkarma wrote: Sun Jun 07, 2020 2:05 am This isn't a standard starting spell, I can only assume a mod put it there without referencing the correct Effect key, resulting in a broken spell.
This is Hazelnuts "Roleplay & Realism: Items" mod. We cobbled together a set of starter spells that you are assigend based on which magic schools you have selected.

Another player had the same thing and posted it in the RP&R:Items forum thread. Hazelnut spotted the same thing there but couldn't figure out how it happened.

Looking at the mods code, Jumping is a classic spell, so it should just work if it is actually working in the DFU code?

https://github.com/ajrb/dfunity-mods/bl ... od.cs#L758

User avatar
Interkarma
Posts: 7247
Joined: Sun Mar 22, 2015 1:51 am

Re: The spellbook doesn't work

Post by Interkarma »

Ralzar, this should work fine. Jumping is implemented and can be purchased and created normally using Mages Guild services. I also tested adding the spell using the method shown and Jumping was added in a functioning state.

Maybe the game data used by PavkataBrat is unpatched or SPELLS.STD is otherwise in bad shape. That's where the data comes from ultimately, so we're at the mercy of good game data here.

PavkataBrat, do you know your source of game data set for Daggerfall Unity? Was it the Bethesda download version, Anthology version, or original CD version at all? Or did you use a pre-patched install like DaggerfallSetup or DaggerfallGameFiles zip?

PavkataBrat
Posts: 5
Joined: Sat Jun 06, 2020 6:33 pm

Re: The spellbook doesn't work

Post by PavkataBrat »

I'm pretty sure it was the official bethesda version.

Locked