Home   Help Search Login Register  

Author Topic: No shot and no kill?  (Read 1820 times)

0 Members and 2 Guests are viewing this topic.

Minvera

  • Guest
No shot and no kill?
« on: 27 Aug 2007, 14:49:07 »
Im in the middle of making a cutscene where a sniper (on hill) pops an officer (in base) from not that far away.

Now, problem is when i tell him to target and fire (via script) at the officer he doesnt even look at him.

I've tried different ways of getting him to target and fire and all have failed. Does anyone know why? Could it be because of the distance?

I tried the ?(sniper knowsabout officer >4) thing and that didnt work either.

Could someone please help?

Cheers.

M.

Offline Garcia

  • Members
  • *
  • Leeds United is the best football team...EVER!
Re: No shot and no kill?
« Reply #1 on: 27 Aug 2007, 17:58:57 »
Code: [Select]
sniper doTarget officer
sniper doWatch officer
~4
sniper doFire officer

Unless the line of sight between them is blocked or they are too far from each other, that should work. Has worked like a dream for me in the past...

Minvera

  • Guest
Re: No shot and no kill?
« Reply #2 on: 27 Aug 2007, 21:05:04 »
Thanks mate but ive tried that and no luck   :(

Silly AI, the snipers only about 600-800m away and has a clear view  :scratch:

Offline Garcia

  • Members
  • *
  • Leeds United is the best football team...EVER!
Re: No shot and no kill?
« Reply #3 on: 27 Aug 2007, 22:11:37 »
Either you have to low VD/too much fog (but I suppose you've already thought of that), or the sniper is simply too long away. I managed to make a sniper fire at an officer at about 600 m with no problem, when the sniper has clear line of sight and all that. But when I tried 950, the sniper refused to fire, even though he knew about the enemy, and could see him (clear line of sight and high enough VD to see him).

Offline paddy

  • Contributing Member
  • **
  • Llama whipping good
Re: No shot and no kill?
« Reply #4 on: 29 Aug 2007, 10:53:55 »
Hmm  :scratch:, to me the most likely culprit is AI, I havnt been editing for awhile now and dont know if anything has changed in ARMA but if you have the sniper in a group and the group leader defaults the unit to "safe" or "hold fire" you're in uncertain territory, the unit may or may not fire.

Try removing the sniper from any groups, setting his behaviour to "combat" or above (see comref under 'setbehaviour' for more details on how to do this) and try Garcia's code again.  This way nobody will be telling your sniper not to fire!

As far as I am aware there are some really nice bullet camera scripts out there too, could be a nice addition to your cutscene  :D.

If this fails it would help if you could give a fuller description of your script and what actually happens in this section of the cutscene, maybe a copy of the mission??

Minvera

  • Guest
Re: No shot and no kill?
« Reply #5 on: 29 Aug 2007, 22:29:27 »
Thanks for help guys but it still isnt working, the sniper is on his own and no attached to groups and ive tried all sorts of scripts to make him hit that officer but no luck  >:(

Paddy, i would give you a copy but yesterday my pc took a heart attack and the OS crashed and i had to completely wipe my C drive, containing all my missions for this campaign and other stuff.

So...sorry  ::)

but again thanks for the help guys and if i can ever be arsed creating all those missions again il make sure yous get the campaign first  ;)

M.

Offline paddy

  • Contributing Member
  • **
  • Llama whipping good
Re: No shot and no kill?
« Reply #6 on: 30 Aug 2007, 16:58:31 »
No worries, pity we couldnt solve it though :(.

Offline bedges

  • Administrator
  • *****
    • OFPEC The Editing Center
Re: No shot and no kill?
« Reply #7 on: 30 Aug 2007, 20:28:22 »
ladies and gentlemen - i give you ... the reveal command.

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re: No shot and no kill?
« Reply #8 on: 30 Aug 2007, 20:33:17 »
Weird, because it works fine for me.  :dunno:
And as bedges says, I don't see anyone of you using the reveal command.. Nor setting the sniper's skill to the max. :scratch:

This is what I did:
Distance between sniper and the target about 680 meters with clear line of sight, sniper set on behaviour "stealth" and combatMode "yellow", skill at max (and on high ground).
Then I simply used a (radio) trigger with the following in the On Activ. field:
Code: [Select]
sniper reveal target; sniper doTarget target; sniper doFire target
Works fine, although it takes a while for the sniper to acquire the target. He usually also misses the target by meters but may hit eventually..
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Offline paddy

  • Contributing Member
  • **
  • Llama whipping good
Re: No shot and no kill?
« Reply #9 on: 30 Aug 2007, 20:37:50 »
Hmm, I agree you could add this to be safe but surely OFP's AI will increase its 'knowsabout' rating of the target after you told your sniper to target him??  :confused:
Worth investigating?  I doubt it, ArmA is the game of the moment, maybe thats something to look for there ...

It makes me even more eager to get playing ArmA (new comp on order lol)!

Offline bedges

  • Administrator
  • *****
    • OFPEC The Editing Center
Re: No shot and no kill?
« Reply #10 on: 30 Aug 2007, 21:27:09 »
just did an experiment using ofp (arma commands are the same although implementation may be different) - 14 map grids away and a reveal command increased my group's knowsabout of a single enemy loon from 0 to 1. it takes a while for it to kick in, but it works.

however, my group doesn't move to intercept when i tell them to target the enemy loon...  :confused:

Offline paddy

  • Contributing Member
  • **
  • Llama whipping good
Re: No shot and no kill?
« Reply #11 on: 30 Aug 2007, 22:43:21 »
Erm, misunderstanding  ;), I WASNT disputing the fact that reveal works, it certainly does and thanks for the further proof!!!!  I was saying it would be worth investigating whether the doWatch/doTarget commands affect the 'knowsabout' level, but like I said its not really worth knowing because OFP is a little old now and most scripting will be done in ArmA plus the 'reveal' command will of course suffice for the purpose of this piece of cutscene scripting.

If however you do go and test it, id sure like to know (just out of curiosity, and not being bothered to test it meself!).

Pad

Offline Cheetah

  • Former Staff
  • ****
Re: No shot and no kill?
« Reply #12 on: 05 Sep 2007, 23:14:15 »
If you still haven't got it working. Why not just use some tricks as it's in a cutscene?

I don't know how you've set things up, but you can make the sniper fire on a target a few metres away - camera pointing at the sniper firing, not at his target. Then, switch to the base (officer) - add a sniper shooting from a few metres (make sure that there isn't a double rifle firing sound) OR spawn the bullet mid air and give it the proper velocity to hit the officer.
Like missions? Help with Beta Testing! or take a look at the OFPEC Missions Depot for reviewed missions!

Minvera

  • Guest
Re: No shot and no kill?
« Reply #13 on: 06 Sep 2007, 14:23:35 »
Thanks alot for the help guys but when i was messing about i had another idea for the cutscene so i changed it but I did try using camera trickery.

again thanks for the help guys.  :good: