I want to set a special puzzle element.
Posted Jun 08, 2011
I want to to create something like this http://cs.gettysburg.edu/~tneller/resou ... index.html
The lights-out puzzle, I know how to make the lights go out in the rows...but how do i set it up to have multiple inputs to open the door.
The lights-out puzzle, I know how to make the lights go out in the rows...but how do i set it up to have multiple inputs to open the door.
Registered users don’t see ads!
Register now!
Posted Jun 08, 2011
Replied
18 minutes
later
Math_counter would work well here.
Posted Jun 08, 2011
Replied
5 hours
later
Nvm, got what you were asking wrong
Posted Jun 08, 2011
Replied
11 minutes
later
This is a tutorial for Portal, but it should still help you with your problem. (Also you don't have to just use buttons for this.)
http://developer.valvesoftware.com/wiki/Creating_multiple_buttons_for_one_door
Posted Jun 08, 2011
Replied
1 hour
later
Let me clafiy This puzzle is a 3x3 grid all are lit expect the center light. The goal is to turn all the lights off, I only want the door to open when all the lasers are off, but each button toggles the lasers...so they turn on and off.
Posted Jun 09, 2011
Replied
6 hours
later
then as omnicoder said, use math_counter, minvalue 0 maxvalue 9 initial value 8 (number of lights turned on) and if a light is turned off substract 1, if on, add 1.
Onhitmin it opens a door, onchangefrommin closes.
9 event for each light, when that light is toggled it also toggles the neigbours with toggle (also must toggle a logic branch I guess)
Onhitmin it opens a door, onchangefrommin closes.
9 event for each light, when that light is toggled it also toggles the neigbours with toggle (also must toggle a logic branch I guess)
Posted Jun 09, 2011
Replied
6 hours
later
I've had problems personally using a math_counter to count toggle events to activate something when they are all 'on'.
There's some kind of adding lag and if quickly toggled just one over and over it would open the door (etc.).
I decompiled one of the official maps to find they use logic_branch and logic_branch_listener, which did work better... HOWEVER... there were still instances where if you quickly toggle the events it can cause the door (etc.) to open prematurely...
Had to force a delay on the checking, i.e if its activated, if it's STILL activated after 0.5secs then open the door (etc.).
A better way would be to cancel the timer that checks the activation after 0.5s if any of the branches change.
Posted Jun 16, 2011
Replied
7 days
later
So im sitting here...looking at the logic branch...after being away for awhile,do i setup a differnt logic branch for each...or what?
Posted Jun 16, 2011
Replied
19 minutes
later
You could do it inefficiently but it would work if you put an invisible thing over each light where when you used it, it would target all the lights in those rows and toggle their states, then copy and paste it over every light and change the lights it targets to toggle.
Posted Jun 16, 2011
Replied
7 minutes
later
Well it should be efficent. besides i already have the puzzle working, i just dont know how to make the door open once there all off.
Registered users don’t see ads!
Register now!
Posted Jun 21, 2011
Replied
4 days
later
any more input?