You're lucky, I've a little free time today.

Here is the code :
Code:
var speed = 5; // play with 5
var worldCentre;
function main()
{
level_load("yourLevel.wmb");
wait(2);
vec_set(worldCentre,vector(0,0,0));
mouse_mode = 1;
while(1)
{
mouse_pos.x = pointer.x;
mouse_pos.y = pointer.y;
vec_to_angle(camera.pan,vec_diff(temp,worldCentre,camera.x));
// zoom in/out
camera.arc += mickey.z * speed * time_step;
camera.arc = clamp(camera.arc,10,100);
// pan left/right
if (mouse_right)
{
vec_rotate(camera.x,vector(mouse_force.x * speed,0,0));
vec_add(camera.x,worldCentre);
}
// Orbit? don't know how do you achieve this,
// so this part maybe not exactly what you want.
// The camera will orbit around the world center vertically.
if (mouse_middle)
{
vec_rotate(camera.x,vector(0,speed * time_step,0));
vec_add(camera.x,worldCentre);
}
wait(1);
}
}
Hope this helps!