OFPEC Forum

Addons & Mods Depot => OFP - Addons & Mods Beta Testing => Topic started by: Unnamed on 16 Sep 2003, 07:50:52

Title: Observer Addon
Post by: Unnamed on 16 Sep 2003, 07:50:52
Hi,

My first attempt at an addon, well almost an addon :)

I've setup some infantry units to act as observers for East,West and Resistance. Including Black Ops day/night and Spetz Natz.

They will scan the horizon with binoculars almost indefinitely. They will stop, if the player tells them to or they are killed or threatened.

You can order them to start and stop via their action menu or scripts, with a choice of stance (Standing,Combat,Crouching and Prone).

The observers have the same eyesight quality as snipers, this with binoculars roughly doubles their detection range.

At best, the observer should spot units moving in the open, at a range of around 1000m. Add a sniper to the observers group and he will open fire from around 900m, on the desert island.

See the readme in the attached zip file, for more info and example missions.

Any suggestions, advice e.t.c is always welcome.

Cheers

Title: Re:Observer Addon
Post by: Bruce Banner on 22 Sep 2003, 16:40:51
Any chance of a Nam soldier?
Title: Re:Observer Addon
Post by: Unnamed on 27 Sep 2003, 23:02:33
Yeah, it's in the pipeline.

I'm fixing some bugs and giving the AI the option to describe and prioritise targets.

He is ultimately destined to be a Forward Observer for my Mortar scripts, so a SEB Nam version is a definite :)
Title: Re:Observer Addon
Post by: Bruce Banner on 03 Oct 2003, 17:48:02
My thinking also. Good work fella.
Title: Re:Observer Addon
Post by: Zayfod on 11 Oct 2003, 07:55:16
Wow--very VERY nice!

This addon contains some very advanced scripting and has potential to be applied to many other opflash applications (which havent been done yet or even seriously attempted).

Take a look inside at what hes done, I for one can see quite a few opening doors here.

 This is indeed a neat find--Ill be watching this thread closely.

Fantastic work mate, dont stop now. :thumbsup:

Zay
Title: Re:Observer Addon
Post by: cliff on 11 Oct 2003, 12:02:03
This is the kind of addon needed to increase gameplay and realism, not another M4  ;)

I like the trend with scripts and addons making your average OFP-AInutcase a bit more realistic. Try Keycats grouplink script, the SP/MP pack and this all together for a different OFP experience.

Great work, keep it up.
Title: Re:Observer Addon
Post by: sanam on 25 Oct 2003, 19:12:41
Downloading Now.

I've always been fascinated by the way the snipers pop up & run for the ennemy (instead of firing from where they are) when you tell them to engage a target. I hope this solves the problem.

"See" you.

Peacepunk
Title: Re:Observer Addon
Post by: Unnamed on 26 Oct 2003, 12:13:23
Thanks all for the replies,

I always had this guy in mind for my Mortar scripts, the sniper was just a convenient way of demonstrating his increased line of site.

From experience with testing the observer, the sniper will move to engage targets only if he cant get a line of site on them, and then never to far away.

If you can think of any logic that will make the snipers role more effective, let me know and I will try and add it to the addon.

Cheers
Title: Re:Observer Addon
Post by: sanam on 27 Oct 2003, 04:16:59
So I checked, as officer, as officer commanding the two guys, as Sniper, and so on.

GREAT JOB please right now do a sniper-suit observer you'll be nice include it to the pack thank you otherwise I gonna Steal Your Work.

Nope, I won't, cause it's good & far more advanced than I'm.
The mess with "action/hit the dirt" commands, or "stop" is that they're unique, you can hardly have a guy firing from where you choose, as ordering to fire means killing the engagement stance, so stopping & ordering to fire is still a special script to be invented.

I though the Observer threatened a bit to fast, also: OK on "Desert", but when the view is obscured, you definitely need a guy to watch over your shoulder. The way not to get the guy killed too fast must reside in his own "threat factor" to the ennemy, a .cpp value I think, but for my point of view he is high, a very desirable , dangerous target.

Well, Bravo again, I'll keep watching this topic

PeacePunk.
Title: Re:Observer Addon
Post by: Unnamed on 28 Oct 2003, 02:50:17
Quote
otherwise I gonna Steal Your Work.
:)

If you have the observer loaded in your mission already, you could add something like this to a snipers init field via the editor. Just make sure he has some binoculars.

Code: [Select]
[_This,60,1000,3,False] Call FO_RegisterObserver
This includes SEB Nam units, if you dont want to wait until I finish the next version.

If you dont want to have the Observer on the map at all, then add something like this (or call via a script) to the units init field:

Code: [Select]
FO_RegisterObserver=loadfile "\Observer\RegisterObserver.sqf" ; [This,60,1000,3,False] Call FO_RegisterObserver ; [This,True,FO_CROUCH] Call FO_SetActiveStatus
Good idea about the Sniper version of the observer, I've been testing on that desert island for so long, forgot what a bush looks like. I'll add the sniper to the next release.

Quote
The mess with "action/hit the dirt" commands, or "stop" is that they're unique, you can hardly have a guy firing from where you choose, as ordering to fire means killing the engagement stance, so stopping & ordering to fire is still a special script to be invented.

I'm not exactly sure what you mean. I could probably get a sniper to stop and go prone, from a single action menu command. Using the same principle I use for the binocular animations?

Quote
I though the Observer threatened a bit to fast

Yeah this is a problem, that's the next thing I'm looking to improve. In the mean time I added a function to allow you to change the threat level depending on the terrain your using in the mission.

Quote
The way not to get the guy killed too fast must reside in his own "threat factor" to the ennemy, a .cpp value I think

