Vampiric Grip without pulling the enemy?

Post » Tue Jan 01, 2013 11:24 am

Hey everyone, I'm looking to create a spell that does exactly what the title says.. I want to be able to pick up people from a distance and toss them around.. Sort of like a tractor beam without the pull.. I have no scripting experience or anything I've just been watching a few tutorial videos and trying to learn how I can do this. If anyone has any ideas or could possibly help me I would really appreciate it. :biggrin:
User avatar
Far'ed K.G.h.m
 
Posts: 3464
Joined: Sat Jul 14, 2007 11:03 pm

Post » Tue Jan 01, 2013 7:58 am

I have an idea, but I'm too tired to write the script for it right now. I can do it tomorrow if Verteiron hasn't beaten me to the punch by then lol.

Basically what you'll wind up doing is making a scripted spell with a healfakeprojectile on it. When it hits it simply fills an alias with the target. Then it spawns an XMarker type thing with a script on it (these can easily be made by rename-cloning the XMarker object and then attaching a script to it). The script on the xmarker is this:

Scriptname PCKP_Script_HomingTorch extends ObjectReference Actor Property PlayerREF autoSpell Property Grip autoReferenceAlias Property SpellTarget autoevent OnLoad()self.SetMotionType(self.Motion_Keyframed)    Movement()endEventevent OnTranslationAlmostComplete()    Grip.RemoteCast(self, PlayerREF, SpellTarget.GetReference())    Movement()endEventfunction Movement()		 self.TranslateTo(PlayerRef.GetPositionX() + (PlayerREF.GetDistance(SpellTarget.GetReference())*Math.sin(PlayerREF.GetAngleZ())), PlayerRef.GetPositionY() + (PlayerREF.GetDistance(SpellTarget.GetReference())*(Math.cos(PlayerREF.GetAngleZ()))), GetDistance(PlayerREF) * Math.cos(PlayerRef.GetAngleX()) , 0, 0, 0, GetDistance(PlayerREF), 1)endFunction

Now, I just kind of wrote that on the fly, but what I THINK it will do is move around the xmarker to wherever you're pointing, and every so often the xmarker will cast Vampiric grip on the actor, pulling it to the xmarker. Now there's some other stuff you'll have to do, like make sure that you can actually drop the actor once you stopcasting. But I don't feel like adding all that stuff in right now. Also the above script is probably somewhat wrong, but probably verteiron will come in here and correct me, and I'm too tired to make sure its completely correct myself.
User avatar
Sarah Knight
 
Posts: 3416
Joined: Mon Jun 19, 2006 5:02 am

Post » Tue Jan 01, 2013 7:23 am

Wow this is awesome, I'm not educated enough to figure this out right away but you can bet I'll be toying with this all night to see if I can't get something to happen :biggrin: Thank you very much for the help.
User avatar
luis dejesus
 
Posts: 3451
Joined: Sun Aug 19, 2007 7:40 am

Post » Tue Jan 01, 2013 6:42 am

Il Ducey's approach is similar to how I move inanimate objects like stones or fireballs at a distance. I've never actually tried it on an actor, but it should work well. One note, though: to keep an object in front of the player, you actually need to use the player's Z angle - 90 degrees.

The Grab Actor archetype is kind of flaky, though. Not sure how well it would work when remote cast; it barely works when the player uses it :P If it fails, you can instead ragdoll the actor with a 0 magnitude PushActorAway and then translate them to the X marker repeatedly.

Or, you could use PushActorAway with a negative value and get an effect rather like my Actor Magnet, but centered around the marker. Hmm...
User avatar
Kayleigh Williams
 
Posts: 3397
Joined: Wed Aug 23, 2006 10:41 am

Post » Tue Jan 01, 2013 5:18 am

Il Ducey's approach is similar to how I move inanimate objects like stones or fireballs at a distance. I've never actually tried it on an actor, but it should work well. One note, though: to keep an object in front of the player, you actually need to use the player's Z angle - 90 degrees.

The Grab Actor archetype is kind of flaky, though. Not sure how well it would work when remote cast; it barely works when the player uses it :tongue: If it fails, you can instead ragdoll the actor with a 0 magnitude PushActorAway and then translate them to the X marker repeatedly.

Or, you could use PushActorAway with a negative value and get an effect rather like my Actor Magnet, but centered around the marker. Hmm...

Wait...you can use negative values with PushActorAway()?
That would be by FAR the better approach.

Also, it wouldn't require dawnguard.
User avatar
Ann Church
 
Posts: 3450
Joined: Sat Jul 29, 2006 7:41 pm


Return to V - Skyrim