Grimm Posted December 22, 2021 Posted December 22, 2021 (edited) Hi guys, I've forked wheelyjoe's Splash Damage script and added some features you might find interesting: -Adds a blast wave effect which adds timed and scaled secondary explosions on top of game objects -Object geometry within blast wave changes damage intensity -Additional damage boost for structures since they are hard to kill, even if very close to large explosions. -Damage model for ground units that will disable their weapons and ability to move with partial damage before they are killed. INSTALLATION: Load at mission start in mission editor using Trigger> 4 Mission Start > Do Script File (script file) Please let me know what you think! If a weapon is missing from the script, it will display a message to let you know. If you can get the name of the weapon to me (or your DCS.log file), I can get it added in. https://github.com/spencershepard/DCS-Scripts/blob/master/Splash_Damage_2_0.lua Edited December 18, 2022 by Grimm 9 12 Splash Damage 2.0: Make explosions better! RotorOps: Helicopter Mission Generator
Swampy Posted December 24, 2021 Posted December 24, 2021 Hello and thank you for the script. I am trying it out for my missions and I was wondering if there is anyway to stop it from displaying the messages? I have tried changing the following line to false: ["game_messages"] = false, --enable some messages on screen, however it is still displaying the messages. Thanks in advance
Grimm Posted December 25, 2021 Author Posted December 25, 2021 @Swampy Thanks for trying the script! Would you be able to send me your DCS.log file? It should only be showing messages about missing weapons with game_messages set to false, and I'd really like it to be complete. However I added the option to disable those messages in the latest update. Download the file again from the first post and set ["weapon_missing_message"] = false Splash Damage 2.0: Make explosions better! RotorOps: Helicopter Mission Generator
Swampy Posted December 26, 2021 Posted December 26, 2021 @Grimm I Downloaded the file again and it doesn't appear to be showing the messages. Thanks again Swampy
HC_Official Posted December 27, 2021 Posted December 27, 2021 AT_6 missing from Splash Damage script noticed this in the dcs.log 1 No more pre-orders Click here for tutorials for using Virpil Hardware and Software Click here for Virpil Flight equipment dimensions and pictures. .
Magnum Posted December 27, 2021 Posted December 27, 2021 (edited) I found this script interesting and have been working on adding weapons to the table for WW2 aircraft. Its also a bit spammy for flak in the dcs.log because it's tracking the shot event. I'm not quite sure what the value is for each variable(maybe a damage modifier?) but here is what i've added so far to the table; ["British_GP_250LB_Bomb_Mk1"] = 100, --("250 lb GP Mk.I") ["British_GP_250LB_Bomb_Mk4"] = 100, --("250 lb GP Mk.IV") ["British_GP_250LB_Bomb_Mk5"] = 100, --("250 lb GP Mk.V") ["British_GP_500LB_Bomb_Mk1"] = 213, --("500 lb GP Mk.I") ["British_GP_500LB_Bomb_Mk4"] = 213, --("500 lb GP Mk.IV") ["British_GP_500LB_Bomb_Mk4_Short"] = 213, --("500 lb GP Short tail") ["British_GP_500LB_Bomb_Mk5"] = 213, --("500 lb GP Mk.V") ["British_MC_250LB_Bomb_Mk1"] = 100, --("250 lb MC Mk.I") ["British_MC_250LB_Bomb_Mk2"] = 100, --("250 lb MC Mk.II") ["British_MC_500LB_Bomb_Mk1_Short"] = 213, --("500 lb MC Short tail") ["British_MC_500LB_Bomb_Mk2"] = 213, --("500 lb MC Mk.II") ["British_SAP_250LB_Bomb_Mk5"] = 100, --("250 lb S.A.P.") ["British_SAP_500LB_Bomb_Mk5"] = 213, --("500 lb S.A.P.") ["British_AP_25LBNo1_3INCHNo1"] = 4, --("RP-3 25lb AP Mk.I") ["British_HE_60LBSAPNo2_3INCHNo1"] = 4, --("RP-3 60lb SAP No2 Mk.I") ["British_HE_60LBFNo1_3INCHNo1"] = 4, --("RP-3 60lb F No1 Mk.I") ["WGr21"] = 4, --("Werfer-Granate 21 - 21 cm UnGd air-to-air rocket") ["3xM8_ROCKETS_IN_TUBES"] = 4, --("4.5 inch M8 UnGd Rocket") ["AN_M30A1"] = 45, --("AN-M30A1 - 100lb GP Bomb LD") ["AN_M57"] = 100, --("AN-M57 - 250lb GP Bomb LD") ["AN_M65"] = 400, --("AN-M65 - 1000lb GP Bomb LD") ["AN_M66"] = 800, --("AN-M66 - 2000lb GP Bomb LD") ["SC_50"] = 20, --("SC 50 - 50kg GP Bomb LD") ["ER_4_SC50"] = 20, --("4 x SC 50 - 50kg GP Bomb LD") ["SC_250_T1_L2"] = 100, --("SC 250 Type 1 L2 - 250kg GP Bomb LD") ["SC_501_SC250"] = 100, --("SC 250 Type 3 J - 250kg GP Bomb LD") ["Schloss500XIIC1_SC_250_T3_J"] = 100, --("SC 250 Type 3 J - 250kg GP Bomb LD") ["SC_501_SC500"] = 213, --("SC 500 J - 500kg GP Bomb LD") ["SC_500_L2"] = 213, --("SC 500 L2 - 500kg GP Bomb LD") ["SD_250_Stg"] = 100, --("SD 250 Stg - 250kg GP Bomb LD") ["SD_500_A"] = 213, --("SD 500 A - 500kg GP Bomb LD") ["AB_250_2_SD_2"] = 100, --("AB 250-2 - 144 x SD-2, 250kg CBU with HE submunitions") ["AB_250_2_SD_10A"] = 100, --("AB 250-2 - 17 x SD-10A, 250kg CBU with 10kg Frag/HE submunitions") ["AB_500_1_SD_10A"] = 213, --("AB 500-1 - 34 x SD-10A, 500kg CBU with 10kg Frag/HE submunitions") --["LTF_5B"] = 100, --("LTF 5b Aerial Torpedo") These seem to be flak and vehicles and it may be helpful to exclude these from the tracked events... weapons.shells.37x263_HE weapons.shells.37x263_AP weapons.shells.Bofors_40mm_HE weapons.shells.QF94_AA_HE weapons.shells.M1_37mm_HE-T weapons.shells.M1_37mm_37AP-T weapons.shells.Mk_20_HE_shell Edited December 27, 2021 by Magnum 2
HawaiianRyan Posted December 27, 2021 Posted December 27, 2021 (edited) 2 hours ago, Magnum said: I'm not quite sure what the value is for each variable(maybe a damage modifier?) Should be the equivalent explosion power in kilograms of TNT (maybe RDX?) per detonation event. I think there is some uncertainty about what explosive, exactly, is used to specify this number, in part because it seems like the definition of 1 unit seems a bit off (based on people trying to reverse engineer the effects in the game engine, and the possibility that the devs are adjusting the definition slightly). Edited December 27, 2021 by HawaiianRyan
Wheelyjoe Posted December 27, 2021 Posted December 27, 2021 Hey, nice work mate. I originally had the secondary explosions on units as well, but I thought it looked a bit janky, and the existing system for explosions is okay, the values used are just terrible. I did some rudimentary testing and compared to "real world" numbers (I used to study at the UK's blast injury research centre), and it was close enough for something running as a script IMO. I'd much rather it be fixed by ED than me I also used to have it "suppress" units when they were caught within a certain radius, but as disabling AI and weapons is only doable on a per group level it can make a unit quite some distance away "stunned" and it felt a little cheesy. Totally okay with you adding these features back, just thought I'd note what I'd done and discounted and why. That and performance, trying to eek every single frame out of DCS, haha! Enjoy the script, check out the IADS one too if you're into a bit more realism! Needs an update for new launchers, but it's still a fun addition to a server and really easy to use! https://github.com/wheelyjoe/DCS-Scripts - Wheelyjoe 2
HC_Official Posted December 29, 2021 Posted December 29, 2021 (edited) @Grimm is this correct? it looks the wrong way round (inverted?) ["weapon_missing_message"] = false, --false disables messages alerting you to weapons missing from the explTable if splash_damage_options.weapon_missing_message == false then trigger.action.outText(ordnance:getTypeName().." missing from Splash Damage script", 10) end Edited December 29, 2021 by HC_Official No more pre-orders Click here for tutorials for using Virpil Hardware and Software Click here for Virpil Flight equipment dimensions and pictures. .
Admiral_ZIPANGU Posted December 30, 2021 Posted December 30, 2021 (edited) @Grimm Thanks for the fascinating script! I am trying this script too. I wanted to hide the message, so I set the options as follows. Quote ["game_messages"] = false ["weapon_missing_message"] = false However, even with this setting, the weapon_missing_message did not disappear. So I looked at the part about displaying the weapon_missing_message, and found this on line 239. Quote if splash_damage_options.weapon_missing_message == false then When I set this part to true, the weapon_missing_message is displayed or not displayed as per the option setting. I hope you will check it out. Edited December 30, 2021 by Admiral_ZIPANGU As a Japanese, English is difficult for me. Phantom Forever F-4EJ / F-4EJ Kai 1971-2021 Sorry, I don't speak English, so I use DeepL Translate. Well, I can speak Japanese.
Grimm Posted December 31, 2021 Author Posted December 31, 2021 @Magnum This is huge! Thank you! All ready to copy and paste and everything! I've added these to the script, and implemented a filter for anything that has "weapons.shells" @Wheelyjoe Thanks for the comments, helpful info, and the clever scripting!!! All, attached is latest dev version of the script with the changes above and the "weapon_missing_message" issue fixed. Splash_Damage_2_0.lua 3 Splash Damage 2.0: Make explosions better! RotorOps: Helicopter Mission Generator
JeffreyC Posted January 1, 2022 Posted January 1, 2022 Love your splash damage! Thank you so much for making this!! 1
IAF.AssafB Posted January 7, 2022 Posted January 7, 2022 Hello and thanks for sharing! I wonder if this script can be used to include artillery shells as well. What I have in mind is to be able to use artillery for suppression of SAM sites if hitting anywhere around them (Not even causing actual damage but to mimic SAM crews being shocked and unable to function for a minute or two....stuff like that). Specifically looking at 155mm arty (PALADIN and MSTA) as well as 120mm mortar rounds. With scripting knowledge which is next to nil I'd sure appreciate your experts' opinions Thanks !
Andartu Posted January 12, 2022 Posted January 12, 2022 On 12/31/2021 at 9:21 PM, Grimm said: I've added these to the script, and implemented a filter for anything that has "weapons.shells" Hmm in this version? I have that and still get the text showing up.
Grimm Posted January 12, 2022 Author Posted January 12, 2022 9 hours ago, Andartu said: Hmm in this version? I have that and still get the text showing up. Yes the file attached should be the most recent. It is the develop branch if you are pulling it from the repo. Also make sure you remove the script and re-add to your mission when updating. Let me know if it's still an issue. Splash Damage 2.0: Make explosions better! RotorOps: Helicopter Mission Generator
Andartu Posted January 13, 2022 Posted January 13, 2022 17 hours ago, Grimm said: Yes the file attached should be the most recent. It is the develop branch if you are pulling it from the repo. Also make sure you remove the script and re-add to your mission when updating. Let me know if it's still an issue. Was my bad, did not re-added the script, just change the file in its location. Now it works, no more text. Thank you!
Toumal Posted January 15, 2022 Posted January 15, 2022 Heya! I love your script, but unfortunately I found that it interferes with MOOSE scoring. Ground target hits are no longer detected by MOOSE (latest stable version). Is this a known issue or did I just miss a step?
Grimm Posted January 15, 2022 Author Posted January 15, 2022 10 hours ago, Toumal said: Heya! I love your script, but unfortunately I found that it interferes with MOOSE scoring. Ground target hits are no longer detected by MOOSE (latest stable version). Is this a known issue or did I just miss a step? Thanks for bringing this up...it's the first I've heard of it. If you could...would you mind sending me your DCS.log? Splash Damage 2.0: Make explosions better! RotorOps: Helicopter Mission Generator
Chump Posted January 18, 2022 Posted January 18, 2022 CBU_97 missing from Splash Damage script AGR_20A missing from Splash Damage script AGR_20_M282 missing from Splash Damage script AGM_65D missing from Splash Damage script GBU_54_V_1B missing from Splash Damage script
Toumal Posted January 27, 2022 Posted January 27, 2022 On 1/15/2022 at 10:32 PM, Grimm said: Thanks for bringing this up...it's the first I've heard of it. If you could...would you mind sending me your DCS.log? Argh, I don't think I have that log anymore. But I did scour through it and saw no error or other related message really. I think what happens is that MOOSE hooks into the events, and then you hook into the events, and apparently events handlers work via the highlander-principle. But I could be wrong!
Mistermann Posted January 28, 2022 Posted January 28, 2022 (edited) Very cool. I am reminded of the video footage from the latest Apache update. That splash damage from the 30mm chain gun is on full display. Edited January 28, 2022 by Mistermann System Specs: Spoiler Processor:13th Gen Intel(R) Core(TM) i9-13900K - RAM: 64GB - Video Card: NVIDIA RTX 4090 - Display: Pimax 8kx VR Headset - Accessories: VKB Gunfighter III MCG Ultimate, VKB STECS Standard, Thrustmaster TPR Pedals, Simshaker JetPad, Predator HOTAS Mounts, 3D Printed Flight Button Box Video Capture Software: Open Broadcaster Software (OBS), Video Editing Software: PowerDirector 365 Thrustmaster TWCS Mod
Toumal Posted January 29, 2022 Posted January 29, 2022 (edited) On 1/15/2022 at 10:32 PM, Grimm said: Thanks for bringing this up...it's the first I've heard of it. If you could...would you mind sending me your DCS.log? Got some logs for you! Unfortunately, there's not much to see: https://pastebin.com/casfvtuj For this test, I load up the Splash Damage script before MOOSE. However, that doesn't change a thing. The units I attacked are inside a zone, and are spawned as follows: function CaucasusPendulum.SpawnCaptureZoneUnits (zoneName, coalitionParam) local SpawnZones = { ZONE:FindByName( zoneName .. " ZONE" )} local coalitionName = "BLUE" if (coalitionParam == coalition.side.RED) then coalitionName = "RED" end local SpawnGroup env.info("GROUP SPAWN: "..coalitionName.." "..zoneName) SpawnGroup = SPAWN :New(coalitionName .. " " .. zoneName .. " GROUP") :InitKeepUnitNames( true ) :InitLimit(20,0) SpawnGroup:Spawn() end So really nothing special. The zone has MOOSE scoring set up as follows: Score = SCORING:New( "Caucasus Pendulum" ) Score:SetScaleDestroyScore( 100 ) Score:SetScaleDestroyPenalty( 200 ) Score:SetMessage<profanity>( false ) Score:SetMessagesDestroy( true ) Score:SetMessagesToAll( true ) Score:AddZoneScore(AlphaZone, 50) The result is that neither the scoring messages, nor any actual score updates seem to work once SplashDamage is loaded together with MOOSE. EDIT: Here's how MOOSE hooks in: self:HandleEvent( EVENTS.Dead, self._EventOnDeadOrCrash ) self:HandleEvent( EVENTS.Crash, self._EventOnDeadOrCrash ) self:HandleEvent( EVENTS.Hit, self._EventOnHit ) It seems like these don't work anymore once SplashDamage is loaded. Maybe the event has to be passed on by you so other handlers can receive it as well? EDIT: I tried replacing the pcall with a direct call in the splashdamage event handler: function WpnHandler:onEvent(event) -- protectedCall(onWpnEvent, event) onWpnEvent(event) end However that changed nothing - splash damage works fine still, but no MOOSE scoring events. EDIT2: Also tried disabling wave_explosions, same result. Edited February 12, 2022 by Toumal
Kervinou Posted February 9, 2022 Posted February 9, 2022 Big thanks for your work. We R lot of virtual pilot to use and appreciate it 1 System specs: Win10 x64 | i7-9700KF / i9-12900KF | 48/64 GB | GTX 1080 Ti 11 GB / RTX 3090TI 24GB | *NvME PRO 2To | HOTAS Warthog/Virpil | MFG Crosswind Pedals | Button Box
Toumal Posted February 12, 2022 Posted February 12, 2022 (edited) I've been thinking about the MOOSE scoring problem and I *think* I might have an idea why it happens: What if it's not really about the event handling hooks at all? What if the problem is actually the way nearby units are being damaged by the script? After all, you're spawning an explosion for units in the blast radius like so: trigger.action.explosion I believe this may be why MOOSE cannot pick this up and determine who did it. Sooooooooo I think what I'll do is make a function that lets me pass on the player to the MOOSE damage code. I don't really need the player unit or the weapon for scoring. EDIT: Confirmed that this is indeed the root cause of the issue. Working on a fix, but I have one problem that I posted another thread for. Edited February 12, 2022 by Toumal
Recommended Posts