How can I disguise a player as a block? I'm making a hide and seek plugin thingy and I wanna know how to disguise a player is it with packets? teleporting a falling entity??? Comphenix
4 seconds of googling I don't think so... oh yeah I didn't even use that answer from that thread. I started with making a circle and picking 1 certain place in the circle so I didn't found it on internet
I don't know much about how this could be done in Minecraft but I assume you have to go to the lower levels of the server and deny all the packets sending the position of the the hidden player to the seeker. Then just position a flying block where that hidden player is at(I'm guessing this could be done as a higher level or a lower level). If the player stays still for an amount of period, set the block to a solid then.
ok I have this now but how can I spawn only one falling block and teleport it to the player Can you please send me some code for how to do this Code: @EventHandler public void playermoveevent(PlayerMoveEvent e){ Bukkit.getWorld("world").spawnFallingBlock(e.getPlayer().getLocation(), Material.SNOW_BLOCK, (byte) 0); } EDIT by Moderator: merged posts, please use the edit button instead of double posting.
What I suggest, without having to hook into packets/dependencies. - Make all disguised players invisible to other players - Create a FallingBlock for each disguised player and keep track of this - Teleport this FallingBlock entity every tick - Keep in mind that you always have to place it like for example 0.1-0.35Y above the player, otherwise it might instantly update on the ground beneath it and won't show.
I hope you have a fun getting warned for off topic post. Funergy If you are totally serious about not using an API and reinventing the wheel (again), good luck. 1. Intercept player vis 2. Build entity 3. Send as player 4. Update 5. Redo
It wasn't really off topic. It showed that all he had to do was look it up. And Funergy it's really not worth it to go through all this trouble without doing research first.
What? I didn't even claim it as mine and I thought it was funny and demonstrated very well that just looking something up before spamming the forums is probably a good idea. It's annoying when people come to ask for help on how to use a plugin.yml without looking at the plugin tutorial page. It's the same concept. Just look it up before asking bukkit it's that simple.
JBoss925 Alright let's put it the simple way: Did your post contribute to the thread? Did it help OP solve problem? Is it an absolutely essential element to the topic? I would say what you are thinking as you read that post as a no.
Thats what I did before I posted this thread so don't say that I didn't search it on google. If you say that I can find a code that is WITHOUD protocollib and WITHOUD disguise api. If yes show me It http://lmgtfy.com/?q=bukkit code to disguise a player as a block I can't see there any answers that are withoud dependings! And then I have post it on a new thread!
Funergy OP is like "guys, help me make this thing that X has, only different, and tell me how to do it despite having perfectly good examples in their APIs" You will have to play around with sending packets - fooling the client into thinking there is a block there.
If you have no idea how to do this then I doubt you're skilled enough to create your own PacketInterceptor. There's nothing wrong with using API's and definately when it comes to protocol-stuff. Anyways, feel free to do whatever you want, no one is going to stop you but if you decide to make your own implementation then please make sure it is safe. Here are the steps to achieve what you want: - Capture the PacketPlayOutSpawnNamedEntity -> Transform it to a PacketPlayOutBlockChange - Capture the movement packets -> check if the player that moved is disguised -> if so, send a new PacketPlayOutBlockChange where you set the old block/location to air and then send another one with the updated location. If you really don't want to depend on ProtocolLib then take a look at TinyProtocol.
Arguing about this is not worth is. Let's just get over it and stop arguing because this is going nowhere.