Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Mounts?  (Read 733 times)

bloop_bleep

  • Bay Watcher
    • View Profile
Mounts?
« on: August 01, 2017, 03:24:38 am »

How is it possible to determine/set the mount of a specific creature? I'm thinking of Lua scripts again.
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

bloop_bleep

  • Bay Watcher
    • View Profile
Re: Mounts?
« Reply #1 on: August 03, 2017, 10:01:04 pm »

Apparently the unit struct has a T_relations field which itself has rider_mount_id and mount_type fields. Can I obtain/set the unit's mount by accessing these two fields?
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: Mounts?
« Reply #2 on: August 04, 2017, 01:05:46 am »

You don't want relations anymore--you want unit.relationship_ids for stuff like rider_mount_id (rather, unit.relationship_ids.RiderMount)