Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

156
Vistas
Animating the multi user object

I'm new to A-Frame js and am now stuck in one problem. Problem is that I'm using a networked A-Frame library for a multi-user experience. And have on the character which I'm showing there having some animation. So, by using some Jquery code I tried to add some animation controls. When I'm using that animation in the character which is shown on my own screen is animating, But in real scenarios, if I'm moving then that person should see me animating. Because I'm moving the camera or doing activities, not that avatar.

<a-assets>
     <a-asset-item id="person" src="./person/scene.gltf"></a-asset-item>
</a-assets>

This is the person model which I'm using.

<!-- ++++++++++++++++++++++++++ Person Template ++++++++++++++++ -->
      <template id="person_template">
        <a-entity
          id="model"
          gltf-model="#person"
          animation-mixer="clip: Rig|man_idle;"
          scale="0.02 0.02 0.02"
        >
        </a-entity>
      </template>

This is the template that I'm using in the networked entity.

<a-entity
        id="rig"
        position="-9.495 0.770 6.282"
        position="-5 0.2 1"
        rotation="0 180 0"
        movement-controls="speed:0.15; constrainToNavMesh: true;"
      >
        <a-entity camera="active:true" position="0 2 0" look-controls>
         
          <a-entity
            id="player"
            networked="template:#person_template;attachTemplateToLocal:false;"
            movement-controls="speed:0.15; constrainToNavMesh: true;"
            look-controls
            wasd-controls="acceleration:15"
          >
          </a-entity>
        </a-entity>
    </a-entity>

This is the networked entity i used to make multi-user env.

  $(document).ready(function () {
          $(this).keydown(function (e) {
            switch (e.which) {
              case 37:
                $("#model").attr("animation-mixer", "clip: Rig|man_walk_in_place;");
                $("#model").attr("rotation", "0 -90 0");
                break;
             }

This is the code I write to add animation which, is visible by another person in the controlling avatar.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda