Fortress Forever

Go Back   Fortress Forever > Community > Tips and Tutorials

Reply
 
Thread Tools Display Modes
Old 06-07-2008, 10:57 PM   #161
Jester
Fortress Forever Staff
 
Jester's Avatar
 
Join Date: Sep 2007
Class/Position: O: Scout
Affiliations: {NFO} - New Family Order
Posts Rated Helpful 0 Times
That's not possible because it would require an infinite loop and lock hl2 every time you tried to use it.
Jester is offline   Reply With Quote


Old 12-27-2008, 03:27 AM   #162
Nite]M[are
Scripting Trainee
 
Nite]M[are's Avatar
 
Join Date: Dec 2008
Location: Sitting with mah Sentry
Class/Position: Defensive Engineer
Gametype: OvD (Defense Preferred)
Affiliations: None yet
Posts Rated Helpful 0 Times
Send a message via Skype™ to Nite]M[are
Quote:
Originally Posted by Dr.Satan
Sorry I hadn't posted this yet, but I was out of town for a few days...here is one I currently use for sabotaging...but I can whip one out for you if you have a specific request...

Code:
//     --------
//---- Sabotage ----
//     --------

alias sab_1 "sentrysabotage"
alias sab_2 "dispensersabotage"

alias sabsg "sab_1; wait; default; wait; speak vox/female/s.g."
alias sabdis "sab_2; wait; default; wait; speak vox/female/dispenser"
alias sabboth "sab_1; wait; sab_2; wait; default; wait; speak vox/female/both"

alias sabmenu "bind 1 sabsg; wait; echo 1) Sabotage SG; wait; bind 2 
sabdis; wait; echo 2) Sabotage Dispenser; wait; bind 3 sabboth; wait; echo 
3) Sabotage Both; wait; bind 0 default; wait; echo 0) Defaults"

bind ctrl "sabmenu"
How it works:

When you hit ctrl it will rebind keys 1, 2, and 3 as follows:

1 = Sabotage SG and rebind keys (back to defaults)
2 = Sabotage Disp. and rebind
3 = Sabotage All / Both and rebind
0 = Rebind to default (fail safe it you accidently hit the wrong key)

You will also want to put this in your autoexec.cfg

Code:
//     -------
//---- Default ----
//     -------
alias d_1 "wait;bind 1 slot1"
alias d_2 "wait;bind 2 slot2"
alias d_3 "wait;bind 3 slot3"
alias d_4 "wait;bind 4 slot4"
alias d_5 "wait;bind 5 slot5"
alias d_6 "wait;bind 6 slot6"
alias default "wait;d_1;wait;d_2;wait;d_3;wait;d_4;wait;d_5;wait;d_6"
Currently this is the closest we can get to the old way of things...and there is the problem that it won't show up on screen what your binds are.

I have it set now to echo them in consol so if you get confused you can hit your console and it will be shown in there (time consuming, but you generally memorize them fairly quickly)

I remember somewhere someone suggesting a messageme mode or say_me mode where you could send yourself chat messages to compensate for the loss of echo and such, but until DrEvil gets a bit and codes it in we're all pretty much SOL.

~hope it helps
SUPER BUMP -- New scripting student, I need this thread to live :O

I have had trouble scripting with custom plusses and negatives. An example I have is this:

Code:
alias +engy	"bind mouse1 aimsentry;bind mouse2 detdispenser;bind mouse3 detsentry"
alias -engy	"bind mouse1 +attack;bind mouse2 +attack2;bind mouse3 say ^7I built that, ^6%i^7!"

bind c +engy
Sometimes it works, sometimes it doesnt, almost seems random. When it does work, I can get detdispenser to work, but not mouse3. Mouse3 /always/ gives me trouble -- is it some sort of special key?

Anyways, I need help with that engy script (I modified someone else's script, found original on here). Mostly, however, I see what you put, Dr. Satan, and I have an idea -- I dont want to have to push 0 every time I want to reset. COULD this work, and please help elaborate / improve / fix??

Code:
alias sab_1 "sentrysabotage"
alias sab_2 "dispensersabotage"

alias sabsg "sab_1; wait; default; wait; speak vox/female/s.g."
alias sabdis "sab_2; wait; default; wait; speak vox/female/dispenser"
alias sabboth "sab_1; wait; sab_2; wait; default; wait; speak vox/female/both"

alias +sabmenu "bind 1 sabsg; wait; echo 1) Sabotage SG; wait; bind 2 
sabdis; wait; echo 2) Sabotage Dispenser; wait; bind 3 sabboth; wait; echo 
3) Sabotage Both"
alias -sabmenu "default"

bind ctrl "+sabmenu"
Please, I /really/ dont want this thread to die, and any help would be appreciated. Just started toying around with scripting two days ago, and I need a lot of help still. This thread has helped me design my own semi-scripts, for which I am glad. Thanks!
Nite]M[are is offline   Reply With Quote


Old 12-30-2008, 08:35 PM   #163
MonoXideAtWork
Pub Allstar!
Beta Tester
 
Join Date: Aug 2008
Class/Position: under en kvinna
Gametype: Capture the Flag
Affiliations: Eternal Order, Must be h4x, Mono's happy funtime.
Posts Rated Helpful 0 Times
I'm glad you liked the toggle script!


General troubleshooting:

If a button does not work, replace the controller, and test. If the issue continues, it is script or engine related.

Things that work well on lan may not work online without using "wait".

Specific troubleshooting:

Test your commands! Try each command by itself in console. This will help you determine if you are using improper functions, syntax, or cvars.

the toggle script "+engy" will only map those keys while you are holding down the C key. This is the "is your computer plugged in" question.

This is what I use.

Code:
// Engineer easydet.

alias +engy detdispenser
alias -engy  dispenser

bind c +engy
MonoXideAtWork is offline   Reply With Quote


Old 01-01-2009, 10:44 PM   #164
Nite]M[are
Scripting Trainee
 
Nite]M[are's Avatar
 
Join Date: Dec 2008
Location: Sitting with mah Sentry
Class/Position: Defensive Engineer
Gametype: OvD (Defense Preferred)
Affiliations: None yet
Posts Rated Helpful 0 Times
Send a message via Skype™ to Nite]M[are
Quote:
Originally Posted by MonoXideAtWork View Post
I'm glad you liked the toggle script!


General troubleshooting:

If a button does not work, replace the controller, and test. If the issue continues, it is script or engine related.

Things that work well on lan may not work online without using "wait".

Specific troubleshooting:

Test your commands! Try each command by itself in console. This will help you determine if you are using improper functions, syntax, or cvars.

the toggle script "+engy" will only map those keys while you are holding down the C key. This is the "is your computer plugged in" question.

This is what I use.

Code:
// Engineer easydet.

alias +engy detdispenser
alias -engy  dispenser

bind c +engy
Cool, thanks!

Also, I built a really cool pyro script. The perfect pyro jump, just look down and activate it. I'm sure there are others, but I built this looking at my own default config, user config, and pyro config =D

Note: Put this in pyro config. Change the binding from V to whatever key you want.

Code:
//      ---------
//---- FlameLeap ----
//      ---------

unbind v
bind v "+flameleap"
alias +flameleap "slot4;+jump;+attack"
alias -flameleap "slot4;-jump;-attack"
// Edit1: Medic Infection hotkey!

Code:
//     ----
//---- AIDS ----
//     ----
alias number1 "slot1;unbind v"

alias number2a "slot2;bind v number2b"
alias number2b "slot1;bind v number2a"
alias number3a "slot3;bind v number3b"
alias number3b "slot1;bind v number3a"
alias number4a "slot4;bind v number4b"
alias number4b "slot1;bind v number4a"

// Rebinding numbers to make this work.  Bind each key back to its normal slot
// in your cleanup.cfg :-)
bind 1 "number1"
bind 2 "number2a"
bind 3 "number3a"
bind 4 "number4a"

// You start out using slot4, so we want to start out at number4b.
bind v number4b
__________________
Current Projects:
1.) Become a better Engineer.
2.) Become a better bhopper.
3.) Become a better barrel-roller.

Last edited by Nite]M[are; 01-02-2009 at 03:51 AM.
Nite]M[are is offline   Reply With Quote


Old 10-04-2009, 10:31 PM   #165
ochocinco
 
Join Date: Sep 2009
Gametype: Capture the Flag
Posts Rated Helpful 0 Times
duckjump

could someone please post a jumpduck script for me.

thanks!!
ochocinco is offline   Reply With Quote


Old 10-05-2009, 12:03 AM   #166
Dr.Satan
Wiki Team
Fortress Forever Staff
 
Dr.Satan's Avatar
 
Join Date: Sep 2007
Location: Greeley, CO
Class/Position: Med / Solly
Gametype: PAYLOAD
Affiliations: DET-
Posts Rated Helpful 19 Times
I'm not quite sure what your asking for, like do you mean just a script that when you press +jump you also duck? if so then it's just:

Code:
alias +jumpduck "+jump; +duck"
alias -jumpduck "-jump; -duck"

bind <key> "+jumpduck"
replace <key> with whatever key you want

if that's not what your looking for, lemme know.
__________________
(Released) conc_school | hellion_classic | ksour_PAYLOAD | mulch_faf
(Beta) alchimy_b1
(Lua) base_payload_2015
(Models) props_trainyard
Support FF:
Dr.Satan is offline   Reply With Quote


Old 10-20-2009, 06:14 AM   #167
chaunbot
r.A.p.3.D.
 
Join Date: Sep 2007
Affiliations: r.A.p.3.D
Posts Rated Helpful 0 Times
how about a sniper script

a script when i hit alt it zoom's and charges rifle so all i have to do is click mouse to fire. plz k thanks
chaunbot is offline   Reply With Quote


Old 10-20-2009, 07:05 AM   #168
Dr.Satan
Wiki Team
Fortress Forever Staff
 
Dr.Satan's Avatar
 
Join Date: Sep 2007
Location: Greeley, CO
Class/Position: Med / Solly
Gametype: PAYLOAD
Affiliations: DET-
Posts Rated Helpful 19 Times
cba to find it for you, but if you look thru this thread, I know that either myself, or porkchop or DarK_TaO did a script like that already.

Edit: sorry, I lied...it was not in this thread nor was it any of us. But there is a similar script on the wiki page for the sniper, however since that doesn't really do what you wanted here's an edited version for you:

You need to put this into your sniper.cfg:
Code:
//put this at the very TOP of your sniper.cfg (underneath "exec userconfig.cfg")
//this will keep you from getting stuck in attack mode if you get killed while charging or zooming
-attack
bind mouse1 +attack

// place this anywhere in your sniper.cfg EXCEPT before the above command
alias zooming "+attack2; wait; -attack2"
alias charge "zooming; wait; +attack; wait; bind mouse1 discharge"
alias discharge "-attack; wait; zooming; wait; bind mouse1 +attack"

bind alt "charge"
then, you will need to add this to your cleanup.cfg

Code:
-attack
bind mouse1 +attack
//this is only needed if you use alt for anything else with another class
unbind alt
if you don't have a cleanup.cfg, you will need to make one. There is a nice tutorial on the wiki page, cleanup.cfg(click). Be sure you follow all of the steps outlined in that wiki page, or this script will make you shoot continously until you are out of ammo if you change classes at the wrong time.

Edit2: just noticed you wanted alt to zoom and charge, so I changed the above. It should work, but it's not been tested at all so idk for sure. If it doesn't work lemme know and I'm sure i can get something going for you.
__________________
(Released) conc_school | hellion_classic | ksour_PAYLOAD | mulch_faf
(Beta) alchimy_b1
(Lua) base_payload_2015
(Models) props_trainyard
Support FF:

Last edited by Dr.Satan; 10-20-2009 at 07:44 AM.
Dr.Satan is offline   Reply With Quote


Old 10-22-2009, 01:31 AM   #169
chaunbot
r.A.p.3.D.
 
Join Date: Sep 2007
Affiliations: r.A.p.3.D
Posts Rated Helpful 0 Times
thanks for the script ill try it right now
chaunbot is offline   Reply With Quote


Old 10-25-2009, 10:20 PM   #170
Carrots
 
Join Date: Oct 2009
Gametype: Capture the Flag
Posts Rated Helpful 0 Times
hey, i really want a script thats for demo:

lets say you are putting some green pipes onto the flag, and you switch to blues and go dm a bit

you see someone conc at the flag, and you det the greens,

now what i want, is so once you det, and you have the blue pipelauncher equipped, you switch to the greens again,

so basically: bind mouse2 greenpipeluancher
Carrots is offline   Reply With Quote


Old 10-25-2009, 11:47 PM   #171
Raynian
D&A Member
 
Raynian's Avatar
 
Join Date: May 2009
Location: Ruining #pickups
Class/Position: SPAWN CAMPING OH NO
Gametype: Ragequitting
Affiliations: [PMS]. [Shiney]
Posts Rated Helpful 26 Times
Quote:
Originally Posted by Carrots View Post
hey, i really want a script thats for demo:

lets say you are putting some green pipes onto the flag, and you switch to blues and go dm a bit

you see someone conc at the flag, and you det the greens,

now what i want, is so once you det, and you have the blue pipelauncher equipped, you switch to the greens again,

so basically: bind mouse2 greenpipeluancher
In userconfig.cfg
bind mouse2 +attack2

In demo.cfg
bind mouse2 "+attack2; slot5"
Raynian is offline   Reply With Quote


Old 10-27-2009, 02:37 AM   #172
Carrots
 
Join Date: Oct 2009
Gametype: Capture the Flag
Posts Rated Helpful 0 Times
Quote:
Originally Posted by Raynian View Post
In userconfig.cfg
bind mouse2 +attack2

In demo.cfg
bind mouse2 "+attack2; slot5"
nothing seems to happen when i press mouse 2

this is what the tfc script is:

//quickdet:
bind mouse2 "+fdet"
alias "+fdet" "+attack; tf_weapon_gl; detpipe; tf_weapon_pl; -attack; detpipe; wait; +attack2"
alias "-fdet" "-attack2"

Last edited by Carrots; 10-27-2009 at 02:39 AM.
Carrots is offline   Reply With Quote


Old 10-28-2009, 02:14 PM   #173
GenghisTron
AKA LittleAndroidMan
D&A Member
Beta Tester
 
GenghisTron's Avatar
 
Join Date: Sep 2007
Location: Dystopia
Class/Position: Demo/Medic
Gametype: CTF
Affiliations: [TALOS] [SR]
Posts Rated Helpful 11 Times
How about a script to do the following with the following conditions;

-I already have grellow pipes set
-Assume I've had time to reload my pipes

Now I'd like to have a script where say I press "E" and it starts spamming blue pipes, and when I let go, it dets my grellow pipes. I see it as an anti-juke measure against good scouts. Det my pipes, but then they eat a facefull of blue pipes, countering their juke.
__________________
GenghisTron is offline   Reply With Quote


Old 12-27-2009, 01:21 PM   #174
GenghisTron
AKA LittleAndroidMan
D&A Member
Beta Tester
 
GenghisTron's Avatar
 
Join Date: Sep 2007
Location: Dystopia
Class/Position: Demo/Medic
Gametype: CTF
Affiliations: [TALOS] [SR]
Posts Rated Helpful 11 Times
So since no one answered my post above, I decided to mess around and make my own script, but I'm wondering--is there a way to cancel automatically switching to the secondary mode of my alias?

So far I have (In binds.cfg and demoman.cfg)

//----
// Anti-Juke
//----

alias +antijuke "slot4; wait; +attack"
alias -antijuke "-attack; wait; detpipes; wait; slot5"

// Bind

bind "e" "+antijuke"

And it works pretty much perfectly, but say I kill someone with a blue pipe and therefore don't need to det my pipes, is there a way to skip going from +antijuke to -antijuke? I tried to switch weapons, and it still dets my pipes.
__________________
GenghisTron is offline   Reply With Quote


Old 12-27-2009, 05:05 PM   #175
Dr.Satan
Wiki Team
Fortress Forever Staff
 
Dr.Satan's Avatar
 
Join Date: Sep 2007
Location: Greeley, CO
Class/Position: Med / Solly
Gametype: PAYLOAD
Affiliations: DET-
Posts Rated Helpful 19 Times
sorry I missed your above post or I could have done this for you along time ago, but no...once you start the script, you can't stop it afaik.
__________________
(Released) conc_school | hellion_classic | ksour_PAYLOAD | mulch_faf
(Beta) alchimy_b1
(Lua) base_payload_2015
(Models) props_trainyard
Support FF:
Dr.Satan is offline   Reply With Quote


Old 12-27-2009, 11:20 PM   #176
GenghisTron
AKA LittleAndroidMan
D&A Member
Beta Tester
 
GenghisTron's Avatar
 
Join Date: Sep 2007
Location: Dystopia
Class/Position: Demo/Medic
Gametype: CTF
Affiliations: [TALOS] [SR]
Posts Rated Helpful 11 Times
Oh well
__________________
GenghisTron is offline   Reply With Quote


Old 01-03-2010, 10:06 PM   #177
FF_MATT
bloody fire
 
Join Date: Mar 2009
Gametype: Capture the Flag
Affiliations: bloody fire, the babysitter, nadescout
Posts Rated Helpful 1 Times
cycle script

somethin so i can cycle grenades something like.........bind x to cycle between gren1 and gren2 to be binded to mouse 2........and have the opposite grenade binded to f......if ne of that makes sense ty tho
FF_MATT is offline   Reply With Quote


Old 01-04-2010, 09:20 AM   #178
Dr.Satan
Wiki Team
Fortress Forever Staff
 
Dr.Satan's Avatar
 
Join Date: Sep 2007
Location: Greeley, CO
Class/Position: Med / Solly
Gametype: PAYLOAD
Affiliations: DET-
Posts Rated Helpful 19 Times
Not sure which type of nade config you use, but here's both:

Code:
//this one is for the toggle nades (so pressing once primes and pressing again releases)
alias grenset1 "bind f toggleone; bind mouse2 toggletwo; wait alias 
grencycler grenset2"
alias grenset2 "bind f toggletwo; bind mouse2 toggleone; wait alias grencycler grenset1"
alias grencycler grenset1

bind x "grencycler"
Code:
//this one is for the default nades (pressing the key primes and if/when you release it, the nade goes)
alias grenset1 "bind f +gren1; bind mouse2 +gren2; wait alias 
grencycler grenset2"
alias grenset2 "bind f +gren2; bind mouse2 +gren1; wait alias grencycler grenset1"
alias grencycler grenset1

bind x "grencycler"
untested, but should do what your doing (though it is getting late )
__________________
(Released) conc_school | hellion_classic | ksour_PAYLOAD | mulch_faf
(Beta) alchimy_b1
(Lua) base_payload_2015
(Models) props_trainyard
Support FF:
Dr.Satan is offline   Reply With Quote


Old 01-05-2010, 02:02 AM   #179
FF_MATT
bloody fire
 
Join Date: Mar 2009
Gametype: Capture the Flag
Affiliations: bloody fire, the babysitter, nadescout
Posts Rated Helpful 1 Times
cycler

alias grenset1 "bind f +gren1; bind mouse2 +gren2; wait alias grencycler grenset2"
alias grenset2 "bind f +gren2; bind mouse2 +gren1; wait alias grencycler grenset1"
alias grencycler grenset1

bind x "grencycler"

hmm well i tried it it id doesent seem to be workin n less im doin sumthin rong .......i jus made a cfg called grencycler and jus hade it autoexec ..lmk and ty by the way
FF_MATT is offline   Reply With Quote


Old 01-06-2010, 08:44 AM   #180
immortal
BADASS
 
Join Date: Nov 2009
Location: Brazil
Class/Position: D Solly, O Med
Gametype: kill.conc.cap
Affiliations: [TALOS]
Posts Rated Helpful 0 Times
Quote:
Originally Posted by FF_MATT View Post
alias grenset1 "bind f +gren1; bind mouse2 +gren2; wait alias grencycler grenset2"
alias grenset2 "bind f +gren2; bind mouse2 +gren1; wait alias grencycler grenset1"
alias grencycler grenset1

bind x "grencycler"

hmm well i tried it it id doesent seem to be workin n less im doin sumthin rong .......i jus made a cfg called grencycler and jus hade it autoexec ..lmk and ty by the way
you should pick that script and copy into your autoexec.cfg
although i thought every "wait" command should be ended by a ";" but i'm obviously wrong since Satan is a Jedi on scripts
immortal is offline   Reply With Quote


Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 08:30 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.