Jump to content

Resting of familiars? (or any other creature following in that status)


jastey

Recommended Posts

For RestParty(), familiars or all creatures following in that status will be rested just as well.

 

But there are some mods that use the scripted rest to prevent stacking of rest banters as described here.

 

Problem: After such a rest, Players 1-6 will be rested, but familiars won't. Since I am using the familiar status to let some of my NPCs follow as a 7th party member, this is not good.

 

I have a solution that is taken from rest detection of Zed Nocear's BG1 trigger simluations (i.e. apply a spell that increases FATIGUE by 1 to Player1 and do so every time FATIGUE is at 0 -> rest can be detected).

 

This is a bit tedious, though (ahaha, what a game of words!) since it decreases Player1's time until fatigued, adds a scriptblock to Baldur.bcs, and would have to be compatible for all mods that want to make use of this approach as it can only be done once (duh).

 

Is there a more elegant way to achieve this?

 

Unfortunately, the best solution would not be to change the used rest cutscenes, as they are already used by mods as they are now. Still, if there is a way to rest all "creatures that follow as familiars" by scripting, it would interest me to know, too.

Link to comment

I have worked with those two alternatives in my mods:

 

1) I have given those 7th member-like creature a minimum regeneration effect, so an 8 hours rest heals them as well. Of course the same happens during a worldmap travel of some length.

Use of this idea of course depends on how late and at which level your *NPC* appears. It is not for low level creatures early in the game but if we talk of somewhere in SoA or ToB it works.

Anyway, I admit that it is a matter of taste and a workaround.

 

2) Use the PartyRested() trigger in the creature's script to apply the same spell used by the rest function on your creature.

Edited by Roxanne
Link to comment

Sorry, the *same spell used by the rest function* actually is not correct, that was what I tried but not got adequate results.

I use a custom spell now for it, you can find it in my Corwin mod - there is also a slightly similar spell in Argent77's Djinni mod,(when the guy rests in his bottle) and some other mods I cannot remember off-hand.

Link to comment

My main problem is that the NPC has e.g. special abilities or even spells that need to be refreshed after such a scripted rest, as well.

Ah...

add

ActionOverride("yourCre",Rest())

to the script?

It is different from RestParty() as you do not see movie or effect and you can apply it to a single creature.

Edited by Roxanne
Link to comment

PartyRested() only gives true after RestParty(), at least in my tests.

 

I am talking about party rest that is simulated via cutscene and scripted Rest() actions for Players 1-6.

 

Patching these cutscenes would only be possible as crossmod content late in an install. It is possible, of course, but I am interested whether there is a general approach.

Link to comment

PartyRested() only gives true after RestParty(), at least in my tests.

 

I am talking about party rest that is simulated via cutscene and scripted Rest() actions for Players 1-6.

 

Patching these cutscenes would only be possible as crossmod content late in an install. It is possible, of course, but I am interested whether there is a general approach.

Are you talking about that special rest script that was published by someone to prevent multiple rests triggered by mods interacting?

I cannot find it anymore to see how exactly it worked, just - does that always trigger and substitute RestParty()? Or is the triggering of that script rather the exception?

 

Is there anything in this script that you could evaluate, some global set or so?

Edited by Roxanne
Link to comment

Are you talking about that special rest script that was published by someone to prevent multiple rests triggered by mods interacting?

I cannot find it anymore ...

That's cause you have never played the game with SCS then, cause it has been there for YEARS.

But the whole jig of that mods is that you literally can't rest but once.

Edited by Jarno Mikkola
Link to comment

Was going to say, have the creature's script check Player1's FATIGUE stat, and rest the creature whenever it is zero. And prevent it from happening every 6 seconds... maybe by setting Player1's FATIGUE stat to 1. It would minimal effect on normal gameplay.

 

And then I re-read the first post. :blush:

Edited by subtledoctor
Link to comment

Here is a weird idea: if you are programming only for the EE, you can detect the fatigue opcode with param2 = 0 by seven eyes (335/336).

In the triggered spell, you can target familiars globally by anything (using 177 or 318 or 324).

 

You can add the seven eyes opcode by the familiar on creation.

 

This way, you can refresh your familiar the moment its owner has rested.

 

Note: i didn't test this, but feels like doable.

Edited by Avenger
Link to comment

Do you happen to know the progression of the FATIGUE stat in the game? After how many seconds does it get increased by 1?

If I could spare the fatigue spell and use the stat directly it would be cool. But I guess it's more complicated than that or maybe related to gametime timer and /or dependent in the char's CON or something.

Link to comment

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...