Pseudo zones?!.. Add this to the ever growing list of pseudo’s. So what is a pseudo zone? And why do we even need them? A pseudo zone is a zone that is dictated by lasers. They can help us get non-rectangular zones! You can also have some cool gimmicks like making a teleport into the zone not be detected!
Concept
The concept is that the zone will have a property that tracks if the player is in it or not. If the player is in the zone, the property will be 1, and if the player is not in the zone, then the property will be 0. So basically we use a counter with a target of 1 to do this. But this now all gets messed up if we teleport the player into the zone in question. So to remedy that, we put 2 lasers side by side (grid snap 2) to track the movement of the player.
Implementation
So how would we implement this? Well… First we would need the actual zone. So lets get that up!
Some warnings:
-
Make the lasers black to make them not be seen. You’ll also have to turn the path off. However, it’ll disappear while editing, so I recommend either keeping them red (that’s what I’ll do) or using deactivated, invisible barriers to mark them.
-
The physical endpoints of the laser aren’t the end. The box it shows while moving the laser is what will detect the player. The endpoints should be the edges that touch.
-
Of course, set the damage to 0. Do this before copying to make it easier for yourself.
So now we have a layer. We’re going to use a counter to implement this. Make all the lasers broadcast on “Laser Tripped”. Also set the scopes to player. Make a counter that is player scoped and increments on “Laser Tripped”. Make the default be 0 to start. If the player spawns inside at the beginning, make it be 1 to start. Now, when the counter is 1, it will go up to 2 when the player enters. When it is 2, we need it to go back to 0, so we reset it when it is 2. So make a wire repeater. Wire there counter to the wire repeater and back. The second wire should reset it. Make the counter edit a player-scoped number property named “In Zone”.
Now we have a zone that will be messed up by teleporters. If you don’t use teleporters in or out of the zone, then you’re finished! If not, then, do this:
This part is really hard to explain, so I’ll just list it out. To sort out AUO, do everything following, in the EXACT order I typed it in.
Make another box of lasers like the first one, but broadcasting on “Outside Laser”. Make a player scoped trigger that activates on “Outside Laser”, deactivates on “Laser Tripped”, and checks on “Outside Laser”. Make sure to input the checking channel 3rd, due to AUO. Make another player scoped trigger that activates on “Laser Tripped”, deactivates on “Outside Laser”, and checks on “Laser Tripped”.
The exactness is over! Make the first trigger trigger a checker that checks if “In Zone” is equal to 1. Wire the checker to the counter. Make it increment the counter if the check fails. Make the second trigger trigger a checker that checks if “In Zone” is equal to 0. Wire the checker to the counter so that if the check fails, then the counter increments. Here is the final product:
And there you have it! You might ask: Why do we even need these?
- We can get non-rectangular zones.
- This saves memory Edit: Actually, it doesn’t.
- You can teleport the player inside without the system detecting it. This is useful for a spy class that can teleport into an enemy base. I first started thinking about this when I was thinking about SEEING IF A PLAYER’S HEALTH WAS LOWER THAN A SET VALUE, of all things. (It might actually work)
- You can detect if a player enters through a specific side of the zone.