@EyesUnclouded Yup, similar to a reply a couple of msgs back:
https://forums.rpgmakerweb.com/index.php?threads/qplugins-latest-qmovement.73023/page-5#post-710452
You would use that function inside ColliderManager.
That functions accepts 2 parameters; A collider as the first, and a function as the 2nd. Character objects are passed into the function, if the function returns true that character is kept, if it returns false that character is ignored, if it returns 'break' it'll stop looking for characters ( this is useful if you only need to check for a single collision, if a collision is found no need to continue checking other characters)
Here's an example from the collision checking for characters:
Code:
var collider = this.collider(type);
var collided = false;
ColliderManager.getCharactersNear(collider, (function(chara) {
if (chara.isThrough() || chara === this || !chara.isNormalPriority()) {
return false;
}
if (this.ignoreCharacters(type).contains(chara.charaId())) {
return false;
}
collided = chara.collider('collision').intersects(collider);
if (collided) return 'break';
}).bind(this));
return collided;
(From Game_CharacterBase.prototype.collideWithCharacter)
* Note that function returns an array of all the characters that it found.
Here's another example of getting all events that intersect a passed in collider:
Code:
var events = ColliderManager.getCharactersNear(collider, function(chara) {
if (chara.constructor === Game_Event && !chara._erased) {
return chara.collider('interaction').intersects(collider);
}
return false;
})
(From Game_Player.prototype.startMapEvent )