Jump to content


  • Content Count

  • Joined

  • Last visited

About blackhawx

  • Rank
    Advanced Member

Profile Information

  • Interests
    Game Development

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. In the following example for labs... https://labs.phaser.io/edit.html?src=src/game objects\tilemap\collision\non-slope map and impact.js Was the csv file and all of its values manually created? or was there a tool that exported the file? Thanks!
  2. My goal within this preloading sequence is to place a Phaser graphic onto stage that increases in height as the progress gets to 100%, and at the same time, set a mask so that a background image is revealed as the the graphic height increases. I feel i'm halfway there. I'll play with that timer event to see if that helps to keep my preload up long enough before I transition to the rest of the game. Many thanks
  3. I managed to get it working on my end, but with a slightly different structure. I'm using multiple scenes, not just one, as the demo above entails. But in either case, here is whats working for me... class preloadScene extends Phaser.Scene { constructor() { super({ key: 'preLoadScene', active: true, physics: { default: 'arcade', arcade: { debug: true } }, pack: { files: [ { type: 'ima
  4. Within a scene preload function, if I have the following logic setup preload() { ... this.load.on('complete', function () { progress.destroy(); }); ... } ...Is there a way we can set a delay (3 seconds), before progress is actually destroyed? Setting `this.time.addEvent()` does not appear to work within a preload() instance.
  5. Perhaps an alternative would be to chain multiple tween sequences together with the ability of changing up the target value? (untested). In the given example, the same target is given the entire time, but perhaps it is possible... http://labs.phaser.io/edit.html?src=src/tweens\timelines\simple timeline 1.js http://labs.phaser.io/edit.html?src=src/tweens\timelines\simple timeline 7.js http://labs.phaser.io/edit.html?src=src/tweens\timelines\create timeline.js http://labs.phaser.io/edit.html?src=src/tweens\callbacks.js | an oncomplete process for a tween You could put it
  6. Yes, that's exactly what I was looking for. It's because of setCollisionByProperty. that I'm driven to now work with Tiled. Thanks for the suggestion on that!
  7. I'm giving Tiled a shot sense it appears to be a strong map driven application. Thanks!
  8. so to understand you correctly, you want to wait until an input event it triggered, (i.e. a user presses down on their mouse, then wait x number of seconds before tween begins) correct? If that was the case, this request is still easy to implement. If you look at this following example in labs: http://labs.phaser.io/edit.html?src=src/tweens\update to.js and after the paused:true, property, simply add delay:1000 and run the code. The tween won't run until the input is triggered and the delay is met.
  9. I'm looking at the following example in the labs to learn about tile collisions: http://labs.phaser.io/edit.html?src=src/game objects\tilemap\static\set colliding by property.js Based on the example, I would like to set collision properties within a JSON file, rather than depending on setting custom indexes in my game js file. Being new to this, I am attempting to use Texturepacker to create tilemaps. What would be a recommend approach in setting collision properties on tiles? (.i.e.) Do I have to edit the JSON file manually to manually put in a collision property? Is
  10. You are missing the native way to handle delays with tweens in Phaser 3. The following is a simpler and native approach to take: var config = { type: Phaser.WEBGL, width: 800, height: 600, backgroundColor: '#2d2d2d', parent: 'phaser-example', scene: { preload: preload, create: create, update: update } }; var tween; var game = new Phaser.Game(config); function preload () { this.load.image('block', 'delay/media/block.png'); } function create () { var image = this.add.image(100, 300, 'block'); tween = this.tweens.add({ targets: image, x:
  11. @kurhlaa the tween class has delay capabilities you can tap into. I would give a look over the API to see how you can naturally leverage Phaser to do related tasks. https://photonstorm.github.io/phaser3-docs/Phaser.Tweens.html https://photonstorm.github.io/phaser3-docs/Phaser.Tweens.Timeline.html And don't forget searching on Phaser labs for examples (e.g. http://labs.phaser.io/view.html?src=src/tweens\delay.js)
  12. James, if it's not too much to ask and if it works, could you demonstrate how you would use setData in one of your ''anime' scenarios? I'm curious to how we can take advantage of it relating to the topic...
  13. Your description in the process was all I needed to know. Makes perfect sense. Thanks for breaking that logic down!
  14. Hello nkholski. I love what you are doing with collisions in the game. when Mario is small and he jumps up to hit a brick, what part of the code makes the tile bump up and come back down again? Thanks
  • Create New...