The Doors of Oblivion "Summon x" spells do not work - A report on testing

Learn about OpenMW mod compatibility, check for problematic mods, discuss issues, and give us feedback about your experience with modded OpenMW.
Post Reply
valin777
Posts: 2
Joined: 23 Apr 2018, 06:00

The Doors of Oblivion "Summon x" spells do not work - A report on testing

Post by valin777 » 23 Apr 2018, 06:53

The Doors of Oblivion - https://www.nexusmods.com/morrowind/mods/44398

This is my first post on this forum, I, however, have been following the project for many years and using it for the past few. This is a report on a compatibility problem with the Doors of Oblivion mod (linked above) and using it in openMW. I would note before I begin that this mod has been tested and works in vanilla with no issues.

So here is the bug/issue - okay so the issue is with all summon spells in the mod..... (EX. summon morphoid) before buying the spell the spell name is "summon morphoid" the effect in game on the spell is "bound gloves" and when the spell is used instead of doing either of those things it just activates the animation and then does nothing.

Thanks to @Thunderforge on the OpenMW discord for helping me work through this issue. here is what we did and worked through to try and figure out what was going on and fix it -

we took a look at the scripts for the summons themselves and determined there was an extra endif at the end of the script that we removed in case it was causing issues and then we tested and found the issue still persisted Here is an example of the script if that helps at all -

Code: Select all

begin bs_morphoid_script

Short DoOnceA

if ( DoOnceA == 0 )
    if ( player->getspelleffects, "bs_summon_morphoid" == 1 )
        playsound "conjuration area"
        Placeatpc "bs_morphoid01_31_sum" 1 128 0
          set DoOnceA to 1
     endif
endif

if ( DoOnceA == 1 )
     Set DoOnceA to 0
endif

end bs_morphoid_script
I will use the morphoid summon as my example throughout this report for reference sake... be aware this is an issue with ALL summons in this mod.

From here we confirmed the object_id was valid by checking in World->Objects
Then we tested in the game using the command ( Placeatpc "bs_morphoid01_31_sum" ) 1 128 0 into the console and that did in fact work and summoned the creature, meaning the problem was not with the summon line of code there.
we tested the playsound "conjuration area" to make sure no issues existed there either and that was fine as well

the last thing we did is look up the spell in the OpneCS (Mechanics -> spells) "edit the record" and upon inspecting the effect bound gloves was on it.
so tried applying a new effect to the spell, however, the summon morphoid spell is not listed within the list of magic effects (neither is any of the other summons for that matter) so we opened the magic effects menu and confirmed it (or any of the other ones) is not there. upon trying to add it we discovered a bug where "add record" does not show up when right clicking the magic effects window (this bug has been submitted). This is where we stopped and decided to post about it here in hopes someone may be able to help out with this issue further beyond the idea of adding the magic effect (as that's not possible until the bug is fixed).

Thak you to anyone who see's fit to help in advance. this is an interesting problem to solve I think. But I do believe now it is possible to fix. and if we do somehow fix it together I will upload a fixed version of the mod for use with openMW

User avatar
Jemolk
Posts: 103
Joined: 20 Mar 2017, 02:12
Location: Sadrith Mora

Re: The Doors of Oblivion "Summon x" spells do not work - A report on testing

Post by Jemolk » 24 Apr 2018, 07:20

I'm pretty sure this is to do with zero duration spells for magic effects that have a duration. You see, since magic effects are hardcoded in vanilla, you need to script additional effects by using getspelleffects and an existing effect. However, OpenMW doesn't register a spell effect for getspelleffects for any more than a single frame with 0 duration effects, so the script will fail to register that the effect is there and the spell will fail. This was fixed for effects that by their very nature have no duration like interventions, mark and recall. For spell effects that can have durations, however, it still doesn't work. The easy way around this as a user is simply to change the duration of the effect to 1 second. Having it be bound whatever might be a problem, though, unequipping your gear and not reequipping it, since OpenMW hasn't gotten that one figured out yet, so I'd suggest also changing the effect to Turn Undead if possible.

valin777
Posts: 2
Joined: 23 Apr 2018, 06:00

Re: The Doors of Oblivion "Summon x" spells do not work - A report on testing

Post by valin777 » 24 Apr 2018, 23:03

Okay so, an update for you. I did as you said and it worked it does indeed summon a morpoid now.... however its a bit broken it summons like 20 morphoids all over the place. I changed the like to 1 and made it turn undead. so any ideas as to why it would summon a bunch of them instead of just 1?

User avatar
akortunov
Posts: 392
Joined: 13 Mar 2017, 13:49
Location: Samara, Russian Federation
Github profile: https://github.com/akortunov

Re: The Doors of Oblivion "Summon x" spells do not work - A report on testing

Post by akortunov » 25 Apr 2018, 06:25

valin777 wrote:
24 Apr 2018, 23:03
so any ideas as to why it would summon a bunch of them instead of just 1?
If you use script from above, you do not use DoOnce properly (you set it to 0 immediately after you set it to 1).
You will get a new summon in every frame, so if your spell has 1 sec duration, you will get 20-60 summons.

User avatar
Jemolk
Posts: 103
Joined: 20 Mar 2017, 02:12
Location: Sadrith Mora

Re: The Doors of Oblivion "Summon x" spells do not work - A report on testing

Post by Jemolk » 25 Apr 2018, 09:25

akortunov wrote:
25 Apr 2018, 06:25
valin777 wrote:
24 Apr 2018, 23:03
so any ideas as to why it would summon a bunch of them instead of just 1?
If you use script from above, you do not use DoOnce properly (you set it to 0 immediately after you set it to 1).
You will get a new summon in every frame, so if your spell has 1 sec duration, you will get 20-60 summons.
Ouch. How would you suggest fixing that?

User avatar
akortunov
Posts: 392
Joined: 13 Mar 2017, 13:49
Location: Samara, Russian Federation
Github profile: https://github.com/akortunov

Re: The Doors of Oblivion "Summon x" spells do not work - A report on testing

Post by akortunov » 25 Apr 2018, 09:55

Jemolk wrote:
25 Apr 2018, 09:25
Ouch. How would you suggest fixing that?
You can set DoOnce to 0 in the beginning of script via some kind of timer (> 1 sec).
Of course, you should remove last "if" from script. Then you will get only one creature per cast.

User avatar
Jemolk
Posts: 103
Joined: 20 Mar 2017, 02:12
Location: Sadrith Mora

Re: The Doors of Oblivion "Summon x" spells do not work - A report on testing

Post by Jemolk » 25 Apr 2018, 18:36

akortunov wrote:
25 Apr 2018, 09:55
Jemolk wrote:
25 Apr 2018, 09:25
Ouch. How would you suggest fixing that?
You can set DoOnce to 0 in the beginning of script via some kind of timer (> 1 sec).
Of course, you should remove last "if" from script. Then you will get only one creature per cast.
Good to know! And yeah, the second "if" would definitely cause lots of problems when all scripts are constantly running.

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests