Jasmine

A place to download and discuss my mods. No adult content please.

Jasmine

Postby Spirithawke » Fri Dec 21, 2012 4:22 pm

I was looking at her main script, and I see that she has added to her an ability to replenish her fatigue by 1 as a constant effect, and I was curious to why this was done.

Spirithawke
Last edited by Jac on Fri Dec 21, 2012 8:20 pm, edited 1 time in total.
Reason: Fixed topic title
User avatar
Spirithawke
Associate
 
Posts: 43
Joined: Fri Dec 21, 2012 1:56 pm

Re: Jasmine

Postby Jac » Fri Dec 21, 2012 4:27 pm

This was so that she wouldn't miss in combat because of running after the player. The engine wasn't designed with companions in mind, so certain workarounds like this were implemented to make them more useful.
User avatar
Jac
The Boss
 
Posts: 5985
Joined: Sat Feb 12, 2011 8:36 pm
Location: Somewhere on the left side of insanity, the right side was taken.
Title: Elder Wolf

Re: Jasmine

Postby Spirithawke » Fri Dec 21, 2012 7:05 pm

Interesting..thank you for the reply..sorry I posted in the wrong place, I actually thought about posting here, but it seemed to be a thread for releases, hence why I posted in the other forum. I will undoubtedly have some more questions once I wrap my mind around why you did some things they way you did. That one I just could not figure out any kind of explanation for, and Jasmin is the only companion I have seen that in so far.
User avatar
Spirithawke
Associate
 
Posts: 43
Joined: Fri Dec 21, 2012 1:56 pm

Re: Jasmine

Postby Jac » Fri Dec 21, 2012 8:15 pm

No worries.

Melian did most of the scripting for Jasmine, so I may or may not have answers to your questions. I know how it works, but it's not something I could have done myself.
User avatar
Jac
The Boss
 
Posts: 5985
Joined: Sat Feb 12, 2011 8:36 pm
Location: Somewhere on the left side of insanity, the right side was taken.
Title: Elder Wolf

Re: Jasmine

Postby Spirithawke » Sat Dec 22, 2012 5:50 pm

Forcing weapon/spell sheathing:

Code: Select all
      if ( GetSpellReadied )
         cast "1JAC_JasWB_bog" JAC_Jasmine
      else
         equip jac_sheatheweap   ;made this a unique ID so she won't lose any silver daggers
         RemoveItem jac_sheatheweap 1
      endif


Q1: I am guessing this works better than the old
Code: Select all
1gr_comp4->StartCombat 1gr_comp4


Q2: tmpFloat and tmpShort appear to be used in multiple places in the script so as to be able to declare fewer variables in the beginning, cannot make up my mind if I like this idea or not. Was there some sort of problem with having lots of variables?

Q3: JasFollowing apears to be used in place of just using GetCurrentAIPackage, guessing this was done due to the addition of all the fixAI related stuff. Also, there is a lot of code that I am surprised is not inside an IF nest to see if she is following or not. It would seem to me that if she is not following, that code would not need to be executed and so therefore it would be better if it was inside such an IF statement to save on CPU cycles.

Code: Select all
   elseif ( GetPCSleep )   ;levelling
      if ( JasLeveling == 0 )
         StartScript Jac_jasmine_levelscout
      else
         StartScript Jac_jasmine_levelscout
      endif

Q4: To me it appears that it do not matter what JasLeveling is set to, that level script will run regardless.

Q5: I see her being enabled and disabled in varying places, such as the recallring script, the jaswarpQS script, fix AI portion of main script, what sort of bug does this fix?

Q6: I see the short variable noattack being set in a couple places...but I cannot find it really used for anything...what is its purpose?

Code: Select all
elseif ( swimCheck == 1 )
   set tmpFloat to ( ( GetWaterLevel ) - 119.7 )
   set ax to ( GetPos z )
   if ( ax <= tmpFloat )   ;check she's actually swimming
      set tmpFloat to ( tmpFloat - 12 )
      set ay to ( tmpFloat - 20 )
      set coDist1 to ( player->GetPos z )
      if ( ax <= tmpFloat )   ;if underwater
         set Zwarp to 1
      elseif ( coDist1 < ay )   ;if player underwater
         set Zwarp to 1
      endif
   endif
endif


Q7: where did the values 119.7, 12, and 20 come from?

Code: Select all
if ( swimCheck == 0 )
   if ( celltype == 0 )
      set swimCheck to 1
   elseif ( GetWindSpeed > 0.001 )   ;fake exterior
      set swimCheck to 1
   elseif ( GetSoundPlaying "FootWaterLeft" == 1 )
      set swimCheck to 1
   elseif ( GetSoundPlaying "FootWaterRight" == 1 )
      set swimCheck to 1
   elseif ( GetSoundPlaying "DefaultLandWater" == 1 )
      set swimCheck to 1
   endif
endif


Q8: Why set swimCheck for any exterior cell regardless of if the actor is swimming or not?
User avatar
Spirithawke
Associate
 
Posts: 43
Joined: Fri Dec 21, 2012 1:56 pm

Re: Jasmine

Postby Spirithawke » Sun Dec 23, 2012 1:15 pm

Q9: I found this comment in the Jac_jasmine_levelscout script: ";same as athletics, but no point setting athletics anyway" Why is there no point to setting athletics? It used to be the thing to do when doing dynamic speed adjust.

Q10: If all teleport door related warping is handled by the JAC_JasWarpQS script, could she not have one of the older, simpler, less math intensive warping script for in cell warping?
User avatar
Spirithawke
Associate
 
Posts: 43
Joined: Fri Dec 21, 2012 1:56 pm

Re: Jasmine

Postby Spirithawke » Thu Dec 27, 2012 3:38 am

Q1 OK, I have been testing this out and it do seem to work better.
Q5 after much searching I found an explanation inside a different companion script...it appears this is done to fix some bug where she is sometimes invisible
Q6 I found noattack finally...used to keep her from using attack voices in the voices dialog tab.

New question:

Q11 Why does Jasmin's teleport ring script seem unfinished? I ended up having to pretty much rewrite it as when I used it "as is" it caused a endless loop playing the "mysticism hit" sound...and did not move the NPC ever. Effect started about 2 seconds after receiving the ring. Also, apparently the stopscript command is useless when used on an script tied directly to an item in the CS. The script just will not stop, hence the looping of Jasmin's teleport ring script.
User avatar
Spirithawke
Associate
 
Posts: 43
Joined: Fri Dec 21, 2012 1:56 pm

Re: Jasmine

Postby neildarkstar » Thu Dec 27, 2012 3:58 pm

Hehe, the stopscript on attached scripts works just fine, the catch 22 is that the script will start again the very next frame... A variable is often used to set a Return at the beginning of the script to get around that problem, though I'm not familiar with Jasmine's scripts.
"If you want to make God laugh, tell Him your plans." - Movie "Flypaper"
User avatar
neildarkstar
Jac's Hero of the Day
Jac's Hero of the Day
 
Posts: 2845
Joined: Mon Jul 25, 2011 7:57 pm

Re: Jasmine

Postby Jac » Thu Dec 27, 2012 4:41 pm

I haven't looked at Jasmine's scripts in months, if not for a year or so, but the teleporter ring script should only fire whenever her ring is used, hence the reason for the startscript. If it's looping, then it's more likely something on your end, Spirithawke, because I've never noticed it and I don't recall anybody else mentioning it. If it's happening to her when you use the ring, then it should be a simple fix.
User avatar
Jac
The Boss
 
Posts: 5985
Joined: Sat Feb 12, 2011 8:36 pm
Location: Somewhere on the left side of insanity, the right side was taken.
Title: Elder Wolf

Re: Jasmine

Postby Spirithawke » Fri Dec 28, 2012 11:22 am

hmm..ok, after much searching thru jasmin I finally figured out what is going on...I had just taken it for granted that the script named recallring was actually tied to a ring, which is not the case....lol..apparently it is triggered thru dialog only as a specially targeted global script....hence why it would work fine as is and suck when tied to a ring :D
User avatar
Spirithawke
Associate
 
Posts: 43
Joined: Fri Dec 21, 2012 1:56 pm


Return to Jac's Mods

Who is online

Users browsing this forum: No registered users and 1 guest

  • Advertisement
cron