Creating Buttons

You can create all sorts of buttons, activated by triggers, or simply by touching or using it. Anyway on to how to make your own but

Buttons for doors

The most obvious button you might need is a button to open up a door, easy enough to do really. After you have created your door, give it a name, say "mrdoor". You dont need to worry about the other door entities, its just like any other normal door.

Now one thing you might want to know is that there are button textures, you dont have to use them, but some are good, if you want your button off, then place the "off button texture" on your button, rather than the "on texture", for instance, there's one button texture with a green light and one with a red light, so if you want the button to start off, then put on the button use the red texture. soon as you press it it will go green in game as it has been turned on,

Anyway make yourself a little button to go with that door. Tie it to the entity func_button now you need to sort out the following properties

Name: just give it a name i.e. button1 target: what you want the button to open/close, so ours would be "mrdoor" as thats the doors name fx_amount 255

There are other things to set as well, such as the sound of the button, and other self explanatory things, so change them as you see fit.

Now in the "flags" section of your func_button, tick "dont move", otherwise your button will move and most of the time you dont want it to actually move. If you want people to just touch activate it then tick "touch activates" if not just leave it and people will have to "use" it to activate it. You can also tick the box for sparks if you want it to have sparks.

Its that easy to do, now you wont want people moving through the door without pressing the button most times, so make sure in your func_door no flags are ticked. You can play with all the settings to see what happens if you like, say if you need it open to start with, then tick starts open for the door. Its all obvious what to tick.

Triggering lasers

Someone recently mailed me asking how to trigger off a func_laser, I made him a quick map and sent it to him, he never replied back like, oh well.

Anyway its quite simple. First put in a env_laser and set the following properties:

Name: call it "laser" (without the quotes) target of laser: this is what your laser hits, give it the name of "target1"

You can leave all the rest to the default settings, its all obvious what changes what, I mean come on I dont have to tell you beam colour changes the beam colour do I! :) also dont tick any of the flags.

Moving on, we now need a target for the laser, so select the entity info_target and call it "target1" thats all the properties that you need to change in that entity, as there aren't anymore.

Now we have a laser, we need a button, make your object for the button, and tie it to a funcbutton, just call it button1. fxamount 255, targeted object "laser" and tick the flag "dont move". Thats your essential stuff up, you can mess about with the other settings, but basically just remember make a laser, give it a name, and then on your button target the laser.

Tutorial by EYERONIK, brought to CSB by [Xero].

Oh noes! You're not a Member!

Want access to cool stuff? As a member you can:

  • Post. Give the submitter your thoughts on this Tutorial.
  • Say Thanks. Show your appreciation by sending the submitter points.
  • Stamp Posts. Let other posters know what you think of their posts.
  • Rate. Give this Tutorial a rating out of 10.
  • Flag. Alert moderators and warn members of a problem with this Tutorial.
  • Vote. Vote the submitter for the Monthly Awards.
  • Subscribe. Get notified when this submitter submits again.

Interested? Register or Login

Comments

  • cassonberry's Levels
    • P1: Beggar
      Points: 218
    • E1: Helper
      EF: 1
    • C1: Member
    • A4: Graduate
      Account Age: 4 years
    Posted 2 years ago

    would you know how to make a button, that, when you walk on it, will turn a light on? would it work or not? im making a light up dancefloor thing :P

    Forget my name and I'll forget
  • rowtree's Levels
    • P2: Drudge
      Points: 1,015
    • C1: Member
    • A5: Veteran
      Account Age: 6 years
    Posted 6 years ago

    Cool will help mi in future. btw in on of mi maps i need to know how to create a button to triger an explosion can u tell u

    Your car hit my window.
  • Ownerer's Levels
    • C1: Member
    • A5: Veteran
      Account Age: 6 years
    Posted 6 years ago

    Where can i find the targeted object??? i cant target the lasers to turn them on so it doesnt work :( screenshots plz!!!

    User Title
    Mapper, GFX, CSS Gamer
  • Ironmad's Levels
    • P2: Drudge
      Points: 4,844
    • C1: Member
    • A6: Elder
      Account Age: 7 years
    Posted 6 years ago

    Yep, plz do some preent screens

    User Title
    Eat Pizza
  • stoopan's Levels
    • P1: Beggar
      Points: 866
    • C1: Member
    • A6: Elder
      Account Age: 6 years
    Posted 6 years ago

    To create button, make a brush (not an entity/prop), which can be of 'NoDraw' infront of a prop. Then Ctrl+T to tie to the func_button entity to it.

    User Title
    uber pwnage
  • Gbuzzy's Levels
    • P1: Beggar
      Points: 302
    • C1: Member
    • A6: Elder
      Account Age: 6 years
    Posted 6 years ago

    I Agree with these guys, screen shots would be very good :p.

    User Title
    Old Clvl system was better.
  • {ESW}YOWZAE's Levels
    • C1: Member
    • A6: Elder
      Account Age: 7 years
    Posted 7 years ago

    I cant find func_button in my entities area any ides? oh yeah, screenshots!

    Bananite
  • ICECOLD_3000's Levels
    • P4: Worker
      Points: 26,490
    • C1: Member
    • A6: Elder
      Account Age: 8 years
    Posted 7 years ago

    Screenshots !

    User Title
    SRT-4 RuLeZ
  • Depredator's Levels
    • P1: Beggar
      Points: 684
    • C1: Member
    • A6: Elder
      Account Age: 8 years
    Posted 7 years ago

    How about some nifty screenshots of those things?

    User Title
    Strenght lies in mind, not mus

Credits

Submitter
Xero's Levels
  • P3: Peasant
    Points: 8,168
  • E1: Helper
    EF: 17
  • C1: Member
  • A6: Elder
    Account Age: 8 years
Xero (Creator/Co-creator)
Key Authors
unknown
Unknown

Rating

8.0/10
Based off 5 rating(s)

Additional Info

Genre
Other/Misc
Difficulty Level
Advanced

Stats

Post Count
10
ViewCount
4,515
Date Added
8 years ago
Date Modified
1 year ago

Share

Embed Code
Code to use:

More embeddable images

Bookmark and Share