Hello Guest

Author Topic: How to save the changes made to prefab during runtime ??  (Read 5452 times)

RakeshChatra

  • Newbie
  • *
  • Posts: 33
    • View Profile
How to save the changes made to prefab during runtime ??
« 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.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: How to save the changes made to prefab during runtime ??
« Reply #1 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.

RakeshChatra

  • Newbie
  • *
  • Posts: 33
    • View Profile
Re: How to save the changes made to prefab during runtime ??
« Reply #2 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..:)

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: How to save the changes made to prefab during runtime ??
« Reply #3 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.