mirror of
https://github.com/barsdeveloper/ueblueprint.git
synced 2026-02-19 04:55:57 +08:00
Spawn actor node added
This commit is contained in:
@@ -444,12 +444,17 @@ export default class ObjectEntity extends IEntity {
|
||||
return "For Each Loop with Break"
|
||||
case Configuration.nodeType.ifThenElse:
|
||||
return "Branch"
|
||||
case Configuration.nodeType.spawnActorFromClass:
|
||||
return `SpawnActor ${Utility.formatStringName(
|
||||
this.CustomProperties.find(pinEntity => pinEntity.getType() == "class")?.DefaultObject?.getName()
|
||||
?? "NONE"
|
||||
)}`
|
||||
case Configuration.nodeType.switchEnum:
|
||||
return `Switch on ${this.Enum?.getName() ?? "Enum"}`
|
||||
case Configuration.nodeType.variableGet:
|
||||
return ""
|
||||
case Configuration.nodeType.variableSet:
|
||||
return "SET"
|
||||
case Configuration.nodeType.switchEnum:
|
||||
return `Switch on ${this.Enum?.getName() ?? "Enum"}`
|
||||
}
|
||||
const keyNameSymbol = this.getHIDAttribute()
|
||||
if (keyNameSymbol) {
|
||||
@@ -592,6 +597,7 @@ export default class ObjectEntity extends IEntity {
|
||||
case Configuration.nodeType.makeMap: return SVGIcon.makeMap
|
||||
case Configuration.nodeType.makeSet: return SVGIcon.makeSet
|
||||
case Configuration.nodeType.select: return SVGIcon.select
|
||||
case Configuration.nodeType.spawnActorFromClass: return SVGIcon.spawnActor
|
||||
case Configuration.nodeType.switchEnum: return SVGIcon.switch
|
||||
}
|
||||
if (this.nodeDisplayName().startsWith("Break")) {
|
||||
|
||||
@@ -86,8 +86,10 @@ export default class PinEntity extends IEntity {
|
||||
showDefault: false,
|
||||
},
|
||||
DefaultValue: {
|
||||
/** @param {PinEntity} pinEntity */
|
||||
type: new ComputedType(pinEntity => pinEntity.getEntityType(true) ?? String),
|
||||
type: new ComputedType(
|
||||
/** @param {PinEntity} pinEntity */
|
||||
pinEntity => pinEntity.getEntityType(true) ?? String
|
||||
),
|
||||
serialized: true,
|
||||
showDefault: false,
|
||||
},
|
||||
@@ -153,13 +155,7 @@ export default class PinEntity extends IEntity {
|
||||
if (this.PinType.PinCategory === "struct" || this.PinType.PinCategory === "object") {
|
||||
return subCategory.path
|
||||
}
|
||||
if (
|
||||
this.PinType.PinCategory === "byte"
|
||||
&& (
|
||||
subCategory.type === Configuration.nodeType.enum
|
||||
|| subCategory.type === Configuration.nodeType.userDefinedEnum
|
||||
)
|
||||
) {
|
||||
if (this.isEnum()) {
|
||||
return "enum"
|
||||
}
|
||||
return this.PinType.PinCategory
|
||||
@@ -211,6 +207,13 @@ export default class PinEntity extends IEntity {
|
||||
return this.DefaultValue
|
||||
}
|
||||
|
||||
isEnum() {
|
||||
const type = this.PinType.PinSubCategoryObject.type
|
||||
return type === Configuration.nodeType.enum
|
||||
|| type === Configuration.nodeType.userDefinedEnum
|
||||
|| type.toLowerCase() === "enum"
|
||||
}
|
||||
|
||||
isExecution() {
|
||||
return this.PinType.PinCategory === "exec"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user