summaryrefslogtreecommitdiff
path: root/src/newgrf_storage.h
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2010-03-21 11:05:39 +0000
committerfrosch <frosch@openttd.org>2010-03-21 11:05:39 +0000
commitc049bf3f388438c9901981b1943b35fc3add3e4d (patch)
tree2bd583c61b01cecbd8ad64c38b68bd16767904a2 /src/newgrf_storage.h
parentb7b01bb9c703acdf93c36e7212e959b399442d93 (diff)
downloadopenttd-c049bf3f388438c9901981b1943b35fc3add3e4d.tar.xz
(svn r19497) -Fix: [NewGRF] Bytes and words get sign-extended for temporary/persistent storage. (Spotted by yexo)
Diffstat (limited to 'src/newgrf_storage.h')
-rw-r--r--src/newgrf_storage.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/newgrf_storage.h b/src/newgrf_storage.h
index 4e43f124b..cff102ace 100644
--- a/src/newgrf_storage.h
+++ b/src/newgrf_storage.h
@@ -37,7 +37,7 @@ struct BaseStorageArray
* @param pos the position to write at
* @param value the value to write
*/
- virtual void Store(uint pos, uint32 value) = 0;
+ virtual void Store(uint pos, int32 value) = 0;
};
/**
@@ -70,7 +70,7 @@ struct PersistentStorageArray : BaseStorageArray {
* @param pos the position to write at
* @param value the value to write
*/
- void Store(uint pos, uint32 value)
+ void Store(uint pos, int32 value)
{
/* Out of the scope of the array */
if (pos >= SIZE) return;
@@ -138,7 +138,7 @@ struct TemporaryStorageArray : BaseStorageArray {
* @param pos the position to write at
* @param value the value to write
*/
- void Store(uint pos, uint32 value)
+ void Store(uint pos, int32 value)
{
/* Out of the scope of the array */
if (pos >= SIZE) return;