|
|
(34 intermediate revisions by 10 users not shown) |
Line 1: |
Line 1: |
| == Overview ==
| | {{LanguageBar}} |
| [[Image:Developer-console.jpg|right]]
| |
| The developer console allows you to enter commands to the Source engine while testing a map or mod.
| |
|
| |
|
| Typing <code>[[help]]</code> will provide some instructions.
| | [[File:Developer-console.jpg|right]] |
|
| |
|
| Type <code>[[find]] <substring></code> to look for [[ConCommand|console command]]s or [[ConVar|console variables]] related to a specific topic (i.e. typing <code>find npc</code> would show a listing of [[NPC Debugging Command]]s such as [[npc_go]] and [[npc_create]].
| | == Présentation== |
| | La console de devellopement permet d'entrer des commandes dans le moteur Source afin de develloper sa map ou mods. |
|
| |
|
| == Introduction ==
| | Pour trouver une commande tapez <code>{{L|find}}</code> suivie d'un préfixe (voir plus bas). |
| The developer console is an essential tool for game developers for debugging their code and also for players to customize their settings. The console is a text-based input/output interface to execute commands or change global settings during runtime.
| | :Exemple pour trouver toutes les commandes en rapport avec le rendue vidéo : <code>find r</code>. |
|
| |
|
| == Enabling the console == | | == Activez la console == |
| To enable the console for use:
| | Dans le menu Steam, cliquez '''droite''' sur votre jeux, '''Propriétés''' et set '''launch option'''. Puis rentrez cette ligne : <code>-dev -console</code>. |
| | {{bug|hidetested=1|La fonction '''set consol lauch''' dans les option dans le jeux ne fonctionne pas.}} |
|
| |
|
| # Run the game/mod.
| | == Commandes consoles et variables == |
| # In the main menu click on ''Options''.
| | Il existe deux type de commandes : |
| # Click the ''Keyboard'' tab.
| | * {{L|Console Command List|Commandes consoles}} (ou ConCommand) |
| # Click the ''Advanced...'' button.
| | La commandes est executez mais ne reste pas en mémoire une fois le moteur fermer. |
| # Check the box next to ''Enable developer console (~)''.
| | * [http://developer.valvesoftware.com/wiki/Category:Console_Variables Commandes variables] (ou ConVar) |
| # Click ''Apply''.
| | Celle-ci garde en mémoire la valeurs. Elles n'ont qu'un seul paramètre, qui peut être un nombre ou une lettres(?). Beaucoup de console variables agissent comme des déclancheurs, 0 est désactivez et 1 activez. Pour voir leur état tapez juste la variable. |
|
| |
|
| Henceforth, the console can be opened or closed with the key located top left below <Escape>, typically labeled '''~''' ("tilde") on a US keyboard.
| | {{note|Certaines commandes on besoins que le mode Cheat soit activer, tapez la Convar <code>sv_cheats 1</code> dans la consol.}} |
|
| |
|
| {{note|The '''~''' key may not work on some keyboards, in which case you should right click on the game, and add <code>-console</code> in launch options. When the game has launched, the console should be open, enter <code>bind <key-you-want-to-use> toggleconsole</code>
| | == Préfixe : == |
| Replace <key-you-want-to-use> with the key you want to use. Eg:
| | La majorité des commandes on un préfixe, permettant de savoir à quelle types elle appartiennent et ainsi conaitre leur fonctions, mais ce n'est pas toujours le cas notemment pour des commandes venant directement du moteur HL1 Goldsource. |
| <code>bind t toggleconsole</code>
| |
|
| |
|
| You can also manually set another key by opening the ''cfg/config.cfg'' file of the game/mod and changing this line:
| | {| class=standard-table |
| <code>bind "<key-you-want-to-use>" "toggleconsole"</code>
| |
| German keyboard layout: To use the key left to '''1''' which reads '''^''', do <code>bind "\" "toggleconsole"</code>}}
| |
| | |
| The console is also enabled when the game executable is started with the <code>-dev</code> or <code>-console</code> parameters. (Developers should always start the game with <code>-dev</code>.)
| |
| | |
| If the Source Engine is started with an attached debugger, the console output is shown in your debug output window.
| |
| | |
| Starting HL with <code>-condebug</code> will also log all console output in the text file <code>console.log</code> located in your game directory.
| |
| | |
| == Entering commands ==
| |
| Commands are entered into the console by typing them in at the box at the bottom. After entering a new command, it is executed by hitting the <Return> key or pressing the ''Submit'' button.
| |
| | |
| A command has a unique name and an optional list of parameters where each parameter is separated by a <Space> character.
| |
| | |
| {{note|The <code>]</code> is a prompt, and is not typed.}} | |
| | |
| The syntax is: <code>command <parameter1> [<parameter2>]</code>. For example:
| |
| | |
| <pre>
| |
| ]bind mouse1 +attack
| |
| ]map dm_lockdown
| |
| </pre>
| |
| | |
| If a command parameter contains <Space> characters, it must be encapsulated in quotes:
| |
| | |
| <pre>
| |
| ]bind h "say hello world"
| |
| ]name "Gordon Freeman"
| |
| </pre>
| |
| | |
| The console stores the last executed commands in a command history that is accessible with <UpArrow> (goes to the command you just/last entered) and <DownArrow> (goes to the very first command that you entered into the console) keys. You can auto complete a command by pressing <Tab> and choose from a list of available commands if the console found multiple matches. Some commands (e.g. <code>map</code>, <code>load</code> etc) support auto completion for the first parameter too.
| |
| | |
| == Commands and variables == | |
| The console differs between console commands and console variables.
| |
| | |
| ''Console commands'' usually pass the parameters to some code function and execute it, but they don't remember these parameters.
| |
| | |
| ''Console variables'' store the last parameters like a global setting. Console variables can only have one parameter, which can be a number or string; it depends on the game code how these values are interpreted. A lot of console variables act like triggers, 0 usually means off and 1 means on (e.g. <code>cl_showfps</code>). To see the current value of a console variable just type the name without any parameters.
| |
| | |
| Most console commands and variables have prefixes in their name to show the subsystem they belong to, but this isn't always the case, especially for commands coming from Half-Life 1, where the old name was kept unchanged.
| |
| | |
| Commonly used console command prefixes are:
| |
| {|
| |
| | <code>ai_</code> || single player AI | | | <code>ai_</code> || single player AI |
| |- | | |- |
Line 135: |
Line 91: |
| |- | | |- |
| | <code>wc_</code> || WorldCraft/Hammer helpers | | | <code>wc_</code> || WorldCraft/Hammer helpers |
| |} | | |} |
| | | {{ACategory|Source_SDK_FAQ}} |
| If you forgot the exact name of a command or variable, <code>find <substring></code> shows all commands containing a given substring.
| | {{ACategory|Modding}} |
| | | {{ACategory|Dedicated Server}} |
| The command <code>help <command></code> shows help text for a given command (if available).
| |
| | |
| == Entering cheats into the console==
| |
| If you wish to enter a cheat such as [[impulse| impulse 101]] then you would need to have already typed in [[sv_cheats| sv_cheats 1]]. This enables the cheats to be typed in. To turn cheats off simply type in [[sv_cheats| sv_cheats 0]].
| |
| | |
| == See also ==
| |
| * [[Console Command List]] - A complete list of console commands and variables.
| |
| * [[:Category:Console Commands]] - A list of articles on console commands.
| |
| * [[:Category:Console Variables]] - A list of articles on console variables.
| |
| | |
| {{otherlang:en}}
| |
| {{otherlang:en:es|Developer Console:es}},
| |
| {{otherlang:en:jp|Developer Console:jp}}, | |
| {{otherlang:en:pl|Developer Console:pl}}, | |
| {{otherlang:en:ru|Developer Console:ru}}, | |
| {{otherlang:en:zh-tw|Developer Console:zh-tw}}
| |
| | |
| [[Category:Level Design]]
| |
| [[Category:Programming]]
| |
This translated page needs to be updated.You can help by updating the translation.
Also, please make sure the article complies with the
alternate languages guide.(en)This notice is put here by LanguageBar template and if you want to remove it after updating the translation you can do so on
this page.
Présentation
La console de devellopement permet d'entrer des commandes dans le moteur Source afin de develloper sa map ou mods.
Pour trouver une commande tapez find(en)
suivie d'un préfixe (voir plus bas).
- Exemple pour trouver toutes les commandes en rapport avec le rendue vidéo :
find r
.
Activez la console
Dans le menu Steam, cliquez droite sur votre jeux, Propriétés et set launch option. Puis rentrez cette ligne : -dev -console
.
Commandes consoles et variables
Il existe deux type de commandes :
La commandes est executez mais ne reste pas en mémoire une fois le moteur fermer.
Celle-ci garde en mémoire la valeurs. Elles n'ont qu'un seul paramètre, qui peut être un nombre ou une lettres(?). Beaucoup de console variables agissent comme des déclancheurs, 0 est désactivez et 1 activez. Pour voir leur état tapez juste la variable.
Note:Certaines commandes on besoins que le mode Cheat soit activer, tapez la Convar sv_cheats 1
dans la consol.
Préfixe :
La majorité des commandes on un préfixe, permettant de savoir à quelle types elle appartiennent et ainsi conaitre leur fonctions, mais ce n'est pas toujours le cas notemment pour des commandes venant directement du moteur HL1 Goldsource.
ai_ |
single player AI
|
bot_ |
bot system
|
cc_ |
close caption system
|
cl_ |
multiplayer client
|
demo_ |
demo playback
|
disp_ |
terrain displacement maps
|
dsp_ |
audio DSP settings
|
ent_ |
entity control/debug
|
fire_ |
firing entity events
|
fog_ |
fog renderer
|
g_ |
single player game
|
hltv_ |
Half-Life TV
|
host_ |
host system
|
hud_ |
client HUD
|
joy_ |
joystick input
|
log_ |
logging system
|
m_ |
mouse input
|
mat_ |
material system
|
mp_ |
multiplayer game (server)
|
nav_ |
navigation graphs
|
net_ |
engine networking
|
npc_ |
single player game NPCs
|
phys_ |
physics system
|
r_ |
video renderer
|
rcon_ |
remote control access
|
sk_ |
player skill / difficulty
|
snd_ |
sound system
|
sv_ |
server settings (engine)
|
v_ |
client view
|
vgui_ |
VGUI
|
voice_ |
ingame player voice
|
vprof_ |
code profiler
|
wc_ |
WorldCraft/Hammer helpers
|