x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Office Holiday

Epic Games' offices will be on holiday from June 22nd to July 7th. During this period support will be limited. Our offices will reopen on Monday, July 8th. 

Create Output Pin c++

Hey all,

I'm currently adding to a blueprint node of mine and need to add a second output pin.

I'm using the CreatePin Method to do so, but is expecting the PinSubCategoryObject to be a UObject*

 UEdGraphPin* UEdGraphNode::CreatePin(EEdGraphPinDirection Dir, const FString& PinCategory, const FString& PinSubCategory, UObject* PinSubCategoryObject, bool bIsArray, bool bIsReference, const FString& PinName, bool bIsConst /*= false*/, int32 Index /*= INDEX_NONE*/)
 

Am I right in thinking this will be the output type? If so I want to output an array of FTransforms, how would I implement this?

Product Version: UE 4.9
Tags:
more ▼

asked Mar 03 '16 at 03:47 PM in C++ Programming

avatar image

AgentMilkshake1
285 13 18 35

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

It turns out that in the particular place I was trying to output a pin (a class based off of UAnimGraphNode_Base) I had to follow through with some override functions.

For example, I was trying to create an output pin for FPoseLink. To do so I had to add the following to my .cpp.

 void UCustomGraphNodeClass::CreateOutputPins()
 {
 const UAnimationGraphSchema* Schema = GetDefault<UAnimationGraphSchema>();
 CreatePin(EGPD_Output, Schema->PC_Struct, Text("Pose", FPoseLink::StaticStruct(), /*bIsArray=*/ false, /*bIsReference=*/ false, TEXT("Pose"));
 }

I then had to add the override function within my FCustomAnimNode.cpp utilizing the output function that FPoseLink uses. In this case it is a function called

 Evaluate(FPoseContext& Output)

I then placed all of my code the modify the pose as I wanted to, which I won't cover in detail here, but as long as you have called and override all the correct functions, then it should be good to go (it will output the FPoseContext& Output)

more ▼

answered Apr 21 '16 at 12:46 PM

avatar image

AgentMilkshake1
285 13 18 35

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Hi AgentMilkshake1 . If you wanna add more pins Example:

     UFUNCTION(BlueprintCallable, Category = Example)
     static void MyFunction(ULocalPlayer* LocalPlayer, AActor*& NewActor, FString& message);

Input Pins

ULocalPlayer* LocalPlayer

Output Pins

AActor*& NewActor

FString& message

Use & for output pins

more ▼

answered Mar 04 '16 at 10:15 AM

avatar image

Anatoliy
323 12 8 20

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question