Solved Set block at (location) to skull? Can't find way to do this.

  • 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 comminuty!

    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.

uGim

Member
Jan 19, 2018
25
0
0
22
So this is the code:

on place of head:
wait 4 seconds
set block at event-location to player's skull

I have also tried some other ways to do this like:

set block at event-location to skull of player
set block at event-location to ("%player%" parsed as offline player)'s skull
 
Try:

code_language.skript:
on place of head:
    wait 4 seconds
    set block at event-location to event-player's skull
 
code_language.skript:
on script load:
  import "org.bukkit.SkullType"
effect place skull of %player% at %locations%:
  loop expressions 2:
    set {_block} to loop-value.getBlock()
    set block at {_block} to floor head
    set {_state} to {_block}.getState()
    {_state}.setSkullType({SkullType}.PLAYER!);
    {_state}.setOwner("%expression 1%");
    {_state}.update();
working on 1.8
code_language.skript:
place skull of the player at location of player
 
effect place skull of %player% at %locations%:

This doesn't work when I do it like so:

on place of stone:
if {kitpvp.paa.%uuid of player%} is set:
effect place skull of player at event-location: <--- there is the point which is not working
loop expressions 2:
set {_block} to loop-value.getBlock()
set block at {_block} to floor head
set {_state} to {_block}.getState()
{_state}.setSkullType({SkullType}.PLAYER!);
{_state}.setOwner("%expression 1%");
{_state}.update();

Error says: "Cannot understand this condition: effect place skull of player at event-location."

I am newbie when it comes to skripting and I would really like to know what those last 3 lines even do (because I don't think that is skript). I have never met such a things in skript. If possbile, could someone do a command that would place event-players head at location of placed block. I have searched and searched but I think I am too stupid for things like "{_state}.setSkullType({SkullType}.PLAYER!);" <--- seems like alien language to me.
[doublepost=1517165146,1517159390][/doublepost]
place skull of the player at location of player

This also doesn't work, it only DROPS the head of the player at location of player.
 
This doesn't work when I do it like so:

on place of stone:
if {kitpvp.paa.%uuid of player%} is set:
effect place skull of player at event-location: <--- there is the point which is not working
loop expressions 2:
set {_block} to loop-value.getBlock()
set block at {_block} to floor head
set {_state} to {_block}.getState()
{_state}.setSkullType({SkullType}.PLAYER!);
{_state}.setOwner("%expression 1%");
{_state}.update();

Error says: "Cannot understand this condition: effect place skull of player at event-location."

I am newbie when it comes to skripting and I would really like to know what those last 3 lines even do (because I don't think that is skript). I have never met such a things in skript. If possbile, could someone do a command that would place event-players head at location of placed block. I have searched and searched but I think I am too stupid for things like "{_state}.setSkullType({SkullType}.PLAYER!);" <--- seems like alien language to me.
[doublepost=1517165146,1517159390][/doublepost]

This also doesn't work, it only DROPS the head of the player at location of player.
that was an example of how to use that. it's an addon called skript-mirror that uses
 
code_language.skript:
on script load:
  import "org.bukkit.SkullType"
effect place skull of %player% at %locations%:
  loop expressions 2:
    set {_block} to loop-value.getBlock()
    set block at {_block} to floor head
    set {_state} to {_block}.getState()
    {_state}.setSkullType({SkullType}.PLAYER!);
    {_state}.setOwner("%expression 1%");
    {_state}.update();
working on 1.8
code_language.skript:
place skull of the player at location of player
Any way to get this to work with heads of offline players either using their uuid or username? I would love to get a head leaderboard going
 
that was an example of how to use that. it's an addon called skript-mirror that uses

I have skript-mirror but it wont work.
[doublepost=1517326470,1517324419][/doublepost]If I would be possible, could you make me a command which would place skull of player at location of player because none of the tips located up there don't work.

like this:

command /setskull:
set skull of player at location of player
[doublepost=1517329305][/doublepost]Nvm sorry for spamming here and I found the way by my self:

code_language.skript:
command /setskull:
    trigger:
        set block at location of player to head
        set {_l} to location of player
        set {_s} to {_l}.getBlock().getState()
        {_s}.setOwner("%player%")
        {_s}.update()
 
code_language.skript:
#put this in a script called "!!!syntaxes.sk"
get blocks property skull owner:

  loop expressions-1:
    set {_state} to loop-value.getState()
    add {_state}.getOwningPlayer() to {_output::*}

  continue returning {_output::*}

change blocks property skull owner:

  loop expressions-1:
    set {_state} to loop-value.getState()
    {_state}.setOwningPlayer(("%change value%") parsed as offline player)
    {_state}.update()

#Examples
set skull owner of event-block to "Rikka"
 
Status
Not open for further replies.