Inactive [On Hold] [MISC] ConstantSpeed v1.0 - Ensuring a fixed minecart speed when needed [1060]

Discussion in 'Inactive/Unsupported Plugins' started by weeknie, Jul 11, 2011.

  1. Offline

    weeknie

    ConstantSpeed - Ensuring a fixed minecart speed when needed
    Version: v1.0

    With this plugin you can ensure a minecart has a fixed speed from a certain point or in a certain area.
    Example uses are a race or a moving queue

    The default value for speed is 0.5;
    Signs can be used to change the default value, any value between -1E15 and 1E15 is allowed (almost no visual difference for any value higher than ~0.8/0.9 though).
    This means you can also use the speed 0.0 to stop any minecart at that block or a negative value to reverse the minecarts speed (negative speed doesn't work with areas)

    The way to set up a sign is the following:
    1st line: constantspeed
    2nd line: <speed> (anywhere between -1E15 to 1E15)

    Searching for the sign follows this pattern: N, NE, E, SE, S, SW, W, NW, 1 block away;
    When a valid sign has been found, the search will immediately stop.

    Note: due to technical reasons the plugin won't set a speed if you're driving through a curve, which means that if your area has a lot of curves in it, the cart *will* slow down until it reaches a straight piece, at which point the plugin will again set the speed.

    Todo:
    • Make sure the sign doesn't have to be on a certain blocktype to work
    Features:
    • Set the minecarts speed to a certain value when driving over a block of wood (one time set)
    • Set the minecarts speed to a constant value when driving over a block of sand, speed will remain at that value until the minecart passes another block of sand
    • Change the speed by placing a sign next to the track (at the same level as the track!), in a radius of 3x3, 1 bock in every direction
    • If an area was started by a block of sand controlled by a sign, only another block of sand with the same speed value on the sign will end the area, else the speed will be adjusted to the latters value.
    Download: http://dl.dropbox.com/u/5202392/ConstantSpeed.jar
    Sources are included in the jar

    Changelog:
    v 1.0:
    • Released my plugin
     
  2. Offline

    Black_Fox

    I was looking for some mod to allow for taking timelapse pictures in movement, so this is a life-saver (set it to around 0.01).
    For other people that have problems setting thing up and don't understand the help properly - this is how you set things up:

    [​IMG]
     
  3. Offline

    weeknie

    Thanks for the picture, maybe I should've done that:p (btw the sign shouldn't have to be on sand, but that doesn't matter)

    And glad to have helped with this plugin, we're currently using this for a race, so that both players start with the same speed
     
  4. Offline

    Black_Fox

    We may have made some other mistake, but the plugin really does not work when the sign stands on the dirt, just tested with 953 :p

    (EDIT: If I just switch sand for dirt under the sign on that picture)
     
  5. Offline

    weeknie

    Hmm, well I guess I'd have to see what's going on then, it shouldn't require that:p
     
  6. Offline

    weeknie

    Made an oopsie in my thread title, fixed that.
    Now this plugin is findable again:p
     
  7. Offline

    Ben Baptist

    This plugin is awesome! By the way, is it possible to speed minecarts faster than the current speed cap?
     
  8. Offline

    weeknie

    A higher value than ~0.8 won't give you any visual speedup, it will only give your minecart more "energy", ie it will keep going for longer
    1E15 is a very, very big number, I don't see why you would want it higher anyway
     
  9. Offline

    Ben Baptist

    Ah, thanks. I just have a minecart track that spans over 5000 blocks (all legit, took forever to build) and it takes quite a long time to get to each end. However, now that I think of it, it's kind of cool that it takes so long. More realistic.
     
  10. Offline

    weeknie

    I won't be working on this for a couple of weeks/months, got some other things I want to do
     
  11. Offline

    Superspeed500

    I am going to test this tomorrow. Hope you Will continue with the devlopment very soon!
     
  12. Offline

    weeknie

    I doubt it, especially not this plugin, it's pretty much done and not that interesting for me anyway
     
  13. Offline

    Ben Baptist

    What about updating for newer versions of bukkit?
     
  14. Offline

    weeknie

    If something breaks and someone tells me about it I could take a look;)
     
  15. Offline

    kajar9

    Can we have update for 1.1-R5 and R6?
    It seems it ceased to work, and even to load.
     
  16. Offline

    weeknie

    Hmm...well, I haven't looked at bukkit for a good half year, I'm not even sure I have the sources anymore...
    Also, I don't really have the time...nor the will, tbh...to work on this anymore.
    If you really insist though, I could take a look
     
    kajar9 likes this.
  17. Offline

    sebihepp

    I have rewritten the sources for Bukkit 1.2.5-R1.0
    If weeknie allows me to share, I could upload it.
     
  18. Offline

    weeknie

    Go for it, as long as you mention me I'm fine with any updates you make ^_^

    You may even take over the plugin completely, as long as you, as said, mention me;)
     
  19. Offline

    sebihepp

    I changed the package to my name to avoid conflicts with your other plugins. I changed the name in the yml file to "ConstantSpeed by weeknie|sebihepp", so everyone should know you. =) Oh, and the Version in the yml file will be the version of the compatible bukkit release. ;)

    I also had to change the search pattern for the sign. I hope it is still N, NE, E, ...

    Here's the link: http://www.gatewayheaven.com/~sebihepp/minecraft/ConstantSpeed.jar

    If anyone experience problems, please report in this thread.

    best regards
    sebihepp

    Okay, I used not allowed characters for the plugin name. So I changed it to "ConstantSpeed by weeknie and sebihepp".
    And I added a new feature: Acceleration/Decceleration!
    In the third line of the sign you can specify the accel/deccel until the speed of the second line is reached.

    "0.0" or just nothing in third line means instant accel/deccel - so it is backward compatible.
    "1.0" means no accel/deccel - sign is useless
    "1.1" light accel
    "2.0" fast accel
    ...

    Only use values greater than "1.0". The cart detects if it needs to accel or deccel and calculates the deccel value (1/accel) automaticly. Values less than "1.0" results in decceleration to stop if the speed on the sign is greater than the current speed, and acceleration until infinity if the speed on the sign is less than the current speed.

    I also optimized something of the code. Speed and Acceleration are now stored for each minecraft instead of calculating them each time again.

    I uploaded the new version - link is the same.

    Have fun!

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

Share This Page