From 847a10c3c3e01134db699d52da7c0c6518443bf5 Mon Sep 17 00:00:00 2001 From: charuse Date: Wed, 16 Sep 2026 01:57:42 +0000 Subject: [PATCH] Automated Extension submission for issue #2270 --- extensions/community/Signals.json | 131 ++++++++++++++++++++++++++++++ 1 file changed, 131 insertions(+) create mode 100644 extensions/community/Signals.json diff --git a/extensions/community/Signals.json b/extensions/community/Signals.json new file mode 100644 index 000000000..09baefac3 --- /dev/null +++ b/extensions/community/Signals.json @@ -0,0 +1,131 @@ +{ + "author": "", + "category": "General", + "dimension": "", + "extensionNamespace": "", + "fullName": "Signals", + "gdevelopVersion": "", + "helpPath": "", + "iconUrl": "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz48IURPQ1RZUEUgc3ZnIFBVQkxJQyAiLS8vVzNDLy9EVEQgU1ZHIDEuMS8vRU4iICJodHRwOi8vd3d3LnczLm9yZy9HcmFwaGljcy9TVkcvMS4xL0RURC9zdmcxMS5kdGQiPjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0ibWRpLXNpZ25hbC12YXJpYW50IiB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCI+PHBhdGggZD0iTTQsNlY0SDQuMUMxMi45LDQgMjAsMTEuMSAyMCwxOS45VjIwSDE4VjE5LjlDMTgsMTIuMiAxMS44LDYgNCw2TTQsMTBWOEExMiwxMiAwIDAsMSAxNiwyMEgxNEExMCwxMCAwIDAsMCA0LDEwTTQsMTRWMTJBOCw4IDAgMCwxIDEyLDIwSDEwQTYsNiAwIDAsMCA0LDE0TTQsMTZBNCw0IDAgMCwxIDgsMjBINFYxNloiIC8+PC9zdmc+", + "name": "Signals", + "previewIconUrl": "https://asset-resources.gdevelop.io/public-resources/Icons/a422fe56b8214e5d8b8e5ca6ad8f6b9598f89e6bd3af47c9e25d1777c2534c63_signal-variant.svg", + "shortDescription": "Adds Call Signal as an action and On Signal Call as a condition, allowing re-use of multiple actions easily.", + "version": "1.0.1", + "description": [ + "Allows for calling and on call signals within the Action Sheet. ", + "Useful for re-use of the same actions for different calls of the same signal. ", + " ", + "Write \"On Signal Call\" then use \"Call Signal\" in your program for use. ", + "Either can be used in front of another, On Signal Call can appear before Call Signal in the action sheet, and vice versa. " + ], + "tags": [ + "functions", + "general", + "signal", + "calls" + ], + "authorIds": [ + "9AJFDUCQG2hiUqekfo0Y9HVSiRX2" + ], + "dependencies": [], + "globalVariables": [], + "sceneVariables": [], + "eventsFunctions": [ + { + "description": "Calls Signal for use with On Signal Call.", + "fullName": "Call Signal", + "functionType": "Action", + "name": "CallSignal", + "sentence": "Call Signal _PARAM1_", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const extName = \"Signals\";", + "globalThis[extName] = globalThis[extName] || { activeCalls: new Set(), incomingCalls: new Set() };", + "const sigName = eventsFunctionContext.getArgument(\"SignalName\");", + "globalThis[extName].incomingCalls.add(sigName);" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [ + { + "description": "Signal Name", + "name": "SignalName", + "supplementaryInformation": "TextObject::Text", + "type": "string" + } + ], + "objectGroups": [] + }, + { + "description": "Reacts to a Signal Call made by Call Signal with the same Signal Name.", + "fullName": "On Signal Call", + "functionType": "Condition", + "name": "OnSignalCall", + "sentence": "Signal _PARAM1_ is called", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const extName = \"Signals\";", + "const sigName = eventsFunctionContext.getArgument(\"SignalName\");", + "eventsFunctionContext.returnValue = !!globalThis[extName].activeCalls.has(sigName);" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [ + { + "description": "Signal Name", + "name": "SignalName", + "type": "string" + } + ], + "objectGroups": [] + }, + { + "fullName": "", + "functionType": "Action", + "name": "onScenePreEvents", + "sentence": "", + "events": [ + { + "type": "BuiltinCommonInstructions::JsCode", + "inlineCode": [ + "const extName = \"Signals\";", + "globalThis[extName] = globalThis[extName] || { activeCalls: new Set(), incomingCalls: new Set() };", + "globalThis[extName].activeCalls = new Set(globalThis[extName].incomingCalls);", + "globalThis[extName].incomingCalls.clear();" + ], + "parameterObjects": "", + "useStrict": true, + "eventsSheetExpanded": false + } + ], + "parameters": [], + "objectGroups": [] + } + ], + "eventsFunctionsFolderStructure": { + "folderName": "__ROOT", + "children": [ + { + "functionName": "CallSignal" + }, + { + "functionName": "OnSignalCall" + }, + { + "functionName": "onScenePreEvents" + } + ] + }, + "eventsBasedBehaviors": [], + "eventsBasedObjects": [] +}