wandTrigger derived from ygSpace Example Source Header

Description: a space that generates events in the presence of a user and wand

notes:
Category: Trigger
Author: Dave Pape
Revision: 11/01/01

    Messages
local [bool] set position reporting mode
    Events
enter wand, user a wand and associated user have entered the space
inside wand, user, xpos, ypos, zpos a wand is inside the space
event wand, user, xpos, ypos, zpos any wand events are generated while in the space
exit wand, user a wand and associated user have exited the space
    Debugs
inside
    Comments

constructor wandTrigger

destructor ~wandTrigger

method reset

1 clear set of users previously inside
2 set reporting mode to local
3 for each user in the world
3.1 for each associated wand
3.1.0.1 for each wand event
3.1.0.1.1 if not found then add event

method message

1 set position reporting mode

method app

1 for each user in the world
1.1 for each associated wand
1.1.0.0.1 if wand is within the space then
1.1.0.0.1.1 add to set of wands inside
1.1.0.0.1.2 if wand was not previously inside generate enter event
1.1.0.0.1.2.1 a wand and associated user have entered the space
1.1.0.0.1.3 a wand is inside the space
1.1.0.0.1.4 generate any flags associated with the wand
1.1.0.0.1.4.0.1 any wand events are generated while in the space
2 for each wand inside
2.1 if not previously inside then generate exit event
2.1.1 a wand and associated user have exited the space

method previouslyInside