亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? bush.java

?? 用java開發(fā)的一個實施策略游戲源碼 值得學(xué)習(xí)一下
?? JAVA
字號:
/*
	Netwar
	Copyright (C) 2002  Daniel Grund, Kyle Kakligian, Jason Komutrattananon, & Brian Hibler.
 
	This file is part of Netwar.
 
	Netwar is free software; you can redistribute it and/or modify
	it under the terms of the GNU General Public License as published by
	the Free Software Foundation; either version 2 of the License, or
	(at your option) any later version.
 
	Netwar is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	GNU General Public License for more details.
 
	You should have received a copy of the GNU General Public License
	along with Netwar; if not, write to the Free Software
	Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */

package netwar.game.object;
import netwar.game.*;
import netwar.utils.*;
import netwar.utils.vectorgraphics.*;

/** Palm tree object. Destroyable obstacle.
 * @author Group N2 - Project Netwar
 * @author Kyle Kakligian
 */
public class Bush extends netwar.game.GameObject {
    // colors
    private static java.awt.Color ltgreen = new java.awt.Color(0, 192, 0);
    private static java.awt.Color drgreen = new java.awt.Color(64, 96, 0);
    // point list
    protected static SelfConvertingPoint _pts[] = {
        new SelfConvertingPoint(0,         0,        0),
        new SelfConvertingPoint(-1.20000, -0.75000, 3.45000),
        new SelfConvertingPoint(-1.20000, -2.22580, 2.62082),
        new SelfConvertingPoint( 0.20357, -1.20605, 2.62082),
        new SelfConvertingPoint(-1.70988, -2.31924, 1.95000),
        new SelfConvertingPoint(-0.26746,  2.09395, 2.47082),
        new SelfConvertingPoint( 1.46746,  2.09395, 2.47082),
        new SelfConvertingPoint( 1.42500,  0.63194, 3.07598),
        new SelfConvertingPoint( 1.93488,  1.33373, 2.58860),
        new SelfConvertingPoint(-3.05357, -0.45605, 2.02082),
        new SelfConvertingPoint(-2.51746,  1.19395, 2.02082),
        new SelfConvertingPoint(-3.05357,  0.45605, 0.67918),
        new SelfConvertingPoint(-2.15988,  1.56924, 1.35000),
        new SelfConvertingPoint( 3.35357, -0.45605, 1.27082),
        new SelfConvertingPoint(-0.86746,  2.54395, 0.97082),
        new SelfConvertingPoint( 0.65478,  2.38584, 1.20125),
        new SelfConvertingPoint( 2.03087,  1.38403, 1.37762),
        new SelfConvertingPoint(-0.86185,  1.34196, 1.49583),
        new SelfConvertingPoint(-0.62304,  0.51415, 2.66026),
        new SelfConvertingPoint( 0.21454, -0.41681, 2.52585),
        new SelfConvertingPoint(-0.90018, -1.94722, 1.07329),
        new SelfConvertingPoint(-0.04841, -1.73228, 1.57598),
        new SelfConvertingPoint(-2.20240,  0.17948, 0.00000),
        new SelfConvertingPoint( 3.34632,  0.51029, 0.00000),
        new SelfConvertingPoint(-1.12584, -1.97007, 0.00000),
        new SelfConvertingPoint( 0.66979, -2.30141, 0.00000),
        new SelfConvertingPoint(-0.62976,  2.75424, 0.00000)};

    protected static CoherentPointSet points = new CoherentPointSet(_pts.length);
    protected static GraphicThing appearance= null;
    protected VirtualCoherentGraphicThing myAppearance;;

    /** Creates a new instance of PineTree */
    public Bush() {
    }
	
