Cheating is important for developers. It allows us to bypass monsters, so we can get to where we need to go to test out new features and new places. KQ is fun the first time, but if you are a developer, you have probably already played though, and it would be frustrating if you had to play again, fairly, several dozen times. Some non-developers, of course, may also want to cheat.

To cheat, the first thing you need to do is compile with cheating support. Configure with the following command:

  ./configure --enable-cheats

Then make and install.

To add cheats, modify kq.cfg. In Linux, this is in /.kq. In Windows, this can be found under Application Data (or C:\Program Files\...username...\Application Data\KQ).

A typical kq.cfg file looks like so:

  kctrl = 4
  kalt = 6
  skip_splash = 1
  slow_computer = 1
  wait_retrace = 1
  show_frate = 0
  kesc = 75
  windowed = 1
  skip_intro = 1
  debugging = 1

  cheat = 1
  every_hit_999 = 1
  no_random_encounters = 0
  no_monsters = 1

Notice the last four lines. These define cheating variables.

Also worth noting is cheat.lua. Create a file in your /scripts directory called cheat.lua. You should add one function, called cheat. When you want to want to execute this function while playing, press F10. Any changes you make to your characters' assets will be saved when you save the game. Other changes, such as removing obstacles, will not. Note that syntax errors will cause KQ to abort.

Here is an example cheat.lua file:

  function cheat()
        set_gp(get_gp() + 10000)
        give_item(I_DYNAMITE, 5) -- Note that you have to prepare the script if you include items.

You can learn more about what functions are available for character manipulation by reading the intrface.c file.

Page hosted by
Vote for us!
Vote for the RPG top 50
Gaming HTML standards
Valid XHTML 1.0!