Examples of MapProperties


Examples of ch.rakudave.jnetmap.view.properties.MapProperties

    menu.add(new JSeparator());
      i = new JMenuItem(new AbstractAction(Lang.getNoHTML("menu.file.properties"), Icons.get("properties")) {
        @Override
        public void actionPerformed(ActionEvent e) {
          if (Controller.getCurrentMap() == null) return;
          new MapProperties((Frame) Controller.getView(), Controller.getCurrentMap());
        }
      }); menu.add(i);
      i.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_P, InputEvent.CTRL_DOWN_MASK | InputEvent.SHIFT_DOWN_MASK));
    menu.add(new JSeparator());
    // Quit
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

    int mapHeight = root.getIntAttribute("height", 0);
    int tileWidth = root.getIntAttribute("tilewidth", 0);
    int tileHeight = root.getIntAttribute("tileheight", 0);
    String mapBackgroundColor = root.getAttribute("backgroundcolor", null);

    MapProperties mapProperties = map.getProperties();
    if (mapOrientation != null) {
      mapProperties.put("orientation", mapOrientation);
    }
    mapProperties.put("width", mapWidth);
    mapProperties.put("height", mapHeight);
    mapProperties.put("tilewidth", tileWidth);
    mapProperties.put("tileheight", tileHeight);
    if (mapBackgroundColor != null) {
      mapProperties.put("backgroundcolor", mapBackgroundColor);
    }
    mapTileWidth = tileWidth;
    mapTileHeight = tileHeight;
    mapWidthInPixels = mapWidth * tileWidth;
    mapHeightInPixels = mapHeight * tileHeight;
 
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

      }

      TextureRegion texture = imageResolver.getImage(image.path());

      TiledMapTileSet tileset = new TiledMapTileSet();
      MapProperties props = tileset.getProperties();
      tileset.setName(name);
      props.put("firstgid", firstgid);
      props.put("imagesource", imageSource);
      props.put("imagewidth", imageWidth);
      props.put("imageheight", imageHeight);
      props.put("tilewidth", tilewidth);
      props.put("tileheight", tileheight);
      props.put("margin", margin);
      props.put("spacing", spacing);

      int stopWidth = texture.getRegionWidth() - tilewidth;
      int stopHeight = texture.getRegionHeight() - tileheight;

      int id = firstgid;
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

    int mapHeight = root.getIntAttribute("height", 0);
    int tileWidth = root.getIntAttribute("tilewidth", 0);
    int tileHeight = root.getIntAttribute("tileheight", 0);
    String mapBackgroundColor = root.getAttribute("backgroundcolor", null);

    MapProperties mapProperties = map.getProperties();
    if (mapOrientation != null) {
      mapProperties.put("orientation", mapOrientation);
    }
    mapProperties.put("width", mapWidth);
    mapProperties.put("height", mapHeight);
    mapProperties.put("tilewidth", tileWidth);
    mapProperties.put("tileheight", tileHeight);
    if (mapBackgroundColor != null) {
      mapProperties.put("backgroundcolor", mapBackgroundColor);
    }
    mapTileWidth = tileWidth;
    mapTileHeight = tileHeight;
    mapWidthInPixels = mapWidth * tileWidth;
    mapHeightInPixels = mapHeight * tileHeight;
 
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

  }

  @Override
  public MapProperties getProperties () {
    if (properties == null) {
      properties = new MapProperties();
    }
    return properties;
  }
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

      }

      TextureRegion texture = imageResolver.getImage(image.path());

      TiledMapTileSet tileset = new TiledMapTileSet();
      MapProperties props = tileset.getProperties();
      tileset.setName(name);
      props.put("firstgid", firstgid);
      props.put("imagesource", imageSource);
      props.put("imagewidth", imageWidth);
      props.put("imageheight", imageHeight);
      props.put("tilewidth", tilewidth);
      props.put("tileheight", tileheight);
      props.put("margin", margin);
      props.put("spacing", spacing);

      int stopWidth = texture.getRegionWidth() - tilewidth;
      int stopHeight = texture.getRegionHeight() - tileheight;

      int id = firstgid;
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

    int mapHeight = root.getIntAttribute("height", 0);
    int tileWidth = root.getIntAttribute("tilewidth", 0);
    int tileHeight = root.getIntAttribute("tileheight", 0);
    String mapBackgroundColor = root.getAttribute("backgroundcolor", null);

    MapProperties mapProperties = map.getProperties();
    if (mapOrientation != null) {
      mapProperties.put("orientation", mapOrientation);
    }
    mapProperties.put("width", mapWidth);
    mapProperties.put("height", mapHeight);
    mapProperties.put("tilewidth", tileWidth);
    mapProperties.put("tileheight", tileHeight);
    if (mapBackgroundColor != null) {
      mapProperties.put("backgroundcolor", mapBackgroundColor);
    }

    mapTileWidth = tileWidth;
    mapTileHeight = tileHeight;
    mapWidthInPixels = mapWidth * tileWidth;
 
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

          trackedTextures.add(texture);
        }
      }

      TiledMapTileSet tileset = new TiledMapTileSet();
      MapProperties props = tileset.getProperties();
      tileset.setName(name);
      props.put("firstgid", firstgid);
      props.put("imagesource", imageSource);
      props.put("imagewidth", imageWidth);
      props.put("imageheight", imageHeight);
      props.put("tilewidth", tilewidth);
      props.put("tileheight", tileheight);
      props.put("margin", margin);
      props.put("spacing", spacing);

      for (AtlasRegion region : atlas.findRegions(regionsName)) {
        // handle unused tile ids
        if (region != null) {
          StaticTiledMapTile tile = new StaticTiledMapTile(region);
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

    int mapHeight = root.getIntAttribute("height", 0);
    int tileWidth = root.getIntAttribute("tilewidth", 0);
    int tileHeight = root.getIntAttribute("tileheight", 0);
    String mapBackgroundColor = root.getAttribute("backgroundcolor", null);

    MapProperties mapProperties = map.getProperties();
    if (mapOrientation != null) {
      mapProperties.put("orientation", mapOrientation);
    }
    mapProperties.put("width", mapWidth);
    mapProperties.put("height", mapHeight);
    mapProperties.put("tilewidth", tileWidth);
    mapProperties.put("tileheight", tileHeight);
    if (mapBackgroundColor != null) {
      mapProperties.put("backgroundcolor", mapBackgroundColor);
    }
    mapWidthInPixels = mapWidth * tileWidth;
    mapHeightInPixels = mapHeight * tileHeight;

    Element properties = root.getChildByName("properties");
View Full Code Here

Examples of com.badlogic.gdx.maps.MapProperties

      }

      TextureRegion texture = imageResolver.getImage(image.path());

      TiledMapTileSet tileset = new TiledMapTileSet();
      MapProperties props = tileset.getProperties();
      tileset.setName(name);
      props.put("firstgid", firstgid);
      props.put("imagesource", imageSource);
      props.put("imagewidth", imageWidth);
      props.put("imageheight", imageHeight);
      props.put("tilewidth", tilewidth);
      props.put("tileheight", tileheight);
      props.put("margin", margin);
      props.put("spacing", spacing);

      int stopWidth = texture.getRegionWidth() - tilewidth;
      int stopHeight = texture.getRegionHeight() - tileheight;

      int id = firstgid;
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.