So nun habe ich den folgenden Code in meinen Hauptlevelscript geschrieben. Doch es passiert nichts wenn ich die "t" drücke.


/////////////////////////////////////////////////////////////////
//Minimap
/////////////////////////////////////////////////////////////////

view top_view
{
layer = 15;
pos_x = 0;
pos_y = 0;
size_x = 200;
size_y = 150;
tilt = -90;
arc = 80;
}

starter init_topcam()
{
while (player == null) {wait (1);}
while (1)
{
if (key_t == 1)
{
while (key_t == 1) {wait (1);}
if (top_view.visible == on)
{
top_view.visible = off;
}
else
{
top_view.visible = on;
}
}
top_view.x = player.x;
top_view.y = player.y;
top_view.z = 1000; // play with this value
wait (1);
}
}


Woran könnte der fehler liegen??

-------------------------------------------------------
Now I´ver wrote the code into the mainlevel sed file. But it doesn´t work when I press the Button "t".

Here is the code:

/////////////////////////////////////////////////////////////////
//Minimap
/////////////////////////////////////////////////////////////////

view top_view
{
layer = 15;
pos_x = 0;
pos_y = 0;
size_x = 200;
size_y = 150;
tilt = -90;
arc = 80;
}

starter init_topcam()
{
while (player == null) {wait (1);}
while (1)
{
if (key_t == 1)
{
while (key_t == 1) {wait (1);}
if (top_view.visible == on)
{
top_view.visible = off;
}
else
{
top_view.visible = on;
}
}
top_view.x = player.x;
top_view.y = player.y;
top_view.z = 1000; // play with this value
wait (1);
}
}


Where can be the mistake?