Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(integration): implement obs-websocket #4569

Merged
merged 38 commits into from Feb 4, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
3f1b276
WIP obs-websocket
sogehige Jan 26, 2021
0e8664c
update
sogehige Jan 27, 2021
00911fa
direct connection
sogehige Jan 27, 2021
0142c6e
disable heartbeat on overlay
sogehige Jan 27, 2021
acbad13
update
sogehige Jan 28, 2021
f2a107b
updates
sogehige Jan 28, 2021
002efff
fix patch
sogehige Jan 28, 2021
213b18c
update migrationCheck
sogehige Jan 28, 2021
98e1210
update
sogehige Jan 28, 2021
4a7d3c5
update
sogehige Jan 29, 2021
a5d223d
....
sogehige Jan 29, 2021
4b9e492
update...
sogehige Jan 29, 2021
d52addc
.........
sogehige Jan 29, 2021
b5779a2
sss
sogehige Jan 29, 2021
af4cdfa
update
sogehige Jan 29, 2021
e651bf3
update
sogehige Jan 29, 2021
ac42bff
fix
sogehige Jan 29, 2021
5d4071f
env
sogehige Jan 29, 2021
570c15b
use parse
sogehige Jan 29, 2021
37c780d
just test
sogehige Jan 29, 2021
a776493
update
sogehige Jan 29, 2021
3789ab6
ssssst
sogehige Jan 29, 2021
d28312f
asd
sogehige Jan 29, 2021
ba4350a
update
sogehige Jan 29, 2021
f5b12e3
add migration
sogehige Jan 29, 2021
fcf7211
saving item
sogehige Jan 29, 2021
f02563f
remove pending
sogehige Jan 29, 2021
3813213
update migr
sogehige Jan 29, 2021
23d7cb3
force task to run in sequence
sogehige Feb 1, 2021
a718354
advanced mode
sogehige Feb 1, 2021
b83187c
fix
sogehige Feb 1, 2021
24a033f
setVolume, setMute
sogehige Feb 2, 2021
bd6d6ef
direct and overlay working OK
sogehige Feb 2, 2021
e846426
update
sogehige Feb 3, 2021
d579de6
eslint fixes
sogehige Feb 3, 2021
5613464
add obs-scene-change event
sogehige Feb 4, 2021
474d150
update scrim test
sogehige Feb 4, 2021
8c39a11
deepscan fixes
sogehige Feb 4, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .eslintignore
@@ -0,0 +1 @@
webpack.config.js
1 change: 1 addition & 0 deletions .eslintrc.json
Expand Up @@ -6,6 +6,7 @@
"key-spacing": ["error", { "beforeColon": false, "afterColon": true, "align": "value" }],
"object-curly-spacing": ["error", "always"],
"object-curly-newline": ["error", {
"ObjectExpression": { "multiline": true, "minProperties": 3 },
"ImportDeclaration": { "multiline": true, "minProperties": 3 },
"ExportDeclaration": { "multiline": true, "minProperties": 3 }
}],
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/tests.yml
Expand Up @@ -55,7 +55,7 @@ jobs:
run: npm run test:config:sqlite
- name: Run migration test
if: "!contains(steps.log.outputs.MESSAGE, '[skip-tests]')"
run: node tools/migrationCheck.js
run: npm run test:migration
- name: Run mocha
if: "!contains(steps.log.outputs.MESSAGE, '[skip-tests]')"
run: npm test
Expand Down Expand Up @@ -98,7 +98,7 @@ jobs:
run: npm run test:config:postgres
- name: Run migration test
if: "!contains(steps.log.outputs.MESSAGE, '[skip-tests]')"
run: node tools/migrationCheck.js
run: npm run test:migration
- name: Run mocha
if: "!contains(steps.log.outputs.MESSAGE, '[skip-tests]')"
run: npm test
Expand Down Expand Up @@ -143,7 +143,7 @@ jobs:
run: npm run test:config:mysql
- name: Run migration test
if: "!contains(steps.log.outputs.MESSAGE, '[skip-tests]')"
run: node tools/migrationCheck.js
run: npm run test:migration
- name: Run mocha
if: "!contains(steps.log.outputs.MESSAGE, '[skip-tests]')"
run: npm test
Expand Down
2 changes: 2 additions & 0 deletions Makefile
Expand Up @@ -24,6 +24,7 @@ dependencies:
# How to create node_modules patch: https://opensource.christmas/2019/4
patch --forward node_modules/twitch-js/types/index.d.ts < patches/twitch-js-types-2.patch
patch --forward node_modules/twitch-js/types/index.d.ts < patches/twitch-js-add-highlight-msgId.patch
patch --forward node_modules/obs-websocket-js/types/index.d.ts < patches/obswebsocketTypeExpose.patch

