Announcement

Collapse
No announcement yet.

Construct object from class and spawn actor from that class

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

    Construct object from class and spawn actor from that class

    So I have a thing which is not an Actor but it require to spawn actors.

    The problem is that I cannot use "spawn actor from class" from within a class which is not an actor. it says that I need a reference to the current world context which make sense. but how do I add this reference?

    #2
    You can grab World from any actor reference. Using the GetWorld() function.
    If you're using Blueprint, simply get a reference to Self actor and attach to world context.
    | Savior | USQLite | FSM | Object Pool | Sound Occlusion | Property Transfer | Magic Nodes | MORE |

    Comment


      #3
      Originally posted by BrUnO XaVIeR View Post
      You can grab World from any actor reference. Using the GetWorld() function.
      If you're using Blueprint, simply get a reference to Self actor and attach to world context.
      "Spawn actor from class" doesn't have any input for the world context, how can I set it?

      Comment

      Working...
      X