Aller au contenu

Photo

Question about GetHero()


  • Veuillez vous connecter pour répondre
4 réponses à ce sujet

#1
PavelNovotny

PavelNovotny
  • Members
  • 344 messages
Does GetHero() always give you the PC or does it give you the character you are controlling? For example, if I take control of Alistair, does GetHero() give me the PC or Alistair?

Thanks!

#2
Sunjammer

Sunjammer
  • Members
  • 926 messages
I had a chat about this with Craig Graff a couple of months back according to which ...

GetHero will give you the original character the player "rolled up" during character generation. Of course the "hero" not be the character currently being controlled by the player. Moreover the "hero" may not be the party leader or even in the active party! Fortunately the "hero" is will always be in the party pool.

So in your scenario GetHero would give you the player's original character, GetMainControlled would give you Alistair and GetPartyLeader should give you the player's character unless you've removed him from the active party or used SetPartyLeader to nominate another character.

Note that IsHero will return TRUE for GetHero but while IsControlled will return TRUE for GetMainControlled it will also return TRUE for any other currently selected party member!

Confused?

Modifié par Sunjammer, 26 mars 2010 - 01:38 .


#3
Jassper

Jassper
  • Members
  • 571 messages
Just a little


#4
TimelordDC

TimelordDC
  • Members
  • 923 messages

Sunjammer wrote...

...and GetPartyLeader should give you the player's character you've removed him from the active party...


I assume above means 'unless you've removed him'?
This is good information about GetHero.

#5
Sunjammer

Sunjammer
  • Members
  • 926 messages
Indeed. Glad one of us was paying attention.