playMaker

Author Topic: About template is not working  (Read 285 times)

daodao

  • Playmaker Newbie
  • *
  • Posts: 1
About template is not working
« on: March 25, 2024, 10:26:07 PM »
Hi, I am using Unity 2.22.3.17 and I have imported PlayMaker into the project. In editor mode, the state machine I created or the template I saved works. But when I run the PC version of the build, it doesn't play right where the template is used. If I replace the template with a state machine that has the same effect, there is no problem.Why, please? thanks.

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 4002
  • Official Playmaker Support
    • LinkedIn
Re: About template is not working
« Reply #1 on: March 27, 2024, 07:32:40 AM »
Is the FSM in the template referencing scene objects? Templates are assets, which in Unity means they can’t save references to scene objects. Instead you have to find the scene object at runtime, either using an action or by exposing a variable as an input and hooking it up in the inspector.