Showing magic effect in the UI

Post » Tue Nov 20, 2012 12:09 pm

I'm making a mod that adds a magic effect with a "script" type.

It's working, but it isn't showing in the "Active magic effects" section.

So the question is how to make it visible in this section?

P.S. flag "Hide in UI" is unchecked.
User avatar
Bigze Stacks
 
Posts: 3309
Joined: Sun May 20, 2007 5:07 pm

Post » Tue Nov 20, 2012 12:35 am

Have the name and description fields for this magic effect got any text within them?

Posting a screen shot of your magic effect couldn't hurt.
User avatar
.X chantelle .x Smith
 
Posts: 3399
Joined: Thu Jun 15, 2006 6:25 pm

Post » Tue Nov 20, 2012 5:46 am

Yes, they have.
If you can tell me how to attach an image here (not via bbcode, because I don't know where to upload it), I'll surely post it.

For now I'll describe it in words.

So it has:

Spoiler
ID - CooldownEffect
name - Power's cooldown
effect archetype - script
casting type - fire and forget
delivery - self

menu display object - MagicHatMarker

description text - You need to wait before you can use the power again

it also has sounds, but they are not used

that's all, all the other fields are empty (set to default values)
User avatar
naomi
 
Posts: 3400
Joined: Tue Jul 11, 2006 2:58 pm

Post » Tue Nov 20, 2012 8:12 am

And this magic effect is used by a Spell?

How are you adding the spell to the player?
User avatar
flora
 
Posts: 3479
Joined: Fri Jun 23, 2006 1:48 am

Post » Tue Nov 20, 2012 9:23 am

Yes, it is added to a lesser power that has two effects - main power effect (which has 10 seconds duration) and this cooldown effect (which has 2 minutes duration).
User avatar
Sherry Speakman
 
Posts: 3487
Joined: Fri Oct 20, 2006 1:00 pm

Post » Tue Nov 20, 2012 5:32 am

How is this lesser power being added to the player? Or under which circumstances should they be affected by it?
User avatar
Alexis Acevedo
 
Posts: 3330
Joined: Sat Oct 27, 2007 8:58 pm

Post » Tue Nov 20, 2012 4:03 am

Do you have any conditions on each of the magic effects which might be interfering with each other.

I can't see any issue with what you have posted.

I use a similar cooldown system, but i use a seperate spell for the cooldown effect.This is cast via a script when the magic effect is applied. Using this method i have no issues with the CD effect showing up in the Active Magic Effects section.

If you wish to try this method, this is the script i use to cast the cooldown effect on the player
Spoiler

Scriptname GenericCooldownScript extends ActiveMagicEffectImport GameSpell Property CooldownSpell AutoEvent OnEffectStart (Actor akCaster, Actor akTarget)    CooldownSpell.Cast(GetPlayer())	    debug.notification("CD effect applied")EndEvent
User avatar
Kirsty Wood
 
Posts: 3461
Joined: Tue Aug 15, 2006 10:41 am

Post » Tue Nov 20, 2012 12:48 am

@Antares

Lesser power is being added to the player via script.


@heilghast

Thank you very much for the idea, I'll try it.
By the way, (just to be sure that the effect will show up in Active Magic Effects) how does your cooldown magic effect look? I mean, what effect archetype it has, associated items (if any), etc.
User avatar
ONLY ME!!!!
 
Posts: 3479
Joined: Tue Aug 28, 2007 12:16 pm

Post » Tue Nov 20, 2012 9:47 am

Would you care to post the script here?
User avatar
courtnay
 
Posts: 3412
Joined: Sun Nov 05, 2006 8:49 pm

Post » Tue Nov 20, 2012 12:00 am

As a precaution, I always add both markers, one in the magic effect and one in the spell. So far all my spells, including scripted abilities have been appearing in the UI.
User avatar
Ilona Neumann
 
Posts: 3308
Joined: Sat Aug 19, 2006 3:30 am

Post » Tue Nov 20, 2012 12:34 am

@Antares

It's one of the vanilla vampire's powers, so I think it isn't the script's problem (because I didn't touch it). Magic effect is working (you can't recast the power during cooldown effect), it just isn't showing up, and I would like to see the cooldown duration in seconds in Active Magic Effects section.

@Terra Nova

Do you mean "menu display object - MagicHatMarker" in effect's settings?

By the way, all the werewolf abilities that I've added via script are showing correclty, but this power's cooldown is not (haven't tested heilghast's method yet, because steam had updated my Skyrim and my mod requires Update.esm. I think I'll make a little mod that only adds the cooldown spell via script for testing).
User avatar
Strawberry
 
Posts: 3446
Joined: Thu Jul 05, 2007 11:08 am

Post » Tue Nov 20, 2012 12:53 am


@heilghast

Thank you very much for the idea, I'll try it.
By the way, (just to be sure that the effect will show up in Active Magic Effects) how does your cooldown magic effect look? I mean, what effect archetype it has, associated items (if any), etc.

This is how i have my effect set up
Spoiler

Effect Archetype - Script
Casting Type - Fire and Forget
Delivery - Self
Magic Skill -
Minimum Skill - 0
Assoc Item - NONE

FLAGS
Detrimental, FX Persist & No Area checked - I have detrimental checked, so it shows up in red in the active magic effects section. Not sure why i checked the other two.

Keywords
KYWD_ExhaustionCD_NECMAS (specific to this magic effect)

Visual Effects
All set to None

Sounds
All set to None

Magic Item Description
Exhaustion CD seconds

Papyrus Script
I have a script attached to this which is there just to display a message when the cooldown effect ends.
User avatar
Kat Ives
 
Posts: 3408
Joined: Tue Aug 28, 2007 2:11 pm

Post » Tue Nov 20, 2012 2:46 am

@Antares

It's one of the vanilla vampire's powers, so I think it isn't the script's problem (because I didn't touch it). Magic effect is working (you can't recast the power during cooldown effect), it just isn't showing up, and I would like to see the cooldown duration in seconds in Active Magic Effects section.

@Terra Nova

Do you mean "menu display object - MagicHatMarker" in effect's settings?

By the way, all the werewolf abilities that I've added via script are showing correclty, but this power's cooldown is not (haven't tested heilghast's method yet, because steam had updated my Skyrim and my mod requires Update.esm. I think I'll make a little mod that only adds the cooldown spell via script for testing).

Yes.

And I never been able to get cooldowns to show up(tried that long time ago). An idea I had that I never worked on was to try setting it as message displayed via script. Definitely try it. I'm almost positive it'll work.
User avatar
Jose ordaz
 
Posts: 3552
Joined: Mon Aug 27, 2007 10:14 pm

Post » Tue Nov 20, 2012 3:48 am

@heilghast
@Terra Nova

Thanks. I think my magic effect haven't showed up because it doesn't have an attached script.

By the way, does anybody know if there is a way to disable a lesser power until a cooldown effect is removed? I mean, when someone uses a power, it becomes gray colored and it can't be equipped and used until the next day.
User avatar
Ross
 
Posts: 3384
Joined: Thu Aug 10, 2006 7:22 pm

Post » Tue Nov 20, 2012 8:55 am


By the way, does anybody know if there is a way to disable a lesser power until a cooldown effect is removed? I mean, when someone uses a power, it becomes gray colored and it can't be equipped and used until the next day.

I have tried searching for the same method of implementing cooldowns on normal spells, but i suspect its something that can't be done within the CK.
User avatar
Ezekiel Macallister
 
Posts: 3493
Joined: Fri Jun 22, 2007 12:08 pm

Post » Tue Nov 20, 2012 7:04 am

Looks like its hardcoded, isn't it?
Maybe there is a papyrus command that can do such a thing?
User avatar
Sophie Louise Edge
 
Posts: 3461
Joined: Sat Oct 21, 2006 7:09 pm


Return to V - Skyrim