Skip to content

setPedChatWith

Client-side

Pair two NPCs and GTA makes them face each other and perform its original conversation behavior, with one character leading and the other replying.

Syntax

bool setPedChatWith(ped thePed, ped partner, bool leadSpeaker [, bool updateDirection = true, bool conversationEnabled = true])

GTA task mapping

ORIGINAL GTA TASK 0677
CTaskComplexPartnerChat

SCM equivalent: TASK_CHAT_WITH_CHAR

The task is queued through GTA's script-command event path. With conversationEnabled=false, San Andreas Online preserves PartnerChat's native timed SimpleChat/StandStill fallback.

Arguments

thePedped

Living streamed ped simulated by this client.

partnerped

Distinct living streamed conversation partner.

leadSpeakerbool

Whether the first ped leads the conversation.

updateDirectionbooloptional · default true

Allow the task to turn the speakers toward each other.

conversationEnabledbooloptional · default true

Enable the native conversation exchange.

Returns

true when the native task was queued; false when either ped, streaming state, liveness, simulation ownership, or task construction is invalid.

Ownership and lifecycle

Low-level ped task calls require the client that simulates the living, streamed ped. Driving tasks also require control of the streamed vehicle. They do not create lifecycle handles; the optional native-task-runtime adds server-owned route epochs and reconstruction for drive_to routes. Gang-tag ownership is resource-exclusive, survives object streaming and recreation, and is released automatically when the owner stops.

OOP aliases

  • ped:setChatWith(partner, leadSpeaker, updateDirection, conversationEnabled)

Where this comes from

RELATED SA:O APIS

Continue exploring

Read the system guide →