TP+

TP+

222k Downloads

tpp command not usable in command block

Aethersound opened this issue ยท 8 comments

commented
    Mod Version: TP+ -1.12.2-1.0.0.0

Minecraft Version: 1.12 & 1.12.2
Forge Version: 14.21.1.2443 - 1.12
14.23.1.2562 - 1.12.2

Issue:
I tried using the tpp command in a command block, and it came up with an error saying that the command block did not have permission to use that command.

commented

nah, it's a pretty major issue, considering command blocks are like the main use case i had in mind for this in the first place

commented

Double-checking, did it say specifically "/tpp cannot be run from the server!"?

commented

I have a world open to Lan, and this is the error I get on the command block itself:

This is in 1.12 Minecraft just to note:
https://gyazo.com/d527850e6e8f511b9c2fbbe7c39d84a3

EDIT: I am in creative mode if that helps at all.

commented

Can you try using the command yourself? It might be because cheats or off or because it doesn't properly check for permissions, so I wanna see if using it as a player works.

commented

I ran though each different gamemode, using the command myself, and it worked each time. (Survival,Creative,Adventure)

I also went in each gamemode and tried using the command block with the command and it gave the same error message.

commented

Hm, definitely something with the command block as an executor then. I'll see what I can do.

commented

Thank you very much, i'm sorry if this is a bother.

commented

okay i finally got around to looking at this and it's a ridiculously easy fix, i just didn't realize i had to implement getRequiredPermissionLevel (which returns 4 by default, which apparently means "opped players can do it but command blocks can't" which is a little weird but whatev, i gave it 2 instead, the same level as the vanilla tp command)

pushing an update in just a sec here