Skip to content

Commit

Permalink
Prep code for block list retrieval, list doesn't seem worthwhile at t…
Browse files Browse the repository at this point in the history
…he moment.
  • Loading branch information
Talamar1 committed Jun 21, 2015
1 parent 6a29b37 commit 5c5d880
Showing 1 changed file with 9 additions and 1 deletion.
Expand Up @@ -5,7 +5,6 @@
import net.aufdemrand.denizen.objects.dEntity;
import net.aufdemrand.denizen.utilities.DenizenAPI;
import net.aufdemrand.denizencore.objects.Element;
import net.aufdemrand.denizencore.objects.dList;
import net.aufdemrand.denizencore.objects.dObject;
import net.aufdemrand.denizencore.scripts.ScriptEntryData;
import net.aufdemrand.denizencore.scripts.containers.ScriptContainer;
Expand Down Expand Up @@ -45,6 +44,7 @@ public EntityCreatePortalScriptEvent() {
public dEntity entity;
public Element entity_type;
public Element portal_type;
// public dList blocks;
public EntityCreatePortalEvent event;

@Override
Expand Down Expand Up @@ -103,6 +103,7 @@ public HashMap<String, dObject> getContext() {
context.put("entity", entity);
context.put("entity_type", entity_type);
context.put("portal_type", portal_type);
// context.put("blocks", blocks);
return context;
}

Expand All @@ -111,6 +112,13 @@ public void onEntityCreatesPortal(EntityCreatePortalEvent event) {
entity = new dEntity(event.getEntity());
entity_type = new Element(event.getEntityType().toString());
portal_type = new Element(event.getPortalType().toString());
/*
blocks = new dList();
for (int i=0; i < event.getBlocks().size(); i++) {
dLocation tempLoc = new dLocation(event.getBlocks().get(i).getBlock().getLocation());
blocks.add(tempLoc.identifySimple());
}
*/
cancelled = event.isCancelled();
this.event = event;
fire();
Expand Down

0 comments on commit 5c5d880

Please sign in to comment.