the-kid Posted September 26, 2016 Share Posted September 26, 2016 I'm having trouble getting the hitbox and sprite for to appear next to the character. I have tried adding this as a child and as a group. The hitbox will not stick to the player character. Link to comment Share on other sites More sharing options...
PhasedEvolution Posted September 26, 2016 Share Posted September 26, 2016 @the-kid please post some of your code Link to comment Share on other sites More sharing options...
the-kid Posted September 28, 2016 Author Share Posted September 28, 2016 Player.prototype.createMeleeWeapon = function () { var weapon = game.add.weapon(30, 'weapon'); weapon.trackSprite(this); weapon.bulletKillType = Phaser.Weapon.KILL_DISTANCE; weapon.bulletKillDistance = 200; weapon.bullets.attackDamage = this.stats.attackDamage; weapon.fireRate = 1000; return weapon; } Here is the code that I have right now. Link to comment Share on other sites More sharing options...
Recommended Posts