Package com.badlogic.gdx.scenes.scene2d.ui

Examples of com.badlogic.gdx.scenes.scene2d.ui.Skin


    super.render();
  }
 
  public Skin getSkin() {
        if(skin == null ) {
            skin = new Skin(Gdx.files.internal("ui/uiskin.json"));
        }
        return skin;
   
View Full Code Here


  }

  @Override
  public void show() {
    batch = new SpriteBatch();
    skin = new Skin();
    atlas = new TextureAtlas("data/buttons/button.pack");
    skin.addRegions(atlas);
    bonzai = new BitmapFont(Gdx.files.internal("data/fonts/bonzai32.fnt"),
        Gdx.files.internal("data/fonts/bonzai32.png"), false);
  }
View Full Code Here

  @Override
  public void show() {
    batch = new SpriteBatch();
    atlas = new TextureAtlas("data/button.pack");
    skin = new Skin();
    skin.addRegions(atlas);
    white = new BitmapFont(Gdx.files.internal("data/whitefont.fnt"), false);
    black = new BitmapFont(Gdx.files.internal("data/font.fnt"), false);
  }
View Full Code Here

    if (parameter == null)
      textureAtlasPath = file.pathWithoutExtension() + ".atlas";
    else
      textureAtlasPath = parameter.textureAtlasPath;
    TextureAtlas atlas = manager.get(textureAtlasPath, TextureAtlas.class);
    return new Skin(file, atlas);
  }
View Full Code Here

    setScreen(new SplashScreen(this));
  }

    public Skin getSkin() {
        if (skin == null)
            skin = new Skin(Gdx.files.internal("ui/uiskin.json"));

        return skin;
    }
View Full Code Here

      assetManager.setLoader(ParticleEffect.class, new ParticleEffectLoader(new AbsoluteFileHandleResolver()));
      assetManager.get(DEFAULT_MODEL_PARTICLE, Model.class).materials.get(0).set(new BlendingAttribute(GL20.GL_ONE, GL20.GL_ONE_MINUS_SRC_ALPHA, 1));
     
      //Ui
      stringBuilder = new StringBuilder();
      Skin skin = assetManager.get(DEFAULT_SKIN, Skin.class);
      ui = new Stage();
      fpsLabel = new Label("", skin);
      pointCountLabel = new Label("", skin);
      billboardCountLabel = new Label("", skin);
      modelInstanceCountLabel = new Label("", skin);
View Full Code Here

    font.dispose();
  }
 
  public Skin getSkin() {
    if(skin == null ) {
            skin = new Skin(Gdx.files.internal("ui/uiskin.json"));
        }
        return skin;
  }
View Full Code Here

    if (parameter == null)
      texturePath = Gdx.files.internal(fileName).nameWithoutExtension() + ".png";
    else
      texturePath = parameter.texturePath;
    Texture texture = manager.get(texturePath, Texture.class);
    return new Skin(resolve(fileName), texture);
  }
View Full Code Here

  public Actor newWidget (TableLayout layout, String className) {
    try {
      return super.newWidget(layout, className);
    } catch (RuntimeException ex) {
      Skin skin = layout.skin;
      if (skin != null) {
        if (skin.hasResource(className, TextureRegion.class))
          return new Image(skin.getRegion(className));
        if (skin.hasResource(className, NinePatch.class)) return new Image(skin.getPatch(className));
      }
      if (layout.assetManager != null && layout.assetManager.isLoaded(className, Texture.class))
        return new Image(new TextureRegion(layout.assetManager.get(className, Texture.class)));
      throw ex;
    }
View Full Code Here

  }

  public void create() {
  batch = new SpriteBatch();
  MASTER_STAGE = new Stage(new StretchViewport(Gdx.graphics.getWidth(), Gdx.graphics.getHeight()));
  Skin MASTERSKIN = new Skin(Gdx.files.internal("uiskin.json"));
  fps = new Label("FPS: ", MASTERSKIN);
  Table tmp = new Table();
  tmp.setFillParent(true);
  tmp.top().left();
  tmp.add(fps);
View Full Code Here

TOP

Related Classes of com.badlogic.gdx.scenes.scene2d.ui.Skin

Copyright © 2018 www.massapicom. 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.