Question [Question] Need help constructing auto-actuating bridge w/ "player-above" sensors.

Contagious

Terrarian
Hi, i'm fairly new to the mechanical side of Terraria, and completely new to the logic gates & stuff. I've done some searching & reading to try to find answers and i'm sure articles that i've read/bookmarked have the answers in them, more or less, but a lot of what i see is pretty advanced and I can't quite grasp the actual mechanics of what i've seen.

I'm trying to figure out how to construct a bridge/platform (using solid blocks) that stays actuated unless i'm above. It will be roughly a screen width's in length so a good amount of player-above sensors would be needed. The problem that's getting me is the fact that logic gates send a signal for both when it's conditions are met and also when they are no longer met. To keep the bridge from "flickering" on & off, I was thinkin i'd have to place the sensors quite close together so that there is overlap but, it seems there is a simpler solution using faulty logic lamps? I'm having a hard time figuring out exactly how they work and how to use them for this. Also, i don't know which logic gate would be "best", but to me it seemed, i could use any/most of them to get what i wanted to happen.

Help would be much appreciated, thanks for reading.
 
maybe use sensors and timers? build the bridge and actuate the blocks so they are in the background, chain some timers and sensors together so that when you get near the bridge, it actuates and is brought to the foreground for a set time, and when you pass and the timer goes off, the bridge will disappear. may not exactly be what your looking for, but thought i'd try to help somehow
 
it has been talked about on the castlevania project
Thanks for the reply. In that thread you mentioned to some1 to connect each sensor to it's own lamp while using an OR gate, which is what i first did but started to see how many lamps that would require while making sure to keep the wire out of the way of other stuff. There will be either 2 or 3 sensors tall running the span of the bridge (to cover jumping height). It does work though and is what i'll do if i can't figure out a simpler way (or rather, a more compact way).
[doublepost=1513596835,1513596568][/doublepost]
maybe use sensors and timers? build the bridge and actuate the blocks so they are in the background, chain some timers and sensors together so that when you get near the bridge, it actuates and is brought to the foreground for a set time, and when you pass and the timer goes off, the bridge will disappear. may not exactly be what your looking for, but thought i'd try to help somehow

Thanks for the input, and that would be a good solution but i'm using this "bridge" as a substitute for platforms in an arena (a Non-AFK) arena. Platforms give a weird and annoying issue where everytime i hit an enemy w/ a weapon, they drop down the platform. Seems to happen with most enemy types, maybe specifically "fighter AI" enemies? But also, having solid blocks would give me protection from ranged enemies below, though that is just a small bonus i thought of, but not why i want to use blocks vs platforms
 
There will be either 2 or 3 sensors tall running the span of the bridge (to cover jumping height). It does work though and is what i'll do if i can't figure out a simpler way (or rather, a more compact way).
I can compact it to 4 - 6 lamps on the gate, but it would not be multiplayer friendly.
 
You should always post a screen shot of your current setup. It's a lot easier to answer your question when we can see it and get a better idea of what you are talking about. `:)
 
Hi, i'm fairly new to the mechanical side of Terraria, and completely new to the logic gates & stuff. I've done some searching & reading to try to find answers and i'm sure articles that i've read/bookmarked have the answers in them, more or less, but a lot of what i see is pretty advanced and I can't quite grasp the actual mechanics of what i've seen.

I'm trying to figure out how to construct a bridge/platform (using solid blocks) that stays actuated unless i'm above. It will be roughly a screen width's in length so a good amount of player-above sensors would be needed. The problem that's getting me is the fact that logic gates send a signal for both when it's conditions are met and also when they are no longer met. To keep the bridge from "flickering" on & off, I was thinkin i'd have to place the sensors quite close together so that there is overlap but, it seems there is a simpler solution using faulty logic lamps? I'm having a hard time figuring out exactly how they work and how to use them for this. Also, i don't know which logic gate would be "best", but to me it seemed, i could use any/most of them to get what i wanted to happen.
.
Help would be much appreciated, thanks for reading.
Well, it depends.
Do you want it to appear once someone gets on it, or disappear?
Just hook the player-above-sensors to the area of blocks the sensor covers. Make sure nothing overlaps, and use different wire per area/sensor.
If you want it to appear when someone goes on it, make it so each block is not actuated default. If you want it to disappear, make sure it's actuated default.
 
