Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Entities

Comments in 'Plugin Development' started by iDirtPlayzMC, Dec 13, 2015.

  1. iDirtPlayzMC
    Offline

    iDirtPlayzMC Active Member

    Joined:
    Apr 10, 2015
    Posts:
    264
    Minecraft User:
    iZenith_xPr
    How do I remove entities?
    all entities in the world must goes away ( including mob )
  2. Svile
    Offline

    Svile Active Member

    Joined:
    Mar 30, 2015
    Posts:
    239
    Minecraft User:
    svile
  3. iDirtPlayzMC
    Offline

    iDirtPlayzMC Active Member

    Joined:
    Apr 10, 2015
    Posts:
    264
    Minecraft User:
    iZenith_xPr
    not items but entities ) mob!
  4. Svile
    Offline

    Svile Active Member

    Joined:
    Mar 30, 2015
    Posts:
    239
    Minecraft User:
    svile
    this plugin also kills mobs
  5. iDirtPlayzMC
    Offline

    iDirtPlayzMC Active Member

    Joined:
    Apr 10, 2015
    Posts:
    264
    Minecraft User:
    iZenith_xPr
    wait nvm you are right
  6. Svile
    Offline

    Svile Active Member

    Joined:
    Mar 30, 2015
    Posts:
    239
    Minecraft User:
    svile
    PHP:
    foreach($this->getServer()->getLevels() as $level) {
          foreach(
    $level->getEntities() as $entity) {
            if(!
    $this->isEntityExempted($entity) && $entity instanceof Creature && !($entity instanceof Human)) {
              
    $entity->close();
            }
          }
        }
  7. ChiefArtz
    Offline

    ChiefArtz New Member

    Joined:
    Dec 4, 2015
    Posts:
    12
    Minecraft User:
    ChiefArtz

Share This Page

Advertisement