George3D

Members
  • Content Count

    20
  • Joined

  • Last visited

About George3D

  • Rank
    Member

Profile Information

  • Gender
    Male
  • Location
    Germany

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. George3D

    [Solved] PhysicsImpostor

    Ok, thank you for informations, so I better change my Code.
  2. I have always used "setPhysicState" to set physics properties of objects, in many projects. Meanwhile I read it's better to use "new BABYLON.PhysicsImpostor" instead. Why should that be better? What are advantage and disadvantage?
  3. George3D

    Animation "limb" problem

    I want to repeat my "limb"-question: although the objects now rotate around an origin at the top of the cylinders, the first step they made a "jump". Does anyone know a solution for this Problem? http://www.babylonjs-playground.com/#XVUEI#3
  4. George3D

    createAndroid

    No problem
  5. George3D

    createAndroid

    I'm writing a book about the excellent Babylon engine (in German - I'm looking for an anglophone publisher ). In this connection i've created a function to construct a simple android. Maybe someone is interested in the code. Here it is, try and improve it! android.js
  6. George3D

    Animation "limb" problem

    Thank you griff for the hint to an interesting topic. But changing my code by using setPivotMatrix() doesn't solve the problem. the first step is still a "dancing" one.
  7. George3D

    Animation "limb" problem

    Ok, you'll find the (shortened) Code in the Playground: http://www.babylonjs-playground.com/#XVUEI#1
  8. I have built a character with elements created by CreateSphere() and CreateCylinder(). All parented with a central element collected in an own function. To animate single limbs of the "android" I first used the function getChildMeshes() to get the children of the parent. The animation works together with a key-event, but there is one problem: while the first move the limbs are flying around, then they return to their place and work well. How can I solve my Problem?
  9. George3D

    [solved] Wrong direction after rotation

    @JohnK: Thank you for the detailed information. I tried it and it works fine. But meanwhile I found another solution with sin and cos: var xDiff = 0.5 * Math.sin(android.rotation.y); var zDiff = 0.5 * Math.cos(android.rotation.y); if (key == 37) // left around android.rotation.y -= Math.PI/4; if (key == 38) { // forward android.position.x += xDiff; android.position.z += zDiff; } if (key == 39) // right around android.rotation.y += Math.PI/4; if (key == 40) { // backward android.position.x -= xDiff; android.position.z -= zDiff; } @adam: My model (= android) is facing in the right direction. That was not my problem but the rotation.
  10. George3D

    [solved] Wrong direction after rotation

    Sorry, but if you mean "movePOV" it doesn't work: the player is still moving sideways after turning (rotating) left or right.
  11. I have this Code to move a player (3rd person) forward and backward, with the arrow keys left-right I can rotate the Player: if (key == 37) // left android.rotation.y -= Math.PI/2; if (key == 38) // foreward android.position.z += 0.5; if (key == 39) // right android.rotation.y += Math.PI/2; if (key == 40) // backward android.position.z -= 0.5; But after a rotation the facing direction is wrong. How can I correct this?
  12. George3D

    [solved] Sprites

    Thank you your efforts, in the meantime I found out: the picking is working. It's my problem, I hit the bug very rarely. Thanks also for the "click-hints". And a new question: What ist the difference between clientX/Y and pointerX/Y? Both seem to work equally.
  13. George3D

    [solved] Sprites

    I didn't know how to get the image into the Playground.
  14. George3D

    [solved] Sprites

    I copied the shortened Code in the Playground: http://www.babylonjs-playground.com/#26ZKJD#0 I used an image file with 2 cells (0 = normal; 1 = squashed).
  15. George3D

    [solved] Sprites

    I found another (longer-winded) way: function pickIntersect (point, pos, diff) { if ((point.x > pos.x-diff) && (point.x < pos.x+diff) && (point.z > pos.z-diff) && (point.z < pos.z+diff)) return true; return false; } if (pickIntersect(pickResult.pickedPoint, player.position, 2)) player.cellIndex = 1;