Filled Spectate plugin

Discussion in 'Plugin Requests' started by FireFlies, Nov 14, 2017.

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

    FireFlies

    Minecraft version: 1.8.8

    Plugin name: Spectate

    Description: This is a simple plugin. It enables players to spectate other players.

    Commands:
    Execute /spec in order to toggle spectator mode. In this mode you:
    - Are turned invisible to all players except the other players in spectator mode.
    - Have fly enabled.
    - Cannot interact with anything.
    - Cannot drop/pickup items.
    - Do not lose health or hunger.
    Repeat the command to disable spectator mode and teleport back to spawn.

    Execute /spec [name] to enable spectator mode and teleport to a specific player. This command can also be done while in spectator mode to simply teleport to a player.

    Messages (editable in the config preferably):
    When spectator mode is enabled:
    "&7Spectator mode&f: &aenabled"

    When spectator mode is disabled:
    "&7Spectator mode&f: &cdisabled"

    When spectating a player:
    "&7Spectating &a[name]&7."

    No permission:
    "&4The action could not be completed, refer to &c&l/help &4for commands."

    Permissions:
    - spectator.use: to be able to spectate.

    That's it! Thank you very much in advance.
    Blessings and bliss,

    FireFlies
     
  2. Offline

    MightyOne

    @FireFlies but you want to stay players in their actual game mode.
     
  3. Offline

    FireFlies

    That's right @MightyOne
     
  4. Offline

    nethergoblin

    Hey, i might be able to make this for you if no one else has started on it :p
     
  5. Offline

    MightyOne

    @FireFlies well i already tried that once but I find it super hard to make a player unhittable for arrows and projectiles.
     
  6. Offline

    FireFlies

    I don't think anyone is doing it right now, you're free to give it a go @nethergoblin :)
     
  7. Offline

    nethergoblin

    Awesome, ill start now, Etc will be by tomorrow at most!
     
  8. Offline

    trentonjeffro

    Config

    • spec_enabled - the message that is shown when specating is enabled for a player
    • spec_disabled - the message that is shown when spectating is disabled for a player
    • spec_player - the message that is shown when a player spectates another player
    • no_perms - the message that is shown when a player does not have permissions to specate
    • unknown_player - the message that is shown when a player enters in an invalid player name to spectate
    • spec_self - the message that is shown when a player tries to spectate themselves

    Commands

    • /spec - to go straight into spectator mode
    • /spec <playername> to spectate a certain player
    Alias of /spectate aswell so that will work if you want to type it out.

    Permissions

    • spectator.use - to be able to run the '/spec' command

    Let me know if you have any issues and I will get them fixed up!

    https://www.dropbox.com/s/7t5d9dwtu0ycgw9/spectate.jar?dl=0
     
    FireFlies likes this.
  9. Offline

    FireFlies

    Amazing! The features seem to be working flawlessly, there's just a couple changes I'd like:

    1. Deny interaction with signs (there are signs players can right-click to execute commands, I can't let them do that in spectator mode).
    2. Don't remove players from /list or tab when in spectator mode.
    3. Spectators need to be able to see eachother.
    4. Add a "speed boost" when players are sprinting and flying while spectating, so they can move around quickly (perhaps it can be a multiplier I can edit in the config).
    5. Add a /setspecspawn command to set the location spectators are teleported to when they stop spectating.

    Other then that, everything seems to be working very well! @trentonjeffro
     
  10. Offline

    trentonjeffro

    I will work on the changes now.

    Edit:

    Most of the changes are done, but I cannot make it so spectators can see other spectators

    Added Config options:
    • set_spawn - message it shows the player when he sets spawn
    • spec_speed - sets spectators fly speed, needs to be a decimal 0.1 for normal, 0.2 for fly speed 2, 0.3 for fly speed 3, etc up to 1.0 for fly speed 10

    Added Commands:
    • /setspecspawn - to set the point where you get teleported to when you leave spectator mode

    Added Permissions:
    • spectator.setspawn - allow a user to set the spectator spawn point

    https://www.dropbox.com/s/7t5d9dwtu0ycgw9/spectate.jar?dl=0

    Edit 2:
    I put this on bukkitdev https://dev.bukkit.org/projects/spectate-players
    I will update it occasionally there.
     
    Last edited: Nov 15, 2017
  11. Offline

    FireFlies

    Thank you for the update! @trentonjeffro
    Alright so there seems to be a problem:

    1. Player's aren't "invisible" anymore, they just have the invisibility potion effects and they can be seen/hit.

    2. There is a teleport protection: if the spectator spawn is set in the air, the spectators will be teleported on the ground to the side.

    3. The speed doesn't seem to be changing (I tried 0.1, 0.4, 1.0).
     
    Last edited: Nov 16, 2017
  12. I'll make a plugin that does all of these things, plus will do the important job of preventing hackers from seeing the invisible players (this is actually possible unless you prevent the server from telling a player that this player is there), and will prevent you from doing for example /sethome in spectator, and will let staff force spectators out of spectate mode. I normally don't do this when someone has already made a plugin, but there are some fairly important things that need to be ensured for spectators to be flawless, just like /gamemode 3.
     
    Last edited: Nov 16, 2017
  13. Offline

    JustRendering

    i can make one where when you do /spec player, if the player exists, it marks the location you are in, then it puts you into spectator mode, then teleport you to the player. If the player disconnects, it will teleport you back. If you shift, it will teleport you back, and when telporting you back, il make a method to check if there is a block there. if there is, it will see if the location up is a block other then air. then il do void loop to find one block that is empty. @FireFlies if your interested too, i can show you how.
     
  14. Offline

    FireFlies

Thread Status:
Not open for further replies.

Share This Page