First I want to say that I'm not a pro coder or a 1337 h4x0r. I learned most of these thing while modding the game. So the terms that I use and the way I do thing are mostly what I call them and how I do these things. If you know better and/or you want to correct my mistakes, feel free to send me an e-mail.
   
  BASIC TRAINING
   
  Lets start of at the basics. The SoF2 is build around the .pk3 files. These files are in the BASE folder in your SoF2 main directory. Each of these files are basicly ziped files that can be opened with most packing softwares. I prefer the WinRAR, since it keeps the file structure intact. Also making a .pk3 file is just as easy. Just pack up your files and convert the zip into a .pk3 file. That's it.    
  So Lets take a practise run on basic modding. Open the THEREST.PK3 file with the WinRAR. Search the folders for the EXT_DATA folder and open it. Search for the SOF2.WPN file and extract it. Make sure that WinRAR also extraxts the pathnames, so that the file ends up in the right directory. Now open the SOF2.WPN file.
PLEASE NOTE, that if your SoF2 is updated, you should look for the updated files from the UPDATE101, UPDATE102 and UPDATE103 files. But if the file you search is not in the, look it from the older .pk3 files.
 
  The SOF2.WPN file is a compiling file, where all the data for the weapons is compiled to make the weapon work. For MP modding this file is the mostly all that you need to edit. For SP your work has just starting. Open the SOF2.WPN file with your windows notepad. If everuthing is OK, the file should contain lots of text.
Lets take the M3A1 for some editing:
   
 
weapon
{
Start of a weapon.
	name		"M3A1"
	displayName	"WEAPONS_NAME_M3A1"
	model		"models/weapons/m3a1/world/m3a1world.glm"
	safe		true
	rank		0.3
	cvar		wp_m3a1
	category	4		// sub-machine gun
	menuImage	"hud/weapon_icons/m3a1_icon"

	mp_animRaise		"TORSO_RAISE"
	mp_animDrop		"TORSO_DROP"
	mp_animIdle		"TORSO_IDLE_RIFLE"
	mp_animReload		"TORSO_RELOAD_RIFLE"
General informatio section of the weapon.
	attack
	{
		ammoType		"0.45 ACP"
		clipSize		"30"
		damage			"65"
		armorPiercing		"0.25"
		muzzleFlash		"effects/muzzle_flashes/mflash_m3"
		muzzleSmoke		"effects/muzzle_flashes/smoke_m4"
		3rdPersonMuzzleFlash	"effects/muzzle_flashes/mflash_m3_inworld"
		ShellCasingEject	"effects/shell_brass"
		TracerEffect		"effects/tracerTest2"
		EjectBone		"ejection_m3a1"
		inaccuracy		".1"
		maxInaccuracy		"1"
		range			8192
		volume			0.75
		kickAngles		"1 3 -2 1"

		mp_damage		"50"
		mp_inaccuracy		".35"
		mp_maxinaccuracy	"1.5"
		mp_animFire		"TORSO_ATTACK_RIFLE"
		mp_extraClips		"3"
Primary attack section.
		fireModes
		{
			mode1		auto
		}
Firemode section. Only primary fire can have more than 1 firemode.
	}
End of primary fire section.
} End of the weapon.
  Now that you look at the text, it should be quite easy to know what does what.

NAME: this corresponds to the name in the SOF2.INVIEW file. Don't touch this yet.

DISPLAYNAME: Now this is the weapons name as you see in in the screen. Or actualy there's a file that has the name and all that WEAPON_NAME_ stuff refers to it. But you can just type the name to it, since it shouldn't cause any trouble.

MODEL: The world model for the weapon. The one you see on the ground and in enemies hands.

SAFE: For the weapon switch code. So if you have the weapon switching set to safe, and the weapon is not safe (safe = false), the game won't automaticly switch to it.

RANK: Higher the rank, better the weapon in the weapon switch code.

CVAR: Variable of the weapon. WP_ for weapon, AM_ for ammo and so on. Helps the game to know whick thing is which. All weapon and ammo should have its own CVAR. if you have the same on two weapons, you get them both when you pick up one of the weapons.

