]> git.mxchange.org Git - quix0rs-blobwars.git/blobdiff - src/mapData.cpp
Allow playing sounds with stereo effects.
[quix0rs-blobwars.git] / src / mapData.cpp
index dfe8514fb00bb10c337477bb1913c8f3763bcc9c..284f8cf225c5a231332741e5c406c2db8b882d58 100644 (file)
@@ -1,5 +1,6 @@
 /*
-Copyright (C) 2004 Parallel Realities
+Copyright (C) 2004-2011 Parallel Realities
+Copyright (C) 2011-2015 Perpendicular Dimensions
 
 This program is free software; you can redistribute it and/or
 modify it under the terms of the GNU General Public License
@@ -247,8 +248,7 @@ void getMapTokens()
                        else if (strcmp("AMBIENCE", mapEntity) == 0)
                        {
                                sscanf(token, "%*s %*s %s", string[0]);
-                               if (!audio.loadSound(SND_AMBIANCE, string[0]))
-                                       graphics.showErrorAndExit(ERR_FILE, string[0]);
+                               audio.loadSound(SND_AMBIANCE, string[0]);
                        }
                        else if (strcmp("WATERLEVEL", mapEntity) == 0)
                        {
@@ -274,7 +274,7 @@ void getMapTokens()
                        else if (strcmp("ALPHATILES", mapEntity) == 0)
                        {
                                for (int i = 0 ; i < 15 ; i++)
-                                       *token++;
+                                       token++;
 
                                while (true)
                                {
@@ -285,11 +285,11 @@ void getMapTokens()
                                                
                                        debug(("Setting Alpha for Tile %d\n", param[0]));
 
-                                       SDL_SetAlpha(graphics.tile[param[0]], SDL_SRCALPHA|SDL_RLEACCEL, 130);
+                                       SDL_SetAlpha(graphics.tile[param[0]], 130);
 
                                        while (true)
                                        {
-                                               *token++;
+                                               token++;
 
                                                if (*token == ' ')
                                                        break;