Desert Combat Realism: The plan for a new release

Ask questions, discuss ideas, get answers
User avatar
Apache Thunder
Posts: 1213
Joined: Mon Oct 19, 2009 2:48 am
Location: Levelland Texas, USA
Contact:

Re: Desert Combat Realism: The plan for a new release

Post by Apache Thunder »

I just remembered. You can try addtemplating a custom vehicle firearm to your hand-weapon to achieve the backblast projectile and have it use the same key to fire the weapon. The vehicle firearm would fire along with your normal handweapon and the invisible projectile would do the damage you seek. Thus allowing you to customize the direction it fires it in and such since this would be an independent firearm. :D

I had once set something like this up for a APMine handweapon back in the early days of the GFMod where you still had to right click to arm the mine once fired. (the vehicle firearm would fire an invisible projectile that would arm the mine)

This worked without a hitch. Just make sure your new vehicle fire arm has the same mag size and reload time/fire rate as your main weapon and it should work fine. If the mag size/count doesn't match and one of the weapons runs out of ammo first, you can encounter a bug where your main weapon won't fire correctly. So be sure they match up! :D
ImageImageImage
I have cameras in your head!
tanelorn
Posts: 42
Joined: Thu Oct 14, 2010 6:19 pm

Re: Desert Combat Realism: The plan for a new release

Post by tanelorn »

That would be great if I could do that. So, would I just use 'addtemplate' to achieve that? Just like adding effects adn LODs? Also, there is a SetInputID line I see for objects attached to firearms. Do you know if this may influence how the attached weapon may fire? Effects have it set to -1. The MDT has no description for it.
Tanelorn-Desert Combat Realism mod lead
DCR Website: http://www.tanelorn.us/dcr/pages/index.htm
DCR AI development: http://www.battlefieldsingleplayer.com/ ... opic=15529
DCR new features: http://bfmods.com/viewtopic.php?f=6&t=727
tanelorn
Posts: 42
Joined: Thu Oct 14, 2010 6:19 pm

Re: Desert Combat Realism: The plan for a new release

Post by tanelorn »

Allright! It seems to be a good concept and has produced results, but I'm having major synchronization issues. I think I should provide a code snippet to aid in troubleshooting. In the below code, I excluded code irrelevant to timing. I tried attaching the firearm to the complex LOD, but no dice. So then I attached it to the firearm directly and that seemed fine. In this experiment, I am having it fire a RPG out the back, but in the future it will be a special airburst projectile.

The problem I'm having is that the backblast rocket isn't firing at the same time as the main round. It will fire, but there are major synchronization issues. When the main round fires, I seem to be able to initiatate multiple 'firing' animations by tapping the fire button, eventually resulting in a backblast fire.

Code: Select all

ObjectTemplate.create HandFireArms RPG7
rem *** Tan mod changed to give ak74su to antiarmor ***
ObjectTemplate.itemIndex 5
ObjectTemplate.networkableInfo HandFireArmsInfo
ObjectTemplate.projectileTemplate Tan_RPGProjectile
rem *** added Dummy projectile
ObjectTemplate.visibleDummyProjectileTemplate RPGDummy
ObjectTemplate.addFireArmsPosition .01/-.017/.73 0/0/0
ObjectTemplate.magSize 1
ObjectTemplate.numOfMag 5
ObjectTemplate.magType 0
ObjectTemplate.autoReload 1
ObjectTemplate.reloadtime 4
ObjectTemplate.roundOfFire 1
ObjectTemplate.fireOnce 1
objectTemplate.aiTemplate DCR_RPG7_AI
ObjectTemplate.hasDynamicShadow 1
ObjectTemplate.zoomFov 0.5
ObjectTemplate.altFireOnce 1
ObjectTemplate.soldierZoomFov 0.6 
ObjectTemplate.soldierZoomPosition -0.05/-0.02/0
ObjectTemplate.cantSelectWhenNoAmmo 1
ObjectTemplate.changeWeaponWhenNoAmmo 1
ObjectTemplate.AmmoType	3

...

rem *** experimental backblast ***
ObjectTemplate.addTemplate Backblast_firearm
rem ObjectTemplate.setInputId -1
ObjectTemplate.setPosition 0/0/.5
ObjectTemplate.setRotation 180/0/0

... 

rem ===== Backblast emulator ===========================================

ObjectTemplate.create FireArms Backblast_firearm
ObjectTemplate.fireInCameraDof 0
ObjectTemplate.setNetworkableInfo TankFireArmInfo
ObjectTemplate.saveInSeparateFile 1
ObjectTemplate.projectileTemplate Tan_RPGProjectile
ObjectTemplate.projectilePosition 0/0/.5
ObjectTemplate.magSize 1
ObjectTemplate.numOfMag 5
ObjectTemplate.magType 0
ObjectTemplate.autoReload 1
ObjectTemplate.reloadtime 4
ObjectTemplate.roundOfFire 1
ObjectTemplate.fireOnce 1
ObjectTemplate.AmmoType 3

