I have an issue with a minor POC I'm playing with.
I have stumbled on a way to use the mouse wheel to scroll through weapons, spells, ammo, etc. (anything that can be hotkeyed) using a combination of Skyranger-1's Super Hotkeys mod (and his cycler items), a disabler mod for the mouse wheel's control of the vanity camera, and an Oblivion.ini tweak that clones two of the vanilla hotkeys onto the mousewheel up and mousewheel down.
The Oblivion.ini is set up like this:
Quick6=000708FF
Quick7=000809FF
So that the 6 & 7 hotkeys are set to both the normal number keys and to the mousewheel up and mousewheel down.
With item cyclers placed in those hotkey slots with Super Hotkeys rolling the wheel up scrolls through one, and down scrolls through the other.
However, some people actually use the mouse wheel to control the vanity camera, so I was trying to work out a way to give both options. I was thinking I could use a modifer key to enable/disable the vanity camera and enable/disable those two hotkeys in the opposite state. I tried it this way:
scn jawmousewheeltestscriptfloat fQuestDelayTimeBegin Gamemodeset fQuestDelayTime to .0001If IsKeyPressed2 11 == 0 setnumericgamesetting fVanityModeWheelMult 0.0000 EnableControl 23 EnableControl 24 printc "key not held, controls enabled"elseif IsKeyPressed2 11 == 1 setnumericgamesetting fVanityModeWheelMult 0.1000 DisableControl 23 DisableControl 24 printc "key held, controls disabled"EndifEnd
This kind of works, the vanity camera does become available when the 0 key is held down, but the mousewheel still activates the hotkeys even though the numeric keys are disabled.
And I tried this way:
scn jawmousewheeltestscriptfloat fQuestDelayTimeBegin Gamemodeset fQuestDelayTime to .0001If IsKeyPressed2 11 == 0 setnumericgamesetting fVanityModeWheelMult 0.0000 EnableKey 264 EnableKey 265 printc "key not held, controls enabled"elseif IsKeyPressed2 11 == 1 setnumericgamesetting fVanityModeWheelMult 0.1000 DisableKey 264 DisableKey 265 printc "key held, controls disabled"EndifEnd
but it had no effect at all on the mouse wheel activating the hotkeys.
Anyone see an issue or have a suggestion?
edit: Does anyone know how SetStringIniSetting works? Is this even close?
scn jawmousewheeltestscriptfloat fQuestDelayTimestring_var testerstring_var tester1Begin Gamemodeset fQuestDelayTime to .0001If IsKeyPressed2 11 == 0 setnumericgamesetting fVanityModeWheelMult 0.0000 SetStringINISetting "Quick6|000708FF" SetStringINISetting "Quick7|000809FF" set tester to getstringinisetting Quick6 set tester1 to getstringinisetting Quick7 printc "Quick6 is %z" tester printc "Quick6 is %z" tester1elseif IsKeyPressed2 11 == 1 setnumericgamesetting fVanityModeWheelMult 0.1000 SetStringINISetting "Quick6|0007FFFF" SetStringINISetting "Quick7|0008FFFF" set tester to getstringinisetting Quick6 set tester1 to getstringinisetting Quick7 printc "Quick6 is %z" tester printc "Quick6 is %z" tester1Endif