Hi,
I don’t really feel like arguing, but I did not state I needed explosion types. I stated I needed people to help me test what all the indexes of the first argument for the event handler “explosionEvent”. I explicitly stated that I am looking for explosion.f186, explosion.f104, explosion.f1240, and explosion.f242. If you’d like to help find these values and what their purpose is, please don’t assume that I need something completely different than I asked for. My explosion logger works perfectly. I’m just trying to find a reliable way to check how the explosion was caused (gun, melee, car ramming it, etc). I know that there are simpler ways to check this information, such as constantly recording info on vehicle velocities and objects that can explode, record every time a player shoots, etc.
If you want to be beneficial for this thread, you can help discover what these “f codes” do with this script:
AddEventHandler('explosionEvent', function(source, ev)
for i,v in pairs(ev) do
print(i..": "..tostring(v))
end
end)
The ones that are already documented:
explosionType: Pretty obvious.
isAudible: If a explosion is audible or not.
posX: X vector of the explosion or offset (if on a car)
posY: Y vector of the explosion or offset (if on a car)
posZ: Z vector of the explosion or offset (if on a car)
cameraShake: how much the explosion makes the camera shake.
isInvisible: Whether an explosion is invisible.
ownerNetId: The person who caused the explosion (spoofable)
damageScale: How large the blast radius is.
The values I’ve found are as follows:
f210: If an explosion was near or on a prop, this is the entity’s network ID. If not, it’s 0.
f190: If the explosion was a bomb type explosion (sticky bomb, etc), and was ON a prop (meaning f210 was not 0)
If you ever tried to do an explosion logger, you’ll notice that if you put a sticky bomb on a prop, the position won’t be correct. This is because gta sets the x,y, and z vectors to the offset of the prop. To get the correct coords, you have to add the offset to the props coords.