Home   Help Search Login Register  

Author Topic: Search lights, bar gates, Map ID - the works.  (Read 2533 times)

0 Members and 1 Guest are viewing this topic.

Offline PASTORR

  • Members
  • *
Search lights, bar gates, Map ID - the works.
« on: 23 Aug 2007, 01:42:47 »
Hello! My nick is PASTOR, I live Norway and are a member of the STUD-DIVISION gaming society/Clan. Although STUD is not active in Arma, we do play it sometimes just for fun.

I have been fiddling around with the editor for Arma, making computer vs. computer battles the last few days. One battle I made was very cool and as it turned out, it could be used as an extremely challenging and long mission (or at least I think so). I'm new to map editing, so I need some pointers in the right direction. I want to add some ambiance and feel to it, and thereby making the AI more challenging. I played through the mission as it now and it takes about 2 hours in order to complete it. By adding new AI features I reckon it will double since the player(s) must be a lot more patient in order to complete it.

I have tried to find information on the following but are not able to find a script so hopefully someone here can help med out. I will of course release my mission once it's done and I am satisfied with it.

1. Search light.
a). I want an AI player to man a searchlight, do 180 degree sweeps (left to right) for about a minute. Turn of the light and chat with other guard that stand there. After 5 to ten minutes I want him to go back to the searchlight do another sweep and this looping. In the event he find a target he will raise the alarm and follow the target.
b). In the event of an attack I want him to man the searchlight again sweeping and if he find a target to follow it.

2. Houses and Bar Gates need to disappear.
Removing ID items from the map. In order for my mission to function properly I need to get rid of a map built in Bar Gate, House, Bus stop etc. I have tried to use "set damage 1" on the items but it leave debris. How can I do this?

3. Static machine guns.
It seems that AI only fire when I pass a certain point, although one easly can shoot the target long before with a rifle. Is there some way of setting "fire" when they spot a target no matter how far away they are?

4. Retreating soldiers.
If by any chance the attacking force is detected by enemy patrols, is there a script that make soldiers retreat to a set position when ie. the group is down to 50% or less. Once they the Rally Point they call in for support the and the enemy scramble reinforcements and more patrols to that area.

Any pointers, or scripts that can help me out is very much appreciated.

Kind regards

PASTOR
www.stud-division.net

Offline myke13021

  • Contributing Member
  • **
  • Myke
Re: Search lights, bar gates, Map ID - the works.
« Reply #1 on: 23 Aug 2007, 02:16:29 »
To point 3:

