Open BarRaider opened 2 years ago
I've also noticed duplicates in GetHotKeyList. Also, not sure if it's related to this issue but sometimes I can run one command but not another. Example, libobs.mute will mute an audio source but libobs.unmute will not unmute it. Or libobs.show_scene_item will show a scene but libobs.hide_scene_item will not hide it.
I can confirm the behavior as described. I came across this issue because I am looking for a solution
Can confirm the same issue as @onyx-and-iris, I'm trying to hide and unhide a scene item and while hiding works, unhiding does nothing.
I also can confirm that @electricplant's workaround does work, but it is a bit cumbersome to setup multiple assigned hotkeys, especially if you have a lot of items that you want to hide/unhide.
If you don't want a lot of assigned combos to common keys, you can do @electricplant's workaround AND change the keybinds on the scenes JSON to be a key that no one uses (all hotkeys: https://github.com/obsproject/obs-studio/blob/master/libobs/obs-hotkeys.h)
"TriggerHotkeyByName", "libobs.show_scene_item.mediaSourceItem" seems to work, but "TriggerHotkeyByName", "libobs.hide_scene_item.mediaSourceItem" does not
"TriggerHotkeyByName", "libobs.show_scene_item.mediaSourceItem" seems to work, but "TriggerHotkeyByName", "libobs.hide_scene_item.mediaSourceItem" does not
I second this. None of the hide ones work, but the show ones do. Any ideas? Bad code?
OBSBasic.StopRecording
is also a dud
Operating System Info
Windows 11
Other OS
No response
OBS Studio Version
28.0.0
OBS Studio Version (Other)
No response
obs-websocket Version
5.0.1
OBS Studio Log URL
https://obsproject.com/logs/KWhT6Rm5YwoRSM17
OBS Studio Crash Log URL
No response
Expected Behavior
Current Behavior
When calling
GetHotkeyList
multiple hotkeys are getting the same hotkeyNames. Thus when triggering a hotkey such asObsBasic.SelectScene
it (seemingly) tries to trigger a Scene change for ALL scenes, causing OBS to stop respond (and crash when clicked).Specifically:
GetHotkeyList
Is returning the same hotkey names multiple times (see example) thus, when trying to trigger one of those repeated hotkey names withTriggerHotkeyByName
it seems to be triggering it for every source/item that has that trigger name.Proposed Solution: Similarly named hotkeys such as
libobs.mute
orObsBasic.SelectScene
should have some kind of UNIQUE prefix (maybe the name of the source) indicating who it belongs to, and thus will trigger the correct one (and only one) when calling TriggerHotkeyByNameSteps to Reproduce
GetHotkeyList
TriggerHotkeyByName
with one of the repeated hotkeyNames such asObsBasic.SelectScene
Anything else we should know?
No response