unreal.AISense_Blueprint

class unreal.AISense_Blueprint(outer=None, name='None')

Bases: unreal.AISense

AISense Blueprint

C++ Source:

  • Module: AIModule
  • File: AISense_Blueprint.h

Editor Properties: (see get_editor_property/set_editor_property)

  • auto_register_all_pawns_as_sources (bool): [Read-Write] If true all newly spawned pawns will get auto registered as source for this sense.
  • default_expiration_age (float): [Read-Write] age past which stimulus of this sense are “forgotten”
  • listener_container (Array(AIPerceptionComponent)): [Read-Write] Listener Container
  • listener_data_type (type(Class)): [Read-Write] Listener Data Type
  • notify_type (AISenseNotifyType): [Read-Write] Notify Type
  • wants_new_pawn_notification (bool): [Read-Write] whether this sense is interested in getting notified about new Pawns being spawned
    this can be used for example for automated sense sources registration
get_all_listener_actors() -> Array(Actor)

Get All Listener Actors

Returns:listener_actors (Array(Actor)):
Return type:Array(Actor)
get_all_listener_components() -> Array(AIPerceptionComponent)

Get All Listener Components

Returns:listener_components (Array(AIPerceptionComponent)):
Return type:Array(AIPerceptionComponent)
listener_container

(Array(AIPerceptionComponent)) – [Read-Only] Listener Container

listener_data_type

(type(Class)) – [Read-Write] Listener Data Type

on_listener_registered(actor_listener, perception_component) → None
Parameters:
on_listener_unregistered(actor_listener, perception_component) → None

called when a listener unregistered from this sense. Most often this is called due to actor’s death

Parameters:
on_listener_updated(actor_listener, perception_component) → None
Parameters:
on_new_pawn(new_pawn) → None

called when sense’s instance gets notified about new pawn that has just been spawned

Parameters:new_pawn (Pawn) –
on_update(events_to_process) → float
returns requested amount of time to pass until next frame.
Return 0 to get update every frame (WARNING: hits performance)
Parameters:events_to_process (Array(AISenseEvent)) –
Returns:
Return type:float