About This File
Framework that allows you to attach REAL leashes to NPC's and either have them guide you around, or you guide them. No real limitation, you can make a huge train if you wanted.Â
Â
I'm releasing this in it's current beta state! I've yet to find any serious bugs, but I do want to gauge the community to see if this mod is worth continuing further or expanding upon.Â
Â
Â
Â
Features
- Rich Papyrus API for connecting actors together in any order you will
- Advanced physics system that takes full advantage of HAVOK
- Easy to use debug menu for testing, or just using the mod freely
- Zero package interruption, this mod has it's own built-in AI system, pathfinder, and locomotion system. Your mod's packages will never be touched!
- Full support for the player actor, other actors, etc. No animal support yet, although that wouldn't be difficult
- Contains two test leashes by @kzrp to mess around with
- Supports ANY/ALL leashes, they just need a series of bones for this mod to move around! This means that all the chain collars in devious devices are fully compatible!
Â
How to use (Without Papyrus API)
- Enough the leash to the actor (Or a leash, it can be any leash like from devious devices)
- Go into the SKSE Mod Menu using `f1`, find this mod. Open `Debug`.Â
- Select the leasher, and the leashed. Leasher MUST have that leash equipped, the mod doesn't do it for you - stop being lazy
- The parent bone is `NPC Spine2 [Spn2]` for the included leash. This can be any parent of the chain bones, even just NPC
- The `Leash Bone Match` is `Leash1` for the included leash. This is the prefix of the bones (or common name) in your leash
- Select a minimum distance, like ~200+. Don't go too low or it'll be fucked.Â
- `Persistent` means it'll persist with your save.Â
- Click `Leash actor`
- Enjoy
- (Note: Make sure the collar/leash is equipped to the actor, this mod doesn't auto equip it)
Â
For a funnier experience, go into `Settings` and enable `Forced recovery for NPCs`. This will rag doll the actor once they exceed the distance threshold. Works well!
Â
Known issues/limitations
- The leash will visibility disappear if the leashed actor is not on-screen. This is due to screen culling. Fixable, but I don't know if it's work it - you tell ME. It still functions fine
- An actor can get stuck obviously. There's no teleport recovery yet
- The collision isn't perfect. I tried to make it perfect and it was too heavy. So instead it only collides with the surfaces of materials such as the ground, etc. You can enable actor collision in the SKSE Mod Menu too, but that uses the havok hull not the physical body meshes so not perfect
- The less bones in the leash, the more fucked it'll be when stretching a long distance
- Mod still lacks polish obviously. It's polished in loverslab standards though!
- Only supports right hand, because left handed people are satan spawns (Other hands will be supported in the future)
Â
Requirements
- Skyrim SE/AE (Doubt VR support works, this required a lot of reverse engineering)
- SKSE Mod Menu Framework (Optional for the mod menu)
Â
Papyrus API
Scriptname LeashFramework Hidden ;/ Connects a leash from a holder's right hand to leash bones on another actor. holder: Actor holding the leash. The current attachment bone is NPC R Hand [RHnd]. leashed: Actor wearing the leash mesh. An actor can have only one active leash. parentBone: Exact node name to find on the leashed actor before searching its descendants. leashBoneMatch: Text found anywhere in each ordered leash bone name beneath parentBone. For example, Main_ matches hdtSSEPhysics_AutoRename_Armor_00000004 Main_01 after SMP renames the node. minLength: Distance where active leash pulling stops. Must be zero or greater. maxLength: Maximum holder-to-collar distance. Must be positive and at least minLength. persistent: When true, the leash is saved and restored until explicitly disconnected. Applying another leash to the same leashed actor replaces its current leash. Returns true when the arguments are valid and the leash is accepted. /; Bool Function ApplyLeash(Actor holder, Actor leashed, String parentBone, String leashBoneMatch, Float minLength, Float maxLength, Bool persistent) Global Native ;/ Disconnects the leash matching the specific holder and leashed actor. holder: Actor holding the leash. leashed: Actor wearing the leash mesh. Returns true when the matching leash was disconnected. /; Bool Function DisconnectLeash(Actor holder, Actor leashed) Global Native ;/ Disconnects every leash where actor is either the holder or the leashed actor. Returns true when at least one leash was disconnected. /; Bool Function UnleashAll(Actor actor) Global Native ;/ Returns true when actor currently has an active leash. /; Bool Function IsLeashed(Actor actor) Global Native ;/ Returns true when actor currently holds at least one active leash. /; Bool Function IsLeashHolder(Actor actor) Global Native ;/ Returns the actor holding leashed's active leash, or None when leashed has no active leash. /; Actor Function GetLeashHolder(Actor leashed) Global Native ;/ Returns every actor currently leashed to holder. Returns an empty array when holder has no active leashes. /; Actor[] Function GetLeashedActors(Actor holder) Global Native
Â
Future todos:
- Allow attaching the rope to specific bones rather than just the right hand
- Add explicit API to disable walking control (For now just set minLength/maxLength to high numbers so it never triggers)
- Improve the pathfinder for walking more. Seems to actually function better than Skyrim's, but there's always room for improvement
Source code:
(Soon, check my github in a few days)