Package com.ardor3d.extension.ui

Examples of com.ardor3d.extension.ui.UIContainer


    protected void updateLogicalLayer(final ReadOnlyTimer timer) {
        hud.getLogicalLayer().checkTriggers(timer.getTimePerFrame());
    }

    private void resetBalls(final int ballCount) {
        final UIContainer container = _ballFrame.getContentPanel();
        container.setLayout(null);
        container.detachAllChildren();

        balls = new BallComponent[ballCount];

        // Create a texture for our balls to use.
        final SubTex tex = new SubTex(TextureManager.load("images/ball.png",
                Texture.MinificationFilter.NearestNeighborNoMipMaps, TextureStoreFormat.GuessCompressedFormat, true));

        // Add balls
        for (int i = 0; i < balls.length; i++) {
            final BallComponent ballComp = new BallComponent("ball", tex, Ball.radius * 2, Ball.radius * 2, container
                    .getContentWidth(), container.getContentHeight());
            container.add(ballComp);
            balls[i] = ballComp;
        }

        _ballFrame.setTitle("Bubbles  - " + ballCount + " balls");
    }
View Full Code Here

TOP

Related Classes of com.ardor3d.extension.ui.UIContainer

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.