]> git.jsancho.org Git - lugaru.git/commitdiff
bugfix (world texture was messed when fullscreen/windowed switch) and cleanups
authorCôme BERNIGAUD <come.bernigaud@gmail.com>
Fri, 13 May 2011 16:58:19 +0000 (18:58 +0200)
committerCôme BERNIGAUD <come.bernigaud@gmail.com>
Fri, 13 May 2011 16:58:19 +0000 (18:58 +0200)
Source/GameDraw.cpp
Source/GameInitDispose.cpp

index c1fb5532b20768efb0b010629316312cd603fdc7..b4f6ee715f3a97f963228ad47c6fdb86fd6690c4 100644 (file)
@@ -2024,9 +2024,9 @@ void Game::LoadCampaign() {
        if(!Mainmenuitems[7]) {
                ifstream test(ConvertFileName((":Data:Textures:"+accountactive->getCurrentCampaign()+":World.png").c_str()));
                if(test.good()) {
-                       LoadTexture((":Data:Textures:"+accountactive->getCurrentCampaign()+":World.png").c_str(),&Mainmenuitems[7],0,0);
+                       LoadTextureData((":Data:Textures:"+accountactive->getCurrentCampaign()+":World.png").c_str(),&Mainmenuitems[7],0,0);
                } else {
-                       LoadTexture(":Data:Textures:World.png",&Mainmenuitems[7],0,0);
+                       LoadTextureData(":Data:Textures:World.png",&Mainmenuitems[7],0,0);
                }
        }
        ifstream ipstream(ConvertFileName((":Data:Campaigns:"+accountactive->getCurrentCampaign()+".txt").c_str()));
@@ -2087,8 +2087,7 @@ void Game::LoadCampaign() {
        }
 }
 
-void Game::DrawMenu()
-{
+void Game::DrawMenu() {
        int i,j;
        static float lastcheck;
 
index b9d5913fd1f2df0b5fa4f3fe7a19c14e385365fd..7edf75d9e6f44b6027335ea68d94a0e31fdb8fde 100644 (file)
@@ -135,12 +135,12 @@ void Game::Dispose()
 }
 
 
-void Game::LoadTexture(const char *fileName, GLuint *textureid,int mipmap, bool hasalpha){
+void Game::LoadTexture(const char *fileName, GLuint *textureid,int mipmap, bool hasalpha) {
     textures.push_back(TextureInfo(fileName,textureid,mipmap,hasalpha));
     textures.back().load();
 }
 
-void Game::LoadTextureSave(const char *fileName, GLuint *textureid,int mipmap,GLubyte *array, int *skinsize){
+void Game::LoadTextureSave(const char *fileName, GLuint *textureid,int mipmap,GLubyte *array, int *skinsize) {
     textures.push_back(TextureInfo(fileName,textureid,mipmap,array,skinsize));
     textures.back().load();
 }