ESReality - Where Gaming Meets Reality
Not Logged In | Login | Register
19:30 CDT - 448 users online
All Posts
QL macro parser for configs (2 comments)
Posted by epsy @ 21:46 CDT, 11 July 2010 - iMsg

This makes complex binds like toggles or menus easier by providing easy to use macros and a parser(1st link) to automatically convert them into what QL understands. QL should be able to save&restore configs enhanced with this.

The Help is worth a read, feel free to paste the examples into the online parser and test them on QL. There is also a full list of available macros at the end of it, the most prominent ones(toggle, menu, toggle_configs) being explained in detail.

Todo list
* Sensitivity calculation
* More recipes

Known bugs
None yet!

Example config - Don't forget to edit yourname

Please tell me about bugs or wishes you may have! If you host it or an edited version somewhere else, please say so I can put a link to it. If you use it and feel like sharing your config as example please say too :)
Edited by epsy at 13:27 CST, 30 January 2011 - 2383 Hits
QL config preparser macros (7 comments)
Posted by epsy @ 19:57 CST, 26 February 2010 - iMsg
There are many scripts commonly found in QL configs, and quite some of them use complex vstrs. Complex vstrs are often ugly, repetitive, unreadable and unmanageable. This makes it easy by using a first file where common scripts are abstracted in easy to use macros. This file is then preparsed to produce a .cfg you can use in QL.

Preparser? Macro?
A preparser is a program that will read a file(your config), do some changes then output a new file(your parsed config) with the changes done. The file is then supposed to be read by another program(Quake Live). In ASCII art:
Your config ----(preparser)----> Your preparsed config ---->(QL)
A macro is a concept used by some preparser programs. Defining a macro means saying "Okay, from now on, every time you see X, replace it with Y". Of course, it gets a bit more complex, but that's the basic thing.
When a parser uses the concept of macros, we call it a macro processor. More on wikipedia.

Why use that?
Because often you see patterns that are in every config out there: For example, if you play more than one mode, say CTF and TDM, you'd have binds for each of them, but you don't want to have them use twice the number of keys. So you use some vstr magic to make a couple buttons to switch through your two set of binds. That takes effort, isn't pretty, discourages people. With this set of macros you could just do:
bind F9 toggle_configs((
bind a say_team INC HIGH
bind a say_team RUSH QUAD
And you would be done with it :) Same goes for the streamer, the movie maker, which would want to keep a "Playing" config, a "Streaming" and/or a "Video" config.

How to edit my config
Basically, paste the contents of the attached file at the beginning of your config, and put .m4 at the end of the file name(To mark it needs to be preprocessed).
Edit the very beginning of the stuff you just pasted(it's explained), then keep your config intact only placing macros as shown in the examples from the Macro reference section. {} are used for quoting. Unmatched { or }s are likely to break the whole thing. if you really want to have them in your config, double them like this: {{ blabla }}.

How to preparse my config

Other notes
- Consider this beta-quality.
- QL should be able to save/restore properly a config generated with this(as long as you don't use exec in it) as long as you don't put a cvar_restart in it. (To clear unused cvars go to Game settings on the website and click Reset all my settings)
- Configs generated with this will have some parts seriously mangled, meaning editing it will be a difficult thing. So please, please, please, keep your non-preparsed config in a safe place.
- Make sure to use proper "" quotations in your bind and set line, especially if they are inside a toggle_configs.

Macro reference

Known issues
- toggle_config is very slow when being preprocessed.
- command splitting is suboptimal, as I don't know the maximum vstr length.

Example config
(If you have one you wanna put as example here, tell me :))

Sat Feb 27
- Initial release
Edited by Nicky at 12:55 CDT, 8 May 2010 - 16409 Hits
Quake Live Update Feb. 23rd (84 comments)
Posted by epsy @ 11:23 CST, 24 February 2010 - iMsg
Quake Live invites you to celebrate it's first year of public beta and brings an update along with a review of this first year of Quake Live. The update includes for the most part a new CTF map 'Fallout Bunker', advanced ingame settings menu and Bloom as a postprocessing effect.

Happy birthday Quake Live!

Update: Transparent "speconly" feature added for duel servers on Friday 26th.

Source: News entry, Change log, News entry for Friday mini-update
Related Links: ESR Forum topic "new 1 year" map
Edited by epsy at 09:25 CST, 27 February 2010 - 17431 Hits
America's best QL player (19 comments)
Posted by epsy @ 09:33 CST, 22 February 2010 - iMsg

(props to someone else for the pic)
3836 Hits
Next Page >>
Conceived and created by Sujoy Roy (Legal Notices)
RSS Feed Information, Link Buttons and Banners, Report a Bug