pinoygamegeek

Members
  • Content count

    83
  • Joined

  • Last visited

About pinoygamegeek

  • Rank
    Advanced Member

Contact Methods

  • Website URL
    https://www.dolarfun.com

Profile Information

  • Gender
    Not Telling
  • Location
    Philippines

Recent Profile Visitors

566 profile views
  1. Zip file working on cocoon launcher but not after compiling

    Thanks to both of you. Used the Winrar program. I found some errors when I used the dev app.
  2. Hi I have a zip file that I tested on cocoon dev launcher and is working fine but not after compiling on the cloud. Any ideas thanks
  3. P2 physics Physics body overlap to another when dragged

    Works great. Thanks @samid737. Also I have found a solution that when the mouse pointer hits the map, will remove the mouse constraint.
  4. Hi, I need help to resolve the overlapping of 2 physics object. So I have this ant that I want to drag then it must not overlap with the map(maze) here's the example: http://s3-ap-southeast-2.amazonaws.com/demos.wingaru.com.au/au.com.wingaru.honeyant_WK/index-dist.html#!/#%2F Edit* as you can see the ant can overlap with the map. Try to use keyboard arrows and it will not. Only when the ant is dragged. 'use strict'; Game.GameArea = { player: null, maps: null, mouseBody:null, mouseConstraint: null, create: function () { this.game.physics.startSystem(Phaser.Physics.P2JS); var level1 = [ ['layer6', 0, 0, 0], ['layer7', 393, 0, 0], ['layer8', 361, 239, 0], ['layer4', 0, 296, 0], ['layer3', 134, 242, 0], ['layer2', 296, 110, 0], ]; var antCollisionGroup = this.game.physics.p2.createCollisionGroup(); var mapCollisionGroup = this.game.physics.p2.createCollisionGroup(); this.game.physics.p2.updateBoundsCollisionGroup(); this.maps = []; for (var i = level1.length - 1; i >= 0; i--) { var xpos = level1[i][1]; var ypos = level1[i][2] var map = this.game.add.sprite(xpos, ypos, level1[i][0]); this.game.physics.p2.enable(map); map.body.x += map.width / 2; map.body.y += map.height / 2; map.body.kinematic = true; //map is static map.body.clearShapes(); //Remove standard Bounding Box map.body.loadPolygon('collisions', level1[i][0]); this.maps.push(map); } //, , /*Adding ant*/ var antInfo = { xPos: 117, yPos: 163, rotation: 119.9998779296875 } this.player = new ant(this.game, antInfo.xPos, antInfo.yPos, antInfo.rotation); for(var m = 0; m < this.maps.length; m++){ var map = this.maps[m]; //set collision group map.body.setCollisionGroup(mapCollisionGroup); //set collision map.body.collides([mapCollisionGroup, antCollisionGroup]); } this.player.ant.body.setCollisionGroup(antCollisionGroup); this.player.ant.body.collides([antCollisionGroup, mapCollisionGroup]); //ENABLE DRAG this.mouseBody = new p2.Body(); this.game.physics.p2.world.addBody(this.mouseBody); this.game.input.onDown.add(this.click, this); this.game.input.onUp.add(this.release, this); this.game.input.addMoveCallback(this.move, this); }, update: function () { this.player.update(); }, click: function (pointer) { var bodies = this.game.physics.p2.hitTest(pointer.position, [this.player.ant.body]); // p2 uses different coordinate system, so convert the pointer position to p2's coordinate system var physicsPos = [this.game.physics.p2.pxmi(pointer.position.x), this.game.physics.p2.pxmi(pointer.position.y)]; if (bodies.length) { var clickedBody = bodies[0]; var localPointInBody = [0, 0]; // this function takes physicsPos and coverts it to the body's local coordinate system clickedBody.toLocalFrame(localPointInBody, physicsPos); // use a revoluteContraint to attach mouseBody to the clicked body this.mouseConstraint = this.game.physics.p2.createRevoluteConstraint(this.mouseBody, [0, 0], clickedBody, [this.game.physics.p2.mpxi(localPointInBody[0]), this.game.physics.p2.mpxi(localPointInBody[1])]); } }, release: function () { this.game.physics.p2.removeConstraint(this.mouseConstraint); }, move: function (pointer) { // p2 uses different coordinate system, so convert the pointer position to p2's coordinate system this.mouseBody.position[0] = this.game.physics.p2.pxmi(pointer.position.x); this.mouseBody.position[1] = this.game.physics.p2.pxmi(pointer.position.y); } //game.physics.p2.world.solver.iterations };
  5. How to make bitmap drawing to get smooth

    bump
  6. How to make bitmap drawing to get smooth

    Up please help
  7. How to make bitmap drawing to get smooth

    Hi this is my demo for bitmap drawing. But my problem is it is pixelated. Please help me to get it smooth. Sample image below. thanks in advance.
  8. Inspiring for a single person. Good luck!
  9. Tiled map type error Phaser 2.0 migrating to Phaser 2.4.9

    Sorry needs up up for client. Thanks! I just back with Phaser 2 years ago
  10. I don't understand why I get this error TypeError: Failed to execute 'drawImage' on 'CanvasRenderingContext2D I attached the json file of my map. Below is my script map = this.game.add.tilemap('map'); layer = map.createLayer('Maze Pattern'); //Background Maze map.createLayer('background'); map.addTilesetImage('background', 'background'); //sign map.createFromObjects('Object Layer 1', 488, 'sydney', 0, true, false); map.createFromObjects('Object Layer 1', 487, 'orange', 0, true, false); //visible map for pattern only map1 = this.game.add.tilemap('map'); map1.addTilesetImage('roadFinal', 'roadFinal', 32, 32); layer1 = map1.createLayer('Maze Level 1'); And below is my preload this.game.load.tilemap('map', ASSETS_IMAGE_URL+'maze/level1.json', null, Phaser.Tilemap.TILED_JSON); Thanks in advance. I don't have an error in Phaser 2.0 level1.json
  11. Hi Rich,

    Greetings.

    I'd like to ask for your help with finding a sponsor for the game linked below. I believe you have so many clients like bbc, so maybe you could help me with this game. This game was made 2 years ago.

    https://arwin.itch.io/math-tracks

    Thanks.

    Regards,

    Arwin

  12. equivalent of sprite.body.setsize for text

    I want to set the bounding box of text. Thanks!
  13. Down scaling sprites and smoothing

    Hello, So we have this memory game, we are having problems about the smoothness of the images and the text that comes with it when we scaled down on higher levels (more columns and rows). So the more rows and columns the more we scaled down the sprite and they suffered on smoothing and anti aliasing so much. Any help would be appreciated. Thanks in advance.
  14. [Phaser] Christmas Parkour - Available for non exclusives

    thanks for the feed @pheaset!
  15. Christmas Parkour is available for non-exclusives. Pm or shoot me a mail arwinmargallo@gmail.com thanks!