java 弹弹堂源码_Java awt实现的类似弹弹堂的小游戏

// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.

// Jad home page: http://www.kpdus.com/jad.html

// Decompiler options: packimports(3)

// Source File Name: Projectile.java

public class Projectile

implements Viewer

{

public void setAngle(double NewAngle)

{

angle = NewAngle;

if(angle < 0.0D)

angle += 360D;

if(angle > 360D)

angle -= 360D;

gx = Math.sin(((angle + 90D) * 3.1415926535897931D) / 180D) * speed;

gy = Math.cos(((angle + 90D) * 3.1415926535897931D) / 180D) * speed;

radians = angle * -0.017453292519943295D;

}

public void setX(double newX)

{

x = newX;

prevX = newX;

}

public void setY(double newY)

{

y = newY;

prevY = newY;

}

public void setGx(double newGx)

{

gx = newGx;

angle = Math.atan2(gy * 100D, gx * 100D) * -57.295779513082323D;

radians = angle * -0.017453292519943295D;

}

public void setGy(double newGy)

{

gy = newGy;

angle = Math.atan2(gy * 100D, gx * 100D) * -57.295779513082323D;

radians = angle * -0.017453292519943295D;

}

public void setGravity(double gravity)

{

grav = gravity;

}

public void setSpeed(double newSpeed)

{

speed = newSpeed;

}

public void advance()

{

prevX = x;

prevY = y;

gy = gy + grav;

angle = Math.atan2(gy, gx) * -57.295779513082323D;

radians = angle * -0.017453292519943295D;

x += gx;

y += gy;

}

public Projectile()

{

speed = 1.0D;

grav = 0.025000000000000001D;

damRad = 80;

alt = null;

}

public Projectile(double newX, double newY)

{

speed = 1.0D;

grav = 0.025000000000000001D;

damRad = 80;

alt = null;

prevX = newX;

prevY = newY;

x = newX;

y = newY;

}

public int getX()

{

return (int)x;

}

public int getY()

{

return (int)y;

}

public boolean isCamera()

{

return false;

}

static final double DEGtoRAD = -0.017453292519943295D;

static final double RADtoDEG = -57.295779513082323D;

public double prevX;

public double prevY;

public double x;

public double y;

public double gx;

public double gy;

public double angle;

public double radians;

public double speed;

public double grav;

public int damRad;

Chara alt;

}

相关资源:弹弹游戏源码
已标记关键词 清除标记
表情包
插入表情
评论将由博主筛选后显示,对所有人可见 | 还能输入1000个字符
相关推荐
<p> <strong><span style="font-size:20px;color:#FF0000;">本课程主要针对计算机相关专业的正在做毕设的学生与需要项目实战练习的Java学习者</span></strong> </p> <p> <span style="color:#FF0000;"><strong><span style="font-size:18px;">1. 包含:<span style="color:#FFFF00;background-color:#FF0000;">项目源码、</span><span style="color:#FFFF00;background-color:#FF0000;">项目文档、数据库脚本、软件工具</span>等所有资料</span></strong></span> </p> <p> <span style="color:#FF0000;"><strong><span style="font-size:18px;">2. 手把手的带你从零开始部署运行本套系统</span></strong></span> </p> <p> <span style="color:#FF0000;"><strong><span style="font-size:18px;">3. 该项目附带的源码资料可作为毕设使用</span></strong></span> </p> <p> <span style="color:#FF0000;"><strong><span style="font-size:18px;">4. 提供技术答疑和远程协助指导</span></strong></span><strong><span style="font-size:18px;"></span></strong> </p> <p> <br /> </p> <p> <span style="font-size:18px;"><strong>项目运行截图:</strong></span> </p> <p> <strong><span style="font-size:18px;">1)系统登陆界面</span></strong> </p> <p> <strong><span style="font-size:18px;"><img src="https://img-bss.csdn.net/202002241015433522.png" alt="" /><br /> </span></strong> </p> <p> <strong><span style="font-size:18px;"><strong><span style="font-size:18px;">2)学生模块</span></strong></span></strong> </p> <p> <strong><span style="font-size:18px;"><img src="https://img-bss.csdn.net/202002241015575966.png" alt="" /></span></strong> </p> <p> <strong><span style="font-size:18px;"><strong><span style="font-size:18px;">3)教师模块</span></strong></span></strong> </p> <p> <strong><span style="font-size:18px;"><img src="https://img-bss.csdn.net/202002241016127898.png" alt="" /></span></strong> </p> <p> <strong><span style="font-size:18px;"><strong><span style="font-size:18px;">4)系统管理员</span></strong></span></strong> </p> <p> <strong><span style="font-size:18px;"><img src="https://img-bss.csdn.net/202002241016281177.png" alt="" /></span></strong> </p> <p> <strong><span style="font-size:18px;"><img src="https://img-bss.csdn.net/202002241016369884.png" alt="" /></span></strong> </p> <p> <strong><span style="font-size:18px;"><br /> </span></strong> </p> <p> <strong><span style="font-size:18px;"><strong><span style="font-size:18px;">更多Java毕设项目请关注我的毕设系列课程 <a href="https://edu.csdn.net/lecturer/2104">https://edu.csdn.net/lecturer/2104</a></span></strong></span></strong> </p> <p> <strong><span style="font-size:18px;"><br /> </span></strong> </p>
©️2020 CSDN 皮肤主题: 深蓝海洋 设计师:CSDN官方博客 返回首页