Brehanin Posted July 11, 2013 Share Posted July 11, 2013 I have successfully used the Input.Tapkey() command to create customizable hotkeys for the shouts in my mod, Better Vampires, but I cannot for the life of me get the script to tap or hold a mouse button down ... Here is a sample of my script. This snippet is intended to cast Mortal's Mask by equipping it in the left hand, then simulating a RMouse button press to cast it. If BVKeyPressed == BVMortalsMaskHotkey If Game.GetPlayer().HasSpell(VampireRemoveHateSpell) Game.GetPlayer().EquipSpell(VampireRemoveHateSpell,0) Int MappedLeftKey = Input.GetMappedKey("Left Attack/Block") Input.HoldKey(MappedLeftKey) Utility.Wait(3.0) Input.ReleaseKey(MappedLeftKey) EndIf EndIfWill Input.Tapkey() and Input.Holdkey() not work for simulating mouse buttons? They work perfectly fine for keyboard keys. I am using all the correct DXScancodes too - I've confirmed that the MappedKey is 257 (the RMouse button). Any help woudl be greatly appreciated! Can I do this differently? P.S. Ive already tried using the Cast spell procedure, but it casts automatically and doesn't use any Magicka. Also, with the cast procedure, once-a-day powers can be spammed indefinitely, so I wanted to make the use and casting as normal as possible. Link to comment Share on other sites More sharing options...
Recommended Posts