I need Help, i want create a game with level selection and three stars for level

1UpGamestudio1UpGamestudio Member Posts: 213
edited November -1 in Working with GS (Mac)
Hello everyone, I need help.
I want to create a game with the selection of the level and for each level there will be three stars to be taken, for a total of 150 stars.
The question is this without creating 50 variables, one per level, how do I create a few variables? clearly the three stars on each level are independent.
Thank you and look forward to your reply.

Comments

  • mynameisacemynameisace Hull, UKMember Posts: 2,484
    I have created 75 attributes, one per level for my latest game. That way I can refer to them on the level select menu/for points and adding up etc.

    Ace
  • JohnPapiomitisJohnPapiomitis Member Posts: 6,256
    like ace said for the stars youll want a attribute for each level.

    But to actually unlock the all the levels u can do that with 1 attribute

    Have a attribute called level clear set to to 1

    when you beat level 1 change level clear to 2 in whatever you press to go to the 2nd level have when touch is pressed and attribute level clear is >1 change scenee to level 2. then when you beat level 2 change level clear to 3. And in the acotr you press to go to the 3rd level have when touch is pressed and attribute level clear is > 2 change scene to level 3, and so on
  • 1UpGamestudio1UpGamestudio Member Posts: 213
    Mynameisace: i have more variables and my game in several step the game goes very slow.
    I think is the variabile.
  • JohnPapiomitisJohnPapiomitis Member Posts: 6,256
    1UpGamestudio said:
    Mynameisace: i have more variables and my game in several step the game goes very slow.
    I think is the variabile.

    the number of attributes wont effect the performance. That would be timers, constraints, spawns, and destroys. Some of us have games with over 500 atttributes
  • mynameisacemynameisace Hull, UKMember Posts: 2,484
    My game has a shed load of variables in, around 4-500 and is working great even on 3G devices. The actual amount of attributes doesn't affect the game performance at all, just things like badly sized artwork, constrain attributes, timers, not recycling actors, etc.

    Ace
  • mynameisacemynameisace Hull, UKMember Posts: 2,484
    John beat me to it haha... Damn you John :P

    Ace
  • 1UpGamestudio1UpGamestudio Member Posts: 213
    I spawn more sprites and i have more timers.
  • mynameisacemynameisace Hull, UKMember Posts: 2,484
    You need to cut down on them a shed load if you want it to run on a device.

    When you spawn and destroy, GS doesn't garbage collect as efficiently as needed to have a load of spawns/destroys. Instead, try just moving the actor out of the boundaries of the camera so you can't see it then change the x and y values to on screen when you want to spawn.

    Ace
  • 1UpGamestudio1UpGamestudio Member Posts: 213
    You see the trailer of my game?

    the squares come from different sides of the screen, but when the square is many the game becomes slow.
    You have a solution?
  • PortymanPortyman Member, PRO Posts: 409
    I actually just created a template a few days with this feature and 105 scenes.

    http://gamesalad.com/forums/topic.php?id=17697
Sign In or Register to comment.