Solved mob riding another mob

Discussion in 'Plugin Development' started by vtg_the_kid, Dec 6, 2013.

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

    vtg_the_kid

    anyone know how to make a cow ride a bat
     
  2. Offline

    Wolfey

    Try this:
    Code:
    	public void mobRiding(Player p) {
    		Entity bat = p.getWorld().spawnEntity(p.getLocation(), EntityType.BAT);
    		Entity skeleton = p.getWorld().spawnEntity(p.getLocation(), EntityType.SKELETON);
    		bat.setPassenger(skeleton);
    	}
    
     
    vtg_the_kid likes this.
  3. Offline

    Garris0n

    Did you put any effort into searching this first?
     
  4. Offline

    vtg_the_kid

    Garris0n
    Yes, in google a bunch of plugins showed up, and I realized I should have searched in plugin development.
    But, your question was
    so yes, because I have put some effort into searching this. But thanks for asking that question anyways.
     
  5. Offline

    Garris0n

    Try something like this next time.
     
Thread Status:
Not open for further replies.

Share This Page