Start Script After VATS

Post » Thu Oct 14, 2010 12:40 pm

I want that my weapon will drain all AP after a use in VATS, but I have no idea how to make that work. I though about using
player.ForceAV ActionPoints 0
in my script but I have no idea how to make that work after a hot in VATS. Help?

EDIT: I'm trying this script:
scn SurgicalStrikeAPDeductionScriptBegin GameModeIf IsPlayerActionActive 3 == 1	player.ForceAV ActionPoints 0EndIfEnd


Will this work?
User avatar
Sweets Sweets
 
Posts: 3339
Joined: Tue Jun 13, 2006 3:26 am

Post » Thu Oct 14, 2010 3:25 am

No no no. Don't use ForceAv. From the wiki:

[ForceAv] Should never be used on the player, as it will seriously screw up that actor value when combined with other mods or scripts that adjust it or depend on it.


Just use DamageAV instead. I haven't tried any of the VATS functions myself, so I can't offer any sure fire method of doing what you ask.

EDIT: IsPlayerActionActive will return true if the player fires his weapon - which can occur without using VATS. Perhaps using what you have cobined with http://geck.gamesas.com/index.php/GetVATSMode might work, but I dunno.
User avatar
Ebony Lawson
 
Posts: 3504
Joined: Fri Feb 16, 2007 11:00 am

Post » Thu Oct 14, 2010 8:27 am

I want the effect to happen even when outside of VATS, but thanks.
User avatar
Albert Wesker
 
Posts: 3499
Joined: Fri May 11, 2007 11:17 pm

Post » Wed Oct 13, 2010 10:06 pm

If all you want is your weapon to use all action points everytime its fired, you could use the FOSE command http://fose.silverlock.org/fose_command_doc.html#SetWeaponActionPoints (SetAP) to adjust the required AP to the player's maximum Action Points stat. This would prevent the player from being able to fire twice in VATS.
User avatar
Hussnein Amin
 
Posts: 3557
Joined: Sun Aug 05, 2007 2:15 am

Post » Thu Oct 14, 2010 1:03 am

If all you want is your weapon to use all action points everytime its fired, you could use the FOSE command http://fose.silverlock.org/fose_command_doc.html#SetWeaponActionPoints (SetAP) to adjust the required AP to the player's maximum Action Points stat. This would prevent the player from being able to fire twice in VATS.

I thought about that, but I also want the AP to drain when fired outside of VATS.
User avatar
Hot
 
Posts: 3433
Joined: Sat Dec 01, 2007 6:22 pm

Post » Thu Oct 14, 2010 4:11 am

I don't really understand what your after then, cause you don't use AP when firing outside of VATS, so what would be the point?
User avatar
April D. F
 
Posts: 3346
Joined: Wed Mar 21, 2007 8:41 pm

Post » Thu Oct 14, 2010 2:52 am

To do something like this you will need to know when the player uses his weapon. The simplest way is to use the FOSE function isControlPressed 4, followed by player.DamageAV ActionPoints "desired amount". This would be best handled by a quest script as you can adjust the quest delay to control how many action points are removed each fraction of a second while the attack button is held down. You can experiment with quest delay time and how many action points to damage.

Begin GameModeif isControlPressed 4   player.DamageAV ActionPoints 1endifEnd

User avatar
Yvonne Gruening
 
Posts: 3503
Joined: Mon Apr 23, 2007 7:31 pm


Return to Fallout 3