Line of blocks

Discussion in 'Plugin Development' started by skales65, Apr 18, 2017.

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

    skales65

    Hi guys. I have one question. Do you know how to make line of blocks following player? Something like in Tron or if you know slither.io. I have no ideas for this.
    Thanks
     
  2. Offline

    timtower Administrator Administrator Moderator

    Moved to plugin development.
    @skales65 PlayerMoveEvent
    Store the last locations.
    Put a block there.
     
  3. Offline

    skales65

    Please can you post some example code?
    btw: I want line of 5 blocks following player. Last block must change to air
     
  4. Offline

    timtower Administrator Administrator Moderator

    @skales65 I won't spoonfeed.
    And that is keeping track of the length of the list.
     
  5. Offline

    skales65

    Ok. Thanks. I will try.
     
  6. Offline

    Ragnarok_

    You could store all of the blocks in an arraylist, their locations ofcourse, and remove the last one every so often.
     
Thread Status:
Not open for further replies.

Share This Page