I'm going to shoot myself

Discussion for Bani's Tournament Mod

Moderators: Forum moderators, developers

Post Reply
Kami
Posts: 20
Joined: Fri May 14, 2004 1:04 pm
Location: Orlando, in the middle of America's wang.
Contact:

I'm going to shoot myself

Post by Kami »

I cannot get a vid_restart to automatically work with my individual autoexec_map.cfg's. Can anyone fill me in on what I can do? I've tried running vstr's in the cfg and in separate cfg's that are linked and can't seem to get it to (1) work or (2) not loop vid_restarts over and over again.

Please help this is driving me nuts. I thought it was impossible from playing with it before, but someone said that they had done it so I've been trying all day to no avail. I cannot seem to find the person who did it either.


Thanks to the Gurus who can help
User avatar
KingJackaL
Posts: 666
Joined: Thu Jan 08, 2004 3:47 pm
Location: ChCh, NZ
Contact:

Post by KingJackaL »

Post the .cfg already then...

(contents, and exact filename)
Kami
Posts: 20
Joined: Fri May 14, 2004 1:04 pm
Location: Orlando, in the middle of America's wang.
Contact:

Post by Kami »

It's rather simple:

r_mapover 2
r_over 1
r_ignore 1
vid_restart

that is first try, constant looping (remember diff. settings for each map)
second try:

r_mapover 2
r_over 1
r_ignore 1
exec vid

separate vid.cfg with following commands

set vid "vstr vid1"
set vid1 "set vid vstr vid2; vid_restart"
set vid2 "echo ^1No Restart I Hope; set vid vstr vid1"

vstr vid


No luck with that either????????????
User avatar
KingJackaL
Posts: 666
Joined: Thu Jan 08, 2004 3:47 pm
Location: ChCh, NZ
Contact:

Post by KingJackaL »

:o

where to start.... so many errors...

BTW, there are 'code' and 'quote' functions in forums for a reason - they make things MUCH more readable.


First Try

Code: Select all

r_mapover 2
r_over 1
r_ignore 1
vid_restart
It loops? Geez, I wonder why. Think about it dude. You load the map, then what happens? That's right, etpro exec's your map_default, which does a vid_restart. So ET loads the map again, then what happens? That's right, etpro exec's your map_default, which does a vid_restart. So ET loads the map again, then what happens? That's right, etpro exec's your map_default, which does a vid_restart. So ET loads the map again, then what happens? That's right, etpro exec's your map_default, which does a vid_restart. So ET loads the map again, then what happens? That's right, etpro exec's your map_default, which does a vid_restart. So ET loads the map again, then what happens? That's right, etpro exec's your map_default, which does a vid_restart. So ET loads the map again....

....getting the point here?

Second Try

Code: Select all

r_mapover 2
r_over 1
r_ignore 1
exec vid

Still a massive mess. Umm, some quick pointers:
r_mapover 2
Would be nice if there were a cvar 'r_mapover'. But there isn't. So WTF does this line do?

If you mean r_mapOverBrightBits, use r_mapOverBrightBits - the game isn't psychic.
r_over 1
Would be nice if there were a cvar 'r_over'. But there isn't. So WTF does this line do?

If you mean r_overBrightBits, use r_mapOverBrightBits - the game isn't psychic.
r_ignore 1
exec vid
These lines will work. :)

Code: Select all

set vid "vstr vid1"
set vid1 "set vid vstr vid2; vid_restart"
set vid2 "echo ^1No Restart I Hope; set vid vstr vid1"

vstr vid
This is actually correct, well done.
Kami
Posts: 20
Joined: Fri May 14, 2004 1:04 pm
Location: Orlando, in the middle of America's wang.
Contact:

Post by Kami »

KingJackaL wrote::o
If you mean r_overBrightBits, use r_mapOverBrightBits - the game isn't psychic.
I used shortened versions for my post since you knew what I meant. I apologize for this since I know you must have to answer even the dumbest questions and thought I actually used this in script. My settings work fine since I currently use F7 bound to vid_restart and everything is perfect. I however have been having a problem getting the vid_restart to work automatically.

I know the first example doesn't work and I know why. That is however what I tried first off. You can see I delved deeper into the problem but without any luck. What you refer to as correct at the end does not work for me. I will double check it though for typos if you say it will perform correctly.

Thank you for your time.
User avatar
KingJackaL
Posts: 666
Joined: Thu Jan 08, 2004 3:47 pm
Location: ChCh, NZ
Contact:

Post by KingJackaL »

It is syntactically correct. I didn't mention anything about it's semantics.

First, you'd want to define exactly what you want the script to do and when. I take it you want to:

exec several graphic cvars
do a single vid_restart

...at the start of each map change/load?
User avatar
hiro
Posts: 233
Joined: Wed Sep 24, 2003 5:17 pm
Location: au
Contact:

Post by hiro »

I understand what your trying to do, I'd also love to avoid the double restart for the maps that I prefer different levels of contrast and luminence on, but sadly I don't think it's gonna happen with a client-side tweak unless you can find a way to load the next map's autoexec before the previous map finishes.

My limited understanding of how the game works is that it simply won't look for the autoexec_mapname until it's loaded the map. I do not believe it is in ET Pro's capacity, or even of the quake 3 engine, to make certain video changes without restarting. perhaps someone can explain it technically to us noobs?

