Jump to content

Jack McCoy

Members
  • Posts

    381
  • Joined

  • Last visited

1 Follower

Personal Information

  • Flight Simulators
    DCS World, IL-2 BoX
  • Location
    Montreal, Canada

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. I think function dump (name, value, saved, result) should be function dump (name, value, seen, result)
  2. To display force component vectors in MT version, see solution:
  3. @Flappie For the vectors to display, this is required: Saved Games\DCS\Config\autoexec.cfg : drawDebugGeometry = true
  4. Hi Flappie. The issue is not related to any mission and I wouldn't know how to enable via lua script (if even possible!). This is related to development of my External Flight Model (EFM), in file ED_FM_Template.cpp. The thread you found mentions the vectors not being displayed even when: //ED_FM_Template.cpp bool ed_fm_enable_debug_info() { return showVectors; /* When set to true, DCS draws lines on the aircraft. The blue box is the center of mass, green line is net force vector, pink line is the velocity vector. */ } This worked in single-thread and doesn't work in multi-thread. I think the following is a related issue: //ED_FM_Template.cpp size_t ed_fm_debug_watch(int level, char *buffer, size_t maxlen) { return sprintf_s(buffer, maxlen, "ENGINE RPM %f.0", engine.rpm); } In multi-thread, it does not display "ENGINE RPM NNNN" in the "extended" screen, i.e. pressing RCtrl-Pause twice. Am I looking in the right place? I never tried in single-thread.
  5. It was "documented" that the force and moment components display only worked in the single-threaded version. Now that there is only a multithread version, are there any plans of making this feature work?
  6. @IronMike Mods\aircraft\F-4E\Sounds\sdef\Jester\Contacts (F-4E with a dash)
  7. I started with the Eagle Dynamics API a few years back, not your project. My statement was more general but since this is the only topic in the English forums to discuss ed_fm_enable_debug_info(), I just wanted to share a clue for when things don't work as expected.
  8. Technically, the API is in C. But since we use a C++ compiler, we can write our extensions using classes and stuff but it is not mandatory.
  9. If any of your ed_fm_* functions are not called, make sure they are decared in ED_FM_Template.h. They weren't in my version which caused me a lot of frustration (i.e. modding fun!). ED_FM_TEMPLATE_API void ed_fm_on_damage(int Element, double element_integrity_factor); ED_FM_TEMPLATE_API bool ed_fm_enable_debug_info(); This ensures the functions are visible to be called by DCS.
  10. DCS-MT version 2.9.4.53627 . This issue probably affects propellers with any number of blades but is most noticeable with 2-blade propellers. Steps to reproduce: - Start DCS MT in VR - Look at a running Yak-52 (2-blade model) from the front, outside - Pause the simulator - Close one eye, then the other, and notice the propeller in the two views are 90 degrees out of phase. This is very confusing for the brain, simulation paused or running... For my mod, I currently specify 4 blades as workaround. The phase issue is still there but at least both eyes see the same image. MyAircraft.lua engine = { prop_locations = {{2.11219, -0.702867, 0.00}, {0, 0, math.rad(-4.7)}}, -- forward..back, down..up, left..right, rotation roll, yaw, pitch prop_blades_count = 4,
  11. Thanks, @Copprhead! I had a regression about that with the 2.9 update but I couldn't figure it out. It's not easy having to write the API and Breaking Changes document ourselves! I now learned to keep my eye on the evolution of wHumanCustomPhysicsAPI.h. Just to be clear, the propeller in the EDM must respond to argument 407 but it should not be set in the EFM. MyEFM.cpp void ed_fm_simulate(double dt) { propellerAngle += engine_rpm * rpm2radps * dt; propellerAngle = fmod(propellerAngle, twoPI); ===== void ed_fm_set_draw_args(EdDrawArgument * drawargs, size_t size) { // drawargs[407] = (float)propellerAngle_0_1; // don't do this drawargs[413] = (float)0; // [0..1] propeller pitch ===== double ed_fm_get_param(unsigned index) { if (index < ED_FM_ENGINE_2_RPM) { switch (index) { case ED_FM_ENGINE_1_RPM: return engine_rpm; case ED_FM_ENGINE_1_RELATED_RPM: // 0..1 return engine_rpm_0_1; case ED_FM_ENGINE_1_CORE_RPM: // 0..RPMmax Engine and prop sound return engine_rpm * engine_running; case ED_FM_ENGINE_1_CORE_RELATED_RPM: // 0..1 displayed as RPM% in 2D F2 view return engine_rpm_0_1; case ED_FM_ENGINE_1_FAN_PHASE: // 0..2*pi return propellerAngle; } } =====
  12. Thanks, @prccowboy! Somehow I no longer had engine.prop_* fields! This fixes a lot of things! <duh> MyAircraft.lua engine = { prop_locations = {{2.11219, -0.702867, 0.00}, {0.0, 0.0, math.rad(-2.112)}}, -- forward..back, down..up, left..right, spin axis orientation: roll, yaw, pitch prop_blades_count = 2, prop_direction = 1, -- clockwise as viewed from cockpit -- prop_pitch_*: specify even for fixed-pitch propeller or else AI will show thicker (pitched) blades as viewed with the prop disk edge-on (i.e. from the side) prop_pitch_min = 0.0, -- prop pitch min, degrees prop_pitch_max = 10.0, -- prop pitch max, degrees prop_pitch_feather = 80.0, -- prop pitch feather position, degrees if feather < prop_pitch_max no feathering available } prop_blade.FBX Exported a textured single blade at scale 0.01, same orientation as the aircraft model. Textures\MyAircraft\description.lua and/or Liveries\MyAircraft\*\description.lua {"Material_propeller", DIFFUSE, "prop.dds", true}; {"Material_propeller", ROUGHNESS_METALLIC, "prop_roughMet.dds", true}; -- optional With the above changes, the AI now works perfectly in all regimes. Now the problem is with the player aircraft: - The propeller hub spins and stops correctly, in direct relation with argument 407. - The DCS-generated propeller blur disk changes the blurred blades' visual aspect but does not spin. - When engine is off, the propeller's rest position is alternating at every simulation frame between the EDM's rest position and whatever constant value I supply for argument 407. In other words, it flickers... - I still have no idea what I should do, if anything, with argument 370. I tried engine_rpm, engine_rpm_0_1, 0, 1...
  13. Congrats! To communicate with the ground crew, I think the canopy needs to be open (and recognized as such by DCS) OR you need to set up an intercom device. From what I've seen, radios and intercom are related as "linked devices" which, to me, is yet another layer deeper in the black box... Bonne chance!
  14. Related to DCS changelog: "New to DCS 2.9.4.53549: Added over-pressure shockwave influence from bombs, missiles, shells and gunfire on terrain vegetation like trees, bushes, and grass." From my observations, both variables ED_FM_ENGINE_1_FLOW_SPEED and ED_FM_FLOW_VELOCITY have to be set for the effect to manifest itself. Units are meters/second.
×
×
  • Create New...