Checking for Minecart at Specific Location - Possible?

Discussion in 'Plugin Development' started by Intelli, Jan 24, 2011.

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

    Intelli

    Hey everyone,

    Is it possible to check for a minecart at a specific location?
    For example, finding if a minecart is located at x,y,z.

    Any help is greatly appreciated!

    Thanks!
     
  2. Offline

    nachotp

    better try if it is over a X Block just like what minecart mania does
     
  3. Offline

    Afforess

    MinecartManiaCore has a helper method you can use, MinecartManiaWorld.getMinecartAt(x,y,z). Just add MMC to your libraries, call it up, and go.
     
  4. Offline

    Intelli

    Hmm,, sounds handy.

    However, if I weren't to use MinecartManiaCore, is there any default functionality within bukkit to do this?
    Or would I ultimately need to have the server manually keeping track of the location of all the minecarts?
     
  5. Offline

    Afforess

    Bukkit does not keep track Of entities for you like Hmod did, you'd need to write a lot of code to do it w/o MMC
     
  6. Offline

    Intelli

    Alright, thanks.

    One last question: How do I speed up a minecarts speed? I assume that this is possible with setVelocity(), however, I haven't had much luck when messing around with it.

    If anyone knows how to do this, your answer is greatly appreciated =]
     
  7. Offline

    Afforess

    setVelocity takes a vector. Vectors consist of an X, Y and Z value. It's just a fancy object to represent 3 double values, don't let it confuse you.
     
Thread Status:
Not open for further replies.

Share This Page