Announcement

Collapse
No announcement yet.

Spawn Actor From Class

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    Spawn Actor From Class

    Hello folks,

    simple question here, what needs to go in "Spawn Transform" on the SpawnActor StaticMeshActor blueprint node?

    Obviously it works a bit different to the old Kismet spawning system but i'm at a loss with this since it's throwing up "Error Default value '' for SpawnTransform is invalid: 'Literal values are not allowed for pass-by-reference parameters.' " regardless of what value I put in there.

    I would've thought it'd want a vector however it doesn't seem happy with 0,0,0 (0,0,0) x=0,y=0,z=0 or any variation on that.

    cheers, Matt

    #2
    Hmm, attempting to connect a vector should automatically convert it to transform.

    Anyway, you can also drag and drop to an empty area from the Spawn Transform input pin, search for "Make Transform", and enter the vector, rotator and scale values there.
    Jefferson Pinheiro

    Comment


      #3
      This...

      Originally posted by Ixiguis View Post
      Hmm, attempting to connect a vector should automatically convert it to transform.

      Anyway, you can also drag and drop to an empty area from the Spawn Transform input pin, search for "Make Transform", and enter the vector, rotator and scale values there.
      When you drag off the Spawn Transform pin, and enter Vector in the search... it should allow you to create one.

      Click image for larger version

Name:	SpawnActorFromClass.jpg
Views:	1
Size:	18.8 KB
ID:	1049862

      Comment


        #4
        Ahh perfect, cheers folks!

        Comment


          #5
          The easiest way is to drag off and select "make transform".

          This way you have access to its rotation, scale and location!

          Click image for larger version

Name:	Make Transform.jpg
Views:	1
Size:	60.9 KB
ID:	1049863
          Designer

          aka. neoduck

          Comment


            #6
            Depending on how your constructing...if you want to use the the blueprint itself as the placement for the spawn point you can use the variable Get A Reference To Self, hook that up to a Get Actor Location, then hook that up to the Spawn Transform and it creates a vector automatically. So wherever you place the blueprint actor that's where whatever spawns.
            Now..I'm having a problem spawning a character blueprint. It will spawn the character but it will not fall to the ground i.e. stuck at the spawn point. I'm using the character blueprint for testing basic move to navigation and that works when the blueprint actor is placed in the level, but when spawned the character is stuck, animating but stuck and won't fall / move. Any ideas ?
            Mere Mortal Games

            Comment

            Working...
            X