Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
Joined: Sep 2017
M
monzua Offline OP
member
OP Offline
member
M
Joined: Sep 2017
Hi I want to Change the "teleportable" flag via osiris Story script based on specifc conditions in runtime.

Is that possible or is there a different way to block teleport skill to work on a target based on an osiris Event during combat?

thx!

Last edited by monzua; 18/10/17 12:28 PM.
Joined: Sep 2017
Location: UK
apprentice
Offline
apprentice
Joined: Sep 2017
Location: UK
Bump...

I would also like to change the "player" to "true"

am almost at the point where I got an NPC to join a party after a dialogue.

From digging about... it seems that there are a number of calls to add an NPC to the party (and also set what type of character they are). I have not found exactly how this is done.

Here is the relative story code... I think they use.


//REGION Recruitment
IF
DialogEnded("Lohse_Recruitment",_)
THEN
ObjectClearFlag(CHARACTERGUID_S_Player_Lohse_bb932b13-8ebf-4ab4-aac0-83e6924e4295,"FTJ_LohsePlayPossesseddAnimation",0);

IF
ObjectFlagCleared("FTJ_LohsePlayPossesseddAnimation",CHARACTERGUID_S_Player_Lohse_bb932b13-8ebf-4ab4-aac0-83e6924e4295,_)
THEN
CharacterSetAnimationOverride(CHARACTERGUID_S_Player_Lohse_bb932b13-8ebf-4ab4-aac0-83e6924e4295,"");

PROC
PROC_GLO_PartyMembers_Add(CHARACTERGUID_S_Player_Lohse_bb932b13-8ebf-4ab4-aac0-83e6924e4295,(CHARACTERGUID)_Avatar)
AND
NOT DB_GlobalFlag("FTJ_LV_SetUp")
THEN
ObjectSetFlag(_Avatar,"GLO_Lohse_RecruitedInFortJoy");

PROC
PROC_GLO_PartyMembers_Add(CHARACTERGUID_S_Player_Lohse_bb932b13-8ebf-4ab4-aac0-83e6924e4295,(CHARACTERGUID)_Avatar)
AND
DB_GlobalFlag("FTJ_LV_SetUp")
THEN
ObjectSetFlag(_Avatar,"GLO_Lohse_RecruitedInLV");

Joined: Mar 2016
Location: Belgium
T
addict
Offline
addict
T
Joined: Mar 2016
Location: Belgium
Originally Posted by monzua
Hi I want to Change the "teleportable" flag via osiris Story script based on specifc conditions in runtime.

Is that possible or is there a different way to block teleport skill to work on a target based on an osiris Event during combat?

If you look at the stats for the teleport skills (Stat editor -> Projects -> Shared -> SkillData -> Skill_Teleportation), then in the column "TargetConditions" you can see "(Character|Dead);!Grounded". This means the target must be a living character or dead, and it must not have the "grounded" status. Hence, this will block teleportation indefinitely:
Code
ApplyStatus(_Char,"GROUNDED",-1.0);


To remove it:
Code
RemoveStatus(_Char,"GROUNDED",-1.0);

Joined: Mar 2016
Location: Belgium
T
addict
Offline
addict
T
Joined: Mar 2016
Location: Belgium
Originally Posted by Scottworld
Bump...

In the future, please don't hijack threads. Create new ones for different questions (and there's really no need to bump threads if they haven't been answered within 3 hours).

Quote

I would also like to change the "player" to "true"

am almost at the point where I got an NPC to join a party after a dialogue.

To turn a character into a player and have them join the party, use the PROC_GLO_PartyMembers_Add(_CompanionChar,_RecruiterChar) procedure.

To remove them again, use PROC_GLO_PartyMembers_Remove(_CompanionChar,1) .

Joined: Sep 2017
Location: UK
apprentice
Offline
apprentice
Joined: Sep 2017
Location: UK
Thanks for that... you must work for my manager, as you have just copied my question, including the answer I proposed and then posted it as the solution. You will go far, my friend....

I have created a new thread... as requested... if you could show us how to add an NPC to the party after accepting (via a dialog) by setting the flags that would be most useful to the community,

http://larian.com/forums/ubbthreads.php?ubb=showflat&Number=632089#Post632089

and am looking forward to the answer to the original question (in detail) ... or mine (which I think is related)


Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.5