Modding Damage and ForceOnExplosion

Ask questions, discuss ideas, get answers

Re: Modding Damage and ForceOnExplosion

Postby Swaffy » Thu Mar 30, 2017 4:05 am

I think the only way to do this is use it for direct hits. You cannot direct-hit yourself so make it have a low splash damage (material2) and a higher direct-hit damage (material). There is a way to reduce damage over distance but I don't think that can be reversed. I really am not sure how to get your desired damage style except what I explained.
(Forum Thread|Download) Swaffy'sMod v0.34 | Download link to come Soon™
Image
User avatar
Swaffy
 
Posts: 1661
Joined: Sun Aug 29, 2010 9:25 pm
Location: Cibolo, Texas

Re: Modding Damage and ForceOnExplosion

Postby Swaffy » Fri Mar 31, 2017 2:56 am

Here is the piece of code I was talking about:

ObjectTemplate.minDamage 0.5
ObjectTemplate.distToStartLoseDamage 100
ObjectTemplate.distToMinDamage 200

This is added at the end of projectile's code to set the damage drop for that projectile. I wish there was a way to flip it so damage is added, ah well...

There is also this other peculiar piece:
ObjectTemplate.ProximityFusePrimer 0.1

I thought, maybe, that prevents the projectile from exploding within a certain distance, but I don't think it causes the explosion "push" which you want. Worth playing with. You can find this line in the vanilla AA projectile.
(Forum Thread|Download) Swaffy'sMod v0.34 | Download link to come Soon™
Image
User avatar
Swaffy
 
Posts: 1661
Joined: Sun Aug 29, 2010 9:25 pm
Location: Cibolo, Texas


Return to 1942 Modding Discussion

Who is online

Users browsing this forum: No registered users and 12 guests