it has been talked about on the castlevania project
Heres my drawbridge, do with it what you will. I copy and pasted it into a small world, it's just to the right of spawn. It is one time use, no player sensors, but could easily be modified to suit your purposes. World download at the bottom of post.
Capture 2017-12-18 20_50_19.png
Capture 2017-12-18 20_50_32.png

I can compact it to 4 - 6 lamps on the gate, but it would not be multiplayer friendly.
Here's my player above lamp gate design inspired by Ekinator himself :) , using only 2. The timers are not needed and can be done away with for what you guys are talking about.
Capture 2017-11-25 12_34_18.png

To the OP (whom I cant quote for some reason): Overlapping sensor fields is bad and won't work. I learned that playing with a fountain I want to be a certain color of water whenever the player was near. They must be spaced like mine are in the pic above this. One ends right where another begins (no overlap). However this design will send a pulse as long as a player is in any field. What u want is something like this hallway but each fields floor will only be active when your in that field? Like an invisible bridge that you walk across, it turns off as you progress, and appears in front of you/underneath you as you move across?
 

Attachments

  • Drawbridge.wld
    2.7 MB · Views: 111
I can compact it to 4 - 6 lamps on the gate, but it would not be multiplayer friendly.
Is that 4-6 lamps because that's the amount of sensors you'd have or thats all you'd need even with more sensors? I'd be interested in seeing how you'd do that if you're able to get it working with more sensors than you have lamps.

Overlapping sensor fields is bad and won't work. I learned that playing with a fountain I want to be a certain color of water whenever the player was near. They must be spaced like mine are in the pic above this. One ends right where another begins (no overlap). However this design will send a pulse as long as a player is in any field. What u want is something like this hallway but each fields floor will only be active when your in that field? Like an invisible bridge that you walk across, it turns off as you progress, and appears in front of you/underneath you as you move across?
Thanks for the examples. After first making this thread i tried overlapping some sensors and yeah, it didn't work very well; good to know though that that isn't recommended to do anyway. The last image you posted (Player Above Hallway), do you know if you'd be able to get the whole length of the hallway to basically act as one while keeping the low amount of lamps that you have it running off of now?
Thx for the help & feedback every1, i'll probably just do what Ekinator suggested in the thread he linked to, (1 lamp per sensor). I'm sure i'd be able to get the wiring to not interfere w/ other stuff in the end. The examples the wiki lists for uses for faulty lamps; 1 of them was the flip-flop, and reading the description of a flip-flop sort of sounds like what i was needing, but wasn't grasping how exactly. I'm sure i'll put the effort required in learning the ins & outs of logic once i am building somethin more cool than a row of blocks.. lol.
 
Is that 4-6 lamps because that's the amount of sensors you'd have or thats all you'd need even with more sensors? I'd be interested in seeing how you'd do that if you're able to get it working with more sensors than you have lamps.
4 lamps (sensors are as many as you like) because that is the physical maximum of fields the player can occupy (without the fields overlapping), and I would achieve it in the same manner as @AlexanderStarship already showed us.
Again, this design would fail in a multiplayer scenario. Imagine two players standing in different fields, that are connected to the same lamp. The signals would cancel each other out and actuate the bridge.

A flip-flop could also work. Put a sensor at both ends of the bridge and connect them both to a single flip-flop. EDIT: this is also multiplayer unfriendly
 
The last image you posted (Player Above Hallway), do you know if you'd be able to get the whole length of the hallway to basically act as one while keeping the low amount of lamps that you have it running off of now?​
If I understand you correctly yes. That's how it works right now. All the fields are essentially one big field. As soon as a player enters any field, it starts spawning monsters in the hallway. It doesn't stop until a/all player/s exits. Tested in multiplayer and it works. Additional players can enter and exit and it continues to behave normally. Same for the fountain which also runs off player sensors. As long as any one player is in any field a pulse is being generated.
[doublepost=1513730631,1513727519][/doublepost]Finished. Is this what you are wanting?

bridge.gif
Capture 2017-12-19 19_33_57.png
Capture 2017-12-19 19_34_14.png

This uses no logic gates, turns on as you progress across, turns off behind you, and I believe should be multiplayer friendly. Each field has its own wire color, alternating red and blue, and directly controls the floor in that field. They snap on and off as a player enters or exits. I've added it to the map download below. It is left of spawn.

I pretty much built exactly what EndShulker suggested.
 

Attachments

  • Drawbridge.wld
    2.7 MB · Views: 103
