How do i spawn faster? Over a period of time.

DanielADanielA Member Posts: 101
edited November -1 in Working with GS (Mac)
Ok well im working on a new game. But i have come across a problem with a spawner actor. What im trying to do is over time the spawner starts to spawn faster.
I have tried a few things: I created an attribute (REAL) called "spawnSpeed" set it to (.7), after 10 seconds (change attribute spawnSpeed to spawnSpeed - .1) and nothing works.
I have also tried: Creating an attribute (INTEGER) "spawnSpeed", creating a rule in Spawner saying that (spawnSpeed = 7) do (spawn every .7 seconds) after (10 seconds change spawnSpeed to 6) and repeat the rule just changing the speed.
I hope that you understood what i said just there... Anyone els have any ideas of how i could do this idea?

Comments

  • nulonulo Member Posts: 315
    http://gamesalad.com/forums/topic.php?id=6736#post-43856

    Im having the same problem. seems like a bug inside the timer expression.
  • DanielADanielA Member Posts: 101
    Oh well that sucks. I hope they fix it soon because i want my game out already. (or if theres a different way of going about this problem)
  • peachpellenpeachpellen Member Posts: 977
    Not sure whether or not this is exactly what you are looking for - but I used it to spawn balloons at 3 second intervals, then one second intervals.

    The actor I'm editing is a hidden object spawning balloons - you'll notice my timers are not set up within a rule as the balloons start spawning when the scene loads - you'll want to change this if you don't want the same thing in your game.

    HIDDEN OBJECT (SPAWNER):
    Timer - for 10 seconds
    Timer - every 3 seconds spawn balloon

    Then

    Timer - after 10 seconds
    Timer - every 1 seconds spawn balloon

    Does this help?
  • CodeMonkeyCodeMonkey Head Chef, Member, PRO Posts: 1,803
    You need to restart the timer for the new value.
    http://gamesalad.com/game/play/59180

    Here is how it can be done:
    http://gamesalad.com/wiki/how_tos:gsc_variable_timer_speed
Sign In or Register to comment.