From 22383f5366bcc97180ba34b4cf6a46e5598efbed Mon Sep 17 00:00:00 2001 From: James Brown Date: Mon, 1 Sep 2003 17:07:31 +0000 Subject: [PATCH] Headcrash is a great book by Bruce Bethke. This however is a nasty hack to prevent memory corruption when computing Mannys Head's bounding box --- model.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/model.cpp b/model.cpp index 8d6d6a1e87d..5416b24e5a8 100644 --- a/model.cpp +++ b/model.cpp @@ -647,6 +647,12 @@ void Model::Mesh::draw() const { glPopMatrix(); glEnable(GL_TEXTURE_2D ); */ + // Ender: HACK HACK HACK + // Mannys head isn't computed correctly, so bail out to prevent memory corruption. + // .. at least until it IS computed, or the DirtyScreen code has bounds checking :) + if (strstr(name_, "m_head_1")) + return; + // Yaz: debug // this compute the dirty rect for the mesh