Difference between revisions of "AutoExec"

From WolfWiki
Jump to: navigation, search
(corrected autoexec launch mixup)
(fix autoexec usage, case)
 
Line 1: Line 1:
 
== Default AutoExec ==
 
== Default AutoExec ==
  
When connecting to any server, the client will look for the file ''AutoExec.cfg'' in the base folder of whatever mod the '''client''' is running, in ETPro's case this would be ''\Wolfenstein - Enemy Territory\etpro\'' and if found that file will be launched. It is advised that you start up the client with the mod of the server you are connecting to. This is especially true if you have a different config for each mod.
+
When started, ET attempts to load and the file ''autoexec.cfg''. If you start with <tt>+set fs_game <mod directory></tt> ET looks in the fs_game directory first. Some external server browsers may do this for you when you connect to a server that is running a mod.
  
This is often used to store important settings that would normally be in your ''ETConfig.cfg'' file, as if the server forces a cvar to a value that does not match what you set the cvar's value to in your ETConfig.cfg file then that value will then be changed in your config file.
+
This is often used to store important settings that would normally be in your ''etconfig.cfg'' file, as if the server forces a cvar to a value that does not match what you set the cvar's value to in your etconfig.cfg file then that value will then be changed in your config file.
  
However if you store the cvar setting in your AutoExec.cfg file, then even if a server changes the cvar value, the next time you connect to a server the original setting you chose will be used again.
+
However if you store the cvar setting in your autoexec.cfg file, then even if a server changes the cvar value, the next time you connect to a server the original setting you chose will be used again.
  
 
== Client Auto Map Scripts ==
 
== Client Auto Map Scripts ==

Latest revision as of 04:51, 28 April 2006

Default AutoExec

When started, ET attempts to load and the file autoexec.cfg. If you start with +set fs_game <mod directory> ET looks in the fs_game directory first. Some external server browsers may do this for you when you connect to a server that is running a mod.

This is often used to store important settings that would normally be in your etconfig.cfg file, as if the server forces a cvar to a value that does not match what you set the cvar's value to in your etconfig.cfg file then that value will then be changed in your config file.

However if you store the cvar setting in your autoexec.cfg file, then even if a server changes the cvar value, the next time you connect to a server the original setting you chose will be used again.

Client Auto Map Scripts

When a map loads or restarts, the client will look for the following scripts and run them if found:

  • autoexec_mapname.cfg
  • autoexec_default.cfg

For example if the map rotates to battery, the client would look for autoexec_battery.cfg and run it. If autoexec_battery.cfg is not found, it would try to run autoexec_default.cfg instead.

Client Auto Team/Class Scripts

When players spawn with a changed team or class, the client will look for the following scripts and run them if found:

  • autoexec_axis.cfg
  • autoexec_allies.cfg
  • autoexec_spectator.cfg
  • autoexec_soldier.cfg
  • autoexec_medic.cfg
  • autoexec_engineer.cfg
  • autoexec_fieldops.cfg
  • autoexec_covertops.cfg

These are only run when the team or class changes, they are not run on every spawn.