- fix TestWalkingChar shooting
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@8455 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
This commit is contained in:
parent
a71340c196
commit
2055bf0fe3
@ -186,7 +186,7 @@ public class TestWalkingChar extends SimpleApplication implements ActionListener
|
|||||||
|
|
||||||
private void addBrick(Vector3f ori) {
|
private void addBrick(Vector3f ori) {
|
||||||
Geometry reBoxg = new Geometry("brick", brick);
|
Geometry reBoxg = new Geometry("brick", brick);
|
||||||
reBoxg.setMaterial(matRock);
|
reBoxg.setMaterial(matBullet);
|
||||||
reBoxg.setLocalTranslation(ori);
|
reBoxg.setLocalTranslation(ori);
|
||||||
reBoxg.addControl(new RigidBodyControl(1.5f));
|
reBoxg.addControl(new RigidBodyControl(1.5f));
|
||||||
reBoxg.setShadowMode(ShadowMode.CastAndReceive);
|
reBoxg.setShadowMode(ShadowMode.CastAndReceive);
|
||||||
@ -397,7 +397,7 @@ public class TestWalkingChar extends SimpleApplication implements ActionListener
|
|||||||
Geometry bulletg = new Geometry("bullet", bullet);
|
Geometry bulletg = new Geometry("bullet", bullet);
|
||||||
bulletg.setMaterial(matBullet);
|
bulletg.setMaterial(matBullet);
|
||||||
bulletg.setShadowMode(ShadowMode.CastAndReceive);
|
bulletg.setShadowMode(ShadowMode.CastAndReceive);
|
||||||
bulletg.setLocalTranslation(character.getPhysicsLocation().add(cam.getDirection().mult(2)));
|
bulletg.setLocalTranslation(character.getPhysicsLocation().add(cam.getDirection().mult(5)));
|
||||||
RigidBodyControl bulletControl = new BombControl(bulletCollisionShape, 1);
|
RigidBodyControl bulletControl = new BombControl(bulletCollisionShape, 1);
|
||||||
bulletControl.setCcdMotionThreshold(0.1f);
|
bulletControl.setCcdMotionThreshold(0.1f);
|
||||||
bulletControl.setLinearVelocity(cam.getDirection().mult(80));
|
bulletControl.setLinearVelocity(cam.getDirection().mult(80));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user