Table of Contents

COMP_AGENT

Category: Component

Parent class: COMPONENT

Properties


BehaviorTree

Serialized, Savegame


ActivityMessage

Runtime only, Savegame


IsDying

Runtime only, Savegame


Gender

Runtime only, Savegame


WalkOnPlatform

Serialized


RoadPaintSpeed

Serialized


Model

Serialized, Savegame

Functions


setAnimation

void setAnimation(animation [, speed])

Name Type Description
animation AGENT_ANIMATION
speed float

setActivityMessage

void setActivityMessage(message)

Deprecated since version 1.8; use ActivityMessage property instead

Name Type Description
message string

setBehaviorMessage

void setBehaviorMessage(message)

Deprecated since version

Name Type Description
message string

setIsRoadTracingEnabled

void setIsRoadTracingEnabled(enabled)

Name Type Description
enabled boolean

isOnWater

boolean isOnWater()


setProfile

void setProfile(profile)

Name Type Description
profile AGENT_PROFILE

getProfile

AGENT_PROFILE getProfile()


setVehicle

void setVehicle(vehicle)

Assign the vehicle to the agent. This does not destroy previously assigned vehicle.

Name Type Description
vehicle COMP_VEHICLE

getVehicle

COMP_VEHICLE getVehicle()


isOnBoat

boolean isOnBoat()


die

void die()

This will make the agent die during his next update().

Events


ON_DYING

ON_DYING()


ON_VEHICLE_CHANGED

ON_VEHICLE_CHANGED(COMP_VEHICLE previousVehicle, COMP_VEHICLE newVehicle)