Factions3/src/main/java/com/massivecraft/factions/cmd/CmdFactionsSetOne.java

41 lines
976 B
Java
Raw Normal View History

2011-10-09 21:57:43 +02:00
package com.massivecraft.factions.cmd;
2014-10-13 11:42:40 +02:00
import java.util.Collections;
import java.util.Set;
2014-10-13 11:42:40 +02:00
import com.massivecraft.factions.Perm;
2014-06-04 14:02:23 +02:00
import com.massivecraft.massivecore.cmd.req.ReqHasPerm;
import com.massivecraft.massivecore.cmd.req.ReqIsPlayer;
import com.massivecraft.massivecore.ps.PS;
public class CmdFactionsSetOne extends CmdFactionsSetXSimple
2011-10-09 18:35:39 +02:00
{
2013-11-11 09:31:04 +01:00
// -------------------------------------------- //
// CONSTRUCT
// -------------------------------------------- //
public CmdFactionsSetOne()
2011-10-09 18:35:39 +02:00
{
2013-11-11 09:31:04 +01:00
// Aliases
this.addAliases("o", "one");
2013-11-11 09:31:04 +01:00
// Requirements
this.addRequirements(ReqIsPlayer.get());
this.addRequirements(ReqHasPerm.get(Perm.SET_ONE.node));
}
2013-11-11 09:31:04 +01:00
// -------------------------------------------- //
// OVERRIDE
// -------------------------------------------- //
@Override
public Set<PS> getChunks()
2011-10-09 18:35:39 +02:00
{
final PS chunk = PS.valueOf(me.getLocation()).getChunk(true);
final Set<PS> chunks = Collections.singleton(chunk);
return chunks;
}
}