Random TP plugin with delay?

Discussion in 'Archived: Plugin Requests' started by danielfr789, Apr 13, 2013.

  1. Offline

    danielfr789

    Plugin category: Teleportation

    Suggested name: RandomTeleport

    What I want: A plugin when you type /randomtp you teleport to specified coordinates in a config file. Say X: -5000 to 5000 Z: -5000 5000 At the highest y coorninate possible.

    Also hook it into essentials so if you have a teleport command delay set in the essentials config it takes you however long the delay is without moving to teleport.

    Also if I can have the source when you are finished.

    Ideas for commands: /randomtp

    Ideas for permissions: No permissions needed.

    When I'd like it by: When ever is possible on your schedule.
     
  2. Offline

    InflamedSebi

    Nearly finished!

    commands:
    /randomtp
    aliases: [randtp, rtp]
    description: will tp you to random location.
    /randomtp list
    description: displays all locations from config.
    /randomtp add <name> <chanceMultiplier>
    description: add your current location to the config. (will override, if a location with the same name already exits)
    /randomtp remove <name>
    description:remove location <name> from config.
    /randomtp reload
    description: will reload the locations from config.

    permissions:
    randomtp.use
    description: Gives access to /randomtp.
    default: true
    randomtp.admin
    description: Gives access to /randomtp <reload|add|remove|list>.
    default: op


    Config:
    Code:yaml
    1. # debug | high | medium | low | none
    2. logging: debug
    3.  
    4. # 20 delay = 1 sec; 200 = 10 sec and so on ...
    5. delay_for_tp: 200
    6.  
    7. #each location is given like: 'worldName:X:Y:Z=chanceMultiplier'!
    8. #the chanceMultiplier defines how often this location will be called compared to a location with Multiplier = 1
    9. # in the example: 'anotherlocation' is called 4 times often than 'location1' and twice as often as 'just_a_name'.
    10.  
    11. Locations:
    12. location1: world_end:0.5:64.0:0.5=1
    13. anotherLocation: world_nether:0.5:64.0:0.5=4
    14. just_a_name: world:0.5:64.0:0.5=2
    15.  
    16.  
    17. Messages:
    18. moved: 'You moved! Teleport canceled!'
    19. initiated: 'Teleport initiated! You will be teleported in %t seconds!'
    20. done: 'You teleported to a random location!'


    plugin will be here in a few hours ... (lunch first :D)
     
  3. Offline

    danielfr789

    Sweet! When your done remember to pm me the source too. Thanks so much dude!

    And make sure you can use color codes in the messages of the config.

    Also I forgot to mention can you make it so you cant spawn on lava, cacti, water, or fire?
     
  4. Offline

    InflamedSebi

    here it is :D the source is in the .jar :D just open the jar with winRar or something similar :D

    (atm there is a know issue witch the /rtp reload command .... im working on that ...)

    if u found some errors pls tell me :D
     
  5. Offline

    danielfr789

    Where is it? I think you forgot to post the link lol.
     
  6. Offline

    InflamedSebi

    seems like the forum doesn't show attached files ...
    danielfr789

    --LINK REMOVED--

    it's a german hoster ... so just click 'Datei aufrufen' and this is ur jar :D just rename it like RandomTP.jar or something ^^
     
  7. Offline

    danielfr789

    I think you misunderstood what I meant. I meant ranges Ex. X: -5000 to 5000 Z: -5000 5000 At the highest y coorninate possible.
     
  8. Offline

    InflamedSebi

    and how to specify the world?
    or always the world of the player?
     
  9. Offline

    danielfr789

    For example world:-5000:5000:-5000:5000
     
  10. Offline

    InflamedSebi

    than some more questions:

    multiple areas per world?
    and what about hell? there is no max y ...
    will the teleport switch between worlds?
     
  11. Offline

    danielfr789

    I mean the highest block possible. No I don't need it to switch worlds. And what do you mean multiple areas per world?
     
  12. Offline

    InflamedSebi

    the plugin i wrote will randomly teleport you to one of the locations from the list ...

    now u don't want to use it for single locations ... u want areas ... so lets say:
    u have an area in world "world1" and an area in world "world2" and two areas in world "world3".

    now a player in world "world2" does "/rtp" so is this possible:

    - the player is teleportet somewhere in the area of world "world1"? yes -no?

    and multiple areas per world mean ... that there can more than 1 area per werld ... so maybe for world "world3":
    area1: -500:0:-500:-250 area2: 2500:2800:1500:1800

    and the player is teleportet into one of them ...
     
  13. Offline

    danielfr789

    Similar, but I only need one world.

    Lets say someone in the world "Factions" types /rtp

    Then they get teleported to a random spot between X: -5000,5000 Z: -5000,5000 And at the highest solid block for Y

    And they cant spawn on cacti, water, lava, or fire.
     
  14. Offline

    InflamedSebi

    okay ... I'll add this as a feature :D
    dunno if i can finis it today ... but tomorrow :)
     
  15. Offline

    danielfr789

    Ok, you don't have to add it to the current plugin if you want. The feature that you posted is all I want. (WITH A CONFIGURABLE DELAY AND DELAY MESSAGES!)

    And here are a few bugs with your current plugin.

    If you move the way you are facing (moving your mouse) the teleport cancels.

    If you take damage (with no movement) it doesnt cancel. This happens when you drown.
     
  16. Offline

    InflamedSebi

    okay ... i'll fix that ...

    this too :D

    danielfr789
    finished :D

    ill put it to bukkit.dev:

    LINK

    (may take awhile)

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 1, 2016
  17. Offline

    danielfr789

    Can you just send me the download?
     
  18. Offline

    InflamedSebi

    link to --LINKREMOVED--
    danielfr789

    also bukkit dev is ready^^
     
  19. Offline

    danielfr789

    Ok I am confused. How do I make it so I teleport to a random in world "Factions" to a random location between X: -5000 5000 Z: -5000 5000 Y: Highest solid block
     
  20. Offline

    InflamedSebi

    in fact u want to teleport to an area do:
    Code:
    mode: area
    now it will use the:
    Code:
    LocationAreas:
    and u cann add areas there in the from:
    worldName<>Xmin:Ymin:Zmin<>Xmax:Ymax:Zmax=chanceMultiplier

    your example would be:
    Factions<>-5000:0:-5000<>5000:255:5000=1

    it will alway use the highest y in the area.
     
  21. Offline

    danielfr789

    Thank you for this plugin!
     
  22. Offline

    InflamedSebi

    np ... due to there are some more people who wanted this, I m rewriting it, to improve performance/ better config and so on :D so check for updates ;)
     

Share This Page