[FIXED] Possible ScenEdit_AddExplosion Problem (Full Version)

All Forums >> [New Releases from Matrix Games] >> Command: Modern Operations series >> Tech Support



Message


stilesw -> [FIXED] Possible ScenEdit_AddExplosion Problem (11/22/2018 4:34:00 PM)

Found this while working on a scenario:

Created a medium size generic building as a target with coordinates: latitude='39.2037648957788', longitude='-97.9353296783759' and elevation 1447 ft.

Attacked it with a F-15E using Mk84 2000lb (dbid=1839, warhead id=299) works fine, target is destroyed.

However, using the same Mk84 with ScenEdit_AddExplosion({warheadid=299, Latitude='39.2037648957788, lon=-97.9353296783759, altitude=1450}) shows an explosion but does no damage to the target.

Using a B57 20kT bomb with ScenEdit_AddExplosion({warheadid=458, Latitude='39.2037648957788, lon=-97.9353296783759, altitude=1450}) shows the explosion and does destroy the target.

I tried this with several other warheads and all the nuclear ones worked but none of the conventional weapons.

The attached test scenario uses CMANO v1.14 Build 998.15 and DB3K_476.db3.

The detonations are activated manually via “Game > Special Actions”.

I have successfully used ScenEdit_AddExplosion in the past so either something has changed or I’ve done something wrong.

Test scenario is attached and thanks for checking.

-Wayne Stiles




stilesw -> RE: Possible ScenEdit_AddExplosion Problem (11/22/2018 4:39:05 PM)

Crap! Never mind, I figured it out. The altitude needs to be in meters and I had it in feet. So, 1447 ft is approximately 441 meters. Conventional weapons work fine if the correct altitude measurement is used.

Sorry for the bother.

-Wayne Stiles




michaelm75au -> RE: Possible ScenEdit_AddExplosion Problem (11/23/2018 12:42:21 AM)

Not at code at the moment, but ..
Default unit of measure is M, but I think you can use the 'FT' suffix for 'altitude'
eg ScenEdit_AddExplosion({warheadid=299, Latitude='39.2037648957788, lon=-97.9353296783759, altitude='1450 ft'})




stilesw -> RE: Possible ScenEdit_AddExplosion Problem (11/23/2018 2:36:33 PM)

Thanks. I did find that meters worked and easily converted feet to meters and everything worked fine.

I tried using the command you suggested: ScenEdit_AddExplosion({warheadid=299, Latitude=39.2037648957788, lon=-97.9353296783759, altitude='1450 ft'}) in the Lua console but got the message: ERROR: Input string was not in a correct format..

Then tried using it with altitude='1450ft' and got ERROR: [string "Console"]:1: malformed number near '1450f'.


No problem converting feet to meters and using that, but it seems that it does not convert using '1450 ft'. Could be doing something wrong with this option though.

-Wayne




michaelm75au -> RE: Possible ScenEdit_AddExplosion Problem (11/24/2018 4:52:52 AM)

I'll check it out; I thought it would handle it.
I converted several functions to use a common validation method to get some consistency across repeatable Lua entry/values.
--
Looks like this function wasn't updated to handle FT or M. I'll add it to my list.




Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
1.375