Getting Autoexec to bind controls once

Archive of the old editing forum
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Locked
skadoomer
Posts: 1026
Joined: Fri Sep 05, 2003 12:49 pm

Getting Autoexec to bind controls once

Post by skadoomer »

I've got an autoexec file that re-binds doom's standard controls to a more modern WSAD format. The problem with autoexec though is that I'm unbinding all commands and manually re-binding them to eliminate all non necessary keys (this is to help some beta testers with what is a necessary control and what isn't). The problem is if any of them change the keys to something else, its get over-ridden the next time they launch zdoom. Does anyone have any suggestions of how to get autoexec to re-write the default commands if a user doesn't have a config, but ignore all re-binds if they do? I didn't see any indication that If / else statements are supported in the console, but is there any way to do something with eval?
User avatar
Siggi
Posts: 3288
Joined: Sun Oct 03, 2004 8:57 am
Preferred Pronouns: They/Them
Location: South Africa

Re: Getting Autoexec to bind controls once

Post by Siggi »

If you're shipping your mod bundled with a copy of ZDoom, then you can include your own custom copy of zdoom.ini.
zdoom.ini is what is loaded when no config is found, so on the first run all its settings will be used instead of ZDoom's defaults.
skadoomer
Posts: 1026
Joined: Fri Sep 05, 2003 12:49 pm

Re: Getting Autoexec to bind controls once

Post by skadoomer »

Is there is a pullin command like there is for wad files to make loading a configuration easier, or am i limited to specifying the file at startup?
Locked

Return to “Editing (Archive)”