servercmdcontrolplayer(%cl)
{
%cam = %cl.camera;
%client.setcontrolobject(%cam);
%cam.setcontrolobject(%client.player);
}
hmm?
It requires checking that the client is admin, that the player and camera exists, that the player isn't dead and that the client is controlling the camera.
If all those things didn't matter I would just have written the following:
function serverCmdControlPlayer( %cl )
{
%cl.camera.setControlObject( %cl.player );
}