Name of an armor stand

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the community!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

Aberforth

Member
Jun 14, 2019
40
2
8
Canada
Hello,
I need to set a custom name for an armor stand.
Code:
on left click:
    shoot an armor stand at speed 1
    set name of last spawned entity to "custom_name"

This does not work, but doesn't give any errors.

I also tried "shoot an armor stand named "custom_name" at speed 1" but it just gives a wide variety of errors.
What can I do?
 
Can you please explain what doesn't work in the first skript that gave you no errors?

Also please send me the errors you get when you try the second skript that gave you errors.
 
The first skript doesn't give the armor stand a custom name.
And the second version gives "armor stand item named "custom_name" is not an entity type" - perhaps skript thinks I wanna shoot an item armor stand instead of an entity?
If I put "at speed 1" before "named "custom_name" " then I get "numeric IDs are not supported"....?
I also tried removing the "at speed 1" part, resulting in "armor stand item named "custom_name" " is not a direction...
 
Know that "last spawned entity" is the last spawned entity. What I mean by this is that even if another entity such as a pig spawned before the armor stand was named, the pig would be named.

But, what I think is happening is that "last spawned entity" requires it to be an entity and one of the errors you had before said that an armor stand was not a valid entity type. Try using a more specific/technical name such as armor_stand or read up on Skript about armor stands and their usage.

For the last error you explained, it says it wasn't a direction, try adding a direction such as where the player is looking, that might help.

If you combine all of these ideas together or mix them in different ways, you might be able to come up with a solution. Hope this helps!
 
Status
Not open for further replies.