From 391a537a78daa2e328162e39d375b5de87da89a6 Mon Sep 17 00:00:00 2001 From: barsdeveloper Date: Tue, 15 Mar 2022 20:47:38 +0100 Subject: [PATCH] Fix index mistake --- dist/ueblueprint.js | 2 +- index.html | 81 ++++++++++++++++++++++++++++---------- js/template/PinTemplate.js | 2 +- 3 files changed, 63 insertions(+), 22 deletions(-) diff --git a/dist/ueblueprint.js b/dist/ueblueprint.js index 3298d59..56b9ed3 100755 --- a/dist/ueblueprint.js +++ b/dist/ueblueprint.js @@ -2631,7 +2631,7 @@ class PinTemplate extends ITemplate { window.customElements.whenDefined(NodeElement.tagName).then(pin.nodeElement = pin.closest(NodeElement.tagName)); pin.getLinks().forEach(pinReference => { const targetPin = pin.blueprint.getPin(pinReference.pinGuid); - if (linkedToPin) { + if (targetPin) { const [sourcePin, destinationPin] = pin.isOutput() ? [pin, targetPin] : [targetPin, pin]; pin.blueprint.addGraphElement(new LinkElement(sourcePin, destinationPin)); } diff --git a/index.html b/index.html index 9f66a00..c82be08 100755 --- a/index.html +++ b/index.html @@ -1,20 +1,61 @@ -Begin Object Class=/Script/BlueprintGraph.K2Node_CommutativeAssociativeBinaryOperator -Name="K2Node_CommutativeAssociativeBinaryOperator_1" -NodePosX=30 -NodePosY=50 -NodeGuid=43D899AC42EB640EF98BFCA1597FD6C9 -bIsPureFunc=True -FunctionReference=(MemberParent=Class'"/Script/Engine.KismetStringLibrary"',MemberName="Concat_StrStr") -CustomProperties Pin (PinId=FB3490034B2B6127D29E1397E04F6BD6,PinName="self",PinToolTip="Target Kismet String Library -Object -Reference",PinType.PinCategory="object",PinType.PinSubCategory="",PinType.PinSubCategoryObject=Class'"/Script/Engine.KismetStringLibrary"',PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=True,LinkedTo=(),DefaultValue="",AutogeneratedDefaultValue="",PersistentGuid=00000000000000000000000000000000,bHidden=True,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False,PinFriendlyName=NSLOCTEXT("K2Node","Target","Target"),DefaultObject="/Script/Engine.Default__KismetStringLibrary") -CustomProperties Pin (PinId=22257AFF4730E84DE3EF0DBA7A92E1EE,PinName="A",PinToolTip="A String The original -string",PinType.PinCategory="string",PinType.PinSubCategory="",PinType.PinSubCategoryObject=None,PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=False,LinkedTo=(),DefaultValue="",AutogeneratedDefaultValue="",PersistentGuid=00000000000000000000000000000000,bHidden=False,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False) -CustomProperties Pin (PinId=81E183294B6CBC122C5E88A8C37F13A3,PinName="B",PinToolTip="B String The string to append to -A",PinType.PinCategory="string",PinType.PinSubCategory="",PinType.PinSubCategoryObject=None,PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=False,LinkedTo=(),DefaultValue="",AutogeneratedDefaultValue="",PersistentGuid=00000000000000000000000000000000,bHidden=False,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False) -CustomProperties Pin (PinId=E9BBB3A54DE64C213F52B2AFC8197637,PinName="ReturnValue",PinToolTip="Return Value String A new -string which is the concatenation of -A+B",PinType.PinCategory="string",PinType.PinSubCategory="",PinType.PinSubCategoryObject=None,PinType.PinSubCategoryMemberReference=(),PinType.PinValueType=(),PinType.ContainerType=None,PinType.bIsReference=False,PinType.bIsConst=False,PinType.bIsWeakPointer=False,PinType.bIsUObjectWrapper=False,LinkedTo=("K2Node_CommutativeAssociativeBinaryOperator_1" -22257AFF4730E84DE3EF0DBA7A92E1EE,,"K2Node_CommutativeAssociativeBinaryOperator_1" -81E183294B6CBC122C5E88A8C37F13A3,),DefaultValue="",AutogeneratedDefaultValue="",PersistentGuid=00000000000000000000000000000000,bHidden=False,bNotConnectable=False,bDefaultValueIsReadOnly=False,bDefaultValueIsIgnored=False,bAdvancedView=False,bOrphanedPin=False,Direction="EGPD_Output") -End Object \ No newline at end of file + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/js/template/PinTemplate.js b/js/template/PinTemplate.js index baf383b..9fd81ad 100755 --- a/js/template/PinTemplate.js +++ b/js/template/PinTemplate.js @@ -44,7 +44,7 @@ export default class PinTemplate extends ITemplate { window.customElements.whenDefined(NodeElement.tagName).then(pin.nodeElement = pin.closest(NodeElement.tagName)) pin.getLinks().forEach(pinReference => { const targetPin = pin.blueprint.getPin(pinReference.pinGuid) - if (linkedToPin) { + if (targetPin) { const [sourcePin, destinationPin] = pin.isOutput() ? [pin, targetPin] : [targetPin, pin] pin.blueprint.addGraphElement(new LinkElement(sourcePin, destinationPin)) }