diff --git a/ChangeLog b/ChangeLog index 51d284d2c..afa86c7d6 100755 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2006-11-30 Chris Taylor + + * arch/ogl/ogl.c: avoid loading OpenGL textures before they have + been paged in, bug found by loading Abalyon 5 + 2006-11-26 Chris Taylor * main/game.c, main/gamerend.c: small brace tidy up to allow diff --git a/arch/ogl/ogl.c b/arch/ogl/ogl.c index a761de743..98a52643b 100755 --- a/arch/ogl/ogl.c +++ b/arch/ogl/ogl.c @@ -533,10 +533,16 @@ void ogl_cache_level_textures(void) } else if(Objects[i].render_type==RT_POLYOBJ){ //printf("robot %i model %i rmodel %i\n", Objects[i].id, Objects[i].rtype.pobj_info.model_num, Robot_info[Objects[i].id].model_num); - ogl_cache_vclipn_textures(Robot_info[Objects[i].id].exp1_vclip_num); - ogl_cache_vclipn_textures(Robot_info[Objects[i].id].exp2_vclip_num); - ogl_cache_weapon_textures(Robot_info[Objects[i].id].weapon_type); - ogl_cache_polymodel_textures(Objects[i].rtype.pobj_info.model_num); + if (Objects[i].type == OBJ_ROBOT) + { + ogl_cache_vclipn_textures(Robot_info[Objects[i].id].exp1_vclip_num); + ogl_cache_vclipn_textures(Robot_info[Objects[i].id].exp2_vclip_num); + ogl_cache_weapon_textures(Robot_info[Objects[i].id].weapon_type); + } + if (Objects[i].rtype.pobj_info.tmap_override != -1) + ogl_loadbmtexture(&GameBitmaps[Textures[Objects[i].rtype.pobj_info.tmap_override].index]); + else + ogl_cache_polymodel_textures(Objects[i].rtype.pobj_info.model_num); } } } diff --git a/dxx-changelog.txt b/dxx-changelog.txt index 2762dd8ed..d9b291fb1 100755 --- a/dxx-changelog.txt +++ b/dxx-changelog.txt @@ -3,6 +3,7 @@ D2X-Rebirth Changelog 20061224 -------- arch/ogl/gr.c: use PhysicsFS to check for existing screenshots, previous method may have caused writing over of open screenshots (from D2X CVS) +arch/ogl/gr.c: avoid loading OpenGL textures before they have been paged in, bug found by loading Abalyon 5 (from D2X CVS) 20061219 --------