habinabi
Active member
hi, i needed to write a speed limit of 17 and in order to turn it on and off, I put a show text in there to let me write when the limit is on, but I don't know why, it always crashes right after I start the game
PHP:
{$CLEO .cs}
//-------------MAIN---------------
0001: wait 2000 ms
0006: 0@ = 0
if
0AB0: key_pressed 103
then
if
0039: 0@ == 1
then
0ACD: show_text_highpriority "~B~Speed limit ~R~OFF" time 1337
0006: 0@ = 0
else
0006: 0@ = 1
end
end
if and
0039: 0@ == 1
0449: actor $PLAYER_ACTOR in_a_car
then
0ACD: show_text_highpriority "~B~Speed limit ~G~ON" time 5
03C0: 1@ = actor $PLAYER_ACTOR car
00AD: set_car 1@ max_speed_to 17.0
end