Examples of PortalManager


Examples of com.onarandombox.MultiversePortals.utils.PortalManager

        if (event.isCancelled()) {
            this.plugin.log(Level.FINE, "This Portal event was already cancelled.");
            return;
        }
        this.plugin.log(Level.FINER, "onPlayerPortal called!");
        PortalManager pm = this.plugin.getPortalManager();
        Location playerPortalLoc = event.getPlayer().getLocation();
        // Determine if we're in a portal
        MVPortal portal = pm.getPortal(event.getPlayer(), playerPortalLoc);
        Player p = event.getPlayer();
        // Even if the location was null, we still have to see if
        // someone wasn't exactly on (because they can do this).
        if (portal == null) {
            // Check around the player to make sure
            playerPortalLoc = this.plugin.getCore().getSafeTTeleporter().findPortalBlockNextTo(event.getFrom());
            if (playerPortalLoc != null) {
                this.plugin.log(Level.FINER, "Player was outside of portal, The location has been successfully translated.");
                portal = pm.getPortal(event.getPlayer(), playerPortalLoc);
            }
        }
        if (portal != null) {
            this.plugin.log(Level.FINER, "There was a portal found!");
            MVDestination portalDest = portal.getDestination();
View Full Code Here

Examples of com.onarandombox.MultiversePortals.utils.PortalManager

    public void blockPhysics(BlockPhysicsEvent event) {
        if (event.isCancelled()) {
            return;
        }
        if (event.getChangedType() == Material.PORTAL || event.getBlock().getType() == Material.PORTAL) {
            PortalManager pm = this.plugin.getPortalManager();
            if (pm.isPortal(event.getBlock().getLocation())) {
                event.setCancelled(true);
            }
        }
    }
View Full Code Here

Examples of com.onarandombox.MultiversePortals.utils.PortalManager

        this.registerCommands();

        // Ensure permissions are created
        this.createDefaultPerms();

        this.portalManager = new PortalManager(this);
        this.portalSessions = new HashMap<String, PortalPlayerSession>();
        this.getCore().getDestFactory().registerDestinationType(PortalDestination.class, "p");
        this.getCore().getDestFactory().registerDestinationType(RandomPortalDestination.class, "rp");

        this.loadPortals();
View Full Code Here

Examples of com.onarandombox.MultiversePortals.utils.PortalManager

     * This method should be called every time a player teleports to a portal.
     *
     * @param location
     */
    public void playerDidTeleport(Location location) {
        PortalManager pm = this.plugin.getPortalManager();
        if (pm.getPortal(location) != null) {
            this.hasMovedOutOfPortal = false;
            return;
        }
        this.hasMovedOutOfPortal = true;
    }
View Full Code Here

Examples of org.apache.cocoon.portal.PortalManager

  public void generate()
    throws IOException, SAXException, ProcessingException {
        // start the portal rendering
        // 1. event processing
        // 2. rendering
        PortalManager pm = null;
        try {
            pm = (PortalManager)this.manager.lookup(PortalManager.ROLE);
            pm.process();
            pm.showPortal(this.xmlConsumer, this.parameters);
        } catch (ServiceException ce) {
            throw new ProcessingException("Unable to lookup portal manager.", ce);
        } finally {
            this.manager.release(pm);
        }
View Full Code Here

Examples of org.apache.cocoon.portal.PortalManager

        Map result;
        PortalService service = null;
        try {
            service = (PortalService)this.manager.lookup(PortalService.ROLE);

            PortalManager portalManager = null;
            try {
                portalManager = (PortalManager) this.manager.lookup(PortalManager.ROLE);
                portalManager.process();
            } finally {
                this.manager.release(portalManager);
            }
           
            final Request request = ObjectModelHelper.getRequest(objectModel);
View Full Code Here

Examples of org.apache.cocoon.portal.PortalManager

  public void generate()
    throws IOException, SAXException, ProcessingException {
        // start the portal rendering
        // 1. event processing
        // 2. rendering
        PortalManager pm = null;
        try {
            pm = (PortalManager)this.manager.lookup(PortalManager.ROLE);
            pm.process();
            pm.showPortal(this.xmlConsumer, this.parameters);
        } catch (ServiceException ce) {
            throw new ProcessingException("Unable to lookup portal manager.", ce);
        } finally {
            this.manager.release(pm);
        }
View Full Code Here

Examples of org.apache.cocoon.portal.PortalManager

   * @see org.apache.cocoon.generation.Generator#generate()
   */
  public void generate()
    throws IOException, SAXException, ProcessingException {
       
        PortalManager pm = null;
        try {
            pm = (PortalManager)this.manager.lookup(PortalManager.ROLE);
            pm.process();
            pm.showPortal(this.xmlConsumer, this.parameters);
        } catch (ComponentException ce) {
            throw new ProcessingException("Unable to lookup portal manager.", ce);
        } finally {
            this.manager.release(pm);
        }
View Full Code Here

Examples of org.apache.cocoon.portal.PortalManager

    throws IOException, SAXException, ProcessingException {
       
        // start the portal rendering
        // 1. event processing
        // 2. rendering
        PortalManager pm = null;
        try {
            pm = (PortalManager)this.manager.lookup(PortalManager.ROLE);
            pm.process();
            pm.showPortal(this.xmlConsumer, this.parameters);
        } catch (ServiceException ce) {
            throw new ProcessingException("Unable to lookup portal manager.", ce);
        } finally {
            this.manager.release(pm);
        }
View Full Code Here

Examples of org.apache.cocoon.portal.PortalManager

   * @see org.apache.cocoon.generation.Generator#generate()
   */
  public void generate()
    throws IOException, SAXException, ProcessingException {
       
        PortalManager pm = null;
        try {
            pm = (PortalManager)this.manager.lookup(PortalManager.ROLE);
            pm.process();
            pm.showPortal(this.xmlConsumer, this.parameters);
        } catch (ComponentException ce) {
            throw new ProcessingException("Unable to lookup portal manager.", ce);
        } finally {
            this.manager.release(pm);
        }
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.