playMaker

Author Topic: How to load a game object from prefab?  (Read 1285 times)

Adam Z

  • Full Member
  • ***
  • Posts: 207
How to load a game object from prefab?
« on: February 17, 2016, 05:00:18 PM »
I have two characters which are prefabs, and neither are brought into the level. I have a character controller with an FSM, and have the action to "Select Random Game Object" to randomly choose between the two.  If they're not brought into the level, how can I load the chosen one into my game?

Thanks.

mdotstrange

  • Hero Member
  • *****
  • Posts: 555
    • Can't code? Who cares! Make games anyway!
Re: How to load a game object from prefab?
« Reply #1 on: February 17, 2016, 07:40:36 PM »
You can using a pooling system- then you would spawn/despawn them-

You could also use the "Resources Load" action that is on Ecosystem
Indie game dev and instructor at the Strange School. Learn Playmaker at the Strange School!