mirror of
https://github.com/nzp-team/quakec.git
synced 2024-11-22 20:01:34 +00:00
217 lines
20 KiB
INI
217 lines
20 KiB
INI
|
optimisation t default # c = a*b is performed in one operation rather than two, and can
|
|||
|
# cause older decompilers to fail.
|
|||
|
optimisation i default # if (!a) was traditionally compiled in two statements. This optimisation
|
|||
|
# does it in one, but can cause some decompilers to get confused.
|
|||
|
optimisation p default # In the original qcc, function parameters were specified as a vector
|
|||
|
# store even for floats. This fixes that.
|
|||
|
optimisation c default # This optimisation strips out the names of constants (but not strings)
|
|||
|
# from your progs, resulting in smaller files. It makes decompilers
|
|||
|
# leave out names or fabricate numerical ones.
|
|||
|
optimisation cs default # This optimisation strips out the names of string constants from
|
|||
|
# your progs. However, this can break addons, so don't use it in
|
|||
|
# those cases.
|
|||
|
optimisation d default # This will merge definitions of constants which are the same value.
|
|||
|
# Pay extra attention to assignment to constant warnings.
|
|||
|
optimisation s default # This will compact the string table that is stored in the progs.
|
|||
|
# It will be considerably smaller with this.
|
|||
|
optimisation l default # Strips out local names and definitions. Most decompiles will break
|
|||
|
# on this.
|
|||
|
optimisation n default # This strips out the names of functions which are never called.
|
|||
|
# Doesn't make much of an impact though.
|
|||
|
optimisation f default # This strips out the filenames of the progs. This can confuse the
|
|||
|
# really old decompilers, but is nothing to the more recent ones.
|
|||
|
optimisation u default # Removes the entries of unreferenced variables. Doesn't make a
|
|||
|
# difference in well maintained code.
|
|||
|
optimisation r default # Optimises the pr_globals count by overlapping temporaries. In
|
|||
|
# QC, every multiplication, division or operation in general produces
|
|||
|
# a temporary variable. This optimisation prevents excess, and in
|
|||
|
# the case of Hexen2's gamecode, reduces the count by 50k. This
|
|||
|
# is the most important optimisation, ever.
|
|||
|
optimisation a default # 5*6 actually emits an operation into the progs. This prevents
|
|||
|
# that happening, effectivly making the compiler see 30
|
|||
|
optimisation pf default # Strip out stuff wasted used in function calls and strings to the
|
|||
|
# precache_file builtin (which is actually a stub in quake).
|
|||
|
optimisation ro default # Functions ending in a return statement do not need a done statement
|
|||
|
# at the end of the function. This can confuse some decompilers,
|
|||
|
# making functions appear larger than they were.
|
|||
|
optimisation cj default # This optimisation plays an effect mostly with nested if/else statements,
|
|||
|
# instead of jumping to an unconditional jump statement, it'll jump
|
|||
|
# to the final destination instead. This will bewilder decompilers.
|
|||
|
optimisation sf default # Strips out the 'defs' of functions that were only ever called
|
|||
|
# directly. This does not affect saved games. This can affect FTE_MULTIPROGS.
|
|||
|
optimisation lo default # Store all locals in a single section of the pr_globals. Vastly
|
|||
|
# reducing it. This effectivly does the job of overlaptemps.
|
|||
|
# However, locals are no longer automatically initialised to 0 (and
|
|||
|
# never were in the case of recursion, but at least then its the
|
|||
|
# same type).
|
|||
|
# If locals appear uninitialised, fteqcc will disable this optimisation
|
|||
|
# for the affected functions, you can optionally get a warning about
|
|||
|
# these locals using: #pragma warning enable F302
|
|||
|
optimisation vc default # Where a function is called with just a vector, this causes the
|
|||
|
# function call to store three floats instead of one vector. This
|
|||
|
# can save a good number of pr_globals where those vectors contain
|
|||
|
# many duplicate coordinates but do not match entirly.
|
|||
|
optimisation cf default # Strip class field names. This will harm debugging and can result
|
|||
|
# in 'gibberish' names appearing in saved games. Has no effect on
|
|||
|
# engines other than FTEQW, which will not recognise these anyway.
|
|||
|
keyword asm true # Disables the 'asm' keyword. Use the writeasm flag to see an example
|
|||
|
# of the asm.
|
|||
|
keyword break true # Disables the 'break' keyword.
|
|||
|
keyword case true # Disables the 'case' keyword.
|
|||
|
keyword class true # Disables the 'class' keyword.
|
|||
|
keyword const true # Disables the 'const' keyword.
|
|||
|
keyword continue true # Disables the 'continue' keyword.
|
|||
|
keyword default true # Disables the 'default' keyword.
|
|||
|
keyword entity true # Disables the 'entity' keyword.
|
|||
|
keyword enum true # Disables the 'enum' keyword.
|
|||
|
keyword enumflags true # Disables the 'enumflags' keyword.
|
|||
|
keyword extern true # Disables the 'extern' keyword. Use only on functions inside addons.
|
|||
|
keyword float true # Disables the 'float' keyword. (Disables the float keyword without
|
|||
|
# 'local' preceeding it)
|
|||
|
keyword for true # Disables the 'for' keyword. Syntax: for(assignment; while; increment)
|
|||
|
# {codeblock;}
|
|||
|
keyword goto true # Disables the 'goto' keyword.
|
|||
|
keyword int true # Disables the 'int' keyword.
|
|||
|
keyword integer true # Disables the 'integer' keyword.
|
|||
|
keyword noref true # Disables the 'noref' keyword.
|
|||
|
keyword unused false # Disables the 'unused' keyword. 'unused' means that the variable
|
|||
|
# is unused, you're aware that its unused, and you'd rather not
|
|||
|
# know about all the warnings this results in.
|
|||
|
keyword used false # Disables the 'used' keyword. 'used' means that the variable is
|
|||
|
# used even if the qcc can't see how - thus preventing it from ever
|
|||
|
# being stripped.
|
|||
|
keyword static true # Disables the 'static' keyword. 'static' means that a variable
|
|||
|
# has altered scope. On globals, the variable is visible only to
|
|||
|
# the current .qc file. On locals, the variable's value does not
|
|||
|
# change between calls to the function. On class variables, specifies
|
|||
|
# that the field is a scoped global instead of a local. On class
|
|||
|
# functions, specifies that 'this' is expected to be invalid and
|
|||
|
# that the function will access any memembers via it.
|
|||
|
keyword nonstatic true # Disables the 'nonstatic' keyword. 'nonstatic' acts upon globals+functions,
|
|||
|
# reverting the defaultstatic pragma on a per-variable basis. For
|
|||
|
# use by people who prefer to keep their APIs explicit.
|
|||
|
keyword ignore false # Disables the 'ignore' keyword. 'ignore' is expected to typically
|
|||
|
# be hidden behind a 'csqconly' define, and in such a context can
|
|||
|
# be used to conditionally compile functions a little more gracefully.
|
|||
|
# The opposite of the 'used' keyword. These variables/functions/members
|
|||
|
# are ALWAYS stripped, and effectively ignored.
|
|||
|
keyword nosave true # Disables the 'nosave' keyword.
|
|||
|
keyword inline true # Disables the 'inline' keyword.
|
|||
|
keyword strip true # Disables the 'strip' keyword.
|
|||
|
keyword shared true # Disables the 'shared' keyword.
|
|||
|
keyword state false # Disables the 'state' keyword.
|
|||
|
keyword optional true # Disables the 'optional' keyword.
|
|||
|
keyword inout false # Disables the 'inout' keyword.
|
|||
|
keyword string true # Disables the 'string' keyword.
|
|||
|
keyword struct true # Disables the 'struct' keyword.
|
|||
|
keyword switch true # Disables the 'switch' keyword.
|
|||
|
keyword thinktime false # Disables the 'thinktime' keyword which is used in HexenC
|
|||
|
keyword until false # Disables the 'until' keyword which is used in HexenC
|
|||
|
keyword loop false # Disables the 'loop' keyword which is used in HexenC
|
|||
|
keyword typedef true # Disables the 'typedef' keyword.
|
|||
|
keyword union true # Disables the 'union' keyword.
|
|||
|
keyword var true # Disables the 'var' keyword.
|
|||
|
keyword vector true # Disables the 'vector' keyword.
|
|||
|
keyword wrap true # Disables the 'wrap' keyword.
|
|||
|
keyword weak true # Disables the 'weak' keyword.
|
|||
|
flag kce true # If you want keywords to NOT be disabled when they a variable by
|
|||
|
# the same name is defined, check here.
|
|||
|
flag parms false # if PARM0 PARM1 etc should be defined by the compiler. These are
|
|||
|
# useful if you make use of the asm keyword for function calls,
|
|||
|
# or you wish to create your own variable arguments. This is an
|
|||
|
# easy way to break decompilers.
|
|||
|
flag autoproto false # Causes compilation to take two passes instead of one. The first
|
|||
|
# pass, only the definitions are read. The second pass actually
|
|||
|
# compiles your code. This means you never have to remember to prototype
|
|||
|
# functions again.
|
|||
|
flag wasm false # Writes out a qc.asm which contains all your functions but in assembler.
|
|||
|
# This is a great way to look for bugs in fteqcc, but can also be
|
|||
|
# used to see exactly what your functions turn into, and thus how
|
|||
|
# to optimise statements better.
|
|||
|
flag annotate false # Annotate source code with assembler statements on compile (requires
|
|||
|
# gui).
|
|||
|
flag nullemptystr false # Empty string immediates will have the raw value 0 instead of 1.
|
|||
|
flag ifstring false # Causes if(string) to behave identically to if(string!=) This is
|
|||
|
# most useful with addons of course, but also has adverse effects
|
|||
|
# with FRIK_FILE's fgets, where it becomes impossible to determin
|
|||
|
# the end of the file. In such a case, you can still use asm {IF
|
|||
|
# string 2;RETURN} to detect eof and leave the function.
|
|||
|
flag iffloat false # Fixes certain floating point logic.
|
|||
|
flag ifvector true # Fixes conditional vector logic.
|
|||
|
flag vectorlogic true # Fixes conditional vector logic.
|
|||
|
flag brokenarray false # Treat references to arrays as references to the first index of
|
|||
|
# said array, to replicate an old fteqcc bug.
|
|||
|
flag rootconstructor false # When enabled, the root constructor should be called first like
|
|||
|
# in c++.
|
|||
|
flag acc false # Reacc is a pascall like compiler. It was released before the Quake
|
|||
|
# source was released. This flag has a few effects. It sorts all
|
|||
|
# qc files in the current directory into alphabetical order to compile
|
|||
|
# them. It also allows Reacc global/field distinctions, as well
|
|||
|
# as allows <20> as EOF. Whilst case insensitivity and lax type checking
|
|||
|
# are supported by reacc, they are seperate compiler flags in fteqcc.
|
|||
|
flag caseinsens false # Causes fteqcc to become case insensitive whilst compiling names.
|
|||
|
# It's generally not advised to use this as it compiles a little
|
|||
|
# more slowly and provides little benefit. However, it is required
|
|||
|
# for full reacc support.
|
|||
|
flag lax false # Disables many errors (generating warnings instead) when function
|
|||
|
# calls or operations refer to two normally incompatible types.
|
|||
|
# This is required for reacc support, and can also allow certain
|
|||
|
# (evil) mods to compile that were originally written for frikqcc.
|
|||
|
flag hashonly false # Allows use of only #constant for precompiler constants, allows
|
|||
|
# certain preqcc using mods to compile
|
|||
|
flag lo false # This changes the behaviour of your code. It generates additional
|
|||
|
# if operations to early-out in if statements. With this flag, the
|
|||
|
# line if (0 && somefunction()) will never call the function. It
|
|||
|
# can thus be considered an optimisation. However, due to the change
|
|||
|
# of behaviour, it is not considered so by fteqcc. Note that due
|
|||
|
# to inprecisions with floats, this flag can cause runaway loop
|
|||
|
# errors within the player walk and run functions (without iffloat
|
|||
|
# also enabled). This code is advised:
|
|||
|
# player_stand1:
|
|||
|
# if (self.velocity_x || self.velocity_y)
|
|||
|
# player_run
|
|||
|
# if (!(self.velocity_x || self.velocity_y))
|
|||
|
flag msvcstyle false # Generates warning and error messages in a format that msvc understands,
|
|||
|
# to facilitate ide integration.
|
|||
|
flag debugmacros false # Print out the contents of macros that are expanded. This can help
|
|||
|
# look inside macros that are expanded and is especially handy if
|
|||
|
# people are using preprocessor hacks.
|
|||
|
flag filetimes false # Recompiles the progs only if the file times are modified.
|
|||
|
flag fastarrays false # Generates extra instructions inside array handling functions to
|
|||
|
# detect engine and use extension opcodes only in supporting engines.
|
|||
|
# Adds a global which is set by the engine if the engine supports
|
|||
|
# the extra opcodes. Note that this applies to all arrays or none.
|
|||
|
flag assumeint false # Numerical constants are assumed to be integers, instead of floats.
|
|||
|
flag subscope false # Restrict the scope of locals to the block they are actually defined
|
|||
|
# within, as in C.
|
|||
|
flag verbose false # Lots of extra compiler messages.
|
|||
|
flag typeexplicit false # All type conversions must be explicit or directly supported by
|
|||
|
# instruction set.
|
|||
|
flag noboundchecks false # Disable array index checks, speeding up array access but can result
|
|||
|
# in your code misbehaving.
|
|||
|
flag qccx false # WARNING: This syntax makes mods inherantly engine specific.
|
|||
|
# Do NOT use unless you know what you're doing.This is provided
|
|||
|
# for compatibility only
|
|||
|
# Any entity hacks will be unsupported in FTEQW, DP, and others,
|
|||
|
# resulting in engine crashes if the code in question is executed.
|
|||
|
flag embedsrc false # Write the sourcecode into the output file.
|
|||
|
showall off # Show all keyword options in the gui
|
|||
|
compileonstart off # Recompile on GUI startup
|
|||
|
log off # Write out a compile log
|
|||
|
enginebinary fteglqw.exe # Location of the engine binary to run. Change this to something
|
|||
|
# else to run a different engine, but not all support debugging.
|
|||
|
basedir ../.. # The base directory of the game that contains your sub directory
|
|||
|
engineargs "-window -nohome -game game"
|
|||
|
# The engine commandline to use when debugging. You'll likely want
|
|||
|
# to ensure this contains -window as well as the appropriate -game
|
|||
|
# argument.
|
|||
|
srcfile progs.src # The progs.src file to load to find ordering of other qc files.
|
|||
|
src # Additional subdir to read qc files from. Typically blank (ie:
|
|||
|
# the working directory).
|
|||
|
extramargins off # Enables line number and folding margins.
|
|||
|
hexen2 off # Enable the extra tweaks needed for compatibility with hexen2 engines.
|
|||
|
extendedopcodes off # Utilise an extended instruction set, providing support for pointers
|
|||
|
# and faster arrays and other speedups.
|
|||
|
parameters # Other additional parameters that are not supported by the gui.
|
|||
|
# Likely including -DFOO
|