Jump to content

Detecting a Swing


Lethargio

Recommended Posts

Ok, I'm trying to accomplish something and I've thought of several different ways, which is possible/the best?

 

Trying to make a magic blast fly out when the player swings a weapon, it could also be when a plyer draws the weapon.

 

Method 1(pseudocode here people):

WhenPlayerSwings>PlayerCastSpell

 

Method 2:

PlayerSwings>GetObjectPlayerIsLookingAt>CauseMeshToFlyOutCreatingEffect>CastSpellOnObjectPlayerIsLookingAt

The Object is obviously a player or animal, not an inanimate object, although I wouldn't mind if it was

 

Method 3:

There would need to be an companion object traveling constaly with the player for him to cast the spell on

PlayerSwings>CastWideAreaSpellOnCompanionObject

 

What is the best way of doing this?

Will I have to use the Morrowind Enhanced Plugin?

What commands do I need to know to do this that aren't listed?

Is there like an OnAttack variable or something I can use to detect the player's swing?

Link to comment
Share on other sites

The only possibility for strike detection that I can immediately see is to set a value true whenever a weapon hit (or swing, if that's your intention) sound is recorded that originated from the PC -- that would involve seperating the weapons (or possibly even weapon types, which I don't think is entirely possible) used by NPCs and the PC in all possible scenarios.
Link to comment
Share on other sites

Archived

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

  • Recently Browsing   0 members

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