0 votes
asked by (16 points)

Hallo,

I am using the 11.31 version. I am trying to load new plane into the Plane 1 using the ACPR command.

First, I have a problem with the ACFN struct. In the UDP comunication documentation

<!--[if gte mso 9]> <![endif]--><!--[if gte mso 9]> Normal 0 21 false false false CS X-NONE X-NONE <![endif]--><!--[if gte mso 9]> <![endif]--><!--[if gte mso 10]>

<![endif]-->

struct acfn_struct

{

         xint              acfn_p                                   ;

         xchr            acfn_path_rel[150]     ;

         xint              livery_index                 ;

};

If I add up bytes as writen int32+150*char+int32=158. But when I tried to set up the struct this way, xPlane had a problem. Error messege told me that it was expecting 160 bytes instead of 158. So I added to hard nulls. First was after the path and second after the infill 'spaces' (to fill up the 150 chars). But this does not work properly. The new plane loads into the sim, but I experience lags. When I enter the Flight configuration menu I can see the newly loaded plane. When I click resume (with no change) everything returns to normal.

Log file messege:

RECV label=ACFN from IP=---------------49001, length after packaging removal=160
Private-message parse, RECV label=ACFN, len=160
Public-message parse, RECV label=ACFN, len=160
Receiving and applying input label=ACFN
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/../L5_Sentinel_cockpit.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/prop.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/fuse.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/wings.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/inn_1.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/inn_2.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/seat.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/panel.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/airspeed/airspeed.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/altimeter/altimeter_ag.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/compass/compass_mag.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/engine_RPM/engine_RPM_ag.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/turn_slip/turn_slip_ga.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/variometer/variometer_ag.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/cht_oilt_oilp_amps/cht_oilt_oilp_amps.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/com_bking/com_bking.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/transponder_bking/transponder_bking.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/instruments/xPad/xPad_arm.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/pilot/pilot.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/glass_inn.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/glass_out.obj
Will try to read the OBJ, path=Aircraft/Laminar Research/Stinson L5/objects/../L5_Sentinel_cockpit.obj
We already have that object! Index=000001E1C8E5FDA0, so we will use that index rather than re-loading the object.

This messege repeats several times.

When I try to combine it with the PREL struct into the ACPR X-Plane crashes.

Can anybody tell me what should i change?

Please log in or register to answer this question.

Welcome to X-Plane Q&A, where you can ask support questions and get answers from members of the community.

This site is for X-Plane support questions only. Please search for existing answers before posting your question. Off-topic questions will be locked.

If you’re new, you’ll need to register before asking your first question.

If your question is answered, click on the check mark to select the best response.

Categories

...