<aside> ⚡ Script "core_checkDistance" (int Distance)

</aside>

Usage


<aside> 💡 This script is simple to use, but has a very limited scope and may not be suitable for all uses. Consider using [core_getPlayersInRadius](<https://mm8bdm.notion.site/core_getPlayersInRadius-f8ebd948d73240bfbb527f2aea13fe0e>) and its more robust features instead!

</aside>

Returns a true or false value depending on if there are any players within distance units to the actor calling the script.

Parameters

Return Value

Returns true if there is any player within range, false otherwise.

Example


The Drop Platforms in Shadow Man’s stage will stay open so long as there is a player inside of them.

PlayerCheck:
	SHPL E 2
	SHPL E 2 A_JumpIf(ACS_NamedExecuteWithResult("core_checkdistance", 64) == 1, "PlayerCheck")
	SHPL D 0 A_ChangeFlag("SOLID",1)
	SHPL DCB 3
	SHPL A 2 
	goto Spawn+1

See Also


core_getPlayersInRadius

core_radiusPull