Sunday 8 June 2014

Prototype - SteerGun

Weapon spec:
  • You are able to steer the projectile,
  • Game is slowing down,
  • Radius damage (which will be implemented when I will have enemies)
I will use assets from WB Art.
WB Art have great weapons you should check it out!

Implementation will be simple. As earlier you will need to: add socket to HeroFPP, add MuzzleFlash socket to the weapon, add another weapon to WeaponTypes ENUM, add the weapon to ChangeWeapon function. You definitely should know now how to do that.

1. Copy MyProjectile (it was Reaper projectile - our first weapon) and name it B-Reaper_Projectile,
2. Move to components,
3. Add audio component and use  this sound: GrenadeLauncher_ProjectileLoop_Cue
4. Add spring arm and set Target Arm lenght to 25, disable Do Collision Test,
5. Add camera and assign it to  Spring Arm,
6 For trail use this: P_Launcher_proj,
7. For projectile set: initial speed: 100, maximum speed: 200, Velocity X: 1,
8. Components should look like this:
9. Now move into Graph,
10. Create Tick function for allowing player to steer the projectile:
11. For EventHit try to create something like this:
For SpawnProjectile I use: P_Explosion_Bomb and for Play Sound: P_Explosion_Bomb.

That's all here, compile and open MyCharacter.

1. Create new bool variable BR_WaitingForFire,
2. Add this to CurrentWeapon Swtich (chose your new weapon ofc)
For MuzzleFlash I've used this: P_Launcher_MF and for sound: GrenadeLauncher_Shot_Cue

And that's all! You can now shoot and steer your projectile! I won't be implementing damage dealing here because we need enemies to check out which will be the best way to use that weapon. 

This is how it looks:
In next post we will be adding last weapon! Simple pistol that will be primary weapon in the game.

No comments:

Post a Comment