- [FIX] No es mostrava res en pantalla perque faltava el 0xff000000 al ficar pixels en la textura
- [FIX] No s'escoltava so, no estic segur de perqué. He agafat el JailAudio de mini i ja va tot. - [NEW] Afegida opció "SET INFINITELIVES" desde la consola - [NEW] Afegida opció "SET KIOSK" desde la consola - [FIX] Les SDL_texture es veien borroses - [FIX] En windows no es carregaven be els GIFs del txt per culpa del salt de linea doble que té.
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
#include "actor.h"
|
||||
#include "jgame.h"
|
||||
#include "debug.h"
|
||||
#include "config.h"
|
||||
|
||||
namespace console
|
||||
{
|
||||
@@ -134,10 +135,11 @@ namespace console
|
||||
#define CMD_EXIT 4
|
||||
#define CMD_SHOW 5
|
||||
#define CMD_HIDE 6
|
||||
#define CMD_HELP 7
|
||||
#define NUM_CMDS 8
|
||||
#define CMD_SET 7
|
||||
#define CMD_HELP 8
|
||||
#define NUM_CMDS 9
|
||||
|
||||
const char *command_text[NUM_CMDS] = { "GIVE", "DROP", "GOTO", "MOVE", "EXIT", "SHOW", "HIDE", "HELP" };
|
||||
const char *command_text[NUM_CMDS] = { "GIVE", "DROP", "GOTO", "MOVE", "EXIT", "SHOW", "HIDE", "SET", "HELP" };
|
||||
|
||||
#define PARAM_UNKNOWN -1
|
||||
#define PARAM_RUN 0
|
||||
@@ -283,9 +285,28 @@ namespace console
|
||||
debug::disable(value);
|
||||
}
|
||||
break;
|
||||
case CMD_SET:
|
||||
if (!tokens[1]) {
|
||||
strcpy(msg, "ERROR: Nothing to set.");
|
||||
} else {
|
||||
strcpy(msg, "Ok.");
|
||||
const int value = getIndexFromString(tokens[1], {"KIOSK", "INFINITELIVES"});
|
||||
if (value==-1)
|
||||
strcpy(msg, "ERROR: Cannot set that.");
|
||||
else
|
||||
switch (value) {
|
||||
case 0:
|
||||
config::setKioskMode(!config::getKioskMode());
|
||||
break;
|
||||
case 1:
|
||||
config::setInifiniteLives(!config::getInfiniteLives());
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
case CMD_HELP:
|
||||
if (!tokens[1]) {
|
||||
strcpy(msg, "GIVE DROP GOTO MOVE EXIT SHOW HIDE HELP");
|
||||
strcpy(msg, "GIVE DROP GOTO MOVE EXIT SHOW HIDE SET HELP");
|
||||
} else {
|
||||
int command = getCommand();
|
||||
switch (command)
|
||||
|
||||
Reference in New Issue
Block a user