Can you change a monsters "enemies"?

Discussion in 'Plugin Development' started by rApp, Mar 21, 2011.

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

    rApp

    Hi!
    I was thinking of adding a new feature to my plugin and i was wondering if there is a way to give lets say a specific monster its enemies?

    Lets say the admin can spawn a zombie, can you make this zombie not attacking the admin? (Or its "spawner" if you will)
     
  2. Offline

    Edward Hand

    creatures have a setTarget and getTarget method for setting and getting what the creature is targetting. There's also an EntityTargetEvent which is triggered when an entities target changes. Using those three things it should be possible to control entity targeting as you require.
     
  3. Offline

    rApp

    Nice, im at school right now but i will have a go for it when i get home!

    Thanks! :D
     
Thread Status:
Not open for further replies.

Share This Page