blade2xs

Members
  • Content Count

    12
  • Joined

  • Last visited

About blade2xs

  • Rank
    Member

Recent Profile Visitors

435 profile views
  1. OK Update Matter physics seems to allow for more complex and advanced physics bodies and constructs while Arcade is just meant for simple physics where as Impact is specific if you are using ImpactJS
  2. It has to be attached to a physics body to see the bounds of the box, otherwise you have to write your own graphics outline of a scene.add.image, which is not connected to a physics body... unless there is a higher level debug flag in the config I dont know about :)
  3. The docs and samples have not caught up yet with Phaser 3. There is a great amount on Phaser 2 but for now we are frontiersmen on this one and this is where this forum comes in handy
  4. Hey guys, I am using Phaser 3.8.0 I was looking at this as an example https://labs.phaser.io/view.html?src=src\input\mouse\text input test.js and it appears to be working on Phaser 3.8.0 on the sample but when I use the code below in my scene's "create" method, I can see the event in my console logs and if I change the code to "setColor('red')" the text properly turns red... just curious what I am doing wrong here or missing with setting the tint of the font? encounterSceneContext.menuAttack = this.add.text(55, 210, "Attack", { fontSize: '10px', fill: '#ffffff' }); encounterSceneContext.menuRun = this.add.text(55, 225, "Escape", { fontSize: '10px', fill: '#ffffff' }); encounterSceneContext.menuAttack.setInteractive( new Phaser.Geom.Rectangle(0, 0, encounterSceneContext.menuAttack.width, encounterSceneContext.menuAttack.height), Phaser.Geom.Rectangle.Contains); encounterSceneContext.menuRun.setInteractive( new Phaser.Geom.Rectangle(0, 0, encounterSceneContext.menuRun.width, encounterSceneContext.menuRun.height), Phaser.Geom.Rectangle.Contains); this.input.on('gameobjectover', function (pointer, gameObject) { console.log("gameobjectover"); gameObject.setTint(0xff0000, 0xff0000, 0xffff00, 0xff00ff); }); this.input.on('gameobjectout', function (pointer, gameObject) { console.log("gameobjectout"); gameObject.clearTint(); });
  5. Ok I solved it in a kind of hacky way... not super please but it works... I'll note it in a TODO in my code when I post it to github. Basically I follow the advice here and had to set up all monster animations possible for the scene, then just before restarting the Encounter scene, I have to manually call a function to change the sprite animation and had to save the context of the encounter scene globally otherwise all the "this" references break... I'm not super happy with it but I have a deadline to meet and it works. A nice to have would be some documentation on the best practice for switching between scenes like this.
  6. Thanks guys, This partially worked. I ran a series of tests and, apparently, when the the scene preload and create methods get re-run, it is the culprit with increasing the animation speeds. I say partially worked with the resume because I am stuck with the first creature I randomly created for the initial scene call... I am working on a way to run a method in the scene to reinitialize the animations for the new creature.
  7. I was curious if this was an expensive way to do it here: https://labs.phaser.io/view.html?src=src\game objects\tilemap\dynamic\swap tiles.js https://labs.phaser.io/view.html?src=src\game objects\tilemap\dynamic\replace tiles.js https://labs.phaser.io/view.html?src=src\game objects\tile sprite\Example 2.js You could perform the animation in the update event for the scene? Or maybe treat them as a regular sprites? That could be expensive though
  8. I have an old school RPG I am making and I have two main scenes, the Overworld and Encounter scenens. The overworld is fine when switching to it but the problem is the Encounter, before I switch to it, I reset it so I can recreate it from scratch with a random monster in it. The problem is, every time I switch/restart the Encounter scene, the animation of the creature gets progressively faster. I do remove the animation key so I dont get the warning when I switch back to the Overworld scene. Just curious if I am taking the right approach to this and if so, do I need to clean up the sprite of the monster before hand so it doesn't make the animation speed up?
  9. Ha ha! Awesome! I was one level off for that Thanks a ton @samme!!!
  10. blade2xs

    Social Auth

    I'm using Okta for my Users Identity store and Aocial Auth provider developer.okta.com You can take a peek at the sign on widget I am using along with OIDC to keep a user session. I am planning to post my code up in git hub once I get further along... the game is on c9.io so it may go down every now and then but you are welcome to test with it. https://okta-python-game-recinto.c9users.io/
  11. Hey everyone, I looked around for details on this but I am trying to determine the difference between the Physic types: Arcade, Impact, Matter to see what would be best for my type of game or to experiment with. I read in the Dev blogs that "Arcade" was meant for very simple physics in a game, while somewhere else I read that "Matter" was meant for debugging... I would like to know what the real differences are and which would make the most sense for a given game type. Does anyone know what the differences between the Physic types are? Thanks!!!
  12. Hey guys, I have searched all over to figure this our but no luck. How do I enable the debug to show the bounding/collision boxes on sprites in Phaser 3? this was pretty easy to do in Phaser 2 but I dont see any docs on how to do this for 3. Thanks!!!