well it worked until yesterday on all the levels then i was stupid and updated to the latest version of 3dgs and it screwed my doors in level 3 and 4 same script and same levels no change other that i compiled them with the new version..

here is the code.

// door open close action //

var clockwise = 1; // the door will rotate clockwise, set it to 0 if you need a conter-clockwise rotation



SOUND* dooropens_wav = "door1_sfx.wav";



action my_door()

{

var init_pan;

init_pan = my.pan;

while (!player) {wait (1);} // make sure to add the "player = my;" line of code to your player action

while (1)

{

// this section opens the door

while (vec_dist (player.x, my.x) > 250) {wait (1);} // play with 100

snd_play (dooropens_wav, 100, 0);

if (clockwise) // the door is supposed to rotate clockwise?

{

while (my.pan > init_pan - 90)

{

c_rotate (me, vector(-4 * time_step, 0, 0), IGNORE_FLAG2);

wait (1);

}

}

else // default = rotate counter-clockwise

{

while (my.pan < init_pan + 90)

{

c_rotate (me, vector(4 * time_step, 0, 0), IGNORE_FLAG2);

wait (1);

}

}

// this section closes the door

while (vec_dist (player.x, my.x) < 400) {wait (1);} // wait until the player moves away, play with 300

snd_play (dooropens_wav, 100, 0);

if (clockwise) // the door is supposed to rotate clockwise?

{

while (my.pan < init_pan)

{

c_rotate (me, vector(4 * time_step, 0, 0), IGNORE_FLAG2);

wait (1);

}

}

else // default = rotate counter-clockwise

{

while (my.pan > init_pan)

{

c_rotate (me, vector(-4 * time_step, 0, 0), IGNORE_FLAG2);
wait (1);

}

}

wait (1);

}

}


Lets finish this mother¤%"#%& of.