Using the same actor for multiple scenes
Chr0nos
Wondering Vagabond AustraliaMember Posts: 113
Hi guys,
I'm attempting my first game atm. I am super new to GameSalad but giving it the ol' college try.
In my game, the Hero must jump from one platform to another to complete the level. (Simple, I know, but I'm just getting my feet wet) However, each level, the hero's jump increases so he can deal with bigger and bigger jumps from platform to platform.
Here is my question: Is there a way that I can use the same actor (The hero actor) for each scene, and just change his jump size? I tried doing that, but when I change it in one scene, it changes it in all the scenes. So do I really have to create a new hero actor for every scene that I change his jump in?
Thanks in advance for any help or advice you can offer!
Joel
Comments
In your Hero actor, Change Attribute game.jumpSize to game.jumpSize+50, or whatever mathematical function you like. In each scene, that behavior will run and increase that game attribute. Do not put the behavior inside of a rule.
If you need different rules and not just different attribute values, then you would need to double-click on the Hero actor in each scene and unlock it to create an instance with unique rules.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Thank you tatiang,
I will be sure to give this a try. I really appreciate your help!
That worked tatiang.
Thank you so much!
You're welcome!
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User