/* * Copyright (C) 2002-2007 The Warp Rogue Team * Part of the Warp Rogue Project * * This software is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License. * This software is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY. * * See the license.txt file for more details. */ /* * Module Name: Debug * Description: Debug code */ #define Uses_Ui #define Uses_Stats #define Uses_Random #define Uses_Inventory #define Uses_Object #define Uses_Character #define Uses_Area #define Uses_CharacterAdvancement #include "mheader.h" #include "debug.h" /* * the debug console */ void debug_console(void) { KEY_CODE key; key = get_key(); if (key == 'x') { give_ep(player_controlled_character(), 1000); } else if (key == 'm') { OBJECT *money; money = object_create(MONEY_OBJECT_NAME); money->charge = 10000; inventory_add(player_controlled_character(), money); } else if (key == 'e') { inventory_add(player_controlled_character(), object_create("Plasma pistol") ); } }