Skip to main content

Condition_NearestCityGraphPointDistance

Description

Checks whether the distance between the BaseObject character and the nearest city graph point of the specified category is within the threshold defined by F1. F1 is also used as the search radius when querying the city graph, so it must be greater than 0.

Parameters

ParameterDescription
BaseObjectThe character whose position is used as the query origin (Self or Target)
CompareTypeEqual: distance is within F1; NotEqual is not supported (returns false if no point is found)
S1City graph category to search (e.g., Spawn, Commerce, Residential, Industrial, Service)
F1Distance threshold in Unreal units; must be greater than 0. Also used as the search radius.

Examples

DescriptionBaseObjectCommandCompareTypeS1F1
Is self within 1000 units of a Spawn point?SelfNearestCityGraphPointDistanceEqualSpawn1000
Is self within 500 units of a Commerce zone?SelfNearestCityGraphPointDistanceEqualCommerce500
Is target within 800 units of a Residential area?TargetNearestCityGraphPointDistanceEqualResidential800