Areportals

Discussion in 'Mapping Questions & Discussion' started by Grim Tuesday, Mar 31, 2010.

  1. Grim Tuesday

    aa Grim Tuesday

    Messages:
    1,257
    Positive Ratings:
    371
    I am finally starting to optimize my map, and I can't for the life of me figure out how to use areaportals. I assumed that they were put in doorways to stop rendering of stuff in the background rendering. However, when I load up my map, they are solid: I cant walk through them. They show the "areaportal" texture, and stop rendering, but I can see them. Also, I really dont get the use of hint/skips! I have read multiple tutorials, and still dont get it. Can someone come up with an explanation for a noob?

    Thanks in advance!
     
  2. Firest0rm

    Firest0rm L4: Comfortable Member

    Messages:
    171
    Positive Ratings:
    33
    you have to tie your areaportals to func_areaportal. However, read the guides i linked to below before you use areaportals, because there are some things you need to make sure of before you randomly throw areaportals in doors.

    for optimization, use these guides, and play around with it a bunch in hammer. It may also help to look through valve maps for optimization help, because they seem to be pretty good at it
     
    Last edited: Mar 31, 2010
  3. The Political Gamer

    aa The Political Gamer

    Messages:
    4,468
    Positive Ratings:
    1,682
  4. Lancey

    aa Lancey Currently On: ?????

    Messages:
    3,076
    Positive Ratings:
    1,314
    Keep in mind that areaportals are also useful when open (though I'm not particularly sure why.) Even when a doorway doesn't have a door, but separates two major areas, consider placing an areaportal there that remains open. Also remember that any section of your map that is divided by areaportals can leak into other areas. They must all be individually sealed or otherwise blocked off with APs to prevent them from ruining your compile.

    I recommend reading the Interlopers' guides on optimization, as they walk you through how each entity works very well (they've already been linked here, but a second link couldn't hurt.) The tutorials also have images that describe what each does, so it's a good read. It's also what I used to learn more about optimization as well, so I recommend you take a read through.

    Finally, before you go off placing areaportals willy-nilly, consider that they do have a small cost on the engine. Think about where an areaportal isn't as necessary when you can use, for example, a hint.
     
    Last edited: Mar 31, 2010
  5. Cynick

    Cynick L4: Comfortable Member

    Messages:
    153
    Positive Ratings:
    144
    Because open portals cull visibility into a cone of leaves that you can see (while closed ones block all visibility through them). From the VDC:

    [​IMG]

    Shows what an open areaportal does to aid optimization.
     
  6. Lancey

    aa Lancey Currently On: ?????

    Messages:
    3,076
    Positive Ratings:
    1,314
    I see, so like the opposite of an occluder (which, by the way, culls visibility of any entity directly behind it.)
     
  7. cadeonehalf

    cadeonehalf L1: Registered

    Messages:
    32
    Positive Ratings:
    6
    So what exactly does it mean when your areaportals become untied from the solids during compiling?
    Let me explain:
    I am starting optimization by creating some basic "always open" areaportals to cull visibility a little bit before I get into portals associated with doors and hint/skip. I make the areaportals in my doorways/windows, making sure there are no leaks. Then (obviously) I compile them.
    During compile, I get a ton of errors that it doesn't touch two solids (even though I made sure the areaportal solids were flush with the sides of each doorway) and when I select the appropriate brush number, they are no longer tied to func_areaportal.
    What exactly causes that? It doesn't say its leaking at all.
     
  8. Vincent

    aa Vincent 🔨 Grandmaster Lizard Wizard Jedi 🔨

    Messages:
    914
    Positive Ratings:
    578
  9. Psy

    aa Psy The Imp Queen

    Messages:
    1,705
    Positive Ratings:
    1,465
    The tutorial that TPG explains it as well.

     
  10. Cynick

    Cynick L4: Comfortable Member

    Messages:
    153
    Positive Ratings:
    144
    If you haven't already fixed the problem:

    Brushes not being tied to a func_areaportal is usually caused by having ignore groups :)ig:) enabled. Turn it off, as it will show the entities as solids rather than the entities they are tied to.

    There are other minor limitations: EACH INDIVIDUAL brush must be it's own func_areaportal, they cannot be grouped together under a single entity like func_detail can be. Also, areaportals cannot cross the surface of water, so if they do, you must cut them in two at the water line. (Remember the above, they must be TWO SEPARATE areaportals)

    If they're still leaking...use that pointfile!