mirror of
https://github.com/barsdeveloper/ueblueprint.git
synced 2026-05-21 05:27:34 +08:00
Additional operations
This commit is contained in:
29
dist/ueblueprint.js
vendored
29
dist/ueblueprint.js
vendored
@@ -3344,6 +3344,9 @@ class ObjectEntity extends IEntity {
|
|||||||
PCGNode: {
|
PCGNode: {
|
||||||
type: ObjectReferenceEntity,
|
type: ObjectReferenceEntity,
|
||||||
},
|
},
|
||||||
|
Operation: {
|
||||||
|
type: SymbolEntity,
|
||||||
|
},
|
||||||
NodePosX: {
|
NodePosX: {
|
||||||
type: IntegerEntity,
|
type: IntegerEntity,
|
||||||
},
|
},
|
||||||
@@ -3543,6 +3546,7 @@ class ObjectEntity extends IEntity {
|
|||||||
/** @type {MirroredEntity} */ this.PositionX;
|
/** @type {MirroredEntity} */ this.PositionX;
|
||||||
/** @type {MirroredEntity} */ this.PositionY;
|
/** @type {MirroredEntity} */ this.PositionY;
|
||||||
/** @type {ObjectReferenceEntity} */ this.PCGNode;
|
/** @type {ObjectReferenceEntity} */ this.PCGNode;
|
||||||
|
/** @type {String} */ this.Operation;
|
||||||
/** @type {IntegerEntity} */ this.NodePosX;
|
/** @type {IntegerEntity} */ this.NodePosX;
|
||||||
/** @type {IntegerEntity} */ this.NodePosY;
|
/** @type {IntegerEntity} */ this.NodePosY;
|
||||||
/** @type {IntegerEntity} */ this.NodeWidth;
|
/** @type {IntegerEntity} */ this.NodeWidth;
|
||||||
@@ -3948,6 +3952,12 @@ class ObjectEntity extends IEntity {
|
|||||||
if (settingsObject.BlueprintElementInstance) {
|
if (settingsObject.BlueprintElementInstance) {
|
||||||
return Utility.formatStringName(settingsObject.BlueprintElementType.getName())
|
return Utility.formatStringName(settingsObject.BlueprintElementType.getName())
|
||||||
}
|
}
|
||||||
|
if (settingsObject.Operation) {
|
||||||
|
const match = settingsObject.Name.match(/PCGMetadata(\w+)Settings_\d+/);
|
||||||
|
if (match) {
|
||||||
|
return Utility.formatStringName(match[1] + ": " + settingsObject.Operation)
|
||||||
|
}
|
||||||
|
}
|
||||||
const settingsSubgraphObject = settingsObject.getSubgraphObject();
|
const settingsSubgraphObject = settingsObject.getSubgraphObject();
|
||||||
if (settingsSubgraphObject && settingsSubgraphObject.Graph) {
|
if (settingsSubgraphObject && settingsSubgraphObject.Graph) {
|
||||||
return settingsSubgraphObject.Graph.getName()
|
return settingsSubgraphObject.Graph.getName()
|
||||||
@@ -4018,6 +4028,9 @@ class ObjectEntity extends IEntity {
|
|||||||
if (memberName.startsWith("Cross_")) {
|
if (memberName.startsWith("Cross_")) {
|
||||||
return "cross"
|
return "cross"
|
||||||
}
|
}
|
||||||
|
if (memberName.startsWith("Divide_")) {
|
||||||
|
return String.fromCharCode(0x00f7)
|
||||||
|
}
|
||||||
if (memberName.startsWith("Dot_")) {
|
if (memberName.startsWith("Dot_")) {
|
||||||
return "dot"
|
return "dot"
|
||||||
}
|
}
|
||||||
@@ -4051,6 +4064,9 @@ class ObjectEntity extends IEntity {
|
|||||||
if (memberName.startsWith("Percent_")) {
|
if (memberName.startsWith("Percent_")) {
|
||||||
return "%"
|
return "%"
|
||||||
}
|
}
|
||||||
|
if (memberName.startsWith("Subtract_")) {
|
||||||
|
return "-"
|
||||||
|
}
|
||||||
if (memberName.startsWith("Xor_")) {
|
if (memberName.startsWith("Xor_")) {
|
||||||
return "^"
|
return "^"
|
||||||
}
|
}
|
||||||
@@ -4156,6 +4172,9 @@ class ObjectEntity extends IEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
nodeIcon() {
|
nodeIcon() {
|
||||||
|
if (this.isMaterial() || this.isPcg()) {
|
||||||
|
return undefined
|
||||||
|
}
|
||||||
switch (this.getType()) {
|
switch (this.getType()) {
|
||||||
case Configuration.paths.asyncAction:
|
case Configuration.paths.asyncAction:
|
||||||
case Configuration.paths.addDelegate:
|
case Configuration.paths.addDelegate:
|
||||||
@@ -4201,9 +4220,6 @@ class ObjectEntity extends IEntity {
|
|||||||
if (this.getClass() === Configuration.paths.macro) {
|
if (this.getClass() === Configuration.paths.macro) {
|
||||||
return SVGIcon.macro
|
return SVGIcon.macro
|
||||||
}
|
}
|
||||||
if (this.isMaterial() || this.isPcg()) {
|
|
||||||
return undefined
|
|
||||||
}
|
|
||||||
const hidValue = this.getHIDAttribute()?.toString();
|
const hidValue = this.getHIDAttribute()?.toString();
|
||||||
if (hidValue) {
|
if (hidValue) {
|
||||||
if (hidValue.includes("Mouse")) {
|
if (hidValue.includes("Mouse")) {
|
||||||
@@ -4240,8 +4256,10 @@ class ObjectEntity extends IEntity {
|
|||||||
switch (this.FunctionReference?.MemberName) {
|
switch (this.FunctionReference?.MemberName) {
|
||||||
default:
|
default:
|
||||||
if (
|
if (
|
||||||
!this.FunctionReference?.MemberName?.startsWith("Multiply_")
|
!this.FunctionReference?.MemberName?.startsWith("Add_")
|
||||||
&& !this.FunctionReference?.MemberName?.startsWith("Add_")
|
&& !this.FunctionReference?.MemberName?.startsWith("Subtract_")
|
||||||
|
&& !this.FunctionReference?.MemberName?.startsWith("Multiply_")
|
||||||
|
&& !this.FunctionReference?.MemberName?.startsWith("Divide_")
|
||||||
) {
|
) {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
@@ -4261,6 +4279,7 @@ class ObjectEntity extends IEntity {
|
|||||||
case "MinInt64":
|
case "MinInt64":
|
||||||
case "Or_Int64Int64":
|
case "Or_Int64Int64":
|
||||||
case "Or_IntInt":
|
case "Or_IntInt":
|
||||||
|
|
||||||
pinEntities ??= () => this.getPinEntities().filter(pinEntity => pinEntity.isInput());
|
pinEntities ??= () => this.getPinEntities().filter(pinEntity => pinEntity.isInput());
|
||||||
pinIndexFromEntity ??= pinEntity =>
|
pinIndexFromEntity ??= pinEntity =>
|
||||||
pinEntity.PinName.match(/^\s*([A-Z])\s*$/)?.[1]?.charCodeAt(0) - "A".charCodeAt(0);
|
pinEntity.PinName.match(/^\s*([A-Z])\s*$/)?.[1]?.charCodeAt(0) - "A".charCodeAt(0);
|
||||||
|
|||||||
2
dist/ueblueprint.min.js
vendored
2
dist/ueblueprint.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -211,6 +211,9 @@ export default class ObjectEntity extends IEntity {
|
|||||||
PCGNode: {
|
PCGNode: {
|
||||||
type: ObjectReferenceEntity,
|
type: ObjectReferenceEntity,
|
||||||
},
|
},
|
||||||
|
Operation: {
|
||||||
|
type: SymbolEntity,
|
||||||
|
},
|
||||||
NodePosX: {
|
NodePosX: {
|
||||||
type: IntegerEntity,
|
type: IntegerEntity,
|
||||||
},
|
},
|
||||||
@@ -410,6 +413,7 @@ export default class ObjectEntity extends IEntity {
|
|||||||
/** @type {MirroredEntity} */ this.PositionX
|
/** @type {MirroredEntity} */ this.PositionX
|
||||||
/** @type {MirroredEntity} */ this.PositionY
|
/** @type {MirroredEntity} */ this.PositionY
|
||||||
/** @type {ObjectReferenceEntity} */ this.PCGNode
|
/** @type {ObjectReferenceEntity} */ this.PCGNode
|
||||||
|
/** @type {String} */ this.Operation
|
||||||
/** @type {IntegerEntity} */ this.NodePosX
|
/** @type {IntegerEntity} */ this.NodePosX
|
||||||
/** @type {IntegerEntity} */ this.NodePosY
|
/** @type {IntegerEntity} */ this.NodePosY
|
||||||
/** @type {IntegerEntity} */ this.NodeWidth
|
/** @type {IntegerEntity} */ this.NodeWidth
|
||||||
@@ -815,6 +819,12 @@ export default class ObjectEntity extends IEntity {
|
|||||||
if (settingsObject.BlueprintElementInstance) {
|
if (settingsObject.BlueprintElementInstance) {
|
||||||
return Utility.formatStringName(settingsObject.BlueprintElementType.getName())
|
return Utility.formatStringName(settingsObject.BlueprintElementType.getName())
|
||||||
}
|
}
|
||||||
|
if (settingsObject.Operation) {
|
||||||
|
const match = settingsObject.Name.match(/PCGMetadata(\w+)Settings_\d+/)
|
||||||
|
if (match) {
|
||||||
|
return Utility.formatStringName(match[1] + ": " + settingsObject.Operation)
|
||||||
|
}
|
||||||
|
}
|
||||||
const settingsSubgraphObject = settingsObject.getSubgraphObject()
|
const settingsSubgraphObject = settingsObject.getSubgraphObject()
|
||||||
if (settingsSubgraphObject && settingsSubgraphObject.Graph) {
|
if (settingsSubgraphObject && settingsSubgraphObject.Graph) {
|
||||||
return settingsSubgraphObject.Graph.getName()
|
return settingsSubgraphObject.Graph.getName()
|
||||||
@@ -885,6 +895,9 @@ export default class ObjectEntity extends IEntity {
|
|||||||
if (memberName.startsWith("Cross_")) {
|
if (memberName.startsWith("Cross_")) {
|
||||||
return "cross"
|
return "cross"
|
||||||
}
|
}
|
||||||
|
if (memberName.startsWith("Divide_")) {
|
||||||
|
return String.fromCharCode(0x00f7)
|
||||||
|
}
|
||||||
if (memberName.startsWith("Dot_")) {
|
if (memberName.startsWith("Dot_")) {
|
||||||
return "dot"
|
return "dot"
|
||||||
}
|
}
|
||||||
@@ -918,6 +931,9 @@ export default class ObjectEntity extends IEntity {
|
|||||||
if (memberName.startsWith("Percent_")) {
|
if (memberName.startsWith("Percent_")) {
|
||||||
return "%"
|
return "%"
|
||||||
}
|
}
|
||||||
|
if (memberName.startsWith("Subtract_")) {
|
||||||
|
return "-"
|
||||||
|
}
|
||||||
if (memberName.startsWith("Xor_")) {
|
if (memberName.startsWith("Xor_")) {
|
||||||
return "^"
|
return "^"
|
||||||
}
|
}
|
||||||
@@ -1023,6 +1039,9 @@ export default class ObjectEntity extends IEntity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
nodeIcon() {
|
nodeIcon() {
|
||||||
|
if (this.isMaterial() || this.isPcg()) {
|
||||||
|
return undefined
|
||||||
|
}
|
||||||
switch (this.getType()) {
|
switch (this.getType()) {
|
||||||
case Configuration.paths.asyncAction:
|
case Configuration.paths.asyncAction:
|
||||||
case Configuration.paths.addDelegate:
|
case Configuration.paths.addDelegate:
|
||||||
@@ -1068,9 +1087,6 @@ export default class ObjectEntity extends IEntity {
|
|||||||
if (this.getClass() === Configuration.paths.macro) {
|
if (this.getClass() === Configuration.paths.macro) {
|
||||||
return SVGIcon.macro
|
return SVGIcon.macro
|
||||||
}
|
}
|
||||||
if (this.isMaterial() || this.isPcg()) {
|
|
||||||
return undefined
|
|
||||||
}
|
|
||||||
const hidValue = this.getHIDAttribute()?.toString()
|
const hidValue = this.getHIDAttribute()?.toString()
|
||||||
if (hidValue) {
|
if (hidValue) {
|
||||||
if (hidValue.includes("Mouse")) {
|
if (hidValue.includes("Mouse")) {
|
||||||
@@ -1107,8 +1123,10 @@ export default class ObjectEntity extends IEntity {
|
|||||||
switch (this.FunctionReference?.MemberName) {
|
switch (this.FunctionReference?.MemberName) {
|
||||||
default:
|
default:
|
||||||
if (
|
if (
|
||||||
!this.FunctionReference?.MemberName?.startsWith("Multiply_")
|
!this.FunctionReference?.MemberName?.startsWith("Add_")
|
||||||
&& !this.FunctionReference?.MemberName?.startsWith("Add_")
|
&& !this.FunctionReference?.MemberName?.startsWith("Subtract_")
|
||||||
|
&& !this.FunctionReference?.MemberName?.startsWith("Multiply_")
|
||||||
|
&& !this.FunctionReference?.MemberName?.startsWith("Divide_")
|
||||||
) {
|
) {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
@@ -1128,6 +1146,7 @@ export default class ObjectEntity extends IEntity {
|
|||||||
case "MinInt64":
|
case "MinInt64":
|
||||||
case "Or_Int64Int64":
|
case "Or_Int64Int64":
|
||||||
case "Or_IntInt":
|
case "Or_IntInt":
|
||||||
|
|
||||||
pinEntities ??= () => this.getPinEntities().filter(pinEntity => pinEntity.isInput())
|
pinEntities ??= () => this.getPinEntities().filter(pinEntity => pinEntity.isInput())
|
||||||
pinIndexFromEntity ??= pinEntity =>
|
pinIndexFromEntity ??= pinEntity =>
|
||||||
pinEntity.PinName.match(/^\s*([A-Z])\s*$/)?.[1]?.charCodeAt(0) - "A".charCodeAt(0)
|
pinEntity.PinName.match(/^\s*([A-Z])\s*$/)?.[1]?.charCodeAt(0) - "A".charCodeAt(0)
|
||||||
|
|||||||
Reference in New Issue
Block a user