Rem *** Deviation Begin *****
ObjectTemplate.velocity 100
Rem *** Deviation  End *****
ObjectTemplate.setInputFire c_PIFire
Tanelorn-Desert Combat Realism mod lead
DCR Website: http://www.tanelorn.us/dcr/pages/index.htm
DCR AI development: http://www.battlefieldsingleplayer.com/ ... opic=15529
DCR new features: http://bfmods.com/viewtopic.php?f=6&t=727
tanelorn
Posts: 42
Joined: Thu Oct 14, 2010 6:19 pm

Re: Desert Combat Realism: The plan for a new release

Post by tanelorn »

- UPDATE -

Good progress with the dynamic dust generation for tanks. They have 2 special projectiles with 2 special material classes. 1 is for the immediate area that violently kicks up dust. The second follows the path of the projectile and creates a stream of dust from the terrain as the projectile passes over it. If the angle is too high, only the immediate area kicks up dust. I've got 3 effects so far: a violent immediate dust, a light projecile following dust, and an over-water effect.

Still deadlocked on RPG backblast damage...

Removed faulty COOP support for 73Eastings
Added COOP for Desert Shield

P.S. Nothing's cooler than watching a Shilka track and take down an A-10 flying overhead!
Tanelorn-Desert Combat Realism mod lead
DCR Website: http://www.tanelorn.us/dcr/pages/index.htm
DCR AI development: http://www.battlefieldsingleplayer.com/ ... opic=15529
DCR new features: http://bfmods.com/viewtopic.php?f=6&t=727
freddy
Posts: 1267
Joined: Sun Oct 18, 2009 4:58 pm

Post by freddy »

tanelorn wrote:The problem I'm having is that the backblast rocket isn't firing at the same time as the main round. It will fire, but there are major synchronization issues.
i think iwé run into something similiar many years ago in my first attempts to add an extra weapon to a aagun, it had to do with where i addtemplated the extra gun.

as i did this on a pco object it was easy to fix, but there might be harder to find a solution when it comes to a weaponkit.

----------------------------------------------------------------------------------------------------------------------------------------------------------

i have used the criticalDamage setting to remove dummy objects over time but found it a bit buggy, especially in a busy server. the quick solution in my case was to add a negative healingbubble that destroyed the object.

you could use a bubble both to destroy the object and/or deal damage to soldiers in its way

the one thing iwé never tested is the response time, how quick a bubble can begin its work. its also a risk for the "dead hulks" effect using bubbles
tanelorn
Posts: 42
Joined: Thu Oct 14, 2010 6:19 pm

Re: Desert Combat Realism: The plan for a new release

Post by tanelorn »

I was feeling really good about using an attached extra firearm to the handweapon, as it seems to only be an issue of tweaking it to make it synchronize better. But now that you mention a negative healing bubble, I'm rethinging that approach and rethinking the ejection of a bundle object with a negative healer attached. The disadvantage is that a negative healing bubble doesn't produce any push or disturbance, as a projectile could. But it does get around the 'wait 1 full second before detonation' issue of a critically damaged object with explosive death effect. Still, imagine the object flies backwards and hits a wall as it spends its 1 second dying. That means someone in that location will experience a full second of harmbubble. If the bubble is strong enough to harm someone whom the object flies by, then it will be intensely deadly to someone who stands where the object settles.

I may avoid the 1 second issue by having the harm bubble harm people AND the object that it belongs to. Or, as I think you mentioned, I could simply use the harmbubble to more quickly kill the object, and let the end of life explosion do the damage to people...

Still, if I can do it with a projectile, that will give me the MOST control. So I'd like to pursue that farther if possible. Too bad I can't use the shotgun code to fire more than one projectile type. If that were possible, it would be problem solved. I wonder though... if 2 rounds are fired synchronously like a shotgun, if the tracer occurs as the second pellet, or the second shot. If it's the second pellet, it may be possible to use a tracer for the backblast projectile as you can assign the position and direction of each pellet's starting point...
Tanelorn-Desert Combat Realism mod lead
DCR Website: http://www.tanelorn.us/dcr/pages/index.htm
DCR AI development: http://www.battlefieldsingleplayer.com/ ... opic=15529
DCR new features: http://bfmods.com/viewtopic.php?f=6&t=727
tanelorn
Posts: 42
Joined: Thu Oct 14, 2010 6:19 pm

Re: Desert Combat Realism: The plan for a new release

Post by tanelorn »

- UPDATE -

- Refined the Gaskin AA vehicle to have nice firing effects, a reticle, radar, basically making it up to par with the other vehicles

