Hide dropped items from some players

Discussion in 'Plugin Development' started by Pr07o7yp3, Jan 14, 2014.

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

    Pr07o7yp3

    Ok, I have started to write plugin for PVP 1 vs 1.
    But instead to make 10-15 arenas for every couple, I want to make just one arena and every couples to play in this arena. I'll hide them each other so I'll simulate every couple is alone in the arena.
    The problem are the dropped items.

    Lets see an example:
    There are 4 players. Player1 vs Player2 and Player3 vs Player4.
    Player1 can see Player2 and vice versa but they cannot see Player3 and Player4.
    So, if Player1 kill Player2, Player2 will drop some items. I just want these items to be hidden for Player3 and Player4, only Player1 to can see it.

    Is it possible? If yes I'll be very grateful if you help me. :)
     
  2. Listen to playerdeathevent and clear the drops.
     
  3. Offline

    Pr07o7yp3

    Did you read my thread?
     
  4. oh... I am afraid you could not hide items due to Bukkit's restrictions. You could do that through packets though
     
  5. Offline

    Garris0n

  6. Offline

    Deleted user

    Pr07o7yp3
    AFAIK it's not possible to hide specific entities without packets.

    However, it would be much better to
    a) Just make the drops unable to be picked up for the other players or
    b) Just make separate arenas. Once you get a large amount of players, remember that although Bukkit isn't letting the client know there's players in the arena, Bukkit still knows. Arrows will drop out of mid air, and sword hits may hit other people, and not count in the 1v1 match
     
  7. Offline

    TryB4

Thread Status:
Not open for further replies.

Share This Page