Posts: 637
Threads: 106
Joined: May 2011
Reputation:
0
you probably put it on the timer or OnPlayerUpdate.
Posts: 637
Threads: 106
Joined: May 2011
Reputation:
0
where you put this line of code?Under which calback?
Posts: 637
Threads: 106
Joined: May 2011
Reputation:
0
can you show me whole command?And tell me where you place the cmd?
Posts: 637
Threads: 106
Joined: May 2011
Reputation:
0
if(IsPlayerInRangeOfPoint(playerid, 1.5, HouseInfo[i][hEnterX], HouseInfo[i][hEnterY], HouseInfo[i][hEnterZ]) && GetPlayerInterior(playerid) == HouseInfo[i][hOutsideInt] && GetPlayerVirtualWorld(playerid) == HouseInfo[i][hOutsideVir])
try this
Posts: 843
Threads: 61
Joined: Feb 2013
Reputation:
0
Yes, it gets repeated because you are sending the message under check for every house. Create a variable, let's say id, set it to -1 and go through the loop. If the player is near the house, change the id. After the loop check if the id is equal to -1, if it is, send the message that player is not near any house.