Environment Query System Overview

Overview page for Environment Query System.


The Environment Query System (or EQS for short) is a feature within the AI Tools in Unreal Engine 4 (UE4) that can be used for collecting data about the environment. Then, through the use of a Generator, the system can ask questions about that data through a variety of user-defined Tests, returning the best Item that fits the types of questions being asked. Some example use-cases for EQS could be to find the closest health pickup or ammo, figure out which enemy is the highest threat, or to find line of sight to the Player (an example of which is shown below). 


The conceptual idea and theory behind EQS comes from Unreal Engine 3's Environment Tactical Query (ETQ) system which you can read more about in the following article, Asking the Environment Smart Questions.

EQS Basics

EQS Query assets can be created in the Content Browser and can be edited inside a special Environmental Query Editor. The Environmental Query Editor is a node-based editor where you can add a Generator node to produce Items, add your desired Tests to run on those Items, and the Context in which to run them. UE4 supplies of number of Generator types by default, however you can create your own custom Generators through Blueprint (or C++ for even faster execution). 


Above, we add a Distance Test to our existing Generator.

Similar to Generators, there are several different types of Tests you can run to filter and (or) score the Items returned. Unlike Generators, custom Tests can only be created through C++. Multiple Tests can be added to a Generator and is a common practice to narrow down the Item results that are returned. The order in which you add Tests to a Generator does not matter as filter Tests are done before scoring Tests. This is done so that less Items are returned and need to be scored. Refer to the table below for the type of tests. 

Node Type



This produces the locations or Actors, referred to as Items, that will be actually tested and weighted.


These are a frame of reference for the various Tests and Generators.


These are how the Environment Query decides which Item from the Generator is the "best" option.

Please refer to the EQS Node Reference page for more information on each type.

Once you have set up your EQS Query, you can run it through a

[Behavior Tree](InteractiveExperiences/BehaviorTrees)
 using the Run EQS Query Task node. 


For a full walk-through of creating and using an EQS Query, please see the EQS Quick Start Guide.

Enabling EQS

Before you can start working with EQS, you will need to enable it from the Editor Preferences menu.

  • Under Editor Preferences > Experimental > AI section, enable the Environmental Query System option.


Previewing an EQS Query

You can preview the results of an EQS Query inside the Editor, where weighted/filtered results will be represented by debug spheres. 


In the image above, we debug an EQS Query that returns a location which provides line of sight to the Player Character in the Level. 

Please see AI Debugging or EQS Testing Pawn for more information.

Select Skin
언리얼 엔진 문서의 미래를 함께 만들어주세요! 더 나은 서비스를 제공할 수 있도록 문서 사용에 대한 피드백을 주세요.
설문조사에 참여해 주세요

새로운 언리얼 엔진 4 문서 사이트에 오신 것을 환영합니다!

문서 사이트에 대한 의견을 모을 수 있는 피드백 시스템을 포함해서 여러가지 새로운 기능을 준비하고 있습니다. 아래 Documentation Feedback 포럼(영문) 또는 언리얼 엔진 네이버 공식 카페(한글) 중 편하신 곳에 의견이나 문제점을 알려 주세요.

새 시스템이 준비되면 알려 드리겠습니다.

네이버 카페
공식 포럼