anissen

Members
  • Content Count

    23
  • Joined

  • Last visited

About anissen

  • Rank
    Member

Contact Methods

  • Twitter
    andershnissen

Recent Profile Visitors

949 profile views
  • Juls

  1. I finished my second Ludum Dare game, Dungeon Break! Link: http://www.ludumdare.com/compo/ludum-dare-29/?action=preview&uid=30512 Story: A deranged wizard has trapped you in his magical dungeon deep beneath the ground! To escape you need exploit the dungeon itself. Reach the stairs to get to the next level and finally -- to the surface and to freedom! Controls: Mouse/touch only. Click adjacent tiles to move left/right/up/down. Click and drag (e.g. swipe) tiles to push rows horizontally and columns vertically. NOTE: Rows/columns containing "X"-blocks cannot be pushed. Development tools:Coded in Haxe using the Flambe game engine. Graphics are doing using Pixelmator. Music is made using Autotracker + Audacity. Sound effects are made using Sfxr (procedurally).
  2. Very nice! This could definitely come in handy. It would be nice if there was a functional web-based version in addition to the node-webkit version. I tried using 5minfork.com on the repo, but didn't get json output from the inputted ogg-file...
  3. Cool! I'm more interested in HTML5 and Android/iOS targets but Flambe already supports those. However, the more targets that Flambe support (and the more community backing Flambe) the better
  4. I just found Flambe and started testing it out. I seems like a really awesome framework, very neat and intuitive and with an incredible showcase to vouch for it. My concerns with Flambe are as follows: The development seems to be slow (judging by the number and frequency of commits) and by very few contributors. Is it still under active development or only being maintained? Where's the roadmap?There are a lot of old issues and pull-requests that have not been handled. This makes me somewhat nervous about getting involved.The framework seems pretty bare-bones. Where are the contributions from Disney and Nickelodeon?I hope that Aduros is able to answer these questions. Either way, I am going to experiment with Flambe some more to see if it is a good fit for my projects. Thanks a lot to Aduros for your work on Flambe and markknol for you excellent Flambe guide!
  5. I can reproduce your issue, but I have no clue to that causes it or how to fix it. What I do have is a request for you; when you get it working, please make this is into an audio filter library (or Phaser plugin)! The demo that you have made is already extremely cool by itself!
  6. Solved it! As with so many other things, the solution appeared after a good nights sleep Thank you for your reply, Heppell08. However, my problem was that I had set the different collision groups to collide with the tilesCollisionsGroup, but not the other way around. So, I had done something like var tilesCollisionGroup = this.physics.p2.createCollisionGroup(); var playerCollisionGroup = this.physics.p2.createCollisionGroup(); for (var i = 0; i < tileObjects.length; i++) { var tileBody = tileObjects[i]; tileBody.setCollisionGroup(tilesCollisionGroup); } var ship = this.add.sprite(200, 200, 'ship'); this.physics.p2.enable(ship, false); ship.body.setCollisionGroup(playerCollisionGroup); ship.body.collides(tilesCollisionGroup);When I should have done it like this (notice tileBody.collides(playerCollisionGroup): var tilesCollisionGroup = this.physics.p2.createCollisionGroup(); var playerCollisionGroup = this.physics.p2.createCollisionGroup(); for (var i = 0; i < tileObjects.length; i++) { var tileBody = tileObjects[i]; tileBody.setCollisionGroup(tilesCollisionGroup); tileBody.collides(playerCollisionGroup); } var ship = this.add.sprite(200, 200, 'ship'); this.physics.p2.enable(ship, false); ship.body.setCollisionGroup(playerCollisionGroup); ship.body.collides(tilesCollisionGroup);
  7. I have a tilemap and some sprites. Some of the sprites must collide with each other and all most collide with the tilemap. When I set a sprite to collide with a collision group (ie. playerSprite.body.collides(enemyCollisionGroup)), the sprite *only* collides with that group. To make it also collide with the tilemap I guess I need to do a playerSprite.body.collides(tilesCollisionGroup). However, I cannot figure out how to correctly construct tilesCollisionGroup. I tried several different approaches along the lines of map.setCollisionBetween(1, 12, true, layer2); var tileObjects = this.physics.p2.convertTilemap(map, layer2); var tilesCollisionGroup = this.physics.p2.createCollisionGroup(); for (var i = 0; i < tileObjects.length; i++) { var tileBody = tileObjects[i]; tileBody.setCollisionGroup(tilesCollisionGroup); tileBody.collides(playerCollisionGroup); }... with no luck. Any ideas for handling collisions between sprites/sprites and sprites/tiles using P2? Thank you for your time
  8. I tried it, but couldn't get it working. Luckily, it turned out to be pretty easy to handle the rotation "manually". Here's the gist of it: var planet = shipEntity.misc.landedOnPlanet; var rot = planet.position.rotation - shipEntity.misc.startRotation; shipEntity.position.rotation = rot - Math.PI / 2; shipEntity.position.x = planet.position.x - Math.cos(rot) * planet.sprite.radius * 1.2; shipEntity.position.y = planet.position.y - Math.sin(rot) * planet.sprite.radius * 1.2;where shipEntity.misc.startRotation = entity.position.rotation - Math.atan2(planet.position.y - shipEntity.position.y, planet.position.x - shipEntity.position.x);Here's another laggy video: http://recordit.co/I8QzIw
  9. I need my space ship to follow the rotation of the planet it lands on. See example below: My current approach is as follows: ship.position.x = planet.x;ship.position.y = planet.y;ship.pivot.set(planet.width);ship.rotation = planet.rotation;However, this results in the ship getting an incorrect position and rotation. See this (quite laggy) example. Ideally, I would like to be able to write: ship.pivot.set(planet.position); // rotate around this global positionship.rotation = planet.rotation;Any ideas?
  10. I believe you can also use text.anchor.set(0.5, 0.5);Which sets the anchor of the text sprite to be at the center of the sprite (i.e. 50% width, 50% height).
  11. I simply use a filter-function on my list of entities, like this: MotionSystem = { tick: function(entities, deltaTime) { entities.filter(function(e) { return e.position && e.motion; }).forEach(function(entity) { entity.position.x += entity.motion.dx * deltaTime; entity.position.y += entity.motion.dy * deltaTime; entity.position.rotation += entity.motion.drotation * deltaTime; }); }};I am not concerned about performance as of yet - if that becomes an issue at a later point then I'll handle it then
  12. One approach is to use one of the following color-libraries to create a color object, tween the values of that object, and pull out the corresponding color value when rendering: https://github.com/bgrins/TinyColor https://github.com/mbjordan/Colors https://github.com/harthur/color https://github.com/gka/chroma.js
  13. Rescue Rush Rescue as many patients as possible! Drag ambulances to pick up patients and bring them to a hospital before their time runs out. Works best with touch on a tablet device. Made with Phaser. • Link to game • 1 Game A Month profile page