Chunk loading entitys

Discussion in 'Plugin Development' started by MCCoding, Feb 28, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    MCCoding

    I'm trying to check if there is an event that triggers when a chunk adds entitys to itself. before you say just just check the entitys in the chunk when it loads it won't work. What I mean is if you are far away from a chunk then go to a players chunk it's the point on when chunk adds the existing entitys to the already loaded chunk. I think it's client side by I'm not sure any help is appreciated.
     
  2. Offline

    Skionz

    @MCCoding If you don't find a solution you can always listen for outgoing packets.
     
  3. Offline

    Zombie_Striker

    @MCCoding One event that does get fired is the EntitySpawnEvent, you would have to keep a map of the newly loaded chunks and remove them after a period of time though.
     
  4. Offline

    MCCoding

    @Zombie_Striker
    That won't work since the entity is already spawned I do believe that there has to be a packet sent to load up the existing entity.

    @Skionz do you know what packet it is?
     
  5. Offline

    Skionz

  6. Offline

    MCCoding

    @Skionz
    I have been but I don't see anything that would relate to loading existing entitys from a chunk
     
  7. Offline

    Skionz

    @MCCoding Look for a packet sent when a mob spawns.
     
  8. Offline

    MCCoding

    @Skionz
    But would that work since the mob already exists and only specific players who are loading up the world on the client side are loading the mobs in?
     
  9. Offline

    Skionz

    @MCCoding I'm not sure, but most likely. You would have too check.
     
Thread Status:
Not open for further replies.

Share This Page