Home   Help Search Login Register  

Author Topic: Back down to earth - slit / fire trench / trenches  (Read 1062 times)

0 Members and 1 Guest are viewing this topic.

Offline ACF

  • Members
  • *
  • Llama?? Ain't that French for tanks?
Back down to earth - slit / fire trench / trenches
« on: 17 Aug 2004, 23:17:10 »
I've sat on this idea for a while, thinking that they'd implement it in OFP2 . . . they might, but why take the chance?

Before I start, I will globally excuse my ignorance of modelling and animation; if I keep apologising as I type it will become tiresome.  All I can really offer is a concept that might be a worthy challenge for someone who's already got the skills to do it. The payoff is that it could open up quite a few mission scenarios to occupy us for the next 18 months.

One of the biggest limitations I find with the engine is what to do with defending troops that can't dig in.  Yep, you can stand 'em in a bush, lay them under one or pepper the landscape with sandbags - but, to me, these detract from the 'look' and 'functionality' of any conventional attack/defence scenario.

This has, of course, been noted by people in the past, but the only solutions I'm aware of are trench objects that sit on the ground.  Here's my line of thought:

OK - put an empty jeep on the map and no-one fires at it.

Order or script a soldier to go in it and he will assume the appropriate position/animation, but retain his skin and current weapons. His presence will cause hostile forces to engage the vehicle and independently damage the vehicle and/or the occupant. If the vehicle is armoured, the soldier can be head-out or head-in; if the latter, the vehicle will still be targetted.

Seems to me this is analogous to what you'd want from a slit trench:  units get in and get out, units can be heads in or out, units in the trench are targetted, as is the 'occupied' trench.

So, I propose that a functional[-enough] trench object could be made.

The trench would essentially be a static, empty vehicle object; probably 'Car' class and VSoft type as you'd want its occupants to be engaged by small arms.

They would be placed from the editor, or 'in mission' via scripts/actions.  They'd be available to any side - take the trench then use it.

The trench itself would be a DestructNo destruction type. Armor value would be as high as possible, but not so high that the AI won't stop small arms engaging it.

The basic model could be a 2D, dark, rectangular 'decal' say  0.6m x 2m with a 3D parapet (like the 'grave' object), say 0.2m high. It may not be worthwhile, but there could be sub-types: a 'hasty' slit with a brown-earth-textured parapet and a less-AI-spottable 'deliberate' one with a grass-texture. I would also propose a couple of tastefully-cammed trenches with overhead protection (bunkers, if you prefer), with and without an HMG.

I also wonder if the turn in/out feature be 'borrowed' from the armour class.  Of course, entrenched units would need to be head-out in all CombatModes to do anything useful; head-down would be a function of courage/fleeing.  If the config can be tweaked to allow units to turn-in under incoming fire but turn-out fairly quickly, dependent on their 'courage', we'd have an unscripted functional simulation of suppressive fire into the bargain - the AI should still target the 'buttoned-up' vehicle that is our trench. Dreams are free . . .

As far as I can see, there are two real problems.

1)  First-off, the engine does not like AI units below ground level. I've noticed that while objects and empty vehicles can be setpossed below ground, they float to the surface when AI get in. The key might be how 'ground level' is referenced on models and/or animations.  If an animation could be created or revised with a 'ground-level' at chest height, have we got an entrenched unit?  Alternatively, is a 'head and shoulders' model the solution?

2) The big issue is weapons. Ideally, all small arms should be usable from trences as well as LAWs/RPGs/grenades.  I've not seen any vehicles that allow small arms to be fired from them, vehicle-mounted weapons are always configured as turrets that contain units.  It seems the [two-man fire] trench model needs to be configured with two 'turrets' that become units.

I fear the 'turrets' issue may be the big stumbling block. I have got an inelegant less-than-ideal (but hopefully still functional) idea up my sleeve but, first, has anyone got any views on the above??

I'd also argue that some dug-in armour would be useful - Soviet doctrine promoted it and the Iraqis implemented it in GWI.  Might be an easier starting point?
« Last Edit: 17 Aug 2004, 23:18:08 by ACF »

Offline Roni

  • Members
  • *
  • Play the Game !
Re:Back down to earth - slit / fire trench / trenches
« Reply #1 on: 18 Aug 2004, 03:09:33 »
ARRRGGGHHHH !!!!!  WHY DOES THIS FORUM KILL ALL YOUR TYPED TEXT IF YOU MAKE A SIMPLE ERROR !!!

