Game specific autoexec.cfg

Discuss anything ZDoom-related that doesn't fall into one of the other categories.
Post Reply
Hypersonic
Posts: 134
Joined: Mon Aug 14, 2017 3:04 pm

Game specific autoexec.cfg

Post by Hypersonic »

I want to use this for Doom 1&2

bind kp1 "slot 1"
bind kp2 "slot 2"
bind kp3 "use shotgun"
bind kp4 "slot 4"
bind kp5 "slot 5"
bind kp6 "slot 6"
bind kp7 "slot 7"
bind kp8 "use supershotgun"
bind kp9 "slot 9"

I want to use this for Heretic 1 (swaps 5/6 to be consistent with Doom)

bind kp1 "slot 1"
bind kp2 "slot 2"
bind kp3 "slot 3"
bind kp4 "slot 4"
bind kp5 "slot 6"
bind kp6 "slot 5"
bind kp7 "slot 7"
bind kp8 "slot 8"
bind kp9 "slot 9"

Currently there appears to be one autoexec.cfg that execs for all games.
Nevander
Posts: 2254
Joined: Mon Jan 06, 2014 11:32 pm

Re: Game specific autoexec.cfg

Post by Nevander »

Put both in the same folder but rename one to something else like "autoexec_h.cfg" or "autoexec_d.cfg" depending on which game you are not currently going to play. When you want to switch, rename the one in use to _d or _h and then rename the other to just autoexec.

Or better yet, keep your bindings for Doom and then make a copy of your INI file. Then load up Heretic and change them to your Heretic preferences. Make a copy of that. Name them something like cfg_doom.ini and cfg_heretic.cfg. Then you can use -config in command line to run with game-specific INIs and ditch autoexec.
User avatar
Rachael
Posts: 13530
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: Game specific autoexec.cfg

Post by Rachael »

Erm - there's provisions in gzdoom.ini specifically for this kind of thing... but you have to put them in...

Code: Select all

[Doom.AutoExec]
Path=$PROGDIR/autoexec-doom.cfg
Path=$PROGDIR/autoexec.cfg

[Heretic.AutoExec]
Path=$PROGDIR/autoexec-heretic.cfg
Path=$PROGDIR/autoexec.cfg

[Hexen.AutoExec]
Path=$PROGDIR/autoexec-hexen.cfg
Path=$PROGDIR/autoexec.cfg

[Strife.AutoExec]
Path=$PROGDIR/autoexec-strife.cfg
Path=$PROGDIR/autoexec.cfg
... etc

Just add the lines like above to each game you want to do that with, and you will have game-specific autoexecs.
Hypersonic
Posts: 134
Joined: Mon Aug 14, 2017 3:04 pm

Re: Game specific autoexec.cfg

Post by Hypersonic »

Thanks for the info on the autoexec in the ini file, that seems to be the simplest way to go. I'll try that out.

EDIT: works great, thanks!
Nevander
Posts: 2254
Joined: Mon Jan 06, 2014 11:32 pm

Re: Game specific autoexec.cfg

Post by Nevander »

Rachael wrote:Erm - there's provisions in gzdoom.ini specifically for this kind of thing... but you have to put them in...
Oh. :oops:

I've never really used those sections so that's why they slipped my mind.
Post Reply

Return to “General”