Guest Posted February 6, 2013 Posted February 6, 2013 Hi guise, I ran into a weird problem that I cannot make sense of myself. What I have is an activator that uses the following script.. ScriptName SexoutATHControlDeathclawScript short bActive short nIndex short nAnimation int iActorValue ref refActorA ref refActorB Begin OnActivate if IsActionRef Player set refActorA to SexoutATHHall4ActorDeathclaw01 set refActorB to SexoutATHHall4ActorFemale01 ; Set new animation index if ((nIndex >= 0) && (nIndex < 6)) set nIndex to nIndex + 1 elseif (nIndex == 6) set nIndex to 11 elseif (nIndex >= 11) set nIndex to 0 endif ; Finish current act refActorA.CIOS SexoutNGFinishNow ; Switch animation if (nIndex > 0) set bActive to 1 else ShowMessage SexoutATHAnimationStopped endif Activate endif End Begin GameMode if bActive set iActorValue to refActorA.GetActorValue Variable04 if ((LogicalAnd iActorValue SexoutNG.FlagInUse) == 0) ; Start new animation set nAnimation to (1300 + nIndex) refActorA.NX_SetEVFl "Sexout:Start::CallVer" 1 refActorA.NX_SetEVFo "Sexout:Start::ActorA" refActorA refActorA.NX_SetEVFo "Sexout:Start::ActorB" refActorB refActorA.NX_SetEVFl "Sexout:Start::Duration" 3600 refActorA.NX_SetEVFl "Sexout:Start::Anim" nAnimation refActorA.CIOS SexoutBegin ShowMessage SexoutATHAnimationMessage nAnimation set bActive to 0 endif endif End It switches between the seven Deathclaw animations and a full stop. Now, the weird thing is although it shows that nAnimation changes to the intended number (1301, 1302, ... 1311) it always plays animation 1301..Should I let the script sleep a few seconds before starting the next animation? I thought just checking Variable04 would be sufficient to see, if there is still something going on.. please halp!?Thanks,So
astymma Posted February 6, 2013 Posted February 6, 2013 When setting the anim through the new calling method set the value according to the actor. Since you're using refActorA to call refActorA.NX_SetEVFl "Sexout:Start::Anim" nAnimation you should be using refActorA.NX_SetEVFl "Sexout:Start::AnimA" nAnimation. As far as I know, there is no Start::Anim, but there is Start::AnimA, Start::AnimB and Start::AnimC. Since there is no animation being defined, you're likely just playing the default deathclaw animation... 1301.
Guest Posted February 6, 2013 Posted February 6, 2013 When setting the anim through the new calling method set the value according to the actor. Since you're using refActorA to call refActorA.NX_SetEVFl "Sexout:Start::Anim" nAnimation you should be using refActorA.NX_SetEVFl "Sexout:Start::AnimA" nAnimation. As far as I know, there is no Start::Anim, but there is Start::AnimA, Start::AnimB and Start::AnimC. Since there is no animation being defined, you're likely just playing the default deathclaw animation... 1301. I didn't even know you could set the animations per actor.. cool, thanks for telling .. I used Start::Anim all the time before and never experienced problems with that until now, but what's still puzzeling.. at least for me.. I had a very crude animation changing mechanism before I rewrote it to do the animation changing inside the GameMode block and that early version of the script set the seven animations explicitly inside the OnActivate block using Start::Anim and that worked, too.. that's why I guessed the changing might have been coming too fast inside the GameMode block.. anyway, with your solution it works perfect.. I added another FlagInUse check for actor B - now it works as intended .. thanks to you
astymma Posted February 6, 2013 Posted February 6, 2013 Oh, I was just going off my read of the Sexout scripts themselves. The two scripts that I saw that did animation handling were looking for the specific AnimA-C variables and not Anim. It's entirely possible that there's some handling in one of the scripts I didn't see that uses it.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.