Jump to content

Search the Community

Showing results for tags 'createmultiple'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Web Gaming Standards
    • Coding and Game Design
    • Paid Promotion (Buy Banner)
  • Frameworks
    • Pixi.js
    • Phaser 3
    • Phaser 2
    • Babylon.js
    • Panda 2
    • melonJS
    • Haxe JS
    • Kiwi.js
  • General
    • General Talk
    • GameMonetize
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered
    • Marketplace (Sell Apps, Websites, Games)

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Twitter


Skype


Location


Interests

Found 4 results

  1. So I am preloading an atlasXML spritesheet game.load.atlasXML('sheet', 'images/sheet.png', 'images/sheet.xml'); and I can create a sprite using: game.add.sprite(game.world.centerX, game.world.centerY, 'sheet', 'playerShip1_orange.png'); I am trying not to use a for loop to create many sprites for a a sprite group I'm creating by using Group.createMultiple Now if I'm just loading a sprite or image, I can do this.meteorGrey = game.add.group(); this.meteorGrey.createMultiple(25, 'meteorGreyBig1.png'); Now when it's in a atlas sprite, this is where I'm running into trouble. this.meteorGrey = game.add.group(); this.meteorGrey.createMultiple(25, 'sheet', 'meteorGreyBig1.png'); It ends up displaying nothing
  2. Hello & Thanks , I have 2 images (actually 4 in final code) named thruth01sprite and thruth02sprite . Rather than duplicate this code , I would like to group them: But I'm not having much luck in writing the group code: // All 40 of them bullets.createMultiple(10, 'bullet'); // bullet becomes bullets bullets.setAll('anchor.x', 0.5); bullets.setAll('anchor.y', 0.5); // bullets.body.velocity.y = -300; // bullets.body.acceleration.y = -300; // All 4 of them okGuys.createMultiple(2, ('truth01sprite','truth02sprite')); // truth01sprite becomes okGuys okGuys.setAll('anchor.x', 0.5); okGuys.setAll('anchor.y', 0.5); The bullets code works fine , but the okGuys no go . Pls, how can I do this properly ? Thanks
  3. Hi, I'm creating a shooter game, and I've followed the 'Space Invaders' example. Everything is working but one thing, I would like to have infinite ammo, so CreateMultiple has to be infinite. It requires a value, so I don't know how to make it actually infinite. Basically what I want to do is create a couple bullets and recycle them over and over again. Any suggestions on how I could do so you never run out of bullets? Thanks in advance, Kevin
  4. Hi gamers! I have a group in which some coins are created with createMultiple. When I start the game the player collisions with unexpected group of coins ... The score of the player increases, therefore the collision occurs, but is not physically collide ... Some code: this.coinlGroup = this.game.add.group(); this.coinGroup.createMultiple(70, 'coin'); this.coinGroup.forEach(setupCoinGroup, this); Greetings!
×
×
  • Create New...