Difference between revisions of "Osiris/API/CharacterAddToParty"

From Divinity Engine Wiki
Jump to: navigation, search
(Clarified that this is no substitute for CharacterRecruitCharacter, and updated usage notes)
m
Line 9: Line 9:
 
* '''_Character''' must be global.
 
* '''_Character''' must be global.
 
* This API should only be used to add [[Osiris/API/CharacterIsPlayer|player-controlled characters]] to a new party after they have been removed from one with [[Osiris/API/CharacterRemoveFromParty|CharacterRemoveFromParty]]. This '''''must''''' be done in the same [[Osiris_Overview#Osiris_Frames|frame]] as the one in which the character was removed.
 
* This API should only be used to add [[Osiris/API/CharacterIsPlayer|player-controlled characters]] to a new party after they have been removed from one with [[Osiris/API/CharacterRemoveFromParty|CharacterRemoveFromParty]]. This '''''must''''' be done in the same [[Osiris_Overview#Osiris_Frames|frame]] as the one in which the character was removed.
* Use [[Osiris/API/CharacterRecruitCharacter|CharacterRecruitCharacter]] instead to recruit NPCs into a party (and make them a player).
+
* Use [[Osiris/API/CharacterRecruitCharacter|CharacterRecruitCharacter]] instead to recruit NPCs into a party (and make them a player-controlled character at the same time).
 
===== See Also =====
 
===== See Also =====
 
* [[Osiris/API/AddToParty|AddToParty]]
 
* [[Osiris/API/AddToParty|AddToParty]]

Revision as of 16:28, 29 November 2017

Full Definition(s)
  • call CharacterAddToParty((CHARACTERGUID)_Character, (CHARACTERGUID)_PartyCharacter)
Description

Adds the character _Character to _PartyCharacter's party.

Normally, you should never use need nor use this call.

Notes
  • This call will not do anything if _Character or _PartyCharacter is NULL, if _PartyCharacter is not in any party, or if _Character is already in another party.
  • _Character must be global.
  • This API should only be used to add player-controlled characters to a new party after they have been removed from one with CharacterRemoveFromParty. This must be done in the same frame as the one in which the character was removed.
  • Use CharacterRecruitCharacter instead to recruit NPCs into a party (and make them a player-controlled character at the same time).
See Also