03.04.2016, 04:08
Oh, I see, it's ok then.
And I have two questions?
It's secure to do the follwing?
I mean, what happens if the player disconnects before the interval?
Do I need the .isOnline condition?
And the last question, how do I get all the commands from a specific class? I have tried do the following but I think it is not the correct way
And I have two questions?
It's secure to do the follwing?
Код:
public void onPlayerSpawn(Player player){ Timer.create(2500, 1, (inverval) ->{ player.setLocation(289.511F, -1873.112F, 6.402F); if(player.isOnline()){ player.setCameraBehind(); player.spawn(); if(player.getLocation().getZ() >= 5.0F){ Maps.removerObjects(player); } } }).start(); }
Do I need the .isOnline condition?
And the last question, how do I get all the commands from a specific class? I have tried do the following but I think it is not the correct way
Код:
commandM.getCommandEntries("SpecialCommands")