Package org.spout.api.entity

Examples of org.spout.api.entity.Player.detach()


    //Set up component holder methods
    Mockito.when(player.add(Matchers.argThat(new ClassOrSubclassMatcher<EntityComponent>(EntityComponent.class)))).thenAnswer(componentHolder);
    Mockito.when(player.get(Matchers.argThat(new ClassOrSubclassMatcher<EntityComponent>(EntityComponent.class)))).thenAnswer(componentHolder);
    Mockito.when(player.getExact(Matchers.argThat(new ClassOrSubclassMatcher<EntityComponent>(EntityComponent.class)))).thenAnswer(componentHolder);
    Mockito.when(player.detach(Matchers.argThat(new ClassOrSubclassMatcher<EntityComponent>(EntityComponent.class)))).thenAnswer(componentHolder);
    Mockito.when(player.getData()).thenReturn(componentHolder.getData());
    Mockito.when(player.getEngine()).thenAnswer(new EntityEngineAnswer(engine));
    //Set up entity tick
    Mockito.doAnswer(new EntityTickAnswer(player)).when(player).onTick(Mockito.anyFloat());
View Full Code Here


    // TODO remove comments when Spout only uses fallback
    //player.add(PlayerMovementExecutor.class);

    // Remove Head and default Camera
    player.detach(EntityHead.class);
    player.detach(CameraComponent.class);

    player.add(PlayerHead.class);
  }
View Full Code Here

    // TODO remove comments when Spout only uses fallback
    //player.add(PlayerMovementExecutor.class);

    // Remove Head and default Camera
    player.detach(EntityHead.class);
    player.detach(CameraComponent.class);

    player.add(PlayerHead.class);
  }

  @EventHandler
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.