Yup, this is my personal favorite, usualy about 6-8 tank round going off will make a nice explosion. And this is for a destroyed unit, correct? Here, make the following into a .sqs file, and put it in your mission folder. And put in the unit(s) that you want this to run on, in the initiation field,
this exec "thisscript.sqs";
@((getdammage _this) = 1)
_temp0 = "shell125" createvehicle getpos _this
_temp1 = "heat125" createvehicle getpos _this
_temp2 = "shell125" createvehicle getpos _this
_temp3 = "heat125" createvehicle getpos _this
_temp4 = "shell125" createvehicle getpos _this
_temp5 = "heat125" createvehicle getpos _this
exit
And if you want to make the vehicle fly, this explosion here really makes it go buh-bye.
@((getdammage _this) = 1)
_temp0 = "shell125" createvehicle getpos _this
_temp1 = "heat125" createvehicle getpos _this
~0.2
_temp2 = "shell125" createvehicle getpos _this
_temp3 = "heat125" createvehicle getpos _this
_temp4 = "shell125" createvehicle getpos _this
_temp5 = "heat125" createvehicle getpos _this
~0.2
_temp6 = "shell125" createvehicle getpos _this
_temp7 = "heat125" createvehicle getpos _this
_temp8 = "shell125" createvehicle getpos _this
_temp9 = "heat125" createvehicle getpos _this
_temp10 = "shell125" createvehicle getpos _this
_temp11 = "heat125" createvehicle getpos _this
exit
And hey, if this is to add effect to a vehicle when it dies,
check out my script i just submited a few days ago in the editors depot. It creates an extra explosion, a dust effect around the tank from the explosion, and has a enhanced burning/smoke script that looks beter than the wimpy default OFP smoke from destroyed vehicles.