Skip to content

Commit

Permalink
Fix to actions not firing.
Browse files Browse the repository at this point in the history
  • Loading branch information
aufdemrand committed Mar 21, 2013
1 parent 24425c1 commit 0f5f6fc
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 7 deletions.
Expand Up @@ -44,27 +44,27 @@ public String getType() {
}

public boolean contains(String path) {
return contents.contains(path);
return contents.contains(path.toUpperCase());
}

public String getString(String path) {
return contents.getString(path);
return contents.getString(path.toUpperCase());
}

public String getString(String path, String def) {
return contents.getString(path, def);
return contents.getString(path.toUpperCase(), def);
}

public List<String> getStringList(String path) {
return contents.getStringList(path);
return contents.getStringList(path.toUpperCase());
}

public ConfigurationSection getConfigurationSection(String path) {
return contents.getConfigurationSection(path);
return contents.getConfigurationSection(path.toUpperCase());
}

public void set(String path, Object object) {
contents.set(path, object);
contents.set(path.toUpperCase(), object);
}

public String getName() {
Expand Down
Expand Up @@ -16,7 +16,6 @@ public boolean check(RequirementsContext context, List<String> args) throws Requ
// Deprecated
dB.log("This command is deprecated! Use instead: valueof <proc:name_of_procedure_script>");


return false;
}
}
Expand Up @@ -8,6 +8,7 @@
import net.aufdemrand.denizen.scripts.commands.core.DetermineCommand;
import net.aufdemrand.denizen.utilities.arguments.Script;
import net.aufdemrand.denizen.utilities.arguments.aH;
import net.aufdemrand.denizen.utilities.debugging.dB;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;

Expand All @@ -27,6 +28,11 @@ public void utilTags(ReplaceableTagEvent event) {
// Get the script's name from the tag's value
Script script = aH.getScriptFrom(event.getValue());

if (script == null) {
dB.echoError("Tried to call a procedure script, but couldn't find a match!");
return;
}

// Build script entries
List<ScriptEntry> entries = script.getContainer().getBaseEntries(event.getPlayer(), event.getNPC());

Expand Down

0 comments on commit 0f5f6fc

Please sign in to comment.