Колобок в GDevelop
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

41 行
1.2KB

  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. </head>
  6. <body>
  7. <p>X: <input id="x" type="number" min="-360" max="360" value="0"></p>
  8. <p>Y: <input id="y" type="number" min="-360" max="360" value="0"></p>
  9. <p>Z: <input id="z" type="number" min="-360" max="360" value="0"></p>
  10. <br>
  11. <br>
  12. <br>
  13. <br>
  14. <p><img id="изо" src="вещи/перекладины.png"></p>
  15. <script>
  16. function rotate3D()
  17. {
  18. var x = document.getElementById("x").value;
  19. var y = document.getElementById("y").value;
  20. var z = document.getElementById("z").value;
  21. var изо = document.getElementById("изо");
  22. изо.style.transform = `rotateX(${x}deg) rotateY(${y}deg) rotateZ(${z}deg)`;
  23. }
  24. var x = document.getElementById("x");
  25. x.oninput = function() {
  26. rotate3D();
  27. }
  28. var y = document.getElementById("y");
  29. y.oninput = function() {
  30. rotate3D();
  31. }
  32. var z = document.getElementById("z");
  33. z.oninput = function() {
  34. rotate3D();
  35. }
  36. rotate3D();
  37. </script>
  38. </body>
  39. </html>