Jump to content

Can Someone help me with a script with Magic Effects


ZaZ

Recommended Posts

Posted

Hello 

I want to start an magic effect "cloaking"  when an animation event is called in my case its a killmove , 

and the magic effect should dispel once the  Kill move is done 

 

It seems easy enough , but I have no Idea of getting it done , also could use help in the spells if  I want to time them or add multiple effects

 

Cheers

Posted

What you want to do, doesn´t seem difficult though. I do know how to hook into the Killmove to trigger the event.

Spells are simple once you understood how they work. You have to start with the Magic Effect. This is what does stuff. The spell it the delivery method. You can attach a magic effect onto potions and shouts too. Like the magic effects is the bullet and the spell is a gun.
Once you made you effect you make a spell and attack you effect to it.
All attributes the spell shall have, like duration, area and so on, are defined in the magic effect. These are the mutiplied in the spell via the magnitude of the effect. If you only want to execute a script use the ¨script effect¨ in the magical effect. This only runs the script without anything else.

You can use the line:
 

MySpell.Cast(Game.GetPlayer(), Game.GetPlayer())

To cast the make the player cast the spell onto himself. This happens instantly without any animation or visible effect.
Any script effect spell doesn`t need to be removed since it only runs its script. To remove other spells eighter set the duration for as long as needed or use the line:
 

MySpell.Dispel()

Hope I could help you.

Posted

The basic of the Spell is:

The point is all the MagicEffect

 

Spell, potion, shout, Power, this are all "shape" to a single/group of Magic effect(s)

 

The basic are those that Guffel said, but eventually you could add also more complex script in the magic effect.

I don't know what are you willing exactly to do, but let me know if you need some script clarifications.

Posted

Actually , Its not a spell technically ...... , I want the Cloaking effect to start when the kill move is starting during combat  on auto and end the cloaking when the move is finished 

 

 

The short Teleports looks awkward when there is no effect  , I'm not sure if there is trailing effect in any the magical spells that would suit this kind , but I would go for anything that is suitable 

Thank you Guys for helping out , I dont require a spell I need an effect to trigger when the Kill move is called during combat 

 

Cheers and thank you

 

Posted

Ahnn... Got it (sorry, my english is limited).

 

You want a shader effect during the anim to make all more scenic.

 

Like a ghost effect for the character timed with the various action

 

For example:

A cycle trough white flash, a ghost effect, back to normal

 

 

Never done anything like that but I have a few ideas about:

 

1) You need to have access at the exact moment when the animation start.

 

I don't know what's your script infrastructure around the kill move, so I'll pretend that is the basic killmove system

 

I think that you could use the RegisterforAnimationEvent ( http://www.creationkit.com/RegisterForAnimationEvent_-_Form) to get the exact moment of start.

 

2)Then you'll need the exact timing of the animation (and this shouldn't be a problem for you)

 

I'll give you a little of structure:

Event OnAnimationEvent(ObjectReference akSource, string asEventName)
     If akSource == PlayerRef
        If asEventName == "KillMoveName"
            Utility.Wait(*time until first Teleport*)
            SpellScenicEffect.Cast(PlayerRef)    ;If the spell is TargetSelf there's no need of a target
            Utility.Wait(*time until second Teleport*)
            SpellScenicEffect.Cast(PlayerRef)
            ;and so On
        EndIf
    EndIf
EndEvent

You can eventually do something more elaborate, like a while cycle unlocked at various conditional, or other

 

3)The spell:

MAGICEFFECT

It's a very basic mgeff, where you need only to set the basic parameter. Cast and forgot, deliver self, etc etc. (and place it in a spell)

 

I'll focus only on 2 aspect:

Visual Effect (is the tab when you should set the actual visual effect that you want to do, in this example the white flash)

And Script:

If you want to make some chain timed effect: You put a second cast for another spell in the Event OnEffectStart(Actor akTarget, Actor akCaster), after an Utility.Wait (for the correct timing)

 

And so on for every ring of the chain..

 

When a Chain is done you could apply serval time with the previous script (point 2)

 

In this case You do a:

Cast 1 (Flash Effect)

  Inside this: Event OnEffectStart -> Wait -> Cast 2 (Ghostly shader)

 

 

So You'll have:

 

Start the Anim

    The OnAnimationEvent Start

    Wait for X seconds

    Cast the Flash Spell

        When the Flash start the event OnEffectStart fire

              Wait for X seconds

              Cast the Second Spell (ghost effect)

   The OnAnimationEvent is on the second wait

   Cast the Flash Spell

      When the Flash start the event OnEffectStart fire

              Wait for X seconds

             Cast the Second Spell (ghost effect)

 

And so on...

 

Note1: Remember to set the spell as neutral

Note2: You could eventually create your own arteffect for the magic effect (*.nif) so you could time it at the millisecond

Note3: Consider that (like all the scenic works) is consuming some resources, but this shouldn't be a problem due the fact that during the kill move the time goes in slowmotion...

 

 

Doing a new ArtEffect is highly suggested, because you could make ONE simply spell with all the effect perfectly timed without any Utilitywait

 

All the work above will be reduced to

Event OnAnimationEvent(ObjectReference akSource, string asEventName)
     If akSource == PlayerRef
        If asEventName == "KillMoveName"
            SpellScenicEffect.Cast(PlayerRef)    ;If the spell is TargetSelf there's no need of a target
        EndIf
    EndIf
EndEvent

No chain, no wait, perfect timing, One spell without script

 

 

 

Oh, and also, you'll need to set a sound effect adequate in the Mageff

In your case: the sound of the teleport and those from the stabbing

 

 

_____________

 

 

My opinion is to make a Specific ArtObject (merging the actual aviable) and put it in a specific spell with a specific sound registration

So a single cast equals all the visual/audio support fot the whole killmove with 0 wasting of resources

 

 

Probably I've been too verbose, tell me if I've bad explain something...

 

 

Edit: Consider that this is only teory and what I'll do in your situation. If there's a better way to do that I don't know.

 

p.s. Nice Anim ;)

Posted

That pretty much what I had in mind. But I didn't have the idea of making diffrent effects for every teleportation, very good!

Posted

That pretty much what I had in mind. But I didn't have the idea of making diffrent effects for every teleportation, very good!

What!? All the nonsense above have actually sense!?

Damn...

 

XD

Posted

Ahnn... Got it (sorry, my english is limited).

 

You want a shader effect during the anim to make all more scenic.

 

Like a ghost effect for the character timed with the various action

 

For example:

A cycle trough white flash, a ghost effect, back to normal

 

 

Never done anything like that but I have a few ideas about:

 

1) You need to have access at the exact moment when the animation start.

 

I don't know what's your script infrastructure around the kill move, so I'll pretend that is the basic killmove system

 

I think that you could use the RegisterforAnimationEvent ( http://www.creationkit.com/RegisterForAnimationEvent_-_Form) to get the exact moment of start.

 

2)Then you'll need the exact timing of the animation (and this shouldn't be a problem for you)

 

I'll give you a little of structure:

Event OnAnimationEvent(ObjectReference akSource, string asEventName)
     If akSource == PlayerRef
        If asEventName == "KillMoveName"
            Utility.Wait(*time until first Teleport*)
            SpellScenicEffect.Cast(PlayerRef)    ;If the spell is TargetSelf there's no need of a target
            Utility.Wait(*time until second Teleport*)
            SpellScenicEffect.Cast(PlayerRef)
            ;and so On
        EndIf
    EndIf
EndEvent

You can eventually do something more elaborate, like a while cycle unlocked at various conditional, or other

 

3)The spell:

MAGICEFFECT

It's a very basic mgeff, where you need only to set the basic parameter. Cast and forgot, deliver self, etc etc. (and place it in a spell)

 

I'll focus only on 2 aspect:

Visual Effect (is the tab when you should set the actual visual effect that you want to do, in this example the white flash)

And Script:

If you want to make some chain timed effect: You put a second cast for another spell in the Event OnEffectStart(Actor akTarget, Actor akCaster), after an Utility.Wait (for the correct timing)

 

And so on for every ring of the chain..

 

When a Chain is done you could apply serval time with the previous script (point 2)

 

In this case You do a:

Cast 1 (Flash Effect)

  Inside this: Event OnEffectStart -> Wait -> Cast 2 (Ghostly shader)

 

 

So You'll have:

 

Start the Anim

    The OnAnimationEvent Start

    Wait for X seconds

    Cast the Flash Spell

        When the Flash start the event OnEffectStart fire

              Wait for X seconds

              Cast the Second Spell (ghost effect)

   The OnAnimationEvent is on the second wait

   Cast the Flash Spell

      When the Flash start the event OnEffectStart fire

              Wait for X seconds

             Cast the Second Spell (ghost effect)

 

And so on...

 

Note1: Remember to set the spell as neutral

Note2: You could eventually create your own arteffect for the magic effect (*.nif) so you could time it at the millisecond

Note3: Consider that (like all the scenic works) is consuming some resources, but this shouldn't be a problem due the fact that during the kill move the time goes in slowmotion...

 

 

Doing a new ArtEffect is highly suggested, because you could make ONE simply spell with all the effect perfectly timed without any Utilitywait

 

All the work above will be reduced to

Event OnAnimationEvent(ObjectReference akSource, string asEventName)
     If akSource == PlayerRef
        If asEventName == "KillMoveName"
            SpellScenicEffect.Cast(PlayerRef)    ;If the spell is TargetSelf there's no need of a target
        EndIf
    EndIf
EndEvent

No chain, no wait, perfect timing, One spell without script

 

 

 

Oh, and also, you'll need to set a sound effect adequate in the Mageff

In your case: the sound of the teleport and those from the stabbing

 

 

_____________

 

 

My opinion is to make a Specific ArtObject (merging the actual aviable) and put it in a specific spell with a specific sound registration

So a single cast equals all the visual/audio support fot the whole killmove with 0 wasting of resources

 

 

Probably I've been too verbose, tell me if I've bad explain something...

 

 

Edit: Consider that this is only teory and what I'll do in your situation. If there's a better way to do that I don't know.

 

p.s. Nice Anim ;)

Thanks , that made sense a little 

 

The second option intrigues me more , Though Being somewhat an average Nifskope user , What are the values that need to be changed in the . NIf 

I know the the exact times of the Blink Strikes , Im not sure what needs to be altered

 

Cheers

Posted

Technically it should be the NiTextKeyExtraData in the Niconrollersequence that has the start and stop times , But will give have to give it a go soon , one way to find out

Posted

Sorry, Nifskope is out of my sphere of infulence, the first time that I open it  was like:

 

OMFG!!?? *Closed*

 

Wish you luck about, let me know ;)

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...