eslint:
@echo -ne "\n\t ----- Checking eslint\n"
Expand Down Expand Up @@ -51,6 +52,7 @@ else
endif

bot:
@rm -rf dest
ifeq ($(ENV),production)
@echo -ne "\n\t ----- Building bot (strip comments)\n"
@npx tsc -p src/bot --removeComments true
Expand Down
8 changes: 7 additions & 1 deletion locales/en.json
Expand Up @@ -170,6 +170,10 @@
"filter": {
"label": "Filter"
},
"linkFilter": {
"label": "Link Overlay Filter",
"placeholder": "If using overlay, add link or id of your overlay"
},
"hashtag": {
"label": "Hashtag or Keyword",
"placeholder": "#yourHashtagHere or Keyword"
Expand Down Expand Up @@ -436,7 +440,8 @@
"username": "Username on Twitter",
"displayname": "Screen name on twitter",
"url": "Tweet link"
}
},
"sceneName": "Name of scene"
}
},
"page-settings": {
Expand Down Expand Up @@ -746,6 +751,7 @@
"user-parted-channel": "user parted a channel",
"follow": "new follow",
"tip": "new tip",
"obs-scene-changed": "OBS scene changed",
"unfollow": "unfollow",
"subscription": "new subscription",
"subgift": "new subgift",
Expand Down
7 changes: 7 additions & 0 deletions locales/en/integrations/obswebsocket.json
@@ -0,0 +1,7 @@
{
"runTask": {
"EntityNotFound": "$sender, there is no action set for id:$id!",
"ParameterError": "$sender, you need to specify id!",
"UnknownError": "$sender, something went wrong. Check bot logs for additional informations."
}
}
3 changes: 2 additions & 1 deletion locales/en/ui.menu.json
Expand Up @@ -86,5 +86,6 @@
"texttospeech": "Text To Speech",
"lastfm": "Last.fm",
"pubg": "PLAYERUNKNOWN'S BATTLEGROUNDS",
"levels": "Levels"
"levels": "Levels",
"obswebsocket": "OBS Websocket"
}
57 changes: 57 additions & 0 deletions locales/en/ui/integrations/obswebsocket.json
@@ -0,0 +1,57 @@
{
"settings": {
"enabled": "Status",
"accessBy": {
"title": "Access by",
"help": "Direct - connect directly from a bot | Overlay - connect via overlay browser source"
},
"address": "Address",
"password": "Password"
},
"noSourceSelected": "No source selected",
"noSceneSelected": "No scene selected",
"empty": "No action sets were created yet.",
"emptyAfterSearch": "No action sets were found by your search for <strong>\"$search\"</strong>.",
"command": "Command",
"new": "Create new OBS Websocket action set",
"actions": "Actions",
"name": {
"name": "Name"
},
"SetCurrentScene": {
"name": "SetCurrentScene"
},
"StartReplayBuffer": {
"name": "StartReplayBuffer"
},
"StopReplayBuffer": {
"name": "StopReplayBuffer"
},
"SaveReplayBuffer": {
"name": "SaveReplayBuffer"
},
"WaitMs": {
"name": "Wait X miliseconds"
},
"Log": {
"name": "Log message"
},
"StartRecording": {
"name": "StartRecording"
},
"StopRecording": {
"name": "StopRecording"
},
"PauseRecording": {
"name": "PauseRecording"
},
"ResumeRecording": {
"name": "ResumeRecording"
},
"SetMute": {
"name": "SetMute"
},
"SetVolume": {
"name": "SetVolume"
}
}