Jump to content

Make peds say something


CowNation

Recommended Posts

How would I make a ped say something, am trying to get 1 to yell at another.

Also, is there a task to make a ped turn towards another ped?

Also, Also, how do I get them to move their mouth?

 

EDIT1:

I tried PlayAnimation("facials@gestures@", "talk_additive_spoken", 1, AnimationFlags.Loop); to get the ped to talk, didn't work so well

https://imgur.com/xgc1aET

Edited by CowNation

C++, C#, and Python dev with a dream.. and depression

Link to comment
Share on other sites

35 minutes ago, SRS Bladez said:

For them saying something, I usually do Suspect.PlayAmbientSpeech("// What ever speech in here"); Just rename Suspect to what you want.

 With the ped turning, I do Suspect.TurnToFaceEntity(VictimPed); again renaming Suspect to what you have your ped as.

 

TurnToFaceEntity is not a member of Ped or Entity

 

EDIT:
FIXED

public static void TurnToFaceEntity(this Ped ped, Entity entity, int duration = -1/*-1 = forever...*/)
{
    NativeFunction.Natives.TASK_TURN_PED_TO_FACE_ENTITY(ped, entity, duration);
}

 

Edited by CowNation

C++, C#, and Python dev with a dream.. and depression

Link to comment
Share on other sites

1 hour ago, SRS Bladez said:

For them saying something, I usually do Suspect.PlayAmbientSpeech("// What ever speech in here"); Just rename Suspect to what you want.

 With the ped turning, I do Suspect.TurnToFaceEntity(VictimPed); again renaming Suspect to what you have your ped as.

 

Also, how do I get them to move their mouth? What animation is that?

C++, C#, and Python dev with a dream.. and depression

Link to comment
Share on other sites

15 minutes ago, SRS Bladez said:

I'd use this one Suspect.Tasks.PlayAnimation(new AnimationDictionary("missfbi3_party_d"), "stand_talk_loop_a_male3", 1f, AnimationFlags.Loop);

 

The character moves his body. Is there any way to only to have his face/mouth move?

 

https://imgur.com/tuJtoaU

Edited by CowNation

C++, C#, and Python dev with a dream.. and depression

Link to comment
Share on other sites

9 minutes ago, SRS Bladez said:

Suspect.Tasks.PlayAnimation(new AnimationDictionary("mp_facial"), "mic_chatter", 1f, AnimationFlags.Loop | AnimationFlags.SecondaryTask);

I believe that's the one

 

Thanks, that's the one! Is there an easy way too look at a list of all of the animations and PlayAmbientSpeech speech names?

C++, C#, and Python dev with a dream.. and depression

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...