I guess that this can be only made using a mod , on Ply's mod , Project Blue\Green , That's your script :
:state=0,haveweap=1:plrspeed=< Your Value , Default is 100 >,state=1
:state=1,haveweap=0:plrspeed=100,state=0
On Fenix mod , The player will be slower only if he uses his weapon , The script will be that way :
:state=0,usingweapon=< Your Weapon Path >:playerspeed=< Your Value >
:state=0,notusingweapon=< Your Weapon Path >:playerspeed=100
Example for Weapon path : ww2\colt45
As for Vanilla FPSC , I don't think you can do it .
Cheers
"I am the night visitor when everyone is sleep , and when the last light fades"
The illusionest