Basics

A detailed guide on how to setup the firearm using its wizard.

Start by creating a first person controller as mentioned here.

Firearm Wizard

The FPS Framework includes a Firearm Wizard that simplifies the setup process. To access it, right-click anywhere in the hierarchy, then navigate to Akila > FPS Framework > Firearm. This will open the Firearm Wizard window.

The firearm wizard

How To Use?

Each section represents exactly what its title indicates. Below are the full details:

Basic

Name
Description

Name

The name of your firearm. This will be used as the preset name, the GameObject name, and the display name. You can change it later if needed.

Preset

The selected preset from the default firearm options. For example, choosing "Assault Rifle" will apply all the default settings for that weapon type. The same applies to all other preset options.

You can customize the presets by editing them under FPS Framework > Data > Preset.

Assginables

Name
Description

Replacement

The object that will be spawned when the item is dropped.

Firearm HUD

The FirearmHUD prefab that displays all relevant firearm information.

Crosshair

The crosshair assigned to your firearm type.

Advanced

Name
Description

Shooting Mechanisim

Defines how projectiles are fired. Hitscan uses a Raycast for instant impact, while Projectile spawns a physical projectile.

Shooting Direction

The origin point from which projectiles are fired.

Firerate

The rate at which projectiles or hitscan shots are fired.

Muzzle Velocity

The velocity at which physical projectiles travel.

Range

The maximum range where hits can damage items.

Audio & FX

See Audio System to understand this section.

Name
Description

Fire Sound

The fire audio profile to be played when gun is fired.

Reload Sound

The reload audio profile to be played during reloading.

Auto Generate

If enabled, the AudioClips below will be activated. Upon firearm creation, the corresponding Audio Profiles will be generated and assigned.

Fire Audio Clip

The fire audio clip to be used in the generated audio profile.

Reload Audio Clip

The reload audio clip to be used in the generated audio profile.

Utilizes

Name
Description

Generate Prefab

Generates a prefab of the created firearm. This is useful for later use as a pickable item. For more information, refer to the Pickable section.

After clicking the "Create" button, the Save Scriptable Object window will appear. Select a save path and click "Save." The firearm will now be successfully created.

Last updated

Was this helpful?