commandline keybinds question

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Post Reply
User avatar
krutomisi
Posts: 24
Joined: Mon Jan 11, 2021 10:17 am

commandline keybinds question

Post by krutomisi »

trying to launch gzdoom via commandline and bind a key at the same time

gzdoom.exe +bind q +example

it is reading the plus on the keybind as a new command, cannot figure out how to escape it
quotes appear to be ignored and anything else gets tacked onto the keybind breaking it
Attachments
img01.PNG
img01.PNG (15.82 KiB) Viewed 231 times
User avatar
Player701
 
 
Posts: 1710
Joined: Wed May 13, 2009 3:15 am
Graphics Processor: nVidia with Vulkan support
Contact:

Re: commandline keybinds question

Post by Player701 »

This definitely works for me:

Code: Select all

gzdoom.exe +"bind q +example"
I'm not sure if it'll work in every other case, though. Better create an autoexec.cfg and add your commands there.
User avatar
krutomisi
Posts: 24
Joined: Mon Jan 11, 2021 10:17 am

Re: commandline keybinds question

Post by krutomisi »

ah thanks! I didn't think to put the quotes around the entire string

just realized I can store the commands in a .cfg and pull it in with +exec file.cfg that would be much less messy
Post Reply

Return to “Scripting”