Surely you have an unused key such as insert or home that you can bind vid_restart to? yes, it is an extra button to press and it reduces the time you can spend running around knifing your teammates in warmup, but pressing buttons is what computer games are all about. :moo:
User avatar
KingJackaL
Posts: 666
Joined: Thu Jan 08, 2004 3:47 pm
Location: ChCh, NZ
Contact:

Post by KingJackaL »

hiro wrote:My limited understanding of how the game works is that it simply won't look for the autoexec_mapname until it's loaded the map. I do not believe it is in ET Pro's capacity, or even of the quake 3 engine, to make certain video changes without restarting. perhaps someone can explain it technically to us noobs?
Well, I'm an OpenGL coder, so I have a rough idea. I think it's because you have to reload everything if the changes you make are significant enough to alter drastically your memory usage (whether system or graphics subsystem or sound subsystem etc).

For example, the resolution effects the size of the framebuffer(s) so you'd need to re-allocate all your video card memory... and the best way to do that without totally killing performance is to re-load everything.

As to doing it before the map, that _should_ be possible, but I say that only theoretically - I have no idea which section of code would need to be altered, and whether or not the etpro team have the source for it (they don't have all the engine source IIRC). You'd just have to exec those changes when the server tells the client what map to load, THEN load the map. Sounds easy... I'm guessing that it's not quite so though.
Kami
Posts: 20
Joined: Fri May 14, 2004 1:04 pm
Location: Orlando, in the middle of America's wang.
Contact:

Post by Kami »

thnk you guys for your time. I don't mind the double load. I understand how etpro is limited right now in it's order of loading. I just want it to auto "reload" (if you will) after first load instead of me watching and waiting to press button at first chance. Then perhaps I could get up to grab a soda or something during the double load instead of waiting to press vid_restart after first load. I am sorry for the trouble, I had given up on this idea before but someone had mentioned they had accomplished it so I started trying again. I like to figure things out for myself instead of just doing what someone else tells me and not knowing why but I came to end of my rope with this situation.
Kami
Posts: 20
Joined: Fri May 14, 2004 1:04 pm
Location: Orlando, in the middle of America's wang.
Contact:

Post by Kami »

KingJackaL wrote: exec several graphic cvars
do a single vid_restart

...at the start of each map change/load?

Exactly. My settings exec fine, I just want it to vid_restart again after settings exec. So in this order:

Original map load(settings get exec'd here),
vid_restart (happens auto without me pushing a button),
start of game with hopefully 5 secs of warmup left.
User avatar
KingJackaL
Posts: 666
Joined: Thu Jan 08, 2004 3:47 pm
Location: ChCh, NZ
Contact:

Post by KingJackaL »

OK, I've got it working here. Your second solution, while closer... still doesn't quite make sense. First I'll explain why:

Code: Select all

set r_mode 4 //or whatever cvar's you want to set

set vid "vstr vid1"
set vid1 "set vid vstr vid2; vid_restart"
set vid2 "set vid vstr vid1"

vstr vid
The problem is, you're setting vid to 'vstr vid2' when you run this script through once.... but..... then ET reloads, and the script is re-run, and the first line after your cvar's re-set's vis to 'vstr vid1'. :)

Basically, it does the same stupid little circular game.

What you need to do is set up your toggle there in a script that doesn't get exec'd on every map start, but has global effect. Then you need to 'vstr vid' from the script that is exec'd on every map start!

Basically, put the following lines in your 'autoexec.cfg':

Code: Select all

set vid "vstr vid1"
set vid1 "set vid vstr vid2; vid_restart"
set vid2 "set vid vstr vid1"
And the following lines in your 'autoexec_default.cfg' (or any other mapname for map-specific commands):

Code: Select all

set r_mode 4 //or whatever cvar's you want to set

vstr vid
NOW what happens is, you have your toggle set up by the autoexec, and it STAYS THAT WAY. The autoexec doesn't get exec'd on every map load, so the instantiation of 'vid' won't get reset constantly. Your mapdefault script (autoexec_default.cfg - the etpro scripts) can still access those cvar's though, and will be able to use the toggle as you would expect.
User avatar
KingJackaL
Posts: 666
Joined: Thu Jan 08, 2004 3:47 pm
Location: ChCh, NZ
Contact:

Post by KingJackaL »

Oh, and BTW - re the "I'm going to shoot myself", they fixed that bug in etpro already... :lol:

(see here: http://bani.anime.net/banimod/forums/vi ... php?t=3344 )
Kami
Posts: 20
Joined: Fri May 14, 2004 1:04 pm
Location: Orlando, in the middle of America's wang.
Contact:

Post by Kami »

U soooooo F'in rock. I'll try this as soon as I can. Thank you so much for your time on this problem. Sad part is I even tried putting part of the script into my autoexec.cfg but not all of it. Sometimes it takes some fresh eyes and more likely a better understanding of the coding. Thanks.
User avatar
zero.TA
Posts: 30
Joined: Wed May 19, 2004 5:16 am
Location: UK
Contact:

Post by zero.TA »

Kami, I would have thought that you would have requested a Class Selector Script so u could play different classes rather than a Medic :wink:
Post Reply