Sign in to follow this  
Kodos

Horse/walking movement speed

Recommended Posts

I've been looking through the code but have been unable to find where walking or riding speed is determined.  Anyone know which class the code is in?

 

Thanks,

 

Kodos

Share this post


Link to post
Share on other sites

Some related content in com.wurmonline.server.behaviours.Vehicles and com.wurmonline.server.behaviours.Vehicle (server.jar).

A mount is a vehicle. In these classes there are methods for creature mounts and item mounts.

 

Some more content in com.wurmonline.shared.util.MovementChecker (common.jar). Be warned as this is the worst code I've seen so far during while modding. I was trying to make mod to snap vehicle orientation to one of the 8 major orientation (N,NE,E,SE,S...etc). I ended up giving up.

Share this post


Link to post
Share on other sites

The main code that checks traits and so on is in Creature.getMountSpeedPercent, it's then applied in MovementChecker... but as joedobo said it's a horrible mess :P

Share this post


Link to post
Share on other sites

Movement is a huge mess, if you aren't careful things will start to move backwards instead of forwards especially boats.

 

You can increase the horse speed a few km/h in the Vehicles.class though.

Edited by Sklo:D

Share this post


Link to post
Share on other sites

I'm not sure if this will help you at all, as I'm still learning to understand how all these pieces work together, but on line 2478 of the 'CreatureTemplateCreator.class' is the Temp for horses and on line 2488 there are a ton of variables being made. I used line 76 in 'CreatureTemplateFactory.class' to find out what the numbers and strings were for and the last float passed in the horse template (1.5f) is for speed according to the factory class. I'm not sure if changing this would affect the horse while you're riding it or only while it is roaming but I thought I'd throw it out there to see if it helps or if someone knows what it does do.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this