Stunt Squirrels! now working 100% in 0.81
firemaplegames
Member Posts: 3,211
Hey,
So I retooled Stunt Squirrels! and finally got it working 100% again. The web version has been updated.
My main issue was my "Scene Controller" Actor.
This Actor Instance sits just offscreen and resets the level Attributes. Stuff like:
Change Attribute:
game.currentLevel = 1
Change Attribute:
game.bombCount = 10
Change Attribute:
game.gameOver = false
etc...
It would reset everything as well as set the specifics for that level.
This worked fine before, but with the new speed increase, the other Actors in the Scene would act before getting this information.
For instance, one Actor in the Scene would instantly think that game.bombCount is 0 (because that is what is was when the previous level ended) and would trigger Game Over.
I just had to move stuff around and lock stuff down. Similar to what I had to do in Danger Cats!.
Thanks to the GS team for working so hard to improve this already great product!
Joe
Fire Maple Games
So I retooled Stunt Squirrels! and finally got it working 100% again. The web version has been updated.
My main issue was my "Scene Controller" Actor.
This Actor Instance sits just offscreen and resets the level Attributes. Stuff like:
Change Attribute:
game.currentLevel = 1
Change Attribute:
game.bombCount = 10
Change Attribute:
game.gameOver = false
etc...
It would reset everything as well as set the specifics for that level.
This worked fine before, but with the new speed increase, the other Actors in the Scene would act before getting this information.
For instance, one Actor in the Scene would instantly think that game.bombCount is 0 (because that is what is was when the previous level ended) and would trigger Game Over.
I just had to move stuff around and lock stuff down. Similar to what I had to do in Danger Cats!.
Thanks to the GS team for working so hard to improve this already great product!
Joe
Fire Maple Games
Comments
I agree with Sci that some tips on how to reconfigure things, from the GS team would be nice, but, let's be honest Sci, we're a strange bunch, present company most definitely INcluded, and I doubt that the GS guys would ever be able to second guess all the bizarre ways that we try and get GS to work for us and do what we want it to do!
So FM, I understand it's a pain to explain fully, but would you mind telling us roughly what kinds of things you had to change? I mean, in your example above...
Change Attribute:
game.currentLevel = 1
Change Attribute:
game.bombCount = 10
....what do these rules look like now, in yer working 8.1 version??
Thanks
Wayne
Then all my actors have one rule that encompasses all other rules/behaviors that tests for "SceneSetupComplete" to be true (i.e. before doing its stuff). Works fine for me. You could add some custom pause conditions here too if you weren't doing the seperate pause scene method.
I had to implement this in 0.7.0 as my actors were trying to use values that the scene controller was still setting or hadn't set yet. Sounds like what FMG had to do for 0.8.1.
Maybe that is what he meant by "lock stuff down".
I have a similar "ActorSetupComplete" inside each actor too for similar purposes (on some).
I used to have something like this:
Rule
When TOUCH is PRESSED
Play Sound "Goodbye!"
Destroy Actor
This no longer works. Destroy fires first and the sound never plays.
I had to do this:
Create a Boolean called "destroyMe"
Rule
When TOUCH is PRESSED
Play Sound "Goodbye!"
Change Attribute self.destroyMe to TRUE
Rule
When self.destroyMe = TRUE
Destroy Actor
This now works. I had to separate them and make sure each behavior fires only when I want it to.
Instead of just stacking them on top of each other, I had to 'chain' them together with Rules so to speak.
Also, the whole project is probably not all messed up, just some actors here and there.
Just take a deep breath and tackle them one by one.
In the end, it's just sloppy stuff we were relying on. The speed increase is worth the additional effort.
Also, going forward with this beta software, some things will definitely be rethought and reworked on GS's part, and we're bound to run into issues like this again...
Joe
I should have done that from the beginning, but I was being lazy, and it worked...