$gameMap.eventsXy(199,150).length == 1
false if there are 2 or more events there. It is also a check, rather than a trigger, i.e. by itself it doesn't cause anything to happen.If you only need to check for events, consider this instead:
$gameMap.eventsXy(199, 150).length > 0Or just get the event ID using
$gameMap.eventIdXy or the Get Location Info event command.If you did need to check for other character types as well, those would have to be done separately, e.g.
[$gamePlayer, $gameMap.boat(), $gameMap.ship(), $gameMap.airship()].concat($gameMap.events(), $gamePlayer.followers()).some(function(char) { return char.pos(199, 150); })I.e. "loop through all characters [player, boat, ship, airship, map events, followers] and return
true if at least one of them is on tile (199, 150); otherwise return false". :kaophew:Edit: corrected "other character types" code snippet to use
concat for the events & followers, since they're arrays.