- All the dynamic tank cannon dust effects are done. The dust effects differentiate between sand, dirt, concrete and water, and there are different effects for the immediate area and the dust stirred up by the projectile flying over the terrain. Now I need to investigate doing the same for handheld machineguns

- Added COOP support for Kurst and Battle of the Bulge just because it was easy (BF1942 had the COOP support already for these maps)

- A handful of tweaks / improvements on a variety of items and maps.

- RPG backblast damage still not going anywhere
- DPICM ammo recharging problem still not fixed.
Tanelorn-Desert Combat Realism mod lead
DCR Website: http://www.tanelorn.us/dcr/pages/index.htm
DCR AI development: http://www.battlefieldsingleplayer.com/ ... opic=15529
DCR new features: http://bfmods.com/viewtopic.php?f=6&t=727
tanelorn
Posts: 42
Joined: Thu Oct 14, 2010 6:19 pm

Re: Desert Combat Realism: The plan for a new release

Post by tanelorn »

Latest RPG backblast damage attempt:

It seemed a good possibility that I could use the tracer projectile as the origin of a unique projectile that would cause backblast damage. The idea is that the weapon would fire 2 projectiles, with the tracer set to always be the 2nd shot. Using the addfirearmsposition would create a second muzzle pointing wherever I wanted it to go. Then, on firing, the RPG would be the first projectile fired, then the backblast projectile would be the 'tracer' and go next, in the direction of the second defined muzzle.

2 attempts:
#1: Using the shotgun system of simultaneous firing. Failure. The RPG does fire 2 projectiles, and could fire more, just like a shotgun. However, it fires the default projectile out of both muzzles, then on the next shot, it's the tracer projectile out of both muzzles.

#2: Using a very rapid fire rate, with 2 shots per magazine, and asynchronyfire on. This way, the projectiles are actually fired sequentially, but the fire rate is so high you can't help but fire twice per triggerpull. Still using 2 muzzles. Same problem. Each muzzle keeps track of the tracer count independantly, not as a whole firearm.

So, unless we can figure out how to get an attached, independent firearm to work in synchrony with no problems (earlier attempts would not synchronize), using a special projectile isn't going to work.
Tanelorn-Desert Combat Realism mod lead
DCR Website: http://www.tanelorn.us/dcr/pages/index.htm
DCR AI development: http://www.battlefieldsingleplayer.com/ ... opic=15529
DCR new features: http://bfmods.com/viewtopic.php?f=6&t=727
tanelorn
Posts: 42
Joined: Thu Oct 14, 2010 6:19 pm

Re: Desert Combat Realism: The plan for a new release

Post by tanelorn »

- UPDATE -

Dynamic tank cannon and projectile dust is complete
REM *** Handheld machinegun dust not possible (can't slow down / change angle of special tracer round enough to create localized special impact effects)
-updated- Handheld machineguns are now dynamically producing dust when fired too close to dusty ground!

RPG backblast damage no longer being considered

Working on bot-friendly jets and helis for coop maps only

Refined SA-9 Gaskin, giving it radar, special firing effects, etc. to make it on par with other vehicles, and added it as alternative mobile AA on some maps.

Currently, maps with COOP support in DCR:
El Al Day 1 and 3
Gazala
Battle of the Bulge
Kursk
Operation Aberdeen
Tobruk
DC Desert Shield
DC Basrah's Edge

Other AI related developments listed at BFSinglePlayer forums.
Tanelorn-Desert Combat Realism mod lead
DCR Website: http://www.tanelorn.us/dcr/pages/index.htm
DCR AI development: http://www.battlefieldsingleplayer.com/ ... opic=15529
DCR new features: http://bfmods.com/viewtopic.php?f=6&t=727
mrhowdoimodClassic
Posts: 31
Joined: Fri Oct 29, 2010 7:36 pm
Location: World Loc: 0,0,0
Contact:

Re: Desert Combat Realism: The plan for a new release

Post by mrhowdoimodClassic »

I believe I have an Idea as for the blast-back damage, unless you've totally given it up. I haven't modded 42 in a long time but this is at least an idea I guess? What if you continued with the bundle object method, keeping the time to live at the 1 second but created a new material for it and had it explode on impact of a all the basic materials? If you can control the velocity at which this fires out, you could hopefully have the "blast back projectile" disappear before it collides with a solid object behind you. Just maybe? Sorry, I'll continue brain storming, see if I remember anything. I don't have a copy of the game anymore so I cant look at the rest of the possibility's but where there's a will, there's a way. If it's bf42, there's always a way to fake it.
_____________________________________________
Thanks so much for the years of support and friendship to both: SSM.com and it's legacy, BFMods.com
Sincerely, John P. Harrell
_____________________________________________
Post Reply