SimpleShooter Mega Challenge Tutorial

In this topic, I will show a tutorial on how to fulfill parts of the Mega Challenge of the UE4 SimpleShooter game that you would need to do after finshing the course.

— Switching Weapons —

Open UE4 editor.
Make new weapons by duplicating BP_Rifle. Do not “Create Child Blueprint Class” of BP_Rifle.
Change the name, mesh Max Range and Damage of each Blueprint Weapon.

Create inputs for allowing the mouse scroll wheel to switch weapons.

Switch to Visual Studio Code.
Add to ShooterCharacter.h these highlighed code in the respective places:

Add to ShooterCharacter.cpp these highlighed code in the respective places:

Switch back to UE4 editor.
Click “Compile”.
Open BP_ShooterCharacter, click “full blueprint editor”.

  • Go to Class Defaults. In the Details Panel you can click on “Gun Class” to expand it because it is an array. Change the options to the weapon Blueprints (e.g. “BP_Rifle”. I have renamed mine to “BP_Weapons_Rifle” and etc.).

Hit Compile and Save and play the game!

2 Likes

Wow incredible job with the mega challenge. Thank you for take the time to explain everything and showcase your work :pray:t3::clap:

1 Like

Thank you mate
This was very helpful :slight_smile:

Privacy & Terms