What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

How to know if the player is capable of mounting?

Neverdyne

Community Developer
Joined
Sep 12, 2014
Messages
650
Reaction score
20
This has been eluding me. The Actionmanager.CanMount property returns a uint. What does that value mean?
 
I'm going to guess it's the Mount's ID (so you can specifically check to see if the Chocobo mount is available, or some other mount). Could be wrong though (I've never used it). :cool:
 
Thing is it just returns one number without any parameters, so is that the default mount's id? I just tested with a character that hasn't gotten the chocobo yet and it returned 653.
 
Actually I just tried:

Log(Actionmanager.CanMount);

Regardless of my state it returns 0.

I also tried:

Log(Actionmanager.MountId);

Regardless of what mount I'm on it returns 1.

Maybe the offsets are broken? mastahg might have to chime in.

Actionmanager.AvailableMounts works but that does you no good lol.
 
I guess I could check with "Actionmanager.AvailableMounts.Length > 0". That API call seems to be new.
 
Last edited:
Oh, you're wanting to know if the user has obtained a mount yet, not if they are capable of mounting? Yeah that could work then.

foreach (var Mount in Actionmanager.AvailableMounts)
{
Log(Mount);
}

Returns what mounts the player has (in string form) but I'm not sure what could be done with that (what I was referring to earlier). :o
 
Yeah it's just for my movement logic, don't want to try and mount if the user doesn't even have mounts yet.
 
Yeah it's just for my movement logic, don't want to try and mount if the user doesn't even have mounts yet.
Wasn't there a way to check the players speed. (MovementManager.Speed Property )So if your move check speed and then try to mount and check speed . if the speed is still the same i did not mount and one could assume he hasn't gotten the mount yet.
 
Actionmanager.CanMount == 0

Really should make it a bool and invert it, but as it stands it returns the errorcode so no error means its ok to mount.
 
Actually I just tried:

Log(Actionmanager.CanMount);

Regardless of my state it returns 0.
Actionmanager.CanMount == 0

Really should make it a bool and invert it, but as it stands it returns the errorcode so no error means its ok to mount.

If it's working as intended, then does that mean CanMount just returns if the player HAS a mount (and not if the player is actually available/able to mount)? If so, is there any way to check for that then (technically checking for the ability to Sprint or Cast would work but they wouldn't be consistent)?
 
Last edited:
Core.Player.IsMounted to check if you are currently mounted.
If it's working as intended, then does that mean CanMount just returns if the player HAS a mount

No.
CanMount checks if you can mount hence its name, canmount
 
Hrm, thanks for the info. I'll have to do some more testing when I get back on tonight. I could swear it was returning 0 even when I was already mounted (didn't try while in combat or in town). I suppose if CanMount doesn't check for IsMounted one could just combine them. Thanks again. :cool:
 
Hrm, thanks for the info. I'll have to do some more testing when I get back on tonight. I could swear it was returning 0 even when I was already mounted (didn't try while in combat or in town).
The mount ability can be used while mounted so that's an invalid test case.
 
Back
Top