playMaker

Author Topic: All scripts stop after reloading levels  (Read 8479 times)

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
All scripts stop after reloading levels
« on: April 30, 2013, 03:45:18 PM »
During the 1st time I run the game, all the scripts are working fine. But when the game is over and I reload the 1st level again, all scripts stops working. Any ideia of why this is happening?

Thanks

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
Re: All scripts stop after reloading levels
« Reply #1 on: April 30, 2013, 03:52:46 PM »
Actually, not all the scripts but basically the Fade in actions.

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
Re: All scripts stop after reloading levels
« Reply #2 on: April 30, 2013, 04:28:18 PM »
iTween actions stops after the level is reloaded.

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
Re: All scripts stop after reloading levels
« Reply #3 on: April 30, 2013, 05:23:49 PM »
Problem solved. Just checked the RealTime checkbox on the actions to true. Not sure why but it solved the issues.

Pawel

  • Junior Playmaker
  • **
  • Posts: 93
Re: All scripts stop after reloading levels
« Reply #4 on: April 30, 2013, 11:38:11 PM »
Problem solved. Just checked the RealTime checkbox on the actions to true. Not sure why but it solved the issues.

I have similar problem after reloading with "Smooth Look At" action. After reloading the character that is controlled by this action faces different direction then the target that is specified. In fact it is running sideways. In this case there is no RealTime option to chose.

I've also notices other strange behaviors that happen after reloading the level. Is there a way to load the level as it were running for the first time, rather the re-loading? I mean purging the memory and re-initializing? Those kinds of bugs take days to find a workaround...

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
Re: All scripts stop after reloading levels
« Reply #5 on: May 01, 2013, 09:43:03 AM »
I've solved the iTween Issue and found another one with a Send Message action. Also when the game reloads, it doesn't work anymore. If you find any solution to your issue, please share here.

Pawel

  • Junior Playmaker
  • **
  • Posts: 93
Re: All scripts stop after reloading levels
« Reply #6 on: May 01, 2013, 09:56:33 AM »
I've seen some similar bug reporting messages on Unity website. I wonder if this is not something that is caused by the Unity rather then Playmaker. Either way it needs to be solved since this is a huge issue...

http://forum.unity3d.com/threads/178490-Reload-level-bug

It would be nice to have a Purge Memory Action when reloading levels as an option in case this sort of thing happens...

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
Re: All scripts stop after reloading levels
« Reply #7 on: May 01, 2013, 10:15:19 AM »
The curious thing about this issue is that on my game I am calling the Send Message action in two different ways. On some levels it is called using a NGUI button with a JavaScript and it works fine even when the game is reloaded but on the levels it is called from other FSMs when the game is reloaded, they stop working.

Pawel

  • Junior Playmaker
  • **
  • Posts: 93
Re: All scripts stop after reloading levels
« Reply #8 on: May 01, 2013, 10:18:03 AM »
Same thing here. I have two characters controlled via Move Towards and Smooth Look at actions. One of them works fine... Go figure!

Pawel

  • Junior Playmaker
  • **
  • Posts: 93
Re: All scripts stop after reloading levels
« Reply #9 on: May 01, 2013, 10:23:23 AM »
Although I should not insist that the other character works fine -- Every now an then some of the animations, loading of which relies on the speed of the character that is reported to them, no longer load while the character moves. The character goes to "Idle" animation instead of "Run"... This does not happen all the time, so it is even harder to find the cause.

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
Re: All scripts stop after reloading levels
« Reply #10 on: May 01, 2013, 10:45:45 AM »
Actually it is a Send Event and not a Send Message action.

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
Re: All scripts stop after reloading levels
« Reply #11 on: May 01, 2013, 11:15:53 AM »
Problem solved. I've just changed the Send Event actions to Send Event ByName actions and it is working fine now.

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3987
  • Official Playmaker Support
    • LinkedIn
Re: All scripts stop after reloading levels
« Reply #12 on: May 01, 2013, 12:22:58 PM »
There's something else going on here. You shouldn't have to do that...

Can you send me a project in a broken state? I.e., you press play and it shows the bug?

You could also try loading an empty scene, then your target scene to help Unity reset properly...

Tropical Cyborg

  • Playmaker Newbie
  • *
  • Posts: 23
  • Meet Tropical Cyborg
    • Tropical Cyborg
Re: All scripts stop after reloading levels
« Reply #13 on: May 01, 2013, 12:24:51 PM »
Send to an email?

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3987
  • Official Playmaker Support
    • LinkedIn
Re: All scripts stop after reloading levels
« Reply #14 on: May 01, 2013, 12:30:27 PM »
Either use Playmaker/Tools/Submit Bug Report and you should get a link to a bug that you can attach a project to.

Or email to info@hutonggames.com with a link to this thread.

Thanks!