Quote (}0RIC)-()
перебирал весь пул авто?
Да.
Quote (}0RIC)-()
ну и так вопрос чутка, компонент по названию ищешь или по положению?
По названию. У меня есть небольшой набор опкодов для работы с компонентами
Code
{$CLEO}
0000:
while true
wait 0
{$I forallcars}
if
0D0D: 2@ = get_car veh component "hub_lf" // IF and SET
then
if
0D0D: 3@ = get_car veh component "wheel_lf_dummy" // IF and SET
then
3@ += 0x10
0D04: 7@ = matrix 3@ z_angle
0D06: get_matrix 3@ position_to 8@ 9@ 10@
2@ += 0x10
7@ -= 90.0
0D15: set_matrix 2@ z_angle 7@
0D05: set_matrix 2@ position 8@ 9@ 10@
end
end
if
0D0D: 2@ = get_car veh component "hub_rf" // IF and SET
then
if
0D0D: 3@ = get_car veh component "wheel_rf_dummy" // IF and SET
then
3@ += 0x10
0D04: 7@ = matrix 3@ z_angle
0D06: get_matrix 3@ position_to 8@ 9@ 10@
2@ += 0x10
7@ += 90.0
0D15: set_matrix 2@ z_angle 7@
0D05: set_matrix 2@ position 8@ 9@ 10@
end
end
if
0D0D: 2@ = get_car veh component "hub_lb" // IF and SET
then
if
0D0D: 3@ = get_car veh component "wheel_lb_dummy" // IF and SET
then
3@ += 0x10
0D04: 7@ = matrix 3@ z_angle
0D06: get_matrix 3@ position_to 8@ 9@ 10@
2@ += 0x10
7@ -= 90.0
0D15: set_matrix 2@ z_angle 7@
0D05: set_matrix 2@ position 8@ 9@ 10@
end
end
if
0D0D: 2@ = get_car veh component "hub_rb" // IF and SET
then
if
0D0D: 3@ = get_car veh component "wheel_rb_dummy" // IF and SET
then
3@ += 0x10
0D04: 7@ = matrix 3@ z_angle
0D06: get_matrix 3@ position_to 8@ 9@ 10@
2@ += 0x10
7@ += 90.0
0D15: set_matrix 2@ z_angle 7@
0D05: set_matrix 2@ position 8@ 9@ 10@
end
end
{$I forallcars_end}
end