GetCurrentFriend()

Get the caller's current friend.

object GetCurrentFriend();

Description

Get the caller's current friend.



Remarks

Returns the local object stored in "NW_ANIM_FRIEND". If not found returns OBJECT_INVALID.

Requirements

#include "x0_i0_anims"


Version

???

Example

// See if the critter has a friend, if they do, have them rejoice.
#include "x0_i0_anims"

void main()
{
  // Check for a friend
  object oBud = GetCurrentFriend();

  // If the calling object has a friend, have them rejoice.
  if(GetIsObjectValid(oBud))
  {
    SpeakString("Yay, I have a friend!", TALKVOLUME_TALK);
  }
}

See Also

functions:  GetRandomFriend | SetCurrentFriend
categories:  Get Data from Creature Functions


author: Baragg, editor: Mistress