Help with posing an armorstand

Discussion in 'Plugin Development' started by 360_, Mar 15, 2018.

Thread Status:
Not open for further replies.
  1. Offline

    360_

    So I'm trying to pose an armor stand but it's not looking the way I was hoping. this is how it currently looks like https://imgur.com/2SAURKz the Armor stand that doesn't have the "Test" name is the armor stand that summons and the one with the "Test" name is how it should look like.
    Code:
    summon minecraft:armor_stand 957.5 46.0 -793.5 {ShowArms:1,CustomNameVisible:1,CustomName:"Test",ArmorItems:[{id:air,Count:1,Damage:0},{id:air,Count:1,Damage:0},{id:air,Count:1,Damage:0},{id:skull,Count:1,Damage:3,tag:{SkullOwner:"Red"}}],HandItems:[{id:air,Count:1,Damage:0},{id:air,Count:1,Damage:0}],Pose:{Body:[0.0f,1.24f,0.0f],Head:[2.52f,2.43f,0.0f],LeftLeg:[-1.0f,0.0f,318.21f],RightLeg:[1.0f,0.0f,1.0f],LeftArm:[-10.0f,0.0f,360.0f],RightArm:[-15.0f,0.0f,122.15f]}}
    Thats the command im using to get the angels to set the Arms and legs but it seems to not work. Could anyone help me?
    Code:
    @EventHandler
            public void onPlayerInteract(PlayerInteractEvent e) {
                Player p = e.getPlayer();
                if ((e.getAction() == Action.RIGHT_CLICK_AIR) && (p.getItemInHand().getType() == Material.NETHER_STAR)) {
                    ArmorStand one = (ArmorStand) p.getWorld().spawnEntity(p.getLocation().add(0, 3, 0), EntityType.ARMOR_STAND);
                        one.setArms(true);
                        one.setRightArmPose(new EulerAngle(-15f ,0f , 122.15f));
                        one.setLeftLegPose(new EulerAngle(-1.0f,0.0f,318.21f));
                        one.setLeftLegPose(new EulerAngle(2.52f,2.43f,0.0f));
                }
            }
     
    Last edited by a moderator: Mar 16, 2018
  2. Offline

    Nostos

    if you really want you can use Bukkit.dispatchCommand() I think the function is otherwise I'm not sure I'd try messing with the numbers a lot and seeing what does what.
     
  3. Offline

    360_

    @Nostos i would try that but it would be broadcasted in chat when the event is triggered
     
  4. Offline

    Nostos

    it does?? OwO
     
  5. Offline

    360_

    @Nostos Yeah it does, I've made the console run a command for fireworks and it had the summon broadcast show up in chat
     
  6. Offline

    Horsey

    I believe EulerAngles expect radians, however the summon command expects degrees.

    You have to convert the degrees to radians.
     
Thread Status:
Not open for further replies.

Share This Page