Basic Tutorial 3: Create Skookum nodes for use in Blueprints


#1

Create Skookum nodes for use in Blueprints


Remember that you can download the tutorial project here. This tutorial uses map Level3.

 

This is a quick and easy tutorial for making a BP node out of your Skookum method. This write-up assumes that you’ve already gone through the previous tutorials.

 

  1. In your default test project, create a new default map. Place a TriggerBox somewhere in your level.

  2. Let’s make it into its own BP. Make sure it’s highlighted in the World Outliner then find the Blueprints button on the toolbar. Click it and select Convert Selected Actor to Blueprint Class.... Let’s call it BP_LaunchPad. Compile, save, and hit the :sk: button to move to the Skookum IDE.

  3. Let’s add a method called fling to our new class. This will be our script inside:

&blueprint

(Pawn pawn, Real height) 
[
pawn.launch_pawn(Vector3!xyz(0, 0, height))
]

Note the &blueprint keyword which tells the compiler that this will be a BP node.

  1. Compile and let’s move back to Unreal and open up BP_LaunchPad. Drag out a connector from Event ActorBeginOverlap and then let go. You’ll get a search dialogue for all relevant nodes. You could start typing fling to look for our new node but an even quicker way is to type @ to display all Skookum nodes. Currently, we only have the one so hit Enter to add it.

  2. Now we’ll need to connect Other Actor from our Event to our node. However, our node expects a Pawn so we’ll need to do some casting. Drag out a connector from Other Actor and look for CastToPawn. Add the node and reroute the flow connector through it to Fling. Then connect As Pawn in the cast node to Pawn in Fling.

  1. Set height to some value; 1200 should be good enough. Compile, save, and run the game.

  2. When you walk through the TriggerBox, the overlap event fires off calling our :sk: node and in turn calling the scripts within it to fling our player upwards!

Of course, this was just a simple example with a one-liner script. Imagine the advanced and complex scripts that you can create and fit within one single node.

Stay Skookum!


Understanding the basics, but now how do I apply it?
Basic SkookumScript UE4 Plugin Tutorials
#2

#3

Can it have a return value?
if can, can it have multiple return value?
and where to put them?


#4

Yes, :sk: nodes do support return values but we’ve just discovered that they’re currently not working. @GreatGuru is on the case!


#5

Just a heads up that as of the latest marketplace update, returning a value in a :sk: BP node works again!

Return it the way you would return any value in :sk: like so:


&blueprint
(Real a, Real b) Real
[
!sum : a + b
sum
]


#6