Hello,
I was wondering how do you manage your Unity3D project when you have a Free and Paid game in term of code maintenance as well as buids.
1. Code Maintenance
Free Version ( com.game.freeversion )
-
I would limit the free version to the first 15 Levels and have the other one locked.
I was thinking to define a preprocessor block like#define LITE ... #if LITE freeVersion = true; #endif if(freeVersion) { ... }
As far as i understood, when you have ‘#define LITE’ in the code(at the top of the source), LITE is implicitly set to TRUE. If not defined, it is FALSE.
As a consequence, to build my lite version of the project i need to add this line dynamically, maybe with an ‘ant’ task before compiling the project, which i find really painful
Pro Version( com.game.paidversion )
2. Build
If i want to build both projects in one shot, i guess i would need to have unity3D Pro and play around BuildPipeline.BuildPlayer to manipulate the packagename + set the correct #define in my code.
Do you mind sharing your experiences ? Maybe there is an easy way
Thank you very much
Florent Valdelievre