Just stopping him opening fire when anything passes within 300 meters would help, as the enemy AI is rubbish at spotting stationary units who don't give there position away. At the moment he will happily take on a tank platoon, if there is infantry attached to it :(

Cheers
Title: Re:Observer Addon
Post by: sanam on 28 Oct 2003, 08:06:14
Thanks for the lines of codes, so I can... steal them with your approval !

I understand "Desert Distraction Factor". A bush is actually a small green thing that's ...  :D

& I meaned: If you say "engage this guy" after "stop here", the "stop" is forgotten, you can't combine them. Boring when you carefully place your units around a target, in no firing mode, then you order to attack & some will open fire very fast while others will expose themselves out in the open... and get shot. This points us to the infamous "Hide" feature as well, as I dunno if the AI will engage from the hiding place, well this hidin'retreat is usually in the middle of the road anyway...

Offtopic a bit, but I guess I got to combine all this (in my head) in order to build a workin' sniper team.

( I'm on a 1000m shot mission, by the way. Very functionnal... as long as I take the shot myself. )

Bravo again, thanks for the detailed answers & keep us informed.

Peacepunk
Title: Re:Observer Addon
Post by: Unnamed on 28 Oct 2003, 20:36:28
Quote
Thanks for the lines of codes, so I can... steal them with your approval !

If you can use them for a sniper, go ahead. The only reason I got this far with it, was through trawling the forums here :)
Title: Re:Observer Addon
Post by: walker on 04 Nov 2003, 16:42:45
Hi

It would be nice if your observer could call CoC UA assets if available ;)

Kind Regards Walker
For The Chain of Command

Title: Re:Observer Addon
Post by: Unnamed on 05 Nov 2003, 04:49:58
Of course, this goes without saying. I'm at the point of writing the final chunk to link the Observers chosen target with the firing unit, so it's timing could not be better :)

Regards
Title: Re:Observer Addon
Post by: walker on 05 Nov 2003, 21:24:12
Hi Unnamed

You might also like to consider a threat assesment script within your system to choose the most apropriate asset to use.


x = a squad of enemy or armour.
enemy => x then use artillery.
enemy =< x means use an infantry squad or inform other alied squads of target existense (we have some work in this area at the CoC)

We have some AI improvements at the CoC in the making you may like to speak to BN880, Spinor and Dinger about them and perhaps enact Denoirs Neural net as part of your decision making structure ;)

Email or PM BN880 first we can perhaps work with you on this.

Kind Regards Walker
Title: Re:Observer Addon
Post by: Unnamed on 06 Nov 2003, 05:27:48
Hi,

Quote
You might also like to consider a threat assessment script within your system to choose the most appropriate asset to use.

I have one that tries to evaluate the target composition (All Infantry, All Armour, Vehicle & Infantry e.t.c) more to decide if it's a worthwhile target than anything else.

And another that needs more work, but decides if the observer needs to defend himself.

Quote
perhaps enact Denoirs Neural net as part of your decision making structure

Yes, I think this would be a good place to try it out. I think the role of Observer probably lends itself more to a Neural Net, than other AI tasks.

Quote
Email or PM BN880 first we can perhaps work with you on this.

Will do.

Cheers
Title: Re:Observer Addon
Post by: Zayfod on 01 Apr 2004, 12:37:40
I was wondering how this addon was going?

Have you released a final version? I hope so  :)

Questions:

1: What happens in MP if I were to use your "FObinoccrouch" anim as a playmove in a third party script and the other clients dont have your Observer.pbo?

2: What happens in MP if I were to use your "FObinoccrouch" anim as a playmove in a third party script and the other clients DO have your Observer.pbo?

3: (This last question pertains to the above 2 questions and if it can be answered it will help me possibly integrate the observer unit into the ECP.)

Can the "FObinoccrouch" anim only be seen on all clients if it is the observer unit himself actually performing the anim and all clients have the Observer.pbo.

Sorry if these questions sound confusing, I hope i have defined them well enough for you.

I am personally having a real hard time sorting the ins and outs of global playmoves for MP in the ECP. And if these issues are sorted then I think this is an excellent candidate fot the ECP. :D --with your permission ofcourse.

Zay
Title: Re:Observer Addon
Post by: Unnamed on 01 Apr 2004, 17:53:26
Nice one, it would be great if you could use it in ECP. Not sure it will be up to scratch at the moment though. There are a couple of niggling glitches, mainly down to the AI trying to do his own anims when I dont want them.

I did a quick test by creating and hosting a MP game on my PC, if you don't have the anim present it wont do anything. No errors, just no anim. So I guess anyone watching the Observer without the addon, would just see a guy without binoculars standing around.  With the addon in the addons folder (but not necessarily in the mission) it all works ok.

This would be awkward not just because of the disparity of anims, the client without the anims would have the observer in combat mode with its gun ready to fire. When in reality the other clients would have him as unarmed and busy.

I had to create it as an addon for two reasons, to give the guy the same eye sight as a Sniper and to be able to lock him into using binoculars. Without them he will still rattle of targets and call in fire missions, but without the enhanced detection abilities and with limited use of Binoculars.

Finding a script based solution to using binoculars would be the key, I could live without sniper vision as Binoculars alone do increase the AI's vision.

Other than that it is almost finished, Ive been developing it on the Desert Island so I have to adjust its targetting for the broken terrain of a regular OFP Island. Plus I want to see how it stands up under regular missions rather than just the ones I've made up.

(http://homepages.gotadsl.co.uk/~gssoft/SEBNAMObserver.jpg)

It's easy enough to test for the presence of an addon using scripts, but how this would fit in with ECP I'm not to sure?

Cheers