Fixed an issue with personal gates
Added default permissions
This commit is contained in:
@ -754,7 +754,10 @@ public class Portal {
|
||||
// Check if the player can create gates on this network
|
||||
if (!Stargate.canCreate(player, network)) {
|
||||
Stargate.debug("createPortal", "Player doesn't have create permissions on network. Trying personal");
|
||||
network = player.getName().substring(0, 11);
|
||||
network = player.getName();
|
||||
if (network.length() > 11) {
|
||||
network = network.substring(0, 11);
|
||||
}
|
||||
|
||||
// Check if we can create a gate on our own network
|
||||
if (!Stargate.canCreate(player, network)) {
|
||||
|
@ -432,7 +432,9 @@ public class Stargate extends JavaPlugin {
|
||||
if (hasPerm(player, "stargate.create.network." + network)) return true;
|
||||
|
||||
// Check if this is a personal gate, and if the player has create.personal
|
||||
if (player.getName().substring(0, 11).equalsIgnoreCase(network) && hasPerm(player, "stargate.create.personal")) return true;
|
||||
String pNet = player.getName();
|
||||
if (pNet.length() > 11) pNet = pNet.substring(0, 11);
|
||||
if (pNet.equalsIgnoreCase(network) && hasPerm(player, "stargate.create.personal")) return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -1,10 +1,29 @@
|
||||
name: Stargate
|
||||
main: net.TheDgtl.Stargate.Stargate
|
||||
version: 0.6.1
|
||||
version: 0.6.2
|
||||
description: Stargate mod for Bukkit
|
||||
author: Drakia
|
||||
website: http://www.thedgtl.net
|
||||
commands:
|
||||
sg:
|
||||
description: Used to reload the plugin. Console use only.
|
||||
usage: /<command> reload - Used to reload the plugin. Console use only.
|
||||
usage: /<command> reload - Used to reload the plugin. Console use only.
|
||||
permissions:
|
||||
stargate.use:
|
||||
description: Allow use of all gates linking to any world in any network
|
||||
default: true
|
||||
stargate.create:
|
||||
description: Allow creating gates on any network
|
||||
default: op
|
||||
stargate.destroy:
|
||||
description: Allow destruction gates on any network
|
||||
default: op
|
||||
stargate.free:
|
||||
description: Allow free use/creation/destruction of gates
|
||||
default: op
|
||||
stargate.option:
|
||||
description: Allow use of all options
|
||||
default: op
|
||||
stargate.admin:
|
||||
description: Allow all admin features (Hidden/Private only so far)
|
||||
default: op
|
Reference in New Issue
Block a user