phaserjs / phaser-ce

Phaser CE is a fun, free and fast 2D game framework for making HTML5 games for desktop and mobile web browsers, supporting Canvas and WebGL rendering.
http://phaser.io
MIT License
1.34k stars 491 forks source link

Weapon plugin documentation: bulletDistance versus bulletKillDistance #601

Closed JamesSkemp closed 5 years ago

JamesSkemp commented 5 years ago

This Issue is about an error in the documentation.

Phaser.Weapons.KILL_DISTANCE states:

A bulletKillType constant that automatically kills the bullets after they exceed the bulletDistance from their original firing position.

However, based upon testing it appears that this, and bulletKillType, should instead reference bulletKillDistance, based upon its documentation and test usage.

weapon.bulletKillType = Phaser.Weapon.KILL_DISTANCE;
weapon.bulletKillDistance = 50;

Is that correct?

Thanks!