Modifying a weapon system
Roblox has provided us with a large library of items and tools that we can use and modify. One of the provided items that we will be examining in this recipe is weapons, specifically guns. We will examine how to best configure the various weapon IntValues (store integers), such as ammo capacity and hit damage. To finish, we will work to modify the audio and visual appearance of the weapon.
How to do it…
We will begin by inserting a weapon into the StarterPack object, and then move the WeaponsSystem script into the ServerScriptService object. Next, we will open the Configuration
folder and modify various parameters such as AmmoCapacity and HitDamage. Next, we will apply a new texture onto the gun model; then we will change the SoundID property value, followed by changing the ColorSequence and Width values of the muzzle flash particle effect. To begin, follow these steps:
- To begin, download the Weapons Kit model for Auto Rifles from Creator...