Create a folder called n00dProjectilesExample
Create a child of BPC_N00dProjectiles, call it BPC_Projectiles, and move it into n00dProjectilesExample folder
Add the third person feature pack
Open BP_ThirdPersonCharacter and add BPC_Projectiles
If you want to use the in-built character effect system for projectiles, fill out the details under the Character category, otherwise uncheck UseInbuiltCharacterEffects. Also set the Team to 0
Select the CapsuleComponent and change its collision to custom, and to ignore PhysicsBody
On the Event Graph of the character, create this script on AnyDamage (projectiles use Unreal's inbuilt damage system). Create a RepNotify float variable for Health and a RepNotify variable for Death. The delegate is used for embedded actor destruction and death effects. Set the default Health to 100
Add a widget component (optional) and define the WidgetClass in its Class Defaults, Screen Space, and the DrawSize
Position it where you want it. This will display our team and the player health
Create this script UpdateWidget on the Event Graph. It will set the health on the widget and the Team (display)
On BeginPlay, create this script
In OnRepHealth, call UpdateWidget
Open ThirdPersonMap and drag in BP_N00dProjectilesTurretAutoSphere into the map. Move it closer to the back wall
In the details panel of the turret instance in the world, set the Enabled and Disabled Yaw to 180 under the Turret category
Under the Shooter category, set the ProjectileClasses (index [0]) to BP_N00dProjectilesBullet and the Proxy radius to 800
The turret is shooting us and the projectile is giving us damage!