CATEGORY: What slot does the gun go. 1=knife, 2=pistol, 3=shotgun, 4=smg, 5=assault rifle, 6=sniper rifle, 7=heavy weapon, 8=grenade.

MENUIMAGE: The image that appears in the weapon menu in game.

MP_ANIM: 3rd person animations in multiplayer.

ATTACK: Primary fire. The section under this is the primary fire of the weapon.

AMMOTYPE: What ammo does the gun use for primary fire. Ammo types can be found in the SOF2.AMMO file.

CLIPSIZE: How much ammo does the gun have in it's magazine.

DAMAGE: How much damage does a shot cause. It the weapon shoots pellets (shotgun), it's damage per pellet.

PELLETS: How many pellets does the gun fire per shot. Use SPREAD with this.

SPREAD: How much does the pellets spread during their flight.

ARMORPIERCING: How much damage goes through an armor vest. 0.0 for 0% 1.0 for 100%.

MUZZLEFLASH: Muzzle flash for the gun in 1st person view.

MUZZLESMOKE: Muzzle smoke for the gun in 1st person view.

3RDPERSONMUZZLEFLASH: Muzzle flash for the gun in 3rd person view.

SHELLCASINGEJECT: The type of shell thrown out of the gun.

TRACEREFFECT: Tracer effect for bullets. Only for NPC's weapons and Multiplayer.

INACCURACY: How much does the gun get thrown off target per shot. Higher the number, faster the gun starts shooting off target.

MAXINACCURACY: How much can the weapon shoot off target.

RANGE: How far does the bullet fly. Doesn't aply if you have a projectile (like a grenade) on the attack.

VOLUME: How loud is the gun. Doesn't affect the audio effect, just how far can an NPC hear the gun. 0.0 for no sound, 1.0 so that every one can hear it.

KICKANGLES: What direction does the gun kick. All I know is that in "x y -z q" 'y' is for up.

MP_xxxxx: Same but for MP.

FIREMODES: Under this is all the firemodes for the weapon. These are AUTO, SINGLE and BURST.

 
     
  Now lets do some changes. Switch the ammo type to 9mm. Do this changing the line ammotype "0.45 ACP" to ammotype "9mm". Add two new lines pellets 10 and spread 0.05 between damage and muzzleflash. Now the text should look like this:  
 
weapon
{
name		"M3A1"
displayName	"WEAPONS_NAME_M3A1"
model		"models/weapons/m3a1/world/m3a1world.glm"
safe 		true
rank 		0.3
cvar 		wp_m3a1
category	4 // sub-machine gun
menuImage	"hud/weapon_icons/m3a1_icon"

	mp_animRaise	"TORSO_RAISE"
	mp_animDrop	"TORSO_DROP"
	mp_animIdle	"TORSO_IDLE_RIFLE"
	mp_animReload	"TORSO_RELOAD_RIFLE"

	attack
	{
		ammoType		"9mm"
		clipSize		"30"
		damage			"55"
		pellets			10
		spread			0.05
		muzzleFlash		"effects/muzzle_flashes/mflash_mp5"
	     	muzzleSmoke		"effects/muzzle_flashes/smoke_m60"
		3rdPersonMuzzleFlash	"effects/muzzle_flashes/mflash_mp5_inworld"
		ShellCasingEject	"effects/shell_brass_45acp"
		TracerEffect		"effects/tracerTest2"
		EjectBone		"ejection_m3a1"
		inaccuracy		".1"
		maxInaccuracy		"1"
		range			5000
		volume			0.70
		kickAngles		"1 1 -1 1"

		mp_damage		"50"
		mp_inaccuracy		".35"
		mp_maxinaccuracy	"1.5"
		mp_animFire		"TORSO_ATTACK_RIFLE"
		mp_extraClips		"3"

		fireModes
		{
			mode1		auto
		}
	}
}
 
  Save the file and exit. Now pack (by winzip or other packing software) the EXT_DATA folder that has the file you just edited. Now all you got to do is to rename the .zip file into a .pk3 file and place it into the BASE folder in your SoF2 main directory. There are different ways to rename the file. I use the MS-DOS Prompt in windows. Just go to the directory that has the .zip file and type rename xxxx.zip xxxx.pk3. That's it.
     
     
     
     
     

.