playMaker

Author Topic: [SOLVED] Integrating my asset with PlayMaker  (Read 1863 times)

ATeshGames

  • Playmaker Newbie
  • *
  • Posts: 12
[SOLVED] Integrating my asset with PlayMaker
« on: December 13, 2017, 09:53:55 AM »
I'm currently getting my transition asset working with PlayMaker and have a question about how to have the custom action scripts in my asset but still compile for others who download the asset but don't have PlayMaker. I was hoping that there was a #define that turned PlayMaker code on and that I could wrap a #ifdef around my code but I don't see that in any of PlayMaker's code. The best I can think of is to comment out the whole files that include my PlayMaker actions and tell PlayMaker users to remove those comments which isn't ideal.
Any ideas on what to do here?
« Last Edit: December 15, 2017, 10:24:48 AM by ATeshGames »

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7614
    • jinxtergames
Re: Integrating my asset with PlayMaker
« Reply #1 on: December 13, 2017, 12:33:46 PM »
Hi,
I would place the actions into a package and have an option in the menu to install them (import the package)
Then if you have parts in other code, i believe
Code: [Select]
#define PLAYMAKER
or you can split up you code and include the parts into the package.

ATeshGames

  • Playmaker Newbie
  • *
  • Posts: 12
Re: Integrating my asset with PlayMaker
« Reply #2 on: December 13, 2017, 01:06:05 PM »
I'm a little confused. Are you saying that #define PLAYMAKER already exists?
If so I can just wrap my code up like this:
Code: [Select]
#if PLAYMAKER
//...
#endif

I'll give that a shot!

ATeshGames

  • Playmaker Newbie
  • *
  • Posts: 12
Re: Integrating my asset with PlayMaker
« Reply #3 on: December 13, 2017, 05:57:56 PM »
That worked perfectly thanks!

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Integrating my asset with PlayMaker
« Reply #4 on: December 14, 2017, 12:55:36 AM »
Hi,

 Cool, Let us know when it's up, we'll be happy to give this a shout :)

 Bye,

Jean

ATeshGames

  • Playmaker Newbie
  • *
  • Posts: 12
Re: Integrating my asset with PlayMaker
« Reply #5 on: December 15, 2017, 10:24:06 AM »
Thanks Jean I appreciate it! It's up now at https://assetstore.unity.com/packages/tools/camera/transition-blocks-69448
The asset allows you to easily make nice transitions between scenes.  ;D

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: [SOLVED] Integrating my asset with PlayMaker
« Reply #6 on: December 18, 2017, 02:43:11 AM »
Hi,

 woah, I am impressed, nice transitions! I tweeted about it: https://twitter.com/JeanAtPlayMaker/status/942661368267886592

 Bye,

 Jean