You need to use the word function to define a function.
You also forgot a semi-colon somewhere, and didn't include an argument for Parent.
Also, this may not be very necessary but you should use %client.mode == 1 rather than %client.mode $= "1".
function serverCmdtoggleStarMode(%client) {
if(%client.smode == 0){
%client.smode = 1;
messageAll('', '\c3Star Gun is in \c0Destroy Mode');
} else {
%client.smode = 0;
messageAll('', '\c3Star Gun is in \c0Normal Mode');
}
}
function starGunProjectile::onCollision(%this, %obj, %col, %fade, %pos, %normal) {
if(%col.getClassName() $= "fxDTSBrick" && %obj.client.smode == 1)
%col.killBrick();
else
Parent::onCollision(%this, %obj, %col, %fade, %pos, %normal);
}
function starGunImage::onMount(%this, %obj) {
Parent::onMount(%this, %obj);
%client = %obj.client;
if(!%client.isAdmin || !%client.isSuperAdmin)
%client.player.unMountImage("starGunImage");
}
function serverCmdstarGun(%client) {
if(%client.isAdmin || %client.isSuperAdmin) {
%client.player.mountImage("starGunImage", 0);
%client.player.playThread(0, armreadyright);
}
}