Package megamek.common

Examples of megamek.common.Hex


                theme = st.sval;
                st.nextToken();
                imageName = st.sval;
                // add to list
                if (base) {
                    bases.add(new HexEntry(new Hex(elevation, terrain, theme),
                            imageName));
                } else {
                    supers.add(new HexEntry(new Hex(elevation, terrain, theme),
                            imageName));
                }
            }
        }
        r.close();
View Full Code Here


                theme = st.sval;
                st.nextToken();
                imageName = st.sval;
                // add to list
                if (base) {
                    bases.add(new HexEntry(new Hex(elevation, terrain, theme),
                            imageName));
                } else {
                    supers.add(new HexEntry(new Hex(elevation, terrain, theme),
                            imageName));
                }
            }
        }
        r.close();
View Full Code Here

                * mapSettings.getBoardHeight()];
        int index = 0;
        for (int h = 0; h < mapSettings.getBoardHeight(); h++) {
            for (int w = 0; w < mapSettings.getBoardWidth(); w++) {
                if(mapSettings.getMedium() == MapSettings.MEDIUM_SPACE) {
                    nb[index++] = new Hex(0,"space:1",mapSettings.getTheme());
                } else {
                    nb[index++] = new Hex(elevationMap[w][h], "", mapSettings
                            .getTheme());
                }
            }
        }

View Full Code Here

        bnd.setVisible(true);

        if (bnd.getX() > 0 || bnd.getY() > 0) {
            final IHex[] newHexes = new IHex[bnd.getX() * bnd.getY()];
            for (int i = 0; i < newHexes.length; i++) {
                newHexes[i] = new Hex();
            }
            board.newData(bnd.getX(), bnd.getY(), newHexes);
            curpath = null;
            curfile = null;
            frame.setTitle(Messages.getString("BoardEditor.title")); //$NON-NLS-1$
View Full Code Here

                // Get the theme of the hex (if any).
                attrStr = child.getAttribute("theme");

                // Construct the hex.
                retVal = new Hex(attrVal, terrains, attrStr);

            } // End found-"terrains"-node

        } // Look at the next child.
View Full Code Here

TOP

Related Classes of megamek.common.Hex

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.