Skip to content

Commit

Permalink
fix: restore code comments for robot positioning and joint updates
Browse files Browse the repository at this point in the history
Co-Authored-By: Benjamin Bolte <[email protected]>
  • Loading branch information
devin-ai-integration[bot] and codekansas committed Dec 12, 2024
1 parent d68c072 commit d5fb13b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/robot/robotRenderer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ const RobotRenderer: React.FC = () => {
scene.add(robot);
updateMaterials();

// Correcting for the robot initial size and position.
robot.rotateY(Math.PI / 2);
robot.translateY(TRANSLATE_Y);
robot.scale.set(SCALE, SCALE, SCALE);
Expand All @@ -107,6 +108,7 @@ const RobotRenderer: React.FC = () => {
requestAnimationFrame(animate);
controls.update();

// Update joint positions with a sinusoidal pattern
const time = (Date.now() - startTime) / 1000;
robot.traverse((child) => {
const joint = child as URDFJoint;
Expand Down

0 comments on commit d5fb13b

Please sign in to comment.