spawn and then stop spawning and start again *HELP!!!!*

Hello guys, I have this platform game im just about done. I came into a problem i cant find out by my self idk why. What i want the game to do is when you hit an x amount of points lets say 5 i want it to completely stop spawning these platforms and start spawning something else and lets say when you hit 10 points it'll start spawning the platforms again and so on . ( I want it to keep inter changing with 5's) So when you hit 5 points it'll stop spawning the platforms and it'll start spawing the other platforms and when you hit 10 points it'll stop spawning the the new platforms and it'll start spawning the old ones and keep interchanging.

Thanks for your help so far guys :)
Victor

Comments

  • colandercolander Member Posts: 1,610

    This will turn an integer to 1 or 0 in other words on/off. Use this as a switch to turn spawners on or off.

  • http_gamesaladhttp_gamesalad Member Posts: 1,340

    Hey could you type it out f you don't mind? its not finding the files when I unzipped it on my XML @colander

  • colandercolander Member Posts: 1,610

    @vnwadike13@gmail.com it is a game project you should be able to unzip it and then open it with GameSalad. I have attached a screen shot of the rules.

  • http_gamesaladhttp_gamesalad Member Posts: 1,340

    Hey bro ! instead of the touch at the start I put when game.score = 5 . Cause I want it to only stop spawning when it gets to 5 and it didn;t stop spawing the platforms. Also I wanted it to start spawning the platform when your score is 10 .

  • http_gamesaladhttp_gamesalad Member Posts: 1,340
  • http_gamesaladhttp_gamesalad Member Posts: 1,340

    didn't *

  • colandercolander Member Posts: 1,610

    I am working at the moment so I can't look at it but you should be able to adapt it to do what you need with a little bit of experimenting.

    The when touch is pressed is just to show you the code works. Delete the change attribute from Otherwise section of the rule and use another rule to switch it back when it is divisible by 10. This is not exactly right but you get the idea.

  • http_gamesaladhttp_gamesalad Member Posts: 1,340

    Hello guys, I have this platform game im just about done. I came into a problem i cant find out by my self idk why. What i want the game to do is when you hit an x amount of points lets say 5 i want it to completely stop spawning these platforms and start spawning something else and lets say when you hit 10 points it'll start spawning the platforms again and so on . ( I want it to keep inter changing with 5's) So when you hit 5 points it'll stop spawning the platforms and it'll start spawing the other platforms and when you hit 10 points it'll stop spawning the the new platforms and it'll start spawning the old ones and keep interchanging.

    Thanks for your help so far guys :) Victor

  • colandercolander Member Posts: 1,610

    You already have a thread on this topic "spawn and then stop spawning and start again HELP!!!!" you cannot create multiple threads on the same topic a Moderator will lock it or merge it with the other one.

  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408

    merged

  • colandercolander Member Posts: 1,610
    edited April 2014

    This is probably not the best way to code this and someone else might do a better job of it. Is this what you want?

  • http_gamesaladhttp_gamesalad Member Posts: 1,340

    @colander hello, sound i add this to my platform actor or leave it as is? cause it didn't work.

  • http_gamesaladhttp_gamesalad Member Posts: 1,340

    should*

  • http_gamesaladhttp_gamesalad Member Posts: 1,340

    @colander hey bro! I came up with this new idea uh if game.score = 5 then change attribute to game.spawn to game.spawn0 . does that make sense?

  • colandercolander Member Posts: 1,610

    Without seeing your code I can't say what will work and what won't. What you described in you post can be done you just need to take the time to think it through.

    Take the concept of what I did and then create your own code that fits into your game.

  • http_gamesaladhttp_gamesalad Member Posts: 1,340

    Okay will do thanks! @colander :)

Sign In or Register to comment.