Chapter 4. The Colliding Grabbers
From:
Pro Java 6 3D Game Development
Andrew Davison
Apress, April 2007
ISBN: 1590598172
http://www.apress.com/book/bookDisplay.html?bID=10256
Web Site for the book: http://fivedots.coe.psu.ac.th/~ad/jg2
Contact Address:
Dr. Andrew Davison
Dept. of Computer Engineering
Prince of Songkla University
Hat Yai, Songkhla 90112, Thailand
E-mail: ad@fivedots.coe.psu.ac.th
If you use this code, please mention my name, and include a link
to the book's Web site.
Thanks,
Andrew
==================================
Files and directories here:
* Arms3D.java, WrapArms3D.java, Grabbers.java, Grabber.java,
GrabberBounds.java, KeyBehavior.java, JointsBehavior.java,
CheckerFloor.java, ColouredTiles.java
// 9 Java files
* images/ // a directory holding a single texture
- steel.jpg
==================================
Requirements:
* J2SE 5.0 from http://java.sun.com/j2se/1.5.0/index.jsp
* Java 3D 1.4.0 (or 1.3.2) from https://java3d.dev.java.net/
==================================
Compilation:
$ javac *.java
Execution:
$ java Arms3D
==================================
What Keys Operate the Grabbers?
x // turn the left grabber's forearm left
y // make the left grabber's forearm rotate up
z // make the left grabber's forearm rotate clockwise
f // open the left grabber's fingers
All the rotations have limits, after which further rotations
in the same direction will be ignored.
<alt> with x, y, z, or f
// do the opposite rotation for the left grabber
<shift> with x, y, z, of f
// same as x, y, z, or f, but for the right grabber
<shift> and <alt> with x, y, z, of f
// same as <alt> x, y, z, or f, but for the right grabber
the arrow keys
// translate both grabbers forwards, backwards, left, or right
You can move the camera using Java 3D's OrbitBehavior controls
to pan, rotate, and zoom.
-----------
Last updated: 3rd March 2007
java3d碰撞检测例子
4星 · 超过85%的资源 需积分: 34 189 浏览量
2011-11-18
12:46:40
上传
评论
收藏 24KB ZIP 举报
Geminit
- 粉丝: 14
- 资源: 23
最新资源
- 卡方数据.sav
- Python实现基于Django框架的二手物品购物网站设计源码+数据库.zip
- 基于Python和Django的二手物品购物网站设计源码+数据库脚本.zip
- 【计算机毕业设计】基于h5的移动网赚项目小程序【源码+lw+部署文档+讲解】
- 【计算机毕业设计】基于ssm-vue的oa系统设计与实现【源码+lw+部署文档+讲解】
- 基于pytorch实现的YOLOV5+SORT的车辆行人目标识别及追踪系统源码.zip
- 【计算机毕业设计】基于servlet+jdbc的在线选房系统设计与实现【源码+lw+部署文档+讲解】
- 投身科技创新,勇担时代先锋.pptx
- 【计算机毕业设计】基于SSM的仿微博系统的设计与实现【源码+lw+部署文档+讲解】
- 使用 Web Components 实现,遵循 Material You 设计规范的 Web 前端组件库
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
- 1
- 2
前往页