Package com.l2client.animsystem.jme

Examples of com.l2client.animsystem.jme.JMEAnimationController


      if (n != null) {
        vis = n; //MeshCloner.cloneMesh(n);
        vis.setName(name);
//        vis.setLocalRotation(new Quaternion().fromAngleAxis(FastMath.HALF_PI, Vector3f.UNIT_X));

        JMEAnimationController animControl = (JMEAnimationController) vis
              .getControl(JMEAnimationController.class);
        if(animControl != null)
          animControl.setInput(InputProvider.NOINPUT);
        //FIXME this is the case with the troll model
//        else
//          logger.severe("ERROR no JMEAnimationController on Model");
      }
    }
View Full Code Here


          // com.position.y+com.heightOffset, com.position.z);
          Entity ent = e.getEntity();
          checkForDamageMessages(ent, en);
          // FIXME damn ugly Ent -> NPCModel -> Vis -> Controller WILL BLOW ON PURE VISMODEL
          try {
            JMEAnimationController con = null;
            if(ent.getChildren().size() > 0 && ((Node)ent.getChild(0)) != null && ((Node)ent.getChild(0)).getChildren().size() > 0)
              con = ((Node) ent.getChild(0)).getChild(0).getControl(JMEAnimationController.class);
            if (con != null) {
              InputProvider in = getInputFrom(en, ent);
              con.setInput(in);
//FIXME OEHAM twice done, see Attack sever packet
//            if(en.damageDealt > 0)
//              con.callAction(CallActions.DefaultAttack.toString(), in);
//            if(en.damageReceived > 0)
//              con.callAction(CallActions.Wounded.toString(), in);
View Full Code Here

            Skeleton skel = new Skeleton(skeleton);
          //TODO move this out into AnimationManger
      AnimControl c = new AnimControl(skel);//skeleton, animParts, template
      c.createChannel();
      c.setAnimationProvider(Singleton.get().getAnimManager().getAnimationProvider(animSet));
            model.addControl(new JMEAnimationController(c,animSet));
            SkeletonControl skeletonControl = new SkeletonControl(skel);
            model.addControl(skeletonControl);

            skeletonControl.setHardwareSkinningPreferred(useHWSkinning);
View Full Code Here

      Entity e = idc.getEntity();
      VisualComponent comp = (VisualComponent) Singleton.get().getEntityManager().getComponent(e.getId(), VisualComponent.class);
      if(comp != null){
        //FIXME this can blow up!
        if(e.getChildren().size()>0 && ((Node)e.getChild(0)).getChildren().size()>0 ){
          JMEAnimationController con = ((Node) e.getChild(0)).getChild(0)
              .getControl(JMEAnimationController.class);
          if (con != null) {
            EnvironmentComponent env = (EnvironmentComponent) Singleton.get().getEntityManager().getComponent(entityId,
                    EnvironmentComponent.class);
            if (env != null) {
              log.finest(e.getId()+" callAction "+a);
              con.callAction(a.toString(), getInputFrom(env, e));
            }
          }
        } else {
          log.warning("No proper spatial hierarchy on model "+e.getName());
        }
View Full Code Here

    if(assembler != null)
      createChangedChar();
    else
      createInitialChar();
    if (vis != null){ 
      JMEAnimationController animControl = (JMEAnimationController) vis
          .getControl(JMEAnimationController.class);
      if(animControl != null)
        animControl.setInput(InputProvider.NOINPUT);

      Singleton.get().getSceneManager().changeAnyNode(this,vis, Action.ADD);
    } else
      logger.severe("Vis animations are missing");
   
View Full Code Here

     */
    private void setupScene() {

      //TODO could use getTemplates to switch through models..
      Node n = Assembler2.getModel3("dwarfwarrior"); //humanhalberd"); //goblin");
      JMEAnimationController con=null;
      if(n != null){
        con = n.getControl(JMEAnimationController.class);
        rootNode.attachChild(n);
//        n.updateGeometricState();
      }
     
      if(con!= null ){
        final JMEAnimationController conn = con;
        SwingUtilities.invokeLater(new Runnable() {

          public void run() {
            AnimationInputSwitchSidebar bar = new AnimationInputSwitchSidebar();
            bar.setTarget(conn);
View Full Code Here

TOP

Related Classes of com.l2client.animsystem.jme.JMEAnimationController

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.