Spawn custom player entities

Discussion in 'Plugin Development' started by Devil0s, Mar 27, 2013.

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

    Devil0s

    I want to spawn a player entity that can everything, what a player can do like chopping wood or mine ores etc..
    I took a few looks into other threads but I don't understand the whole thing.

    Do I really have to manipulate the packets or is there an easier way??
    I want to do it from scratch. I don't want use an API.

    To spawn an villager (or another "normal" NPC) is pretty easy
    Code:
            Villager villager = (Villager) spawnLocation.getWorld().spawnEntity(spawnLocation, EntityType.VILLAGER);
    
    I want to maipulate everything what a real player can do. Change the head degree or something like this.
    Can anyone explain the the whole technique. I mean not just which packets I have to edit but why I have to edit which packets.
    Why have I to fake a real connection (if I have to do that. I dont know. :D ).

    Thanks for helping. ;)
     
  2. Offline

    microgeek

    Spawning the Entity is only the start. Have fun writing a custom AI system.
     
    Codisimus likes this.
  3. Offline

    Devil0s

    I know the next step. That would be hard but not impossible (a simple AI). I know many smart guys who help me when I need help.
     
  4. Offline

    ancientart

    sorry my replay doensnt really help you but i was jw if you do learn to make custom AIs. i would love to inc it on my server if your going to share it. im making an rpg server and need better Ais lol
     
  5. Offline

    Cybermaxke

    I made a entity api so you can make on a easy way new ai, but the hard way is also good. :p
    And my code is still a bit bugged.
     
  6. Offline

    Devil0s

    1. I don't want use an API.
    2. I don't have a problem with the AI, just with the spawning, moving etc. of a player like Entity.

    Would be nice if you send me a link.
     
  7. Offline

    Technius

    Devil0s
    You'll have to manipulate packets. I haven't played around with custom player entities, but you will definitely need Spawn Named Entity(0x14) for showing your custom player entities.
     
    Devil0s likes this.
  8. Offline

    Devil0s

    Thank you. Thats the first helpful post. :D
    Why is there a different between player and monster entity? What's the different? Why didn't has Bukkit its own methode??
     
  9. Offline

    Technius

    No one really bothered to make a pull request for it, I guess.
     
Thread Status:
Not open for further replies.

Share This Page