1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

UE2 - UT2kX Getting line of sight trigger to work

Discussion in 'Mapping' started by Superbabs84321, Mar 12, 2010.

  1. Superbabs84321

    Superbabs84321 New Member

    Joined:
    Oct 19, 2009
    Messages:
    24
    Likes Received:
    0
    I have difficulties getting a line of sight trigger to work.

    Currently I have a Player-Proximity Trigger firing a event X which activates an AIscript.

    In addition I want a line of sight trigger to activiate the AIscript but I can't get it to work. I placed a line of sight trigger in the open (bHidden set to false so I can see it). Furthermore, at the event tab I set the Event the trigger fires to event X. Currently, the values in the LineofSightTriggerTab are as follows:

    bEnabled = True
    MaxViewAngle = 50.00
    MaxViewDistance = 3000.00
    SeenActorTag = none

    I have walked to the Trigger (well witin the 3000 units range) and watched at it, but it doesn't activiate the script. What did I do wrong?

    THanks in advance!
     
  2. meowcat

    meowcat take a chance

    Joined:
    Jun 7, 2001
    Messages:
    774
    Likes Received:
    1
    Since the trigger code in this class is native, I *think* that the SeenActorTag has to be set to something other than 'none', and that your pawn must have the matching tag.
     
  3. Wormbo

    Wormbo Administrator Staff Member

    Joined:
    Jun 4, 2001
    Messages:
    5,915
    Likes Received:
    36
    The LOS trigger fires its event whenever the local player (offline or on listen server) sees the actor specified by SeenActorTag. (There is no fallback to the trigger itself, so you need to specify a tag name here!) In this case "see" means that
    • the LOS trigger has never fired before since the map was loaded,
    • the LOS trigger is enabled (bEnabled=True or bEnabled=False+triggering),
    • the player is physically within range (MaxDist),
    • the player is looking towards the specified actor (MaxViewAngle),
    • and there is no level geometry between the player and the specified actor.
    Also note that it doesn't matter whether the player is actually playing or only spectating. Bots, monsters or network clients cannot activate the LOS trigger.
     
    Last edited: Mar 13, 2010
  4. Superbabs84321

    Superbabs84321 New Member

    Joined:
    Oct 19, 2009
    Messages:
    24
    Likes Received:
    0
    Ok, I set the SeenActorTag to the LOStrigger itself (LineOfSightTrigger1) and tried some other tags as well but none appear to trigger the LOStrigger. I have complied to all the other criteria you mentioned. I am running an offline game so there is only a local player, but it doesn;t appear to trigger the LOSTrigger.
     
  5. Superbabs84321

    Superbabs84321 New Member

    Joined:
    Oct 19, 2009
    Messages:
    24
    Likes Received:
    0

    Ah, I figured it out! I had to set it to the object tag and not to the objectname!
     

Share This Page