1
Knock a player off of a block
I would like to knock players back, whenever they step on a block. Is this possible? How would I do it?
Create an account or sign in to comment.
14
2
use squidmanns method if you want to knock players off any block with the same id...
use
/execute @a[x=#,y=#,z=#,r=0] ~ ~ ~ /tp @p ~ ~ ~1
to knockoff any player on one location....
use
/execute @a[x=#,y=#,z=#,r=0] ~ ~ ~ /tp @p ~ ~ ~1
to knockoff any player on one location....
2
Well, my final solution was a Slime with NoAI.
2
just do a playernear command block so whenever players get on that block this happens, then just make it spawn an arrow entity on them
2
you could tp the player from that block one block back and add damage effect for 1 sec.
2
Make a clock and add a command block with the command /execute @a ~ ~ ~ detect ~ ~-1 ~ wool 14 /tp @p ~1 ~ ~ In this case if anyone steps on red wool they will be teleported 1 block in the positive x direction. Change the block to any block you want but make sure to include a data value or else the command wont work. It may not look like your actually getting "knocked" off the block but its the simplest way of doing it.
2
I would suggest summoning an arrow to hit them off the platform. That way you can control the direction, as well as the timing. Something like this should work pretty well:
execute @p ~ ~ ~ summon Arrow ~1 ~ ~ {Motion:[1.0,0.0,0.0]}
You can change who you target by editing the @p, and you can change the direction by changing the spawn coordinates and the arrow's motion.2
Spawn a snowball in that hits the player?
2
You could try making an execute command at the player which spawns an arrow with nbt data that makes it travel towards the player? (u can make it spawn like 0.1 to the side so he gets knocked of but u can't see it) And if this doesn't work (not enough knock back force) you could try summoning a invisible mob around them or something ?
2
i might be pointing out the obvious here, and this might sound stupid to you seasoned redstone veterans, but if it's not to a wall cant you put a piston in the wall and a pressure plate on the block and rig the plate to the piston to push the player off?
2
[deleted]
2
[deleted]
2
For Spigot servers: Skript
on any move:
loop players in radius 1 around the player
push loop-player backwards at speed 1.0
2
Like I said, it's a vanilla server and I would like to do it with command blocks.
07/07/2015 3:31 pm
This reply was removed by the poster or a moderator.
2
Sorry if I stated it wrong. I meant to do this with command blocks. Like when the player stands on a block, the command block will activate and knock the player off of the block, as if a mob hit it, but actually there is no mob. I have tried summoning a zombie on the block but that hits all players around the block that is not on the block. Oh and it is a vanilla server.