How can I make doors open only if a control point is owned?

Discussion in 'Mapping Questions & Discussion' started by mishi, Nov 5, 2014.

  1. mishi

    mishi L1: Registered

    Messages:
    38
    Positive Ratings:
    3
    Hey all,
    there's probably a guide somewhere that explains how I can make doors open only if a team owns a certain control point. I've googled and used the forum search but couldn't find anything useful, so if someone could explain how to do it or link me a page that'd be great :)
    It'd also be nice if there is some way to indicate that a door will only open if point xyz is owned, how could I do that?
    Thanks!
     
  2. Digaag Wa Riz

    Digaag Wa Riz L3: Member

    Messages:
    121
    Positive Ratings:
    84
    Control points have an output called "OnCapReset" that is fired when the point becomes neutral. You can send an input to the door(s) you want affected by the state of the control point to close when this output is fired. You can also open the door(s) with the output "OnCapTeam1" (RED) or "OnCapTeam2".

    EDIT: To be more specific, you can give each control point it's own output for when it is captured/neutral so you can control specific doors. Open the properties window of the team_control_point and go to the "Output" tab.
     
    • Thanks Thanks x 2
    Last edited: Nov 5, 2014
  3. UKCS-Alias

    aa UKCS-Alias Mann vs Machine... or... Mapper vs Meta?

    Messages:
    1,264
    Positive Ratings:
    749
    Have 2 triggers, 1 for red and 1 for blue. On capture you disable the trigger of the enemy team and enable the trigger of those owning the cp. The triggers itself have a teamfilter that only allows that specific team (that means 2 filters are required).

    For indicating of a door will only open for a team there are multiple ways but its probably done the nicest way using a prop that changes the team color (by changing its skin). But maybe a respawnroom visualizer could do the trick aswel.
     
    • Thanks Thanks x 1
  4. mishi

    mishi L1: Registered

    Messages:
    38
    Positive Ratings:
    3
    I'm afraid I'll need the absolute noob explanation, I'm doing sth wrong. So I go to the trigger_capture_area of the control point A. If point A is owned by Blu, I want the blue door to be usable. In the output tab of the trigger_capture_area I select:

    My Output: OnCapTeam2
    Target entity: door_blu_large_1 (which is the func_door entity that isn't being rendered)
    Target: Open (or Unlock? Both didn't work)

    My Output: OnCapTeam1
    Target entity: door_blu_large_1
    Target: Close
     
  5. Crash

    aa Crash func_nerd

    Messages:
    3,190
    Positive Ratings:
    4,918
    If you want it to be able to be opened after cap but not before, have the trigger set to Start Disabled (Yes) and when it's capped have it OnCapTeam<whatever>, <trigger's name>, Enable. That way it doesn't do anything before that point, but after the capture, it allows the door to open.
     
    • Thanks Thanks x 1
  6. henke37

    aa henke37

    Messages:
    1,931
    Positive Ratings:
    456
    But how do you best lock a door? The kind that opens when people are next to it that is. You obviously don't want to cause trouble when there are people around at the instant where you lock it.
     
  7. Crash

    aa Crash func_nerd

    Messages:
    3,190
    Positive Ratings:
    4,918
    Oh, I was thinking of it as a one time capture type thing, missed that part.

    On recapture, disable the trigger and close the door.

    If you want to get fancy and avoid any chance of making a player stuck in the door (looking at you, Valve) you can enable a trigger hurt inside the door or a teleport to just outside the door, depending on how malevolent you are feeling.