"File name already in use"?  What the effin ell does THAT mean anyways ?!  >:(  >:(  >:(

Okay - take two of this reply.


Try the attached script for starters.  It's a dig in script that I made many moons ago (and just renamed !).  I now use it as a standard addAction for my player units.

What the script does is play an animation and a sound (available separately - stupid 50k attachment limit !) then slowly moves the player .3m below ground.  A very fast loop then keeps him there until he moves more than 2m from his dig in position.

The script actually works REALLY well, even if I do say so myself !  8)  Take a sniper and have him dig in under a bush and see what I mean - virtually invisible !  This even works in the open - take a standard man and look straight down and you become a bump on the landscape.

The script also cover protection as well as concealment - I've seen bullets bounce off the ground in front of me that I knew would have hit me.  This doesn't work for explosives though.  The OFP engine doesn't care for cover - explosives simply cause a fixed damage to everyone within a fixed range.  I'm sure that this could be overcome with an eventHandler or some tricky script changes - please feel free to edit the basic script to your heart's content !

The script does have one little quirk though - if you dig in on a slope and try to point downhill your gun barrel goes below ground and this blocks the shot.  I don't really know how this can be avoided . . .

The script doesn't have the addons that you mentioned.  When I wrote the script I asked around for a crater or trench type addon but go no replies.  I tried camCreating a crater or "grave" abject but they didn't look quite right.  Again, feel free to work your own options here.

This script works really well in MP mode - try making up a sniper vs sniper match and see what I mean.

Good luck with it !



Roni

Dubieman

  • Guest
Re:Back down to earth - slit / fire trench / trenches
« Reply #2 on: 18 Aug 2004, 04:37:57 »
Doesn't the ECP core take care of the ppl gettin nailed if within the fixed explosion range? :P

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:Back down to earth - slit / fire trench / trenches
« Reply #3 on: 18 Aug 2004, 04:38:01 »
Hmm... I don't know if your addon idea would work too well, mainly because you can't fire your own weapons from a vehicle (so it would have to be a MG bunker, really). I've seen one trench addon out there, but it didn't look very good, and it didn't even block bullets (!) so it was useless. Even though the "trench" sits above ground, I still think that basic idea could work if it was done better. Basically, you could make a "fighting hole" addon, which would essentially look like a crater that you would kneel in for cover. Throw in some bushes on/around it, and you're in business.

Check out my Simple Cover Script. It could be used with such an addon. However, it does work just as well with sandbags. Check the demo mission, and you will see how well-placed units and objects can make for one hell of a defensive position.


As for Roni's script; I've seen it before, but haven't tried it out yet. I think it is a good idea though, and would work even better with a custom animation. An animation could be made that places the player below ground, which means you wouldn't have to have a very fast "setpos" loop to keep him there. I'll try out your script sometime, and I'll try making a very simple animation to test out my idea.
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Dubieman

  • Guest
Re:Back down to earth - slit / fire trench / trenches
« Reply #4 on: 18 Aug 2004, 04:42:28 »
Ohh yea and to add something else.

Either this is a glitch or a game engine thing but I've had this happen twice, but could never repeat it.

I set up a few laserguidedbombs or some wicked explosions, B61 nukes from the F18...

Anywys afterwards I found all the dead ppl, but it seemed those closest to the detonation were "jammed" into the ground. At random measurements. Like they get pushed underground by 0.3 or 0.15 or something.

They were dead thought and I had some powerful ammo detonating so that may be no use... :P

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:Back down to earth - slit / fire trench / trenches
« Reply #5 on: 18 Aug 2004, 04:52:59 »
I guess I'll throw this in too: explosions don't go through ALL walls, because I made a bunker out of sandbag walls that could protect you from a shell landing on top of it, or next to it.
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Offline ACF

  • Members
  • *
  • Llama?? Ain't that French for tanks?
Re:Back down to earth - slit / fire trench / trenches
« Reply #6 on: 21 Aug 2004, 13:26:50 »
Thanks for the feedback, chaps.

The addon route is an attempt to avoid laggy, script-heavy solutions.  It should also mean they're much easier to use - drop 'em in East- or West-crewed from the editor, or use an empty one and MoveInCargo whoever you want.  It's a shame the concept's not set the addon-world alight; obviously not spectacular enough (he says, chucking a bit of petrol at the smouldering embers).

As no-one's actually said an approach like this isn't possible: @GB can you advise me of any useful non-OFPEC animation tutes, utilities etc. please? Particularly, anything that has an idiot's guide to how man-models/anims relate to vehicles.

The bits I've got to get my head round first is what references your unit's rump to a seat, as well as the unit to ground level.  Roni's approach demonstrates that a standard unit/anim can fire whilst half-buried (except when he sticks his muzzle in the deck (as IRL - you've been digging in the wrong place!), we all know that a binocular-wielding unit can't move from the spot, so there does seem some scope to configure stationary, sunken squaddies.