Package net.aufdemrand.denizen.scripts.queues

Examples of net.aufdemrand.denizen.scripts.queues.ScriptQueue.start()


        // Save the queue for script referencing
        scriptEntry.addObject("created_queue", queue);

        // OK, GO!
        queue.start();
    }
}
View Full Code Here


                    if (locations.size() == 0) {
                        if (script != null) {
                            List<ScriptEntry> entries = script.getContainer().getBaseEntries(scriptEntry.entryData.clone());
                            ScriptQueue queue = InstantQueue.getQueue(ScriptQueue.getNextId(script.getContainer().getName()))
                                    .addEntries(entries);
                            queue.start();
                        }
                        scriptEntry.setFinished(true);
                        cancel();
                    }
                }
View Full Code Here

                                queue.addContext(entry.getKey(), entry.getValue());
                            }
                        }

                        // Start the queue!
                        queue.start();

                        // Check the determination
                        if (DetermineCommand.hasOutcome(id))
                            determination =  DetermineCommand.getOutcome(id);
                    }
View Full Code Here

                queue.addContext(entry.getKey(), entry.getValue());
            }
        }

        // Start the queue!
        queue.start();

        // Check the determination by asking the DetermineCommand
        if (DetermineCommand.hasOutcome(id))
            determination =  DetermineCommand.getOutcome(id);
View Full Code Here

                            queue.addDefinition("location", lastEntity.getLocation().identify());
                        else
                            queue.addDefinition("location", lastLocation.identify());
                        queue.addDefinition("pushed_entities", entityList.toString());
                        queue.addDefinition("last_entity", lastEntity.identify());
                        queue.start();
                    }
                    scriptEntry.setFinished(true);
                }
            }
        };
View Full Code Here

                            }
                        }
                        queue.addDefinition("hit_entities", hitEntities.identify());

                        // Start it!
                        queue.start();
                    }

                    scriptEntry.setFinished(true);
                }
                else {
View Full Code Here

        List<ScriptEntry> listOfEntries = getBaseEntries(new BukkitScriptEntryData(player, npc));
        if (context != null)
            ScriptBuilder.addObjectToEntries(listOfEntries, "context", context);
        queue.addEntries(listOfEntries);
        queue.start();
        return queue;
    }

    public Map<String, Integer> getContextMap() {
        if (contains("CONTEXT")) {
View Full Code Here

        List<ScriptEntry> listOfEntries = getBaseEntries(new BukkitScriptEntryData(player, npc));
        if (context != null)
            ScriptBuilder.addObjectToEntries(listOfEntries, "context", context);
        queue.addEntries(listOfEntries);
        queue.delayUntil(System.currentTimeMillis() + (long) (delay.getSeconds() * 1000));
        queue.start();
        return queue;
    }

    public ScriptQueue injectTaskScript(String queueId, dPlayer player, dNPC npc, Map<String, String> context) {
        ScriptQueue queue = ScriptQueue._getExistingQueue(queueId);
View Full Code Here

        ScriptQueue queue = ScriptQueue._getExistingQueue(queueId);
        List<ScriptEntry> listOfEntries = getBaseEntries(new BukkitScriptEntryData(player, npc));
        if (context != null)
            ScriptBuilder.addObjectToEntries(listOfEntries, "context", context);
        queue.injectEntries(listOfEntries, 0);
        queue.start();
        return queue;
    }
}
View Full Code Here

        if (context != null) {
            for (Map.Entry<String, dObject> entry : context.entrySet()) {
                queue.addContext(entry.getKey(), entry.getValue());
            }
        }
        queue.start();
        return queue;
    }

    public boolean runAllowedHelpProcedure(dPlayer player, dNPC npc, Map<String, dObject> context) {
        // Add the reqId to each of the entries for the determine command
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.