OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: bedges on 15 Dec 2004, 01:35:26
-
the tanks roll down the hill to their waypoint. when they hit it, a script is called which tells each of the four tanks in the group to target their respective telephones a few hundred meters away. why telephones? well, why not? just to have something to fire at really, as the syntax for dofire requires a named object as far as i can tell.
so i have revealed these telephones to the tanks, i've told them to dotarget the telephones, i've even told them to selectweapon "gun125" (being T80s) and only after all that leading-by-the-hand, dofire upon the telephones with great vengeance and furious anger.
but the AI just doesn't seem to think telephones are dangerous enough to warrant shelling them. sigh.
any ideas?
thanks as always
bedges
-
Hmm, well there is an invisible target addon, which to my knowledge is used for things like making attack helicopters reliably FFAR the crap out of infantry and such, so it will probably be good enough for tanks to shoot at.
Link found:
http://www.aef-kampagne.de/german/Addons/InvTargets/InvTargetsAddon.zip
Hope this helps.
-
it was looking so promising there seal, even despite the hassle of using an addon... until i read the blurb -
"Tanks don't fire with their sabots on one of these targets.
Actually I don't know how to repair this problem.
If someone has a good idea, he should send me an e-mail."
scheise.
if it's a bus, now that they can see, and accept as a target. but try placing it 3 meters underground and it's a nono. they see bikes as beneath them too...
so be it. the tanks shall remain silently menacing. i'll just say it's intentional :P
thanks anyways
b
-
I didn't even look it over myself, I had heard that it's a panacea for all your targeting problems so I assumed it would help :-[
There must be some way of getting them to fire....nobody else knows how?
-
you could have a tank setpos'd off where they need to fire, with an invincibility script running on it and have them shoot at it. then when you don't want it, just sepos it somewhere useless or deletevehicle it
-
hmmmmm... schneaky. i shall see if there are any barns nearby big enough to hide a tank ;)
it's damn insubordination i tell you. i specifically identify the gunner of a tank and without even troubling him with a target, i issue a command to fire.
gunner tankname fireweapon "gun125"
nothing.
i thought just pointing the tanks in the general direction and then have them fire at will at whatever is in the line of sight might work, but no.
too much to ask.
it'll be a court martial for him in the morning, mark my words.
-
tank fire ["gun125","single"]
-
again, i'm unsure if it's me that's getting the usage or syntax wrong, but
tank fire ["gun125","single"]
doesn't seem to work. i have set up a test mission to see what's going on, with a T80 (called tank), a bus (called target) some barrels (called target2) and a single barrel (called humphrey).
using a simple
tank dofire whatever_target
either as a waypoint init or a radio command works just fine.
interestingly, i also tried using a telephone as a target, and they can't seem to see it, even when it's revealed. targets need to be in the line of sight it seems, and of a reasonable size, probably why it wasn't working in the mission.
interesting, but totally useless :(
ho hum.
-
hokay, the tanks are firing at barrels. no problem. once the barrels are 'dead' they stop. fine. understandable.
how do i make these barrels indestructable?
i have two scripts running in tandem for this. one is called by a present trigger by the tanks, on the condition that targets_reset is true.
the other script is called by a trigger which detects the damage on the barrels. if the damage rises above 0.4, the script sets it back to 0 and realigns the barrels with their placement markers, and then sets targets_reset back to true.
at least that's what it should do. the barrels are not being ressurected. the script is running, i've put a hint in to check that it's going all the way through.
is there no life after death for poor barrels?
any help greatly appreciated, as this is the final thing standing in the way of version 0.2 of this mission.
b
-
there are a couple invincibility scripts in the editors depot, they should work for you