Inactive [MECH] TrainCarts v1.71.2 - Link minecarts of different types together to form trains [2222]

Discussion in 'Inactive/Unsupported Plugins' started by bergerkiller, Aug 3, 2011.

  1. Offline

    bergerkiller

    [​IMG]

    After a request from Marius A. Winsjansen I started to work on linked Minecarts. On the first day I already managed to make multiple carts move with the same speed, but a long list of bugs was to be expected. After fixing lots of bugs, adding lots of (complicated) Minecart handling functions and after hours of testing on my local server, this plugin is finally ready for a stable release! :D

    Also, special thanks go to @Shamebot for helping me out several times. :)

    Description:
    For a lot of information about TrainCarts see the WIKI page!

    Configuration and permissions

    All configuration nodes can be found in config.yml and contains a description with it. Permissions can be found in PermissionDefaults.yml, combined with a description.

    Media:

    Early development video (Photobucket)

    Video displaying version 0.6 of this plugin (YouTube)

    Video displaying version 1.0 of this plugin (YouTube)

    Video displaying version 1.1 of this plugin (YouTube)

    Video displaying version 1.2 of this plugin (holy...)


    A tutorial video in German explaining various sign-circuitry of TrainCarts


    PhotoBucket Sign system tutorial videos (also linked in the WIKI pages)
    Train spawner / Stations / Stations2 / Arrival signs / Train teleportation / Track switcher based on tags / Destinations / Blocker
    Video of how the switcher, station and destination signs work together

    Side information:

    It works best on straight lines with not too much elevation changes followed up by sharp corners. As long the cart gap can be adjusted, everything goes fine. It had some collision issues in the past, but I fixed all of that by manipulating the actual Minecraft server native code. I added links in the source where this was appropriate. Sharp 'U'-turns cause individual carts to lose perceptive of their direction. Keep at least one piece of track in between corner sections! Trains are stored on-disk when reloading and stopping the server, so expect trains to be there when you return.

    Important when updating: do one reload to save all trains, then replace traincarts.jar, and then do another reload. This next reload will probably cause a noClassDefFound exception (since the old jar got replaced), this is why a pre-reload is required. Replacing the jar without reloading is a very bad idea: it will cause a lot of runtime exceptions. Best is of course to stop the server and start again, but this is not always possible.

    This plugin is made compatible with Minecart Mania. If you notice a certain feature of Minecart Mania is not compatible with TrainCarts, notify me and I'll fix it. :)


    Known bugs:
    - None.

    TODO:
    - Train-sign message handling using SignLink (low priority)
    - Minecart use permissions (for individual carts?) such as Storage Minecarts

    Commenting

    If you encountered a bug, post exactly what you had done and in what order. Even a slight wobble can help fixing bugs. When posting (long) errors I recommend you to post everything, don't cut it off. I work with native methods, so in my case these lines are important. For comments on the media content see YouTube, it also contains a description with the music name when music is used.

    Bug reporting (extend)

    1. Post the Craftbukkit version you are using (the first info message in the console)
    2. Post the log from where the first plugin gets enabled to the 'done'.
    3. Post possible errors in this log too (don't cut them short)
    4. No error? Still post the log. Also explain how I can reproduce it, you can use screenshots
    5. Before reporting, remove ALL plugins other than TrainCarts and try again. If it works then, find out what plugin is interfering and post that here. I can add support.
    6. ALWAYS use the latest recommended Craftbukkit build with this, or my methods may just fail because of renamed functions.

    Important links:

    Request thread
    TrainCarts on BukkitDev for download and more
    TrainCarts source and more on GitHub
    TrainCartsBlocks add-on source and more on GitHub
    SignLink Bukkit page (required to use Arrival signs)
    MyWorlds Bukkit page (required to use Portal train teleportation)

    notice: try to keep SignLink/MyWorlds up-to-date to prevent compatibility issues.

    Installation for those that don't know how

    1. Download and install the latest craftbukkit version
    2. Download the latest TrainCarts version
    3. ^ Save the archive (zip file) to your computer
    4. ^ Open the archive you just downloaded
    5. In the folder your server sits in, create the plugins folder if it doesn't exist
    6. Open the plugins folder
    7. Move the TrainCarts.jar file found in the archive into the plugins folder
    8. Run your craftbukkit server and look in the console/log for possible errors, and/or if the plugin is enabled.

    Changelog

    Show your appreciation for my plugins by donating
    [​IMG]
     
  2. Offline

    tomas1523

    meh. it conflicts with
    HTML:
    http://forums.bukkit.org/threads/misc-dynmap-v0-25-realtime-minecraft-maps-1337-1493.489/
    dynmap
     
  3. Offline

    ledhead900

    Care to explain how ?
     
  4. Offline

    tomas1523

    i don't know how.. i was expenting a fix
     
  5. Well, 1.49.4 seems to work, did not yet try teleportation but the rest seems ok. If there's only one thing which could be better, it's the fact that you can't push a cart you dropped on the rails by yourself. Anyway, NPE seems to be fixed, at least, after 10 hours i did not see any, so, good job mate!
     
  6. Offline

    bergerkiller

    @ledhead900 We don't celebrate Thanksgiving here in the Nether, but thanks anyway :)

    Couldn't locate the issue you mentioned, it never disconnected for no reason...
    Just a question: Does increasing the max cart distance have any effect? If no, then it must be something with cart ordering going wrong.
     
  7. Offline

    BeBuzz

    Hi all,

    Using last TrainCarts 1.49.4 ( with last SignLink 1.12 and last myWorlds 1.3 ) on CB 1337 since today, I have two problems :

    My objective is : station1 -> station2 -> station3 -> station1, with stop 5 and continue always ...

    1. When I push one Minecart with the Sign :

    [train]
    station
    5
    continue

    the Minecart goes and, after maybe 1 turn, stop in the middle or anywhere. And when I run to found where is the Minecart and when I see him, maybe he continue, maybe not !!! And I must destroy them and build an other train.

    2. If I push 2 Minecarts : they stop maybe after 10 seconds !!!

    Maybe is it possible to make an other plan route without station ?

    PS: sorry for my english, I am French ...
     
  8. Offline

    bergerkiller

    @BeBuzz try setting 'keepchunksloaded' to true:
    This way the train won't unload when no player is near. Note that this does increase the amount of loaded chunks.
     
  9. Offline

    ledhead900

    Will take a look and find out :)
     
  10. Offline

    1000bodies

    Hey. I made a rollercoaster with this and I have to say it's pretty awesome :)
    There is an huge jump and when the minecart stops the player in it dies. Can you maybe fix that or remove fall damage in minecarts? Thanks!
     
  11. Dude, more than one minecart linked together, spawned carts, are not reacting on boosters again...... I think 1.47 was just perfect, expect the fact that you can't teleport with carts
     
  12. Offline

    bergerkiller

    @1000bodies it is somewhat on the TODO list, haven't had time to look into it lately...

    @Psychokiller1888 sigh I honestly have no idea what it is then. It's as secure as can be.
     
  13. Offline

    1000bodies

    Okay great. I'll keep watching this thread :)
     
  14. Mmmh, tried just now. I have a destination selector (not this plugin, a vanilla one, using redstone), with buttons. By clicking on any of the buttons, you switch the tracks in the station, and spawn a single minecart. Clicking it again spawns another minecart. After spawn, they go to a waiting station, where you have 20 seconds to step in. If a single cart is waiting, the boosters are ok. If you spawn 2, they won't boost anything....
    EDIT
    Portals not working either. spawners spawn multiple carts sometimes....... The portal is checked, and works when walking :)
     
  15. Offline

    dockter

    Is there anyway to get this mob to kill mobs and animals when they come into contact with a traincart?

    Problem I am having is that on my long routes, the traincarts are bouncing off mobs and returning home instead of getting to their destinations. Please advise.
     
  16. Change your settings, turn on the pushing away option, so the mobs won't be a problem anymore.
     
  17. Offline

    ledhead900

    @bergerkiller
    I think you may need to look into it, I don't want to be a pain in the ass but they really are disconnecting when no one is on the server I have proof this time I don't know why they would do it. This did not happen a few versions ago I think around time u fixed teleporting and pre destination they worked.

    PHP:
    # In here you can change the settings for the TrainCarts plugin
    # Please note that the default settings are usually the best
    # Changing these settings can cause the plugin to fail
    # To reset the settings, remove this file or set 'use' to false to ignore these settings
    # ======================================================================================
    # cartDistance is the distance kept between normal/turned carts in a group
    # cartDistanceForcer is the factor applied to adjust this distance, too high and it will bump violently
    # nearCartDistanceFactor is the factor applied to the regular forcers if the carts are too close to each other
    # removeDerailedCarts sets if carts without tracks underneath are cleared from the group
    # maxCartSpeed is the maximum speed to use for trains. Use a value between 0 and ~0.4, > 0.4 can cause derailments!
    # maxCartDistance sets the distance at which carts are thrown out of their group
    # breakCombinedCarts sets if combined carts (e.g. PoweredMinecart) breaks up into multiple parts upon breaking (e.g. furnace and minecart)
    # spawnItemDrops sets if items are spawned when breaking a minecart
    # exitOffset is the relative offset of where a player is teleported when exiting a Minecart
    # pushAway settings are settings that push mobs, players, items and others away from a riding minecart
    #    atVelocity sets the velocity of the minecart at which it starts pushing others
    #    force sets the pushing force of a pushing Minecart
    #    pushMobs sets if mobs are pushed away
    #    pushPlayers sets if players are pushed away
    #    pushMisc sets if misc. entities, such as boats and dropped items, are pushed away
    # keepChunksLoaded sets if chunks are loaded near minecart Trains
    setOwnerOnPlacementtrue
    removeDerailedCarts
    false
    normal
    :
      
    cartDistance1.7
      cartDistanceForcer
    0.1
    pushAwayForce
    0.2
    use: true
    maxCartDistance
    4.6
    spawnItemDrops
    true
    keepChunksLoaded
    false
    turned
    :
      
    cartDistance1.8
      cartDistanceForcer
    0.2
    maxCartSpeed
    0.23
    useCoalFromStorageCart
    false
    exitOffset
    :
      
    z0.0
      y
    0.0
      x
    0.0
    breakCombinedCarts
    false
    poweredCartBoost
    0.5
    nearCartDistanceFactor
    1.2
    pushAwayIgnoreGlobalOwners
    false
    pushAwayIgnoreOwners
    false
    Taken as soon as I logged in after a couple of days I realized that my test server does not do automatic restarts so it cannot be that it must be chunk unload/train group issues.

    The train/carts actually spawn roughly like that stationary, sometimes they are closer and in a line but are not linked as I can push them together and they make the linkage noise and effect.

    Btw this is/was after I just updated to the latest 1.0 version that had your new changes but it happens in reco as well.
    [​IMG]
     
  18. Offline

    bergerkiller

    @ledhead900 Mmmh do you use NoLagg and the 'chunkUnloadDelay' feature it has? If yes, does setting 'useChunkUnloadDelay' to false fix this issue? I get the idea that it fails to handle chunk unloads properly.
     
  19. Offline

    ledhead900

    Nope I was not aware any of those two were updated for 1.0 development builds.

    I use Myworlds,This,Signlink,Streamremover out of your plugin set.
     
  20. Offline

    dockter

    I already have this on, still doesn't push them away.
     
  21. Offline

    bergerkiller

    @dockter these settings are now in defaultflags.yml. Setting them in the config.yml file will no longer work. (see also the WIKI)
    You can also try the command for it, after selecting the train:
    Code:
    /train pushplayers true
     
  22. Offline

    Dzejkob

    Hm, I've tried this plugin on CB 1518 and it doesn't work, carts didn't link and signs didn't work. I don't know, if version 1.49.4 should work fine on MC 1.0?
     
  23. There's a version meant for MC 1.0
     
  24. Offline

    Dzejkob

    As I said, it doesn't work... Carts doesn't link and signs doesn't do anything, in server.log it said, that plugin is successfully enabled.
     
  25. Offline

    bergerkiller

    Problem is that @Thulinma manages the 1337 -> v1.00 exporting, so not sure what went wrong. I'll look into it at some point...although linking did work when I tested it on a 1.00 server.
     
  26. Offline

    ledhead900

  27. Offline

    kris76

    Hello, it sounds like a great plugin ! I tried it but trains are not persistent at server restart. No config is saved and minecarts are no more linked or often disapear. I use CB1337 + 1.49.4. Since it's the first time I use it I don't know what to expect to find in config files. trainflags.yml is empty and trains.GROUPDATA contains NULL chars. I get no errors in server.log.
     
  28. Offline

    dockter

    /train maxspeed 0.1 doesn't slow the maxspeed of the train by a factor of 4.

    What do I need to do to slow these down?
     
  29. Offline

    bergerkiller

    @kris76 Could be many things, first of all make sure you stop the server using /stop or /reload. Also make sure the plugins folder has IO access by the OS. If the trains work in-game, then they should be saved as well.

    @dockter Which version are you using, the CB 1337 or 1.00 version? Using that command should instantly slow them down (except in stations though)
    Does it work in general? (simple clean straight track, place a minecart, set max speed and push)
     
  30. Offline

    ledhead900

    @bergerkiller
    I got more news on my train issue.

    It appears its not just on chunk unload train just randomly un groups and stops when out of view, does this after a couple trip it is quite strange. Maybe you can come on and look at it see if I cant reproduce it
     
  31. Offline

    Elmardus

    This looks like a nice plugin, but it almost destroyed my server. Because it put the WHOLE map full of minecarts, that created SO much lag, that I couldn't start up the server..!
     

Share This Page