Worldguard Flags

Discussion in 'Spigot Plugin Development' started by TimLampen, May 9, 2015.

  1. Hey,

    I was wondering if anyone knew if there was a worldguard flag, or a way that I could bypass the mob-spawning flag in a region.

    For example I want my plugin to spawn something at the players location, but it doesnt because worldguard blocks it. Is there a way for me to override the worldguard flag?

  2. Set the spawn reason to SpawnReason.PLUGIN
  3. Spawn Entity -> Save UUID of Entity -> EntitySpawnEvent -> Set EventPriority to MONITOR -> Check if the entity's uuid is equal to the one that you saved -> event.setCancelled(true);

    EDIT: Or that:
  4. Where?