, top: Int, left: Int, right: Int, bottom: Int) {
+ if (!isConnected) return
for (container in containers.keys) {
val sourceID = containers[container]!!
obsRemoteController.getSceneItemTransform(container, sourceID) { tResponse: GetSceneItemTransformResponse ->
@@ -234,7 +238,7 @@ class OBSClient(
fun setStreamKey(key: String?) {
if (!isConnected) return
- val settings = JsonObject()
+ val settings: JsonObject = JsonObject()
settings.addProperty("bwtest", false)
settings.addProperty("key", key)
settings.addProperty("server", "auto")
@@ -249,6 +253,13 @@ class OBSClient(
}
}
+ fun reloadLayout() {
+ if (!isConnected) return
+ obsRemoteController.sendRequest(PressInputPropertiesButtonRequest.builder().inputName("PreRaceLayout").propertyName("refreshnocache").build()) { _: PressInputPropertiesButtonResponse -> return@sendRequest }
+ obsRemoteController.sendRequest(PressInputPropertiesButtonRequest.builder().inputName("WebLayout").propertyName("refreshnocache").build()) { _: PressInputPropertiesButtonResponse -> return@sendRequest }
+ obsRemoteController.sendRequest(PressInputPropertiesButtonRequest.builder().inputName("PostRaceLayout").propertyName("refreshnocache").build()) { _: PressInputPropertiesButtonResponse -> return@sendRequest }
+ }
+
companion object {
private val log = LoggerFactory.getLogger(OBSClient::class.java.name)
}
diff --git a/src/main/resources/html/FourPlayer.html b/src/main/resources/html/FourPlayer.html
index 3400642..3605991 100644
--- a/src/main/resources/html/FourPlayer.html
+++ b/src/main/resources/html/FourPlayer.html
@@ -27,6 +27,7 @@
color: white;
font-family: "Roboto", sans-serif;
font-weight: 700;
+ font-size: 2.5rem;
}
iframe {
@@ -87,7 +88,7 @@
}
.hidden {
- display: none;
+ visibility: hidden;
}
#layout {
@@ -156,6 +157,8 @@
height: 49px;
width: 477px;
z-index: 1;
+ overflow: hidden;
+ text-align: center;
}
.player_name {
@@ -163,6 +166,8 @@
height: 49px;
width: 249px;
z-index: 1;
+ overflow: hidden;
+ text-align: center;
}
#t1_name {
@@ -283,7 +288,7 @@
src="https://images.alttprleague.com/static/league/img/player-default.png"
alt="logo"
/>
-Team 1
+Team 1
Player 1
Player 3
diff --git a/src/main/resources/html/TwoPlayer.html b/src/main/resources/html/TwoPlayer.html
index ee1cdd5..9642cda 100644
--- a/src/main/resources/html/TwoPlayer.html
+++ b/src/main/resources/html/TwoPlayer.html
@@ -5,7 +5,7 @@
TwoPlayer
-
+