GoalSelector

interface GoalSelector

Something that selects goals for an entity.

Functions

Link copied to clipboard
abstract fun addGoal(priority: Int, goal: Goal)

Adds the given goal to this goal selector with the given priority.

Link copied to clipboard
abstract fun addTargetFinder(priority: Int, finder: TargetFinder)

Adds the given target finder to this goal selector with the given priority.

Link copied to clipboard
abstract fun findTarget(): Entity?

Finds the target for this goal selector, trying all target finders currently in use until it finds one that returns a non-null target.

Link copied to clipboard
abstract fun removeGoal(goal: Goal)

Removes the given goal from this goal selector.

Link copied to clipboard
abstract fun removeTargetFinder(finder: TargetFinder)

Removes the given target finder from this goal selector.

Properties

Link copied to clipboard

All the goals that this selector will process.

Link copied to clipboard

All the target finders that this selector will try to find targets with.