Plugin category: Transportation Suggested name: Uh.. HorseModify? I'm terrible at this What I want: The ability to change a horse's jump height and speed with a command Ideas for commands: /horsemodify {jump/speed} {integer} - self-explanatory Ideas for permissions: horse.modify When I'd like it by: Yesterday. It's not like I can influence your choice.
Infectedd Do you mind about using RemoteEntities (external plugin) because there's no good way to edit a horses speed without potion effects (unless you don't mind the potion effects).
Jump height is already a part of my plugin http://dev.bukkit.org/bukkit-plugins/mtc-horses-plus/ the download link isnt approved yet so you can get it here http://goo.gl/xn44M I am looking on adding speed adjustments
Speed is an attribute on every living entity now and jump heigth is an attribute on horses. https://github.com/Bukkit/mc-dev/blob/master/net/minecraft/server/EntityLiving.java#L13 https://github.com/Bukkit/mc-dev/blob/master/net/minecraft/server/EntityHorse.java#L9
Interesting , but it didn't change the speed of horses, but this works Code: public Double getHorseSpeed(Horse h){ AttributeInstance attributes = ((EntityInsentient)((CraftLivingEntity)h).getHandle()).getAttributeInstance(GenericAttributes.d); return attributes.getValue(); } public void setHorseSpeed(Horse h,double speed){ // use about 2.25 for normalish speed AttributeInstance attributes = ((EntityInsentient)((CraftLivingEntity)h).getHandle()).getAttributeInstance(GenericAttributes.d); attributes.setValue(speed); }
Interesting the only thing about attributes is I think after every update they usually become broken. Although I will definitely add that into my plugin today. Infectedd
Ewe Loon Hey I was trying out this code but I was having a lot of problems such as classes not existing... I could use some help if you would like to
you need to import the classes from craftbukkit not bukkit thats the jar file you run not the api these are the necessary imports import net.minecraft.server.v1_6_R2.AttributeInstance; import net.minecraft.server.v1_6_R2.EntityInsentient; import net.minecraft.server.v1_6_R2.GenericAttributes;
timtower yes I did I added to my build path craftbukkit.jar even if i do import net.minecraft.server.*; It still gives me an error with "no suggestion" EDIT by Moderator: merged posts, please use the edit button instead of double posting.