Scripting: spell for straighter arrow flight?

Post » Tue Jun 19, 2012 8:57 am

I'd like to change the speed and/or gravity of projectiles using spells, and to do this I assume I'd have to write a script..
But i can't really work out what functions would let you alter Object Attributes like Speed and Gravity?

Please bear in mind I'm a bit rusty at all this.


Background

I've just finished a mod "Blessing of Hircine" which adds 10% damage to bows for 7 hours
http://skyrim.nexusm...le.php?id=11079

Mainly I was thinking, The Daedric Prince of The Hunt would surely bless you with accuracy and not damage..


Clues
I'm guessing this is something useful http://www.creationk...ojectile_Script but dont know how to use it
User avatar
Zualett
 
Posts: 3567
Joined: Mon Aug 20, 2007 6:36 pm

Post » Tue Jun 19, 2012 8:30 am

Can't be done.
User avatar
Katie Louise Ingram
 
Posts: 3437
Joined: Sat Nov 18, 2006 2:10 am

Post » Tue Jun 19, 2012 11:26 am

Well, that was definitive. Thanks :)
User avatar
victoria johnstone
 
Posts: 3424
Joined: Sat Oct 14, 2006 9:56 am

Post » Tue Jun 19, 2012 7:48 pm

You could possibly make a second copy of all the arrow types the player can use and have their projectile speeds higher. Then OnEffectStart of your blessing change all arrows in the players inventory to the new types you have created, then OnEffectFinish change them all back. I'm not positive this would work, just theorizing, seems like it might to me.
User avatar
Damian Parsons
 
Posts: 3375
Joined: Wed Nov 07, 2007 6:48 am

Post » Tue Jun 19, 2012 9:44 am

Yeah i was thinking about some sort of switch'a'roo and your idea is good but then the thought of how messy it could get puts me off..
Eg. I shoot someone with my fast arrow, the blessing wares off, i pick the arrow up.. I now have two types of arrows named the same thing.

I might just lay that idea to rest and leave the current blessing as is.
User avatar
Rhiannon Jones
 
Posts: 3423
Joined: Thu Sep 21, 2006 3:18 pm

Post » Tue Jun 19, 2012 3:09 pm

Ya, I thought about that too, you could just make it so the new arrows can't be picked up, or possibly you could attach a script to them so when they're picked up they turn back (I'm not sure exactly how you would do this though)
User avatar
Sam Parker
 
Posts: 3358
Joined: Sat May 12, 2007 3:10 am

Post » Tue Jun 19, 2012 3:36 pm

I don't think you can attach a script to ammo, though I am not sure. However, since I think the number of arrows that can be lying around is limited, you could create a Form list with all the new arrows, and use FindClosestReferenceOfAnyTypeInListFromRef repeatedly to delete them from world or switching them by default ones once the spell ends.
User avatar
Alkira rose Nankivell
 
Posts: 3417
Joined: Tue Feb 27, 2007 10:56 pm

Post » Tue Jun 19, 2012 8:00 pm

Ya, I thought about that too, you could just make it so the new arrows can't be picked up, or possibly you could attach a script to them so when they're picked up they turn back (I'm not sure exactly how you would do this though)

Attaching scripts to projectiles or targeting projectiles with scripts can not be done. Switching them out as suggested certainly can be, and it's relatively simple bit of scripting. But that breaks too when someone has arrows from another mod that you can't account for. Mods absolutely will add more arrows. Mystic Elven and Dragon Bone are two that come immediately to mind.

An alternative might be, given that this is for a Daedric Princes reward, to give the player bound arrows for the duration. Heck, you could even give them a bound bow (which automatically uses bound arrow projectiles).

There is another alternative that comes to mind that's close to your original idea to alter accuracy. Note that accuracy is not really an issue in this game. People already modify ini settings to get around auto aim issues and distance issues, so the only remaining one is moving targets. So you could script a slow time effect for when a bow is drawn, and release it when the bow is fired. Just a thought. That should be doable.
User avatar
Hot
 
Posts: 3433
Joined: Sat Dec 01, 2007 6:22 pm


Return to V - Skyrim