#How to kick people from realm with a custom message?

1 messages · Page 1 of 1 (latest)

warm bronze
#

Title. Basically just kicking someone from a realm (not banning) with a custom message?

sweet comet
#

/kick <playername> <reason>

warm bronze
#

What I mean is like

#

The kick command can't use target selectors

#

So like how do I kick people if I can't use target selectors?

sweet comet
#

Wdym???

tropic scarab
warm bronze
#

Well, obviously

#

But like

#

You can't use target selectors for /kick for obvious reasons. /kick @a wouldn't work. So I'm wondering how I'd kick people using the script API if I can't use target selectors?

#

Since player.runCommandAsync('/kick @s') wouldn't work how do I do it?

sweet comet
#

uh

tropic scarab
lime bay
#
player.runCommandAsync('kick ' + JSON.stringify(player.name))
twin ocean
#
player.runCommandAsync(`kick “${player.name}”`)
real blade
lime bay