Home   Help Search Login Register  

Author Topic: nearestobject start point of search  (Read 1519 times)

0 Members and 1 Guest are viewing this topic.

Offline Terox

  • Former Staff
  • ****
  • Follow the Sappers!
    • zeus-community.net
nearestobject start point of search
« on: 10 Oct 2005, 22:33:16 »
If i had a tripwire for say a grenade trap or flaretrap
and i used a nearest object search as the condition for activating the grenade/flare etc

what point in the addon object is the reference starting point for the search

eg
If the tripwire was 30m long
does the nearestobject command use every point of the "tripwire" as a possible reference point or just say one of the ends or the centre
Zeus ARMA2 server IP = 77.74.193.124 :2302
Teamspeak IP = 77.74.193.123

Offline Pilot

  • Contributing Member
  • **
Re:nearestobject start point of search
« Reply #1 on: 10 Oct 2005, 23:05:48 »
I'm pretty sure OFP finds the center of the model and uses that for the reference, unless there is a specified point in the model.  The point has a special name, but it's in Czech so I don't know it, nor do I have access to OFP right now to find out. :-\

-Pilot

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:nearestobject start point of search
« Reply #2 on: 10 Oct 2005, 23:06:03 »
Just a guess here...... ;D

But I would say it searches from the centre of the 'tripwire'.

What your tripwire is I don't know, but if it is 30m long then I suspect it would begin its search 15 m from either end.   ;)

Bearing in mind that nearestobject is limited to a 50m radius also.


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

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re:nearestobject start point of search
« Reply #3 on: 11 Oct 2005, 15:16:12 »
It's the center of the object which is defined by many things in the model...

Making a 'real' tripwire with just nearestObject is not going to happen though, you need far more complex stuff...
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Offline Terox

  • Former Staff
  • ****
  • Follow the Sappers!
    • zeus-community.net
Re:nearestobject start point of search
« Reply #4 on: 11 Oct 2005, 17:31:26 »
It's the center of the object which is defined by many things in the model...

Making a 'real' tripwire with just nearestObject is not going to happen though, you need far more complex stuff...

can you explain more please
Zeus ARMA2 server IP = 77.74.193.124 :2302
Teamspeak IP = 77.74.193.123

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re:nearestobject start point of search
« Reply #5 on: 11 Oct 2005, 17:44:51 »
No... :(

Merely because I'm not in liberty as the stuff I've made with pipemines falls under FWW2 Mod NDA and although I'm a co-leader I'm not sure I can brake it...

EDIT:
The problem with using just nearestObject is that it will activate the mine only when the unit tripping the wire is close enough to the wire center...
« Last Edit: 11 Oct 2005, 17:48:34 by HateR_Kint »
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Offline Terox

  • Former Staff
  • ****
  • Follow the Sappers!
    • zeus-community.net
Re:nearestobject start point of search
« Reply #6 on: 12 Oct 2005, 16:24:30 »
The problem with using just nearestObject is that it will activate the mine only when the unit tripping the wire is close enough to the wire center...

thats what i thought was happening and thats enough info to help me, thanks
Zeus ARMA2 server IP = 77.74.193.124 :2302
Teamspeak IP = 77.74.193.123

Kyle Sarnik

  • Guest
Re:nearestobject start point of search
« Reply #7 on: 12 Oct 2005, 21:35:39 »
Not to mention that nearestobject to an object (not a position) will (unless a specified classname to search for is given) allways return the object itself. Its a pain really, for example of you use:

nearestobject [player,""]

It will return as player, no matter how many other objects are next to him, because think about it, the absolute closest object to the center of player would be player.  :-\ Sometimes OFP is too logical...  ::)