Players in range
From Unofficial QEdit Wiki Guide
Contents
Syntax
Syntax: players_in_range register 1, register 3
- Register 1 = Reserved register 250 to get the players slot number.
- Register 2 = Radius to check for players in range.
- Register 3 = Output for # of players in range.
NOTE: This Opcode requires 2 values to be input. The 2nd Register uses a radius.
Use
Used to see how many players are near you in the given radius in the hidden Register 2. Register 2 is not actually input in the opcode itself.
Example
100: get_slotnumber R250 //Stores the value of the slot the player is in in register 250.
let R1, R250 //Stores the player slot in R1.
leti R2, 0000001E //Makes the radius to check 30 units.
players_in_range R1, R3 //Checks the number of players with the given parameters.
ret