Use power instead of value for batteries.
This commit is contained in:
parent
70d1101ded
commit
1ed138b766
|
@ -122,27 +122,27 @@ void dropBattery(float x, float y)
|
||||||
if (r < 1)
|
if (r < 1)
|
||||||
{
|
{
|
||||||
STRNCPY(i->name, _("full battery"), MAX_NAME_LENGTH);
|
STRNCPY(i->name, _("full battery"), MAX_NAME_LENGTH);
|
||||||
i->value = 4;
|
i->power = 4;
|
||||||
}
|
}
|
||||||
else if (r < 10)
|
else if (r < 10)
|
||||||
{
|
{
|
||||||
STRNCPY(i->name, _("battery"), MAX_NAME_LENGTH);
|
STRNCPY(i->name, _("battery"), MAX_NAME_LENGTH);
|
||||||
i->value = 3;
|
i->power = 3;
|
||||||
}
|
}
|
||||||
else if (r < 25)
|
else if (r < 25)
|
||||||
{
|
{
|
||||||
STRNCPY(i->name, _("used battery"), MAX_NAME_LENGTH);
|
STRNCPY(i->name, _("used battery"), MAX_NAME_LENGTH);
|
||||||
i->value = 2;
|
i->power = 2;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
STRNCPY(i->name, _("weak battery"), MAX_NAME_LENGTH);
|
STRNCPY(i->name, _("weak battery"), MAX_NAME_LENGTH);
|
||||||
i->value = 1;
|
i->power = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
i->sprite[0] = i->sprite[1] = i->sprite[2] = batterySprite;
|
i->sprite[0] = i->sprite[1] = i->sprite[2] = batterySprite;
|
||||||
i->spriteTime = -1;
|
i->spriteTime = -1;
|
||||||
i->spriteFrame = i->value;
|
i->spriteFrame = i->power;
|
||||||
|
|
||||||
i->x = x;
|
i->x = x;
|
||||||
i->y = y;
|
i->y = y;
|
||||||
|
|
Loading…
Reference in New Issue