|
WHAT IS 3D RAD? CLICK HERE TO FIND OUT!
|
|
|
EventOnProximity
This object starts/stops (or shows/hides) objects linked to it when the distance between two objects of a
specified set is within a specified range.
For example, you use this object to trigger pre-defined events like the
animation of an opening gate when a character passes by.
This object can itself be started and stopped by other event objects,
allowing you to create chains and achieve articulated event management.
For more about event objects in general, please see this tutorial.
USAGE
Add the EventOnProximity object to your project, link it to all the objects you want to
monitor for proximity and also to all objects you want to start/stop when the proximity
condition is met.
You link objects together in the Object List (left side of 3D Rad main screen), by
selecting an object and then checking the other objects you want to link to it.
To configure the EventOnProximity object, double-click it in the
Object List to open the following property dialog:
Distance (min/max)
The event action is only performed if the distance between any two monitored objects
is within the specified range. See MONITOR (OFFSET 1/2/3/4/5) below for more.
Continuous detection
If this option is checked, the proximity test is performed continuously and the action triggered
repeatedly (75 times per second), until the condition is no longer met.
If this option is not checked, the event action is triggered only once.
It is performed again only after the proximity condition is no longer met and then met again.
Relationships
This list defines how the EventOnProximity object relates to the objects that are linked to it.
The following relationship types are supported:
IGNORE. Do nothing.
Typically used for linked objects that are starters for this EventOnProximity
object itself (in a chain of event objects for example).
MONITOR (OFFSET 1/2/3/4/5). Check the object for proximity with other objects.
The distance for the test is measured using a specific point on the objects as a reference.
This point is relative to the natural object's model center.
For example, assuming the offset from the model's center is a point on the front bumper of a car,
this point on the car bumper will still be the reference point when the car moves or rotates.
Up to 5 different point locations can be defined (Object's center offsets section)
and each monitored object can use one.
START ON PROXIMITY. Start the object when a proximity check between two monitored objects is positive.
Note that the target object must provide some 'startable' action.
STOP ON PROXIMITY. Stop the object when a proximity check between two monitored objects is positive.
SWITCH ON PROXIMITY. Switch the object (start if stopped and vice-versa)
when a proximity check between two monitored objects is positive.
Note that, because the checking is performed 75 times per second, proximity may be reported several times.
This causes the target objects to be switched on/off repeatedly.
SHOW ON PROXIMITY. Show the object when a proximity check between two monitored objects is positive.
HIDE ON PROXIMITY. Hide the object when a proximity check between two monitored objects is positive.
S/H SWITCH ON PROXIMITY. Switch the object (show if hidden and vice-versa) when a proximity check between two monitored objects is positive.
RESET. Re-initialize the object completely, to its default state, as defined in the project.
Randomize target object
If this option is checked, the specified action
is applied to one target object only, picked randomly.
If the option is not checked, the action is applied to all target objects instead.
Working at start
If this option is not checked, the EventOnProximity object will not work
until it is started by using another event object.
For information about the remaining controls, please click here.
INTERNAL PARAMETERS
The following internal parameters can be accessed by using event objects like
EventOnValue or Script:
Current distance between monitored objects, in meters. Read only.
|
|