Misc. tweaks.
This commit is contained in:
parent
5ecdab744d
commit
1df85d0937
|
@ -31,7 +31,6 @@ extern void dropCarriedItem(void);
|
|||
extern void addScorchDecal(int x, int y);
|
||||
extern Unit *createUnit(void);
|
||||
extern double randF(void);
|
||||
extern void playSound(int snd, int ch);
|
||||
|
||||
extern Dev dev;
|
||||
extern Entity *self;
|
||||
|
|
|
@ -97,6 +97,7 @@ void doEntities(void)
|
|||
if (dev.cheatStatic && self != (Entity*)world.bob)
|
||||
{
|
||||
self->isVisible = 1;
|
||||
world.bob->flags |= (EF_WEIGHTLESS | EF_NO_CLIP);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
@ -1043,6 +1044,8 @@ static void addRider(void)
|
|||
return;
|
||||
}
|
||||
}
|
||||
|
||||
SDL_LogMessage(SDL_LOG_CATEGORY_APPLICATION, SDL_LOG_PRIORITY_WARN, "Couldn't add rider: out of array space.");
|
||||
}
|
||||
|
||||
static void addTouched(Entity *e)
|
||||
|
@ -1057,6 +1060,8 @@ static void addTouched(Entity *e)
|
|||
return;
|
||||
}
|
||||
}
|
||||
|
||||
SDL_LogMessage(SDL_LOG_CATEGORY_APPLICATION, SDL_LOG_PRIORITY_WARN, "Couldn't add touched: out of array space.");
|
||||
}
|
||||
|
||||
void swapSelf(Entity *e)
|
||||
|
|
|
@ -20,8 +20,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
|
||||
#include "../common.h"
|
||||
|
||||
#define MAX_RIDERS 12
|
||||
#define MAX_TOUCHED 12
|
||||
#define MAX_RIDERS 64
|
||||
#define MAX_TOUCHED 64
|
||||
|
||||
extern Texture *getTexture(const char *filename);
|
||||
extern void blitRect(SDL_Texture *texture, int x, int y, SDL_Rect *srcRect, int center);
|
||||
|
|
|
@ -295,7 +295,7 @@ void setGameplayMessage(int newMessageType, const char *format, ...)
|
|||
vsprintf(newMessage, format, args);
|
||||
va_end(args);
|
||||
|
||||
if (newMessageType >= messageType && newMessage != NULL)
|
||||
if (newMessageType >= messageType && strcmp(message, newMessage))
|
||||
{
|
||||
STRNCPY(message, newMessage, MAX_DESCRIPTION_LENGTH);
|
||||
messageType = newMessageType;
|
||||
|
|
|
@ -157,11 +157,9 @@ static int canPersistEntity(void)
|
|||
case ET_DECORATION:
|
||||
case ET_CONSUMABLE:
|
||||
return 0;
|
||||
break;
|
||||
|
||||
default:
|
||||
return self->health > 0 && self->alive == ALIVE_ALIVE;
|
||||
break;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue