Ads keep us online. Without them, we wouldn't exist. We don't have paywalls or sell mods - we never will. But every month we have large bills and running ads is our only way to cover them. Please consider unblocking us. Thank you from GameBanana <3

Disabling / Enabling Button with another button - A Question for Counter-Strike 1.6.

Question Solved

This Question was answered and a solution was chosen.
Button A activate door.

Button B deactivate Button A, makes that after pressing it, it would not activate doorm, how to do it?

scenario: there is door which can be opened with button, there is also generator that power up this door, after turning generator off (buttonB) buttonA should stop working.

Many thanks for all help!
  • The Bubblegum Goth avatar
    The Bubblegum Goth username pic Joined 3y ago
    Offline
    3,605 points Ranked 3,561st
    15 medals 1 legendary 2 rare
    • Returned 5000 times Medal icon
    • Returned 1000 times Medal icon
    • 25 posts awarded Exemplary Feedback Medal icon
    • Returned 100 times Medal icon
    • 1 post awarded Exemplary Feedback Medal icon
    • One month a member Medal icon
    1y 1y
    0. func_door; targetname - door [This is the door which should be opened]

    1. func_button; targetname - button; target - door [Our main button which triggers the door]

    2. func_door; targetname - generator; target - generatoroff; toggle - yes [Generator. Note that it should be exactly func_door because it should get reset each new round]

    3. multimanager; targetname - generatoroff;

    target [1] - targetbuttondisable; delay - 0,01;

    target [2] - targetgeneratoroff; delay - 0,01; [This entity will show the behavior of our generator getting turned off. Generator manager will activate two changetarget triggers which will disable our button and also change the target of the generator func_door so it will activate another multimanager]

    4. trigger_changetarget; targetname - targetbuttondisable; target - button; newtargetname - (leave empty); delay - 0,01 [This changetarget will remove target field from func_button and result in our button not being able to open the door]

    5. trigger_changetarget; targetname - targetgeneratoroff; target - generator; newtargetname - generatoron; delay - 0,01 [This changetarget switches the generator behavior. Next time you switch the generator it will activate another multimanager - generatoron]

    6. multimanager; targetname - generatoron;

    target [1] - targetbuttonactivate; delay - 0,01;

    target [2] - targetgeneratoron; delay - 0,01 [This manager shows the behavior of our generator getting turned on. It returns back the name to func_button and changes target of the generator func_door back to targetgeneratoroff]

    7. trigger_changetarget; targetname - targetbuttonactivate; target - button; newtargetname - door; delay - 0,01 [Gives the name to the func_button back so it can be activated again]

    8. trigger_changetarget; targetname - targetgeneratoron; target - generator; newtarget - generatoroff; delay - 0,01 [This changetarget switches the generator behavior. Next time you switch the generator it will activate another multimanager - generatoroff]

    Please note that I haven't tested it. I used this system for one of my maps and it actually works but this entity structure may not work. I may have some time tomorrow to test it and give you 100% working system.
    • Helpful x 1
    Star vs the forces of Mapping
    URL to post:
  • [FPS] Kayn avatar
    [FPS] Kayn Joined 1y ago
    Offline
    182 points Ranked 85,823rd
    18 medals 5 rare
    • Became a Game Pioneer Medal icon
    • Submitted 30 Prefabs Medal icon
    • 10 submissions featured Medal icon
    • Submitted 15 Mods Medal icon
    • Submitted 20 Mods Medal icon
    • Thanked 5 submitters Medal icon
    1y
    Usually, I use Multi Manager Tool Entity for these jobs. You can make anything timed and delayed by what you want.

    Use Multi Manager Tool, there is a billion tutorials for it
    WE ARE YOUNG, LIFE IS FUN!
    URL to post:
  • dimaspaf14 avatar
    dimaspaf14 Joined 2y ago
    Ill be back
    4,260 points Ranked 2,674th
    18 medals 3 rare
    • Submitted 15 Mods Medal icon
    • Submitted 20 Mods Medal icon
    • Returned 1000 times Medal icon
    • One month a member Medal icon
    • Submitted 5 Gamefiles Medal icon
    • Returned 100 times Medal icon
    1y
    intresting..
    Confused avatar
    Mantra
    Confused
    URL to post:
  • The16Mapper avatar
    The16Mapper username pic Joined 2y ago
    Offline
    Studio 16 Flag Affiliation: Studio 16
    309 points Ranked 68,942nd
    15 medals 2 rare
    • Returned 1000 times Medal icon
    • Submitted 15 Mods Medal icon
    • Returned 100 times Medal icon
    • Thanked 5 submitters Medal icon
    • One month a member Medal icon
    • Submitted 5 Tutorials Medal icon
    The16Mapper avatar
    The16Mapper
    Studio 16 Flag
    Affiliation
    Studio 16
    1y
    Tie a trigger_changetarget to be triggered by func_button B and make it change func_button A's target to anything else, or even empty.
    • Helpful x 1
    Just a mapper
    URL to post: