urc field auto press enter?

Post your scripting questions / solutions here

Moderator: Moderators

Post Reply
Elgan
Site Admin
Posts: 890
Joined: Tue Apr 13, 2004 10:43 pm
Location: uk
Contact:

urc field auto press enter?

Post by Elgan »

to exec the stuff command in a field class in a urc menu you have to press enter. Can any1 think of a way this could be bypassed so it would exec the stuffcmd with the linkcvar?
eg

set lol "HI"
linkcvar "lol"

then in the field stuffcommand "say "

then as soon as we see the field it would do "say hi" in console?

ive tried showcommand but it just makes the message box open.

EDIT: even better if any1 cud think of a way to add 2 cvars together?

cmd append adds a string to a cvar:(.

also what does touchfile do?
Rookie One.pl
Site Admin
Posts: 2752
Joined: Fri Jan 31, 2003 7:49 pm
Location: Nowa Wies Tworoska, Poland
Contact:

Post by Rookie One.pl »

I don't really get what you mean... :?
Admin
Image
Image
Honour guide me.

here's my stuff - inequation.org | here's where I work - thefarm51.com
Elgan
Site Admin
Posts: 890
Joined: Tue Apr 13, 2004 10:43 pm
Location: uk
Contact:

Post by Elgan »

well how cud u add 2 cvars together in console ?

using a field of urc menu u can stufcmd and it will auto add the cvar to the end. this is gr8! if u didnt have to press enter to activate it.

so i want to know how to add 2 cvars together or alias and cvars or anything!
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

I don't think you can do what you want just from a urc I think you need a script running also . What is wrong with pressing enter by the way ? I mean you have to type into the box anyway so I don't get it .
Image
Elgan
Site Admin
Posts: 890
Joined: Tue Apr 13, 2004 10:43 pm
Location: uk
Contact:

Post by Elgan »

bdbodger wrote:I don't think you can do what you want just from a urc I think you need a script running also . What is wrong with pressing enter by the way ? I mean you have to type into the box anyway so I don't get it .
i would like ot be able to add 2 cvars in console but then thought maybe a urc cud be used to do it. I want the server to be doing the work not the client. So it does it without the cleint knowing. but nm.
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

Well a script and menu can do it but don't think you can do it with a menu alone but I maybe wrong .
Image
Elgan
Site Admin
Posts: 890
Joined: Tue Apr 13, 2004 10:43 pm
Location: uk
Contact:

Post by Elgan »

bdbodger wrote:Well a script and menu can do it but don't think you can do it with a menu alone but I maybe wrong .
not for the server though.

the menu wud be on the client the script on serv. the menu i just thought might add cvars together and then the script can use that. client cvars. the server cant get those. but we cant add cvars together and we cant make a menu do something without some sort of interaction so nm
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

ok now I see what you are trying to do .
Image
Elgan
Site Admin
Posts: 890
Joined: Tue Apr 13, 2004 10:43 pm
Location: uk
Contact:

Post by Elgan »

bdbodger wrote:ok now I see what you are trying to do .
hehe cool! . but i havnt found a way:(. would of been nice
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

It has been tried before but not done . Closest anyone has come is JV's morse code to get input from a client useing a menu . Tltrude tried it once too but didn't find a way . maybe do a search but not a good way to do it and buggy .
Image
Elgan
Site Admin
Posts: 890
Joined: Tue Apr 13, 2004 10:43 pm
Location: uk
Contact:

Post by Elgan »

ok nm and i thought my state thingy was nicer then jv's morce code. no offence:D
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

Probably is better the morse code idea sorta worked but not very well . No way to do it with out a download of your state file as well I guess but I don't know much about state file mods but I think that way would work a lot better .
Image
Elgan
Site Admin
Posts: 890
Joined: Tue Apr 13, 2004 10:43 pm
Location: uk
Contact:

Post by Elgan »

they are server side.

i am not able to get this to work :(. But i can get the admins stuff.

i wont eb able to get the info wihtout client input soo. on my admin men u thing im planning to make it will have setting "free" or login and when selected to login u have to login and set what if u are instead of the script doing it for u:(. the field linked ot a cvar will send the info to the server:).

the script will then println so people know who did what using the menu by looking at the logfile.
Post Reply