Timers and Spawning Actors

hackmodfordhackmodford Member Posts: 48
edited November -1 in Working with GS (Mac)
Okay... my game is really coming along now. But I think I'm missing something in regards to timers.

Say every second I want to spawn one actor.

I create a timer event set for every second and in there put spawn actor blah blah blah...

But I will end up with around 4 actors... what am I missing?

Comments

  • hackmodfordhackmodford Member Posts: 48
    Yes... except it seems like it spawns as many actors as it can in that 1 second window. I think there's just something I don't understand about the behavior of timers.
  • hackmodfordhackmodford Member Posts: 48
    Here's another problem I'm having with a timer.

    I have it set

    every 10 seconds
    set attribute X to X+10

    X starts out at 150
    The first time it happens it goes up to 200
    Later in in the game it starts adding only 10 as expected.

    Got any ideas why it behaves like this? I know a way to get around it but this just seems wrong to me...
  • DrGlickertDrGlickert Member Posts: 1,135
    Are you using Timer: FOR 1 second spawn actor, or EVERY 1 second spawn actor?
  • hackmodfordhackmodford Member Posts: 48
    I'm an idiot XD
    I figured out what it is...

    Basically let's say I have an actor... we'll call him obstacle

    He is set... every 10 seconds blah blah blah...
    Well if there's more than 1 of these actors in the scene that timer gets repeated for however many times there is an actor.

    So I created another actor to just hold rules that should apply only once and walla! problem solved.
Sign In or Register to comment.