2D Toolkit Forum

2D Toolkit => Support => Topic started by: RakeshChatra on January 06, 2014, 12:19:25 pm

Title: How to save the changes made to prefab during runtime ??
Post by: RakeshChatra on January 06, 2014, 12:19:25 pm
Hi, i am trying to make changes to prefab during runtime by adding some objects to the prefab and also changing the color of the prefab. I want these changes to apply to other prefabs(clones) also.. How can i achieve this ?? are there any ways to achieve this ? I have 3 prefabs and i want any change made on any prefab should automatically make changes in other prefabs also.. Please help.. Thank you in advance.
Title: Re: How to save the changes made to prefab during runtime ??
Post by: unikronsoftware on January 06, 2014, 12:23:24 pm
You can't. As far as I know, Unity doesn't maintain the relationship when the game is running.
Title: Re: How to save the changes made to prefab during runtime ??
Post by: RakeshChatra on January 06, 2014, 01:40:22 pm
thank you unikron for replying.. then what is the alternative approach for updating one change in all other prefabs ?? i am having 3 maps in my game if i change one state sprite colour in one map i want this to be updated in other two maps..:)
Title: Re: How to save the changes made to prefab during runtime ??
Post by: unikronsoftware on January 07, 2014, 11:11:53 am
if you change it in the scene and click Apply when the game isn't playing, it should propagate to the other scenes too, as long as you don't override the value in the other scene.