Enable the console window in the game options, then, press ~ and type in the code you want in the console window to activate what the code does.