{"action":"created","issue":{"url":"https://api.github.com/repos/photonstorm/phaser/issues/2693","repository_url":"https://api.github.com/repos/photonstorm/phaser","labels_url":"https://api.github.com/repos/photonstorm/phaser/issues/2693/labels{/name}","comments_url":"https://api.github.com/repos/photonstorm/phaser/issues/2693/comments","events_url":"https://api.github.com/repos/photonstorm/phaser/issues/2693/events","html_url":"https://github.com/photonstorm/phaser/issues/2693","id":171551747,"number":2693,"title":"Phaser.Weapon's fire method not returning anything","user":{"login":"JTronLabs","id":7429786,"avatar_url":"https://avatars.githubusercontent.com/u/7429786?v=3","gravatar_id":"","url":"https://api.github.com/users/JTronLabs","html_url":"https://github.com/JTronLabs","followers_url":"https://api.github.com/users/JTronLabs/followers","following_url":"https://api.github.com/users/JTronLabs/following{/other_user}","gists_url":"https://api.github.com/users/JTronLabs/gists{/gist_id}","starred_url":"https://api.github.com/users/JTronLabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JTronLabs/subscriptions","organizations_url":"https://api.github.com/users/JTronLabs/orgs","repos_url":"https://api.github.com/users/JTronLabs/repos","events_url":"https://api.github.com/users/JTronLabs/events{/privacy}","received_events_url":"https://api.github.com/users/JTronLabs/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":12,"created_at":"2016-08-17T00:58:40Z","updated_at":"2016-08-18T12:47:00Z","closed_at":"2016-08-17T23:30:16Z","body":"Currently, Phaser.Weapon's fire method does not return any value (look for Phaser.Weapon.prototype.fire in the [weapons file](https://github.com/photonstorm/phaser/blob/master/src/plugins/weapon/WeaponPlugin.js)). The [documentation](http://phaser.io/docs/2.6.1/Phaser.Weapon.html#fire) says it should return false if a bullet was not found and the pool cannot be extended. It does not say what is returned if the bullet is found, presumably it is true?\r\n\r\nI propose that instead of returning true/false, the method returns the fired bullet or null. This change will not break current code in the format `if(bullet)...` However, it will provide the new functionality of potentially manipulating the bullet after it has been fired (like setting tint). Currently, if you want to do this you would have to set all the bullets to the same tint, [have texture for each tint](http://phaser.io/examples/v2/weapon/bullet-frame-cycle), or try to dive into the guts of the engine and manually manipulate variables.  "},"comment":{"url":"https://api.github.com/repos/photonstorm/phaser/issues/comments/240712185","html_url":"https://github.com/photonstorm/phaser/issues/2693#issuecomment-240712185","issue_url":"https://api.github.com/repos/photonstorm/phaser/issues/2693","id":240712185,"user":{"login":"JTronLabs","id":7429786,"avatar_url":"https://avatars.githubusercontent.com/u/7429786?v=3","gravatar_id":"","url":"https://api.github.com/users/JTronLabs","html_url":"https://github.com/JTronLabs","followers_url":"https://api.github.com/users/JTronLabs/followers","following_url":"https://api.github.com/users/JTronLabs/following{/other_user}","gists_url":"https://api.github.com/users/JTronLabs/gists{/gist_id}","starred_url":"https://api.github.com/users/JTronLabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JTronLabs/subscriptions","organizations_url":"https://api.github.com/users/JTronLabs/orgs","repos_url":"https://api.github.com/users/JTronLabs/repos","events_url":"https://api.github.com/users/JTronLabs/events{/privacy}","received_events_url":"https://api.github.com/users/JTronLabs/received_events","type":"User","site_admin":false},"created_at":"2016-08-18T12:47:00Z","updated_at":"2016-08-18T12:47:00Z","body":"Thanks rich. The pr should be good to go then. Just FYI, i updated the typescript defs for 2.7.0 but not 2.6.1. I assumed since its already released we wouldnt want to change it. Is that right? If not i can update the PR. I appreciate you letting me make the changes so i can learn how to do it!"}}
{"actor":{"display_login":"JTronLabs"}}