Take a look at mando_gun (can be found here

to point 4:
You might do some testing with the allowfleeing command.


Oh, and BTW,  :welcome: to the forum.

Myke out

Offline LCD

  • Former Staff
  • ****
    • Everon Cartel
Re: Search lights, bar gates, Map ID - the works.
« Reply #2 on: 23 Aug 2007, 07:49:47 »
4 da searchlight tingy... mebe dis can get u started :D... its not wat u want... but its got somin 2 do w/ searchlights :P so if u open it up ull have some hint on how 2 use

btw

WELCOME 2 OFPEC M8

LCD OUT
"guess being the community has downsides .." - cheetah
Help Perfecting Da Next Best Thing - O-Team Beta

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: Search lights, bar gates, Map ID - the works.
« Reply #3 on: 23 Aug 2007, 18:07:46 »
As for removing objects that are embedded in the .wrp file...this is not possible, as you have stated yourself, the most you can do is setdamage 1.  :no:


Planck
I know a little about a lot, and a lot about a little.

Offline PASTORR

  • Members
  • *
Re: Search lights, bar gates, Map ID - the works.
« Reply #4 on: 23 Aug 2007, 18:33:38 »
Ah shite. But is there some way of "moving" the object to another location then?

Offline PASTORR

  • Members
  • *
Re: Search lights, bar gates, Map ID - the works.
« Reply #5 on: 23 Aug 2007, 19:02:26 »
I tried the allow fleeing info, but what are the variables 1 and 0 only? Can use scripts and game logic to call "allow fleeing"? The mando gun is very powerful, almost to powerful. If I want the gun to activate on say 400 meters what would be appropriate code in the script?

I'm sorry if I pry to much! I really appreciate any help!

Kind regards

Pastor

Offline LCD

  • Former Staff
  • ****
    • Everon Cartel
Re: Search lights, bar gates, Map ID - the works.
« Reply #6 on: 24 Aug 2007, 00:03:01 »
0 = maximum courage
1 = allwayz runnin away

LCD OUT
"guess being the community has downsides .." - cheetah
Help Perfecting Da Next Best Thing - O-Team Beta

Offline myke13021

  • Contributing Member
  • **
  • Myke
Re: Search lights, bar gates, Map ID - the works.
« Reply #7 on: 24 Aug 2007, 00:55:19 »
and:

0.5 will run when scared  :D

Offline PASTORR

  • Members
  • *
Re: Search lights, bar gates, Map ID - the works.
« Reply #8 on: 30 Aug 2007, 04:15:54 »
My mission is taking shape now, still there are somethings here and there that still don't work properly.

I have a tank crew sitting in a tent, doing whatever they do to make the time fly by. If the enemy is detected by any of the guards I want the guard to sound the alarm, and the tank crew to respond accordingly, run and man the tank hence making the mission a lot more difficult to complete.

Can someone please explain to me in detail on how I get the AI to respond correctly. Any help is much appreciated.

Edit: If I want a trigger to be active only at night is this possible?
« Last Edit: 30 Aug 2007, 04:45:39 by PASTORR »

Offline Mr.Peanut

  • Former Staff
  • ****
  • urp!
Re: Search lights, bar gates, Map ID - the works.
« Reply #9 on: 30 Aug 2007, 14:32:56 »
I don't want to nag but I have a couple requests. The first is please do not double post. Instead edit your last post. The second is to start a new topic when you have a new question. Both of these will help others search the board more efficiently and help you get an answer to your question.

What you are asking is normally done by synchronising a switch trigger and waypoints. There are tutorials about these in the Ed Depot(ED). For example place east tank crew group a little ways from an empty tank. Give the crew a waypoint(WP) where you want them to stand waiting. Then add another WP type getin and place it on the tank. Then add a search and destroy waypoint somewhere nearby.

Now add a large trigger covering the area, of type switch, side west detected by east, activate once, and maybe add a countdown.  Now select "synchronise" from the main editor menu and drag a sync line between the trigger and the first waypoint. Just for good measure, in the on activation of the trigger put:
Code: [Select]
loon1 assignAsDriver myTank; loon2 assignAsGunner myTank; loon3 assignAsCommander myTank;where loon1-3 are the names of the crew and myTank is the name of the tank.
« Last Edit: 30 Aug 2007, 14:34:44 by Mr.Peanut »
urp!

Offline paddy

  • Contributing Member
  • **
  • Llama whipping good
Re: Search lights, bar gates, Map ID - the works.
« Reply #10 on: 30 Aug 2007, 16:53:16 »
I apologise in advance for the vagueness of my post, Im a little rusty on the ole OFP/ARMA scripting but you COULD setpos  a wrp based building using its object id to some other part of the island, if you need to get the objectid of the building, try setting a unit right beside it and sweeping the area with a 'nearestobject' loop and spitting that out into a hint.  Then just use a little guesswork to identify the name/id of the building.

Again, apologies for the vagueness but staff guys, maybe you could take my hasty little written thought and flesh it out a little for PASTORR ...

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: Search lights, bar gates, Map ID - the works.
« Reply #11 on: 30 Aug 2007, 21:03:57 »
Unfortunately it is not possible to remove OR move .wrp placed objects, it is only possible to destroy them.


Planck
I know a little about a lot, and a lot about a little.

Offline LCD

  • Former Staff
  • ****
    • Everon Cartel
Re: Search lights, bar gates, Map ID - the works.
« Reply #12 on: 30 Aug 2007, 22:59:34 »
Quote
If I want a trigger to be active only at night is this possible?

use da daytime command... in ur case it cud b

condition field

daytime > 20 (itll triger after 8)

or...

this and (daytime > 20)

dis wil make da triger triger only after 8 in case da oder condition has been met :D

LCD OUT
"guess being the community has downsides .." - cheetah
Help Perfecting Da Next Best Thing - O-Team Beta