Add setting

This commit is contained in:
Miloslav Číž 2020-08-16 12:06:24 +02:00
parent f94f9bbe89
commit de911e4fe4
5 changed files with 31 additions and 20 deletions

View File

@ -88,7 +88,7 @@ level ideas:
- narrow corridor with elevator
- maze from walls and/or props DONE
- narrow bridge with platformer elements over a hole full of enemies kinda
- server room
- server room kinda
- window (low unpassable ceiling) through which finish can be seen from the
start location of the level
- three locked doors in a row at the beginning of the level, the player has
@ -103,7 +103,7 @@ level ideas:
- teleport that leads to another teleport which is on a single high elevated
square from which the player has to jump down and won't be able to return,
making it a de-facto one-way teleport
- teleports placed so that the player can shoot himself with a rocket or plasma
- teleports placed so that the player can shoot himself with a rocket or plasma DONE
(for fun)
- exploders in a maze, hiding behind corners
- teleport leading to a center of big room full of enemies

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

After

Width:  |  Height:  |  Size: 4.7 KiB

View File

@ -523,7 +523,7 @@ SFG_PROGRAM_MEMORY uint8_t SFG_attackDamageTable[SFG_WEAPON_FIRE_TYPES_TOTAL] =
SFG_PROGRAM_MEMORY uint8_t SFG_projectileAttributeTable[SFG_PROJECTILES_TOTAL] =
{
/* explosion */ SFG_PROJECTILE_ATTRIBUTE(0,400),
/* fireball */ SFG_PROJECTILE_ATTRIBUTE(11,1000),
/* fireball */ SFG_PROJECTILE_ATTRIBUTE(15,1000),
/* plasma */ SFG_PROJECTILE_ATTRIBUTE(20,500),
/* dust */ SFG_PROJECTILE_ATTRIBUTE(0,450),
/* bullet */ SFG_PROJECTILE_ATTRIBUTE(28,1000)

4
main.c
View File

@ -795,6 +795,7 @@ void SFG_pixelFunc(RCL_PixelInfo *pixel)
}
else
{
#if SFG_DRAW_LEVEL_BACKGROUND
color = SFG_getTexel(
SFG_backgroundImages[SFG_currentLevel.backgroundImage],
SFG_game.backgroundScaleMap[((pixel->position.x
@ -812,6 +813,9 @@ void SFG_pixelFunc(RCL_PixelInfo *pixel)
#if SFG_BACKGROUND_BLUR != 0
SFG_backgroundBlurIndex = (SFG_backgroundBlurIndex + 1) % 0x07;
#endif
#else
color = 1;
#endif
}
RCL_Unit screenX = pixel->position.x * SFG_RAYCASTING_SUBSAMPLE;

View File

@ -264,6 +264,13 @@
/**
Gives player all keys from start.
*/
#define SFG_UNLOCK_DOOR 1
#define SFG_UNLOCK_DOOR 0
/**
Whether levels background (in distance or transparent wall textures) should
be drawn. If turned off, the background will be constant color, which can
noticably increase performance.
*/
#define SFG_DRAW_LEVEL_BACKGROUND 1
#endif // guard