From 64ed08263ced40eff699bf165d63549148116c47 Mon Sep 17 00:00:00 2001 From: danij Date: Wed, 27 Mar 2013 00:27:34 +0000 Subject: [PATCH] Definitions: Fixed OBOE interpreting supplanted material anims A typo in the definition parser's handling of the case where a texture animation defined by the default game ANIMDEFS, replaced by an add-on, resulted in a crash. --- doomsday/client/src/def_read.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doomsday/client/src/def_read.cpp b/doomsday/client/src/def_read.cpp index 37245e0dbf..73151fb192 100644 --- a/doomsday/client/src/def_read.cpp +++ b/doomsday/client/src/def_read.cpp @@ -1273,9 +1273,9 @@ static int DED_ReadData(ded_t* ded, const char* buffer, const char* _sourceFile) // Need to allocate a new stage? if(layerStage >= mat->layers[layer].stageCount.num) { - layerStage = DED_AddMaterialLayerStage(&mat->layers[layer]); + DED_AddMaterialLayerStage(&mat->layers[layer]); - if(mat->autoGenerated && layerStage > 1) + if(mat->autoGenerated && layerStage > 0) { // When adding a new stage to an autogenerated material // initialize by copying values from the previous stage.