aboutsummaryrefslogtreecommitdiff
path: root/source/globals.c
diff options
context:
space:
mode:
authorTwinaphex2017-08-16 06:04:43 +0200
committerGitHub2017-08-16 06:04:43 +0200
commite2cffaea148cfb79cc3546642acb61245b96069e (patch)
treec0a7c48d53a52641d6451aef386b7c2b73c0752a /source/globals.c
parent4b70a73bcdb09e7f96a1e5696a512f4d33667f40 (diff)
parentb3711dfa5041d08490a8603fe221f267c0da290a (diff)
downloadsnes9x2005-e2cffaea148cfb79cc3546642acb61245b96069e.tar.gz
snes9x2005-e2cffaea148cfb79cc3546642acb61245b96069e.tar.bz2
snes9x2005-e2cffaea148cfb79cc3546642acb61245b96069e.zip
Merge pull request #41 from jamsilva/master
SA1 fixes and Brunnis' lagfix port
Diffstat (limited to 'source/globals.c')
-rw-r--r--source/globals.c68
1 files changed, 36 insertions, 32 deletions
diff --git a/source/globals.c b/source/globals.c
index 14b8a64..f7cdb85 100644
--- a/source/globals.c
+++ b/source/globals.c
@@ -69,6 +69,10 @@ uint32_t even_low[4][16];
SCheatData Cheat;
+#ifdef LAGFIX
+bool finishedFrame = false;
+#endif
+
#ifndef USE_BLARGG_APU
SoundStatus so;
@@ -103,47 +107,47 @@ uint8_t BitShifts[8][4] =
};
uint8_t TileShifts[8][4] =
{
- {4, 4, 4, 4}, // 0
- {5, 5, 4, 0}, // 1
- {5, 5, 0, 0}, // 2
- {6, 5, 0, 0}, // 3
- {6, 4, 0, 0}, // 4
- {5, 4, 0, 0}, // 5
- {5, 0, 0, 0}, // 6
- {6, 0, 0, 0} // 7
+ {4, 4, 4, 4}, /* 0 */
+ {5, 5, 4, 0}, /* 1 */
+ {5, 5, 0, 0}, /* 2 */
+ {6, 5, 0, 0}, /* 3 */
+ {6, 4, 0, 0}, /* 4 */
+ {5, 4, 0, 0}, /* 5 */
+ {5, 0, 0, 0}, /* 6 */
+ {6, 0, 0, 0} /* 7 */
};
uint8_t PaletteShifts[8][4] =
{
- {2, 2, 2, 2}, // 0
- {4, 4, 2, 0}, // 1
- {4, 4, 0, 0}, // 2
- {0, 4, 0, 0}, // 3
- {0, 2, 0, 0}, // 4
- {4, 2, 0, 0}, // 5
- {4, 0, 0, 0}, // 6
- {0, 0, 0, 0} // 7
+ {2, 2, 2, 2}, /* 0 */
+ {4, 4, 2, 0}, /* 1 */
+ {4, 4, 0, 0}, /* 2 */
+ {0, 4, 0, 0}, /* 3 */
+ {0, 2, 0, 0}, /* 4 */
+ {4, 2, 0, 0}, /* 5 */
+ {4, 0, 0, 0}, /* 6 */
+ {0, 0, 0, 0} /* 7 */
};
uint8_t PaletteMasks[8][4] =
{
- {7, 7, 7, 7}, // 0
- {7, 7, 7, 0}, // 1
- {7, 7, 0, 0}, // 2
- {0, 7, 0, 0}, // 3
- {0, 7, 0, 0}, // 4
- {7, 7, 0, 0}, // 5
- {7, 0, 0, 0}, // 6
- {0, 0, 0, 0} // 7
+ {7, 7, 7, 7}, /* 0 */
+ {7, 7, 7, 0}, /* 1 */
+ {7, 7, 0, 0}, /* 2 */
+ {0, 7, 0, 0}, /* 3 */
+ {0, 7, 0, 0}, /* 4 */
+ {7, 7, 0, 0}, /* 5 */
+ {7, 0, 0, 0}, /* 6 */
+ {0, 0, 0, 0} /* 7 */
};
uint8_t Depths[8][4] =
{
- {TILE_2BIT, TILE_2BIT, TILE_2BIT, TILE_2BIT}, // 0
- {TILE_4BIT, TILE_4BIT, TILE_2BIT, 0}, // 1
- {TILE_4BIT, TILE_4BIT, 0, 0}, // 2
- {TILE_8BIT, TILE_4BIT, 0, 0}, // 3
- {TILE_8BIT, TILE_2BIT, 0, 0}, // 4
- {TILE_4BIT, TILE_2BIT, 0, 0}, // 5
- {TILE_4BIT, 0, 0, 0}, // 6
- {0, 0, 0, 0} // 7
+ {TILE_2BIT, TILE_2BIT, TILE_2BIT, TILE_2BIT}, /* 0 */
+ {TILE_4BIT, TILE_4BIT, TILE_2BIT, 0}, /* 1 */
+ {TILE_4BIT, TILE_4BIT, 0, 0}, /* 2 */
+ {TILE_8BIT, TILE_4BIT, 0, 0}, /* 3 */
+ {TILE_8BIT, TILE_2BIT, 0, 0}, /* 4 */
+ {TILE_4BIT, TILE_2BIT, 0, 0}, /* 5 */
+ {TILE_4BIT, 0, 0, 0}, /* 6 */
+ {0, 0, 0, 0} /* 7 */
};
uint8_t BGSizes [2] =
{