diff --git a/configuration.json b/configuration.json
index 49ac2fc97..2c6f0cdf0 100644
--- a/configuration.json
+++ b/configuration.json
@@ -13,7 +13,7 @@
"FIRMWARE_REQUIRED_MAJOR":1,
"FIRMWARE_REQUIRED_MINOR":2,
- "FIRMWARE_REQUIRED_PATCH":17,
+ "FIRMWARE_REQUIRED_PATCH":18,
"USB_VID_0": "0x03eb",
"USB_PID_0": "0xecac",
diff --git a/package.json b/package.json
index 6e64b2a31..fa4ef759c 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "grid_editor",
- "version": "1.2.25",
+ "version": "1.2.26",
"main": "./src/electron.js",
"repository": {
"type": "git",
diff --git a/src/app/config-blocks/EncoderPushRotLeftRight_Else.svelte b/src/app/config-blocks/EncoderPushRotLeftRight_Else.svelte
new file mode 100644
index 000000000..f9981c762
--- /dev/null
+++ b/src/app/config-blocks/EncoderPushRotLeftRight_Else.svelte
@@ -0,0 +1,48 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/app/config-blocks/EncoderPushRotLeftRight_ElseIf.svelte b/src/app/config-blocks/EncoderPushRotLeftRight_ElseIf.svelte
new file mode 100644
index 000000000..8accc72f3
--- /dev/null
+++ b/src/app/config-blocks/EncoderPushRotLeftRight_ElseIf.svelte
@@ -0,0 +1,117 @@
+
+
+
+
+
+
+
+
+ {sendData(e.detail.script)}}
+ {access_tree}
+ {sidebarWidth}
+ value={scriptSegment}
+ />
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/app/config-blocks/EncoderPushRotLeftRight_End.svelte b/src/app/config-blocks/EncoderPushRotLeftRight_End.svelte
new file mode 100644
index 000000000..531396e40
--- /dev/null
+++ b/src/app/config-blocks/EncoderPushRotLeftRight_End.svelte
@@ -0,0 +1,45 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/app/config-blocks/EncoderPushRotLeftRight_If.svelte b/src/app/config-blocks/EncoderPushRotLeftRight_If.svelte
new file mode 100644
index 000000000..5a0c27917
--- /dev/null
+++ b/src/app/config-blocks/EncoderPushRotLeftRight_If.svelte
@@ -0,0 +1,81 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {sendData(e.detail.script)}}
+ {access_tree}
+ {sidebarWidth}
+ value={scriptSegment}
+ />
+
+
+
+
\ No newline at end of file
diff --git a/src/app/main/panels/WebsocketMonitor/WebsocketMonitor.svelte b/src/app/main/panels/WebsocketMonitor/WebsocketMonitor.svelte
index 8fdbdd739..efa5eec8f 100644
--- a/src/app/main/panels/WebsocketMonitor/WebsocketMonitor.svelte
+++ b/src/app/main/panels/WebsocketMonitor/WebsocketMonitor.svelte
@@ -138,20 +138,12 @@
}
- let websocketMessage = `{"zyp": "hy"}`;
+ let websocketMessage = `{zyp: "hy"}`;
function sendMessage(){
- try {
-
- const obj = JSON.parse(websocketMessage);
- wss_send_message(obj);
-
- } catch (error) {
-
- console.log("INVALID JSON", websocketMessage)
+ wss_send_message(websocketMessage);
- }
diff --git a/src/app/main/panels/configuration/components/DynamicWrapper.svelte b/src/app/main/panels/configuration/components/DynamicWrapper.svelte
index c9e2641ec..97af89b71 100644
--- a/src/app/main/panels/configuration/components/DynamicWrapper.svelte
+++ b/src/app/main/panels/configuration/components/DynamicWrapper.svelte
@@ -25,6 +25,8 @@
export let toggle = false;
+ let informationOverride = {};
+
function replace_me(e) {
appMultiSelect.reset()
@@ -42,6 +44,20 @@
handleConfigChange({configName: config.information.name});
}
+ function information_override(e) {
+
+
+ Object.keys(e.detail).forEach((k) => {
+
+ //console.log("k-v", k, e.detail[k]);
+ informationOverride[k] = e.detail[k]
+ });
+
+
+
+ }
+
+
function handleConfigChange({configName}){
// when rendering the Else and End config-blocks, they automatically send out their respective values
@@ -127,16 +143,31 @@
- {@html config.information.icon ? config.information.icon : ' '}
+ {#if informationOverride.icon !== undefined}
+ {@html informationOverride.icon ? informationOverride.icon : ' '}
+ {:else}
+
+ {@html config.information.icon ? config.information.icon : ' '}
+ {/if}
-
{config.information.blockTitle}
+
+
+
+ {#if informationOverride.blockTitle !== undefined}
+ {informationOverride.blockTitle}
+ {:else}
+ {config.information.blockTitle}
+ {/if}
+
+
{replace_me(e)}}
+ on:informationOverride={(e)=>{information_override(e)}}
on:output={(e)=>{config.script = e.detail.script; handleConfigChange({configName: config.information.name}); configs = configs;}}
/>
@@ -163,8 +194,9 @@
{replace_me(e)}}
+ on:informationOverride={(e)=>{information_override(e)}}
on:output={(e)=>{config.script = e.detail.script; handleConfigChange({configName: config.information.name}); configs = configs;}}
/>
diff --git a/src/app/main/user-interface/Monster.svelte b/src/app/main/user-interface/Monster.svelte
index 5813fc5ba..f2c023a50 100644
--- a/src/app/main/user-interface/Monster.svelte
+++ b/src/app/main/user-interface/Monster.svelte
@@ -73,17 +73,6 @@
let sleepTimeout;
let wakeTimeout;
- $: {
- if($attachment !== undefined){
-
-
- if ($attachment.element == null){
- console.log("NULL")
- }
-
-
- }
- }
$: {
if ($windowSize.window){
@@ -99,29 +88,35 @@
const vpos = $attachment.vpos
const hpos = $attachment.hpos
- if (vpos !== undefined && vpos.endsWith("%") && !isNaN(parseInt(vpos))){
- helperY = bounding.top + bounding.height/100*parseInt(vpos) - monsterElement.parentElement.getBoundingClientRect().top
- }
- else{
- helperY = bounding.top
- }
- if (hpos !== undefined && hpos.endsWith("%") && !isNaN(parseInt(hpos))){
- helperX = bounding.left + bounding.width/100*parseInt(hpos) - monsterElement.parentElement.getBoundingClientRect().left
- }
- else{
- helperX = bounding.left
+ let _helperX = bounding.left
+ let _helperY = bounding.top
+ let _scale = 1
+
+ if (typeof vpos !== 'undefined' && vpos !== null) {
+ if (vpos.endsWith("%") && !isNaN(parseInt(vpos))){
+ _helperY = bounding.top + bounding.height/100*parseInt(vpos) - monsterElement.parentElement.getBoundingClientRect().top
+ }
+ }
+
+ if (typeof hpos !== 'undefined' && hpos !== null) {
+ if (hpos.endsWith("%") && !isNaN(parseInt(hpos))){
+ _helperX = bounding.left + bounding.width/100*parseInt(hpos) - monsterElement.parentElement.getBoundingClientRect().left
+ }
}
- if ($attachment.scale !== undefined){
- scale = $attachment.scale
- }
- else{
- scale = 1;
+ if (typeof $attachment.scale !== 'undefined' && $attachment.scale !== null) {
+ _scale = $attachment.scale
}
+ helperX = _helperX
+ helperY = _helperY
+ scale = _scale
+
}
+
+
refreshEyes();
}
diff --git a/src/app/runtime/_utils.js b/src/app/runtime/_utils.js
index 5b19f13bf..f6b8f5db5 100644
--- a/src/app/runtime/_utils.js
+++ b/src/app/runtime/_utils.js
@@ -30,6 +30,7 @@ const _utils = {
return;
}
+
let configs = this.rawLuaToConfigList(fullConfig);
configs = this.configBreakDown(configs);
diff --git a/src/app/runtime/websocket.js b/src/app/runtime/websocket.js
index 37a1f8608..d3a4f3cf7 100644
--- a/src/app/runtime/websocket.js
+++ b/src/app/runtime/websocket.js
@@ -11,7 +11,9 @@ export function initialize_ws(){
export function wss_send_message(msg){
- ipcRenderer.send("websocket_tx", JSON.stringify(msg))
+
+ const toSend = Buffer.from(msg).toString('base64')
+ ipcRenderer.send("websocket_tx", JSON.stringify(toSend))
}
diff --git a/src/app/serialport/message-stream.store.js b/src/app/serialport/message-stream.store.js
index 643585de4..1fbfa2357 100644
--- a/src/app/serialport/message-stream.store.js
+++ b/src/app/serialport/message-stream.store.js
@@ -5,6 +5,7 @@ import { debug_store, runtime, user_input, update_elementNameStore, update_eleme
import { debug_monitor_store } from '../main/panels/DebugMonitor/DebugMonitor.store';
import { midi_monitor_store } from '../main/panels/MidiMonitor/MidiMonitor.store';
+import { wss_send_message } from '../runtime/websocket';
function createMessageStream(){
@@ -29,6 +30,10 @@ function createMessageStream(){
if(class_descr.class_name === "DEBUGTEXT"){
debug_monitor_store.update_debugtext(class_descr);
+ }
+ if(class_descr.class_name === "WEBSOCKET"){
+ wss_send_message(class_descr.class_parameters.TEXT)
+
}
if(class_descr.class_name === "LEDPREVIEW"){
diff --git a/src/external/grid-protocol b/src/external/grid-protocol
index 49bf48903..52ce02404 160000
--- a/src/external/grid-protocol
+++ b/src/external/grid-protocol
@@ -1 +1 @@
-Subproject commit 49bf48903f739841f443db9dc269a585efacfdb6
+Subproject commit 52ce02404674f0d42c312612ff753fddba2c0ccc