Please Help Needed about unlimited enemies in platformer game?

cherrywtzcherrywtz Member, PRO Posts: 40

Please someone help me with this problem :'( .
i want to make a platformer game,
how would i get unlimited random enemies from set of 5 enemies in the endless background..?

please post some answers..........thank you :)

Comments

  • cherrywtzcherrywtz Member, PRO Posts: 40

    Please someone help me with this problem :'( .
    i want to make a platformer game,
    how would i get unlimited random enemies from set of 5 enemies in the endless background..?

    please post some answers

  • ookami007ookami007 Member Posts: 581

    Are you thinking of a platformer game (like Super Mario World) or more of an endless runner game?

    Either way, you can spawn unlimited random enemies, depending on what your criteria is.

    I have several examples of spawning templates on my site monkeyuncle.com. They're all free.

    This shows two ways to spawn random objects:

    http://www.monkeyuncle.com/shop/random-object-generator-mark-ii/

    This shows endless spawning on platformer type setting:

    http://www.monkeyuncle.com/shop/2d-enemy-melee-attack-template/

    And there are others. There's even enemy spawning in some of my tutorials, plus there's plenty of great examples here on the forums and on YouTube.

  • Thunder_ChildThunder_Child Member Posts: 2,343
    edited June 2015

    Sorry I don't have an answer but also wanted to let you know it's slightly frowned upon to create multiple threads....one is just fine.

    I'm not even sure how many people use the Pro section much anymore because the pro section leaves non pro members out of the discussion...and I assure you there are loads of non pro members with tons of input...sometimes you need to give a little time for a day to complete across the globe for members to see your question.

  • jigglybeanjigglybean Member Posts: 1,584

    this should help you. Youtube is a great place to search for videos

    Like Balls? Then click here! We've 100 coming soon

  • BalvamarBalvamar Member, PRO Posts: 117

    an attribute for each enemy to represent the count for each. Each time you spawn an enemy add 1 to the count. Each time an enemy is destroyed take 1 away from that enemy. Set a behaviour to spawn anytime an enemy is below however many of that enemy you want to have in play. e.g. if enemy 3 count is <= 3 spawn enemy (at whatever xy position you want the enemy.

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @Thunder_Child said:
    Sorry I don't have an answer but also wanted to let you know it's slightly frowned upon to create multiple threads....one is just fine.

    I'm not even sure how many people use the Pro section much anymore because the pro section leaves non pro members out of the discussion...and I assure you there are loads of non pro members with tons of input...sometimes you need to give a little time for a day to complete across the globe for members to see your question.

    yeah i agree..

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @jigglybean said:
    this should help you. Youtube is a great place to search for videos

    buddy i know this video...but this not...what i asked..

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @ookami007 said:
    Are you thinking of a platformer game (like Super Mario World) or more of an endless runner game?

    Either way, you can spawn unlimited random enemies, depending on what your criteria is.

    I have several examples of spawning templates on my site monkeyuncle.com. They're all free.

    This shows two ways to spawn random objects:

    http://www.monkeyuncle.com/shop/random-object-generator-mark-ii/

    This shows endless spawning on platformer type setting:

    http://www.monkeyuncle.com/shop/2d-enemy-melee-attack-template/

    And there are others. There's even enemy spawning in some of my tutorials, plus there's plenty of great examples here on the forums and on YouTube.

    SSL connection error???
    while checking out...any help???

  • ookami007ookami007 Member Posts: 581

    @cherrywtz said:
    while checking out...any help???

    I've changed a setting, so try it again. It shouldn't use SSL since all of the templates are free.

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @ookami007 said:

    sorry dude...same error is there anyway i can get it,like gdrive or mediafire???
    please help needed... :|

  • ookami007ookami007 Member Posts: 581

    Describe exactly what you want to do.

  • ApprowApprow Member Posts: 703

    @cherrywtz said:
    how would i get unlimited random enemies from set of 5 enemies in the endless background..?

    What exactly do you mean by sets of 5 enemies in the endless background? If you give a bit more info about how your game works and what you want to achieve, then we could try to help you out:)

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @Approw said:
    What exactly do you mean by sets of 5 enemies in the endless background? If you give a bit more info about how your game works and what you want to achieve, then we could try to help you out:)

    Hi Dude,
    It is platformer game,main actor will be running endless(creating this not a problem),
    but the main problem i'm facing is how to generate unlimited number of obstacles..like randomly.
    reply ASAP man Thank you :)

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @ookami007 said:
    Describe exactly what you want to do.

    This is it dude...please contact ASAP :)

  • ookami007ookami007 Member Posts: 581

    So spawn them and then they move towards the player?

  • BalvamarBalvamar Member, PRO Posts: 117
    edited June 2015

    Create 1 actor to represent the 5 enemies.
    In that actor create an index attribute and call it "myIndex".
    Drag 5 copies of the actor into the scene, then open each one and change its index to 1,2,3 etc.
    Drag an image on top of each enemy in the scene.
    In the prototype actor set your behaviours.
    Create a rule for each index. Eg if self.index = 1. This will allow you to vary each enemy behaviour.
    If you want the enemies to move from right to left..change behaviour self.linear.x to -200
    Create another actor called "control" in that actor create rules to spawn the enemy actor at the right of the screen.

    The endless runner example above by Jamie cross is great. Do the tutorial, then change it to incorporate your own ideas. Hope that helps

  • ookami007ookami007 Member Posts: 581

    Ok... I have a tutorial I created for you for simply spawning actors for an endless runner. I didn't include the random 1 of 5 part in the tutorial, but it is in the template file.

    The tutorial is still processing on YouTube, but you can go ahead and download the template and start playing with it. It will spawn 1 of 5 random obstacles every 1.5 seconds. The video tutorial explains most of it... just not the random spawning part.

    Basically, I'm setting self.random to floor(random(1,5)) which creates a random number from 1 to 5.

    Then, I go through 5 rules. The first checks if self.random = 1 and if so, spawns obstacle 1. The second checks to see if self.random = 2 and if so, spawns obstacle 2, and so on.

    https://dropbox.com/s/nypino8k7wmods3/Endless%20Runner%20Tutorial%202.zip?dl=0

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @Balvamar said:
    Create 1 actor to represent the 5 enemies.
    In that actor create an index attribute and call it "myIndex".
    Drag 5 copies of the actor into the scene, then open each one and change its index to 1,2,3 etc.
    Drag an image on top of each enemy in the scene.
    In the prototype actor set your behaviours.
    Create a rule for each index. Eg if self.index = 1. This will allow you to vary each enemy behaviour.
    If you want the enemies to move from right to left..change behaviour self.linear.x to -200
    Create another actor called "control" in that actor create rules to spawn the enemy actor at the right of the screen.

    The endless runner example above by Jamie cross is great. Do the tutorial, then change it to incorporate your own ideas. Hope that helps

    thank you dude :) cheers :)

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @ookami007 said:
    Ok... I have a tutorial I created for you for simply spawning actors for an endless runner. I didn't include the random 1 of 5 part in the tutorial, but it is in the template file.

    The tutorial is still processing on YouTube, but you can go ahead and download the template and start playing with it. It will spawn 1 of 5 random obstacles every 1.5 seconds. The video tutorial explains most of it... just not the random spawning part.

    Basically, I'm setting self.random to floor(random(1,5)) which creates a random number from 1 to 5.

    Then, I go through 5 rules. The first checks if self.random = 1 and if so, spawns obstacle 1. The second checks to see if self.random = 2 and if so, spawns obstacle 2, and so on.

    https://dropbox.com/s/nypino8k7wmods3/Endless%20Runner%20Tutorial%202.zip?dl=0

    thanks for the tutorial dude... :) cheers :)

  • ookami007ookami007 Member Posts: 581

    I hope it helps you.

  • cherrywtzcherrywtz Member, PRO Posts: 40

    @ookami007 said:
    I hope it helps you.

    it really does man...you're just awesome :)

Sign In or Register to comment.