Please or Register to create posts and topics.

Number of Portals

Is there any way to keep a count of the number of portals in hammer, so that as soon as the player makes more than a certain number of portals in the map, I can trigger some event?

Even thought it could be annoying to do, I think you could use func_portal_detectors in all your white tiles, then use a math_counter to store the count.

When you have your portal_detectors placed all over, use the ouput:

- OnStartTouchPortal > [math_counter_name_here] > Add > 1

And use the Maximum Legal Value math_counter's property to set the maximum number of portals allowed, and use the output OnHitMax to fire the final desired event ;)

ImageImageImageImageImageuseful tools and stuff here on TWP :thumbup:
[spoiler]ImageImageImageImageImage[/spoiler]

There is a much easier way. Put a couple of prop_portals into your chamber. Make sure they start inactive. Make sure that the portal numbers for each of them are for portal 1 and portal 2. Then, for an output on each prop_portal, OnPlacedSuccessfully > [Math_counter_name_here] > Add > 1.