    /** Initialize the Point3Ds used for this Base.
     * These are the location of the ground-center of the Base in game-space, and
     * the relative locations of the triangle/line vertices relative to that point.
     */
    protected void createVectors() {
        vr = new Point3D[1];
        vr[0] = Hex.getMapPoint(x,y);
        
        if(appearance == null) {
            appearance = new OrderedGraphicSet( new GraphicTriangle( _pts[19], _pts[ 3], _pts[ 21], drgreen), _pts.length); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[11], _pts[ 22], _pts[ 9], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[22], _pts[ 20], _pts[ 4], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[9], _pts[ 22], _pts[ 4], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[16], _pts[ 8], _pts[ 7], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[5], _pts[ 15], _pts[ 17], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[16], _pts[ 6], _pts[ 8], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[15], _pts[ 6], _pts[ 16], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[12], _pts[ 17], _pts[ 22], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[11], _pts[ 12], _pts[ 22], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[10], _pts[ 12], _pts[ 11], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[26], _pts[ 16], _pts[ 23], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[23], _pts[ 16], _pts[ 13], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[23], _pts[ 13], _pts[ 25], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[20 ], _pts[24], _pts[ 25], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[20], _pts[ 22], _pts[ 24], drgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[14], _pts[ 26], _pts[ 22], drgreen), false); 

            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[1], _pts[ 9], _pts[ 4], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[2], _pts[ 1], _pts[ 4], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[19], _pts[ 18], _pts[ 1], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[19], _pts[ 1], _pts[ 3], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[3], _pts[ 1], _pts[ 2], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[21], _pts[ 3], _pts[ 2], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[20], _pts[ 21], _pts[ 4], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[21], _pts[ 2], _pts[ 4], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[7], _pts[ 18], _pts[ 19], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[7], _pts[ 5], _pts[ 18], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[6], _pts[ 5], _pts[ 7], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[8], _pts[ 6], _pts[ 7], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[5], _pts[ 17], _pts[ 18], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[18], _pts[ 17], _pts[ 1], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[6], _pts[ 15], _pts[ 5], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[26], _pts[ 15], _pts[ 16], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[26], _pts[ 14], _pts[ 15], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[10], _pts[ 9], _pts[ 1], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[17], _pts[ 10], _pts[ 1], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[10], _pts[ 11], _pts[ 9], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[17], _pts[ 12], _pts[ 10], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[16], _pts[ 7], _pts[ 13], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[13], _pts[ 7], _pts[ 25], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[21], _pts[ 20], _pts[ 25], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[7], _pts[ 21], _pts[ 25], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[7], _pts[ 19], _pts[ 21], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[17], _pts[ 14], _pts[ 22], ltgreen), false); 
            ((OrderedGraphicSet)appearance).add(new GraphicTriangle( _pts[15], _pts[ 14], _pts[ 17], ltgreen), false); 
            
            for(int t = 0; t < _pts.length; t++)
                points.add(_pts[t]);
        }
        if(netwar.Mapper.theApp != null) myAppearance = new VirtualCoherentGraphicThing(appearance, points, vr[0], (new java.util.Random()).nextInt(360));
        else myAppearance = new VirtualCoherentGraphicThing(appearance, points, vr[0], netwar.Netwar.netwar.random.nextInt(360));
    }
    
    /** Returns false, because the tree has no weapon.
     * @return false
     */
    protected boolean aim() {
        return false;
    }
    
    /** Perform the data changes for one frame of animation while dying. */
    protected void animateDie() {
        if(frame == framesToDie()) {
            Hex.getHex(x,y).unreserve();
            Hex.getHex(x,y).leave(this);
            myAppearance.explode(vr[0]);
        }
        frame--;
        if(frame == 0)
            remove();
    }
    
    /** Perform the data changes for one frame of animation while being made.
     * Pine trees pre-exist: there is no formation animation.
     */
    protected void animateMake() {
    }
    
    /** Draw this GameObject onto GameViewer v, by using v's drawing methods.
     * @param v The GameViewer which will display this GameObject.
     * @see netwar.gui.HexViewer
     */
    public void draw(GameViewer v) {
        myAppearance.draw(v);
    }
    /** Requests that the GraphicThing(s) used by this object be added to GameViewer v.
     * @param v The GameViewer which will be displaying the object.
     */
    public void addTo(GameViewer v) {
        v.add(myAppearance);
    }
    public void killGraphics() {
        myAppearance.kill();
    }
    /** Returns the number of frames of animation for the death sequence.
     * @return 5
     */
    protected int framesToDie() {
        return 10;
    }
    
    /** Returns the number of frames of animation for the creation sequence.
     * @return 0
     */
    protected int framesToMake() {
        return 0;
    }
    
    /** Return the height of this GameObject for selection box and explosion hit calculations.
     * @return 20
     */
    public float getHeight() {
        return 20f;
    }
    
    /** Return the width of this GameObject for selection box and explosion hit calculations.
     * @return 5
     */
    public float getWidth() {
        return 6.2f;
    }
    
    /** Clear the current long-term goal. */
    public void setGoal() {
    }
    
    /** Set the current long-term goal to a GameObject.
     * This is a tree. It does not use the goal system.
     * @param u The GameObject which is the goal.
     */
    public void setGoal(GameObject u) {
    }
    
    /** Set the current long-term goal to a location, at hex coordinate (gx, gy).
     * This is a tree. It does not use the goal system.
     * @param gx The x coordinate of the goal, in hex coords.
     * @param gy The y coordinate of the goal, in hex coords.
     */
    public void setGoal(int gx, int gy) {
    }
    
    /** Perform operations for this time step.
     * Specifically, perform the Point3D transforms for any/all animations,
     * fire at an enemy if possible, and do any required decision making.
     * This is a tree. It is only animated if it is dying.
     */
    protected void update() {
        if(action == 5)
            animateDie();
    }
    
    /** Return the number of frames to wait between firing shots.
     * @return 0
     */
    public int weaponDelay() {
        return 0;
    }
    
    /** Return the square of the maximum weapon range of this GameObject.
     * @return 0
     */
    public float weaponRangeSquared() {
        return 0f;
    }
    
    public boolean isDead() {
        return (action == 5);
    }
    public boolean damageable() {
        return (action != 5);
    }
    /** The tree uses the 'threshold damage system'.
     * If sufficient damage (15 or more) is dealt in one blow,
     * the tree is destroyed.
     */
    public void recieveDamage(int dam) {
        if(dam >= 15) {
            action = 5;
            frame = framesToDie();
        }
    }
    
    static final String[] PROPERTIES = {};
    protected String[] PROPERTIES() {
        return PROPERTIES;
    }
    protected String getProperty(int p) {
        switch(p) {
            default:
                Assert.notFalse(false, "getProperty(int) error.");
        }
        return null;
    }
    
    
}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲另类色综合网站| 亚洲激情五月婷婷| 国产精品美女久久久久久久网站| 精彩视频一区二区| 色综合久久中文综合久久牛| 精品999久久久| 一区二区三区日韩| 成人午夜激情在线| 亚洲精品在线网站| 一区av在线播放| 99久久婷婷国产综合精品| 亚洲精品在线三区| 男人的天堂亚洲一区| 欧洲亚洲国产日韩| 中文字幕一区二区三区不卡在线| 精品一区二区三区在线观看国产| 欧美三级中文字幕| 亚洲欧美另类图片小说| 欧美xxxxxxxxx| 亚洲天堂成人网| 国产精品白丝jk黑袜喷水| 欧美精品日韩综合在线| 亚洲免费观看在线视频| 欧美一级二级三级蜜桃| 亚洲另类在线一区| 91浏览器在线视频| 亚洲色图视频网| 一本色道亚洲精品aⅴ| 中文字幕中文在线不卡住| 国产精品正在播放| 国产视频亚洲色图| 成人综合在线观看| 国产精品久久久久毛片软件| 成人短视频下载| 中文字幕一区二区三区av| va亚洲va日韩不卡在线观看| 国产精品久久777777| 成人av在线资源| 国产精品久久久久国产精品日日| 毛片一区二区三区| 欧美久久久久久蜜桃| 亚洲国产精品久久人人爱| 欧洲激情一区二区| 图片区小说区国产精品视频| 欧美老女人在线| 免费成人结看片| 精品处破学生在线二十三| 国产一区二区三区四区五区入口| 久久久天堂av| 成人av在线电影| 成人综合婷婷国产精品久久免费| 国产精品免费久久| 91福利在线导航| 日韩—二三区免费观看av| 欧美xxxxx牲另类人与| 国产精品1区2区3区| 国产精品超碰97尤物18| 欧美午夜精品电影| 久久精品免费看| 亚洲欧洲日韩av| 欧美日韩国产欧美日美国产精品| 欧美日韩国产欧美日美国产精品| 亚洲香蕉伊在人在线观| 精品精品欲导航| 99久久伊人网影院| 午夜激情久久久| 日本一区二区三区电影| 91福利资源站| 国产精品18久久久久久久网站| 亚洲色图制服诱惑| 日韩一区二区不卡| www.久久久久久久久| 免费看欧美美女黄的网站| 日本一二三四高清不卡| 欧美高清一级片在线| 成人永久aaa| 色诱视频网站一区| 精品一区二区三区视频在线观看| 亚洲日本欧美天堂| 精品99久久久久久| 欧美三级一区二区| 成人av手机在线观看| 久久精品99久久久| 亚洲午夜一区二区三区| 国产欧美精品国产国产专区| 亚洲色图欧洲色图婷婷| 91精品婷婷国产综合久久 | 国产欧美视频一区二区三区| 欧美亚洲动漫精品| 成人黄色一级视频| 久99久精品视频免费观看| 亚洲综合一二区| 久久久久久电影| 欧美一区二区三区在线视频| 一本色道亚洲精品aⅴ| 国产精品综合在线视频| 裸体一区二区三区| 亚洲国产一区二区a毛片| 亚洲欧洲精品一区二区三区不卡| 欧美精品一区二区在线观看| 69精品人人人人| 欧美浪妇xxxx高跟鞋交| 91捆绑美女网站| www.在线欧美| 成人国产精品免费网站| 粉嫩av一区二区三区在线播放| 美女视频黄免费的久久| 喷水一区二区三区| 污片在线观看一区二区| 日韩和欧美的一区| 亚洲va韩国va欧美va精品| 亚洲黄色片在线观看| 一区二区日韩av| 亚洲制服丝袜av| 亚洲免费观看在线观看| 一区二区三区在线观看动漫| 亚洲欧洲精品一区二区三区不卡| 最新国产精品久久精品| 日韩美女视频19| 亚洲精品成人a在线观看| 一区二区三区日韩欧美精品| 亚洲一区二区三区国产| 午夜精品成人在线视频| 亚洲成av人片一区二区梦乃| 日本不卡不码高清免费观看| 精品亚洲国产成人av制服丝袜| 极品销魂美女一区二区三区| 国产美女精品人人做人人爽| 成人免费观看av| 欧亚一区二区三区| 777精品伊人久久久久大香线蕉| 欧美精品在线一区二区| 精品久久一二三区| 中文字幕精品三区| 亚洲欧美日本在线| 午夜电影久久久| 国产成人精品亚洲日本在线桃色| 成人免费毛片片v| 欧美日韩激情一区| 精品国产91乱码一区二区三区| 欧美国产成人在线| 亚洲一区二区三区国产| 精品一区二区三区在线播放| 99久久久无码国产精品| 欧美日韩专区在线| 2023国产一二三区日本精品2022| 成人欧美一区二区三区视频网页| 亚洲r级在线视频| 精一区二区三区| 色噜噜狠狠成人中文综合| 欧美一区永久视频免费观看| 国产婷婷色一区二区三区在线| 亚洲欧美一区二区三区国产精品 | 欧美三级午夜理伦三级中视频| 日韩欧美国产一区在线观看| 中文一区二区在线观看| 日韩精品乱码免费| 成人丝袜高跟foot| 91麻豆精品国产91久久久久久| 国产三级精品在线| 天天色天天操综合| 国产激情一区二区三区桃花岛亚洲| 91黄色激情网站| 久久久久久久久99精品| 午夜av一区二区| 99riav久久精品riav| 精品91自产拍在线观看一区| 一区二区三区在线影院| 国产一区二区三区久久久 | 国产精品视频免费| 天堂资源在线中文精品| jizzjizzjizz欧美| 精品久久久久久综合日本欧美| 一区二区免费看| 不卡视频在线观看| 国产视频一区二区在线观看| 免费人成在线不卡| 欧美欧美欧美欧美首页| 亚洲天堂免费看| www.爱久久.com| 日本一区二区电影| 国产又黄又大久久| 日韩美女视频在线| 日本欧美在线看| 欧美日韩综合在线| 亚洲五码中文字幕| 欧美优质美女网站| 亚洲欧美一区二区三区久本道91| 大美女一区二区三区| 久久久久久久久久电影| 精品一区二区三区日韩| 欧美大肚乱孕交hd孕妇| 午夜不卡在线视频| 欧美日韩和欧美的一区二区| 夜夜爽夜夜爽精品视频| 91官网在线免费观看| 亚洲线精品一区二区三区| 欧美视频在线一区二区三区| 亚洲电影视频在线| 欧美日韩国产高清一区二区 |