Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

How do I spawn a sprite anytime later in the game when the game starts?

I'm using FlashDevelop with Flixel. I did try it in override public function create(): void. It works only in the beginning. I try it using if (FlxG.score == 1) but it doesn't work. I also tried it in override public function update(): void. It works and it is moving but it leaves a sprite making it a multi-sprite. I also did try FlxGroup but to no avail.

share|improve this question
    
Is the spawning going to be dependent on some event or is it just time based? –  Byte56 Sep 18 '13 at 15:01
    
It's going to be dependent on some event (FlxG.score). :) –  teddyweedy Sep 19 '13 at 11:38
    
I think I've already answered my question. Case closed. Still, thanks for your reply, Byte56. :) –  teddyweedy Sep 19 '13 at 13:30
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.