You are here

Player character tag

6 posts / 0 new
Last post
Vermillion
Player character tag

Hi

Can I "get" the player character by his tag i.e. using GetObjectByTag() function? Does the PC has a tag at all?

  • up
    50%
  • down
    50%
andysks
andysks's picture

Well player character is the PC. Like if you use GetFirstPC(FALSE) you'll get any player controlled character, and with TRUE only the player created character. And more ways to do it. You don't need the tag. Except if it was a curiosity question :).

  • up
    100%
  • down
    0%
Vermillion

But what about multiplayer? Game must distinguish players from each other...

  • up
    50%
  • down
    50%
rjshae
rjshae's picture

Once you call GetFirstPC, cycle through the list with repeated GetNextPC(). I guess you can then distinguish on name or possibly the object.

  • up
    100%
  • down
    0%
kevL's
kevL's's picture
  • Can I "get" the player character by his tag i.e. using GetObjectByTag() function? Does the PC has a tag at all?

an OwnedPC is an object like most others and can have a tag; no tag by default.

that said, there are a ~dozen ways to get PC-creatures and they tend to depend on the situation ...

  • up
    100%
  • down
    0%
Vermillion

Everyone thanks for answers! Now it is much clearer for me.

  • up
    50%
  • down
    50%