Jump to content

Targets, area portals, and the mythical hint brushes


Go to solution Solved by mrwonko,

Recommended Posts

Posted

Targets:  What I want is a button that both prints a message AND kills the person who uses it.  What I have rigged up isn't working, so I'd like to know what anyone else would do to make it work. (I've tried multiple ways of doing it: Using the trigger_multiple to target a target_print and a target_kill that are both named the same thing, using a target_multiple to activate both the print and a trigger_hurt where the player would stand, and some other way I forgot.)  All that works is the print.  I specifically want to kill the player, too.  It'd have to work when they have full health.  (Would any of those setups work WITHOUT full health?  I didn't think to try until now.  Does the target_kill even work...?)

 

Area portals/hint brushes:  Right.  Anyone who maps is probably groaning and facepalming at the noob who's asking about these, but I seriously don't know.  What I saw on Google confused me more because apparently there're more types of hint brushes and stuff...

 

So here is a lovely Paint diagram of my map, mostly to scale:

fpsissue_zps90760489.png

 

My understanding is that the engine's drawing more of the map than I can see at any given point, which doesn't help anything.  WHAT do I need to be doing with these hint brushes and area portals to fix this?  It might have to do with detail and structural brushes as well, so if anyone knows of some sort of guide to all of that (structure/detail/area portals/hint brushes/fps and mapping in general) for JKA, you could always... y'know... point me in that direction.

 

Thanks!

Posted

You could put an area portal in the door between your two large rooms. Its just a brush the same size as your door just thinner. So if your door is 8 units thick you could make your area portal brush 2, 4, 6, units thick. Just texture the whole brush with the area portal texture. That should stop your framerate issues. You don't need to have them at every door, though. When you start putting in target speakers you may run into some crackling issues since the area portals cut off sound. I ran into that issue with my stuff.

 

Here is a post I made about Area Portals and some issues with some good explanations.  http://jkhub.org/topic/3401-stutters-on-some-area-portals-triggers/

 

As far as detail and structure everything that touches the void is structural. You can also have structural brushes  inside a room such as a wall or cargo containers or something to block vis, too. It gets confusing sometimes depending on how many tutorials you read and each says slightly different things. Most everything inside a room will probably be detail.

 

I have absolutely zero clue how Hint brushes work so someone is going to have to try and explain those. 

Posted

The hint plane creates a split. You use them to control awkward splits from structural brushes, creating cleaner portal scheming, or for creating a new split in conjunction with structural brushes to reduce the PVS where it wouldn't usually happen naturally from the current structural hull in a section.

Posted

You could put an area portal in the door between your two large rooms. Its just a brush the same size as your door just thinner. So if your door is 8 units thick you could make your area portal brush 2, 4, 6, units thick. Just texture the whole brush with the area portal texture.

You don't want to do this. What you should do is cover most of the brush in system/skip and have the system/areaportal texture only on one side that covers the doorway and is inside the door. Otherwise you're relying on the compiler to only create 1 areaportal, not 6.

 

If you enable cheats in SP, or enable cheats and set developer 1 in MP, you can use r_showtris 1 to "see through walls" and see what's visible at any moment. There's also r_lockpvs - I don't know if that works in MP - which once enabled only renders what was rendered when you enabled it, so you can walk around and examine that.

 

Also, if you run your -vis compile with -saveprt q3map2 will save the created portals to a mapname.prt file which the prtviewer plugin for radiant (which it ships with) can display.

Posted

You don't want to do this. What you should do is cover most of the brush in system/skip and have the system/areaportal texture only on one side that covers the doorway and is inside the door. Otherwise you're relying on the compiler to only create 1 areaportal, not 6.

 

If you enable cheats in SP, or enable cheats and set developer 1 in MP, you can use r_showtris 1 to "see through walls" and see what's visible at any moment. There's also r_lockpvs - I don't know if that works in MP - which once enabled only renders what was rendered when you enabled it, so you can walk around and examine that.

 

Also, if you run your -vis compile with -saveprt q3map2 will save the created portals to a mapname.prt file which the prtviewer plugin for radiant (which it ships with) can display.

 

So the area portal should only be on the visible sides and the skip texture should be on everything not visible is what your saying and that is more efficient than than just using the area portal texture all over?

Posted

So the area portal should only be on the visible sides and the skip texture should be on everything not visible is what your saying and that is more efficient than than just using the area portal texture all over?

I don't know about more efficient, but it's only necessary to have one side to define "this is an areaportal" so I don't see why you'd want multiple. In fact, I sometimes experience short vis bugs when walking through doors which I imagine may be connected to having 2 area portals in there, but I never verified that.
Posted

I don't know about more efficient, but it's only necessary to have one side to define "this is an areaportal" so I don't see why you'd want multiple. In fact, I sometimes experience short vis bugs when walking through doors which I imagine may be connected to having 2 area portals in there, but I never verified that.

 

Make a brush the side of the entire doorframe and cover it in the system/areaportal shader.  Then adjust it to fix entirelyinside the door.  This means if you made your original doorframe 5 units thick, the door would be 3 units thick, and the areaportal would be 1 unit thick.

 

The only reason i've made them multiple is from the above. You make a brush the size of the frame, assuming that "side" is a typo because you can't make a side, and cover it in the texture. 

Posted

You only need one plane of the brush in order to fulfill the function of an area portal. Skip suffices for the other planes. Thickness of the brush is entirely irrelevant, as long as the plane is within the func_door affecting it.

 

If you have problems with vis later, odd behaving area portals, errors etc.... it's best to start with best practices to eliminate the amount of troubleshooting you have to do later on.

Posted

I think wonko is right only needing areaportals on 2 sides.  Having them on 6 sides also will cause the touching brushes to the areaportal sides to show up as visable in other parts of the map if those parts can see in the same direction as your areaportal.  I have encountered that problem in the past when using area portals.

 

Personally I would arrange the vis for your area a little different.  As soon as that door opens your fps will drop.  Arranging vis differently would keep this from happening or at least reduce the fps drop.

 

edited...

  • Solution
Posted

@@IrocJeff, your choice of font style is annoying.

 

More on-topic:

 

In general, this is what you want an areaportal to do:

 

Door open -> Stuff on other side gets rendered

5yZKQu7.jpg

Door closed -> Stuff on other side does not get rendered (for the most part)

3b6wmWy.jpg

 

 

And here's how having two area portals inside a door sucks:

 

Standing outside of the two area portals:

ITJjOt3.jpg

Standing between the two area portals:

2WhFvEV.jpg

 

 

While you're between two areaportals in the same door (i.e. inside a brush covered in the areaportal texture on all sides) the whole map gets rendered and all entities go invisible. Big no-no. Bad mapper.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...