Last edited:
Yes flip-flops are fun to use. You can also use them for things you want the player to be able to turn on but not off. `:naughty:

Also you might at times want a smaller sensor field. But you can't change the size of the 'Player Sensor' field so here is an example of a way to use 2 Player Sensors to make a smaller sensor area. As well as an example of a flip-flop gate being used.

The blue and yellow area shows the sensor field of the 2 sensors.
CheckPoint_field.jpg

Notice how they overlap making a green area. It's this green area that we want to trigger the Meteorite Lamp on when the player goes into it.

Down below you can see the blue and yellow wire are connected to the off lamps above an AND gate. The AND gate will only output a signal if both all of its lamps get turned on. The only way that can happen is if the player is in both the blue and yellow field shown in the picture above, (i.e. the green area).
CheckPoint_gates_with_wires.jpg

The output from the AND triggers the faulty lamp on the left side of the flip-flop, and the flip-flop gate turns the Meteorite Lamp above in the green area.
And because the green wire also crosses the logic lamps in the faulty gate it switches the on one off and the off one on. (a.k.a "flip-flop")
The red wire is the reset switch wire and is used to flip the flip-flop gate back on so a player can trigger the Meteorite Lamp on by passing through the green field.


Also here is the logic gate setup with no wires.
CheckPoint_gates_no_wires.jpg


If you have any questions about wiring and logic gates you can always ask...

...Also if you like seeing crazy things built with wiring and logic gates you should check out the Duck Hunt mini-game I made which I call Duck Duck Dart.
It goes for 100 waves and will take almost 3 hours to complete... ...If you can survive that long. `:D
 
Finished. Is this what you are wanting?

Sorry, I wasn't clear enough. When i was asking if you could get it to act as one, I meant have the entire bridge actuate and de-actuate together all at once. Reason is because for me, mine would be a section of an arena, basically taking place of an actual platform, and would have/want enemies to spawn on it. While below the actuated "bridge"/ platform, i wanted to be able to jump up and have it de-actuate, then only actuate again once i walked off the edge. But I'm thinking i've gathered enough info from all you guys and should be able to get it setup how i wanted. Thanks!
Also you might at times want a smaller sensor field
The output from the AND triggers the faulty lamp on the left side of the flip-flop, and the flip-flop gate turns the Meteorite Lamp above in the green area.
And because the green wire also crosses the logic lamps in the faulty gate it switches the on one off and the off one on. (a.k.a "flip-flop")
The red wire is the reset switch wire and is used to flip the flip-flop gate back on so a player can trigger the Meteorite Lamp on by passing through the green field.

That's a clever way to reduce the size of a sensor'(s) field. And I'm starting to understand how flip-flops work and why you'd want to use one. Thanks a lot for those pics and explanations. Just one question though if you don't mind, if you were starting to build a flip-flop to be used like how you show above, would you need to start by placing one OFF lamp and one ON lamp? Just like how the picture shows?
Regarding that Duck Hunting game you created; that's awesome! Im rly curious what it's like to play and i'm going to download the world file you attached.​
 
That's a clever way to reduce the size of a sensor'(s) field. And I'm starting to understand how flip-flops work and why you'd want to use one. Thanks a lot for those pics and explanations. Just one question though if you don't mind, if you were starting to build a flip-flop to be used like how you show above, would you need to start by placing one OFF lamp and one ON lamp? Just like how the picture shows?
Regarding that Duck Hunting game you created; that's awesome! Im rly curious what it's like to play and i'm going to download the world file you attached.​

Yes, normally you would place one ON lamp and one OFF lamp. But if you run out of 1 type of lamp or you just got a ton of ON lamps and didn't have the money for some OFF lamps you can always just wire up one of the ON lamps to a switch and flip it before you wire up the rest of the flip-flop and other logic gates to it. But you do need 1 ON and 1 OFF in the build for the flip-flop gate to work.
 
Yes, normally you would place one ON lamp and one OFF lamp. But if you run out of 1 type of lamp or you just got a ton of ON lamps and didn't have the money for some OFF lamps you can always just wire up one of the ON lamps to a switch and flip it before you wire up the rest of the flip-flop and other logic gates to it. But you do need 1 ON and 1 OFF in the build for the flip-flop gate to work.
Understood, thank you.
 
Pressure plate activates mob that holds down pressure plate. Use some kind of logic gate apparatus thingy to make the same pressure plate kill the mob. Possibly an AND gate to activate a flame trap, with the first signal being produced by the mob, the second signal being you stepping on the pressure plate. If I can get on terraria this arvo, then I will show you what I mean.
 
Back
Top Bottom