# HG changeset patch # User zipi # Date 1383743162 0 # Node ID 30c2b575d25ca3accf3281c25680d2bee7f6303b # Parent 8fa26b63244a480427f76cc81de83e1f9766d55d signed fixes DamagePlayerFromMonster -1 indexing diff -r 8fa26b63244a -r 30c2b575d25c AudioPlayer.cpp --- a/AudioPlayer.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/AudioPlayer.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -84,7 +84,7 @@ sprintf(pSoundName, "%s", pSounds[i].pSoundName); pSoundDesc = &pSoundList->pSounds[i]; if ( pSoundList->pSounds[i].eType != SOUND_DESC_SYSTEM || (sprintf(pSoundName, "%s", pSounds[i].pSoundName), - pSoundList->pSounds[i].pSoundData[0] = ::LoadSound(pSoundName, (SoundData *)0xFFFFFFFF, pSounds[i].uSoundID), + pSoundList->pSounds[i].pSoundData[0] = ::LoadSound(pSoundName, (SoundData *)-1, pSounds[i].uSoundID), !pAudioPlayer->b3DSoundInitialized) || (pSoundDesc = &pSoundList->pSounds[i], !(pSoundDesc->uFlags & SOUND_DESC_SWAP)) || !pSoundDesc->pSoundData[0] ) @@ -150,7 +150,7 @@ return uSoundIdx; if (!pSound->pSoundData[0]) - pSound->pSoundData[0] = ::LoadSound(pSound->pSoundName, (SoundData *)0xFFFFFFFF, pSound->uSoundID); + pSound->pSoundData[0] = ::LoadSound(pSound->pSoundName, (SoundData *)-1, pSound->uSoundID); if (!pSound->pSoundData[0]) return 0; diff -r 8fa26b63244a -r 30c2b575d25c GUIWindow.cpp --- a/GUIWindow.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/GUIWindow.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -1160,7 +1160,7 @@ //----- (0044CE08) -------------------------------------------------------- -void GUIWindow::DrawText( GUIFont *a2, signed int uX, int uY, unsigned int uFontColor, const char *Str, int a7, int a8, unsigned int uFontShadowColor ) +void GUIWindow::DrawText( GUIFont *a2, signed int uX, int uY, unsigned int uFontColor, const char *Str, int a7, int a8, signed int uFontShadowColor ) { GUIWindow *v9; // edi@1 GUIFont *v10; // ebx@1 diff -r 8fa26b63244a -r 30c2b575d25c GUIWindow.h --- a/GUIWindow.h Wed Nov 06 00:09:47 2013 -0800 +++ b/GUIWindow.h Wed Nov 06 13:06:02 2013 +0000 @@ -327,7 +327,7 @@ UIMessageType msg, unsigned int msg_param, unsigned __int8 uHotkey, const char *pName, struct Texture *pTextures, ...); void DrawFlashingInputCursor(signed int uX, int uY, struct GUIFont *a2); int DrawTextInRect(GUIFont *pFont, unsigned int uX, unsigned int uY, unsigned int uColor, const char *text, int rect_width, int reverse_text); - void DrawText(GUIFont *a2, signed int uX, int uY, unsigned int uFontColor, const char *Str, int a7, int a8, unsigned int uFontShadowColor); + void DrawText(GUIFont *a2, signed int uX, int uY, unsigned int uFontColor, const char *Str, int a7, int a8, signed int uFontShadowColor); void DrawTitleText(GUIFont *a2, signed int uHorizontalMargin, unsigned int uVerticalMargin, unsigned __int16 uDefaultColor, const char *pInString, unsigned int uLineSpacing); void DrawShops_next_generation_time_string(__int64 next_generation_time); void HouseDialogManager(); diff -r 8fa26b63244a -r 30c2b575d25c Game.cpp --- a/Game.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/Game.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -234,10 +234,10 @@ { int sector_id = pIndoor->GetSector(pParty->vPosition.x, pParty->vPosition.y, pParty->vPosition.z); sprintf(pTmpBuf.data(), "Party Sector ID: %u/%u\n", sector_id, pIndoor->uNumSectors); - pPrimaryWindow->DrawText(pFontArrus, 16, 16, TargetColor(255, 255, 255), pTmpBuf.data(), 0, 0, 0xFFFFFFFF); + pPrimaryWindow->DrawText(pFontArrus, 16, 16, TargetColor(255, 255, 255), pTmpBuf.data(), 0, 0, -1); } sprintf(pTmpBuf.data(), "Party Position: % d % d % d", pParty->vPosition.x, pParty->vPosition.y, pParty->vPosition.z); - pPrimaryWindow->DrawText(pFontArrus, 16, 16 + 16, TargetColor(255, 255, 255), pTmpBuf.data(), 0, 0, 0xFFFFFFFF); + pPrimaryWindow->DrawText(pFontArrus, 16, 16 + 16, TargetColor(255, 255, 255), pTmpBuf.data(), 0, 0, -1); if (uCurrentlyLoadedLevelType == LEVEL_Indoor) { @@ -252,7 +252,7 @@ int floor_level = ODM_GetFloorLevel(pParty->vPosition.x, pParty->vPosition.y, pParty->vPosition.z, 0, &on_water, &_a6, false); sprintf(pTmpBuf.data(), "ODM_GetFloorLevel: %d on_water: %s a6 = %d\n", floor_level, on_water ? "true" : "false", _a6); } - pPrimaryWindow->DrawText(pFontArrus, 16, 16 + 16 + 16, TargetColor(255, 255, 255), pTmpBuf.data(), 0, 0, 0xFFFFFFFF); + pPrimaryWindow->DrawText(pFontArrus, 16, 16 + 16 + 16, TargetColor(255, 255, 255), pTmpBuf.data(), 0, 0, -1); } GUI_UpdateWindows(); @@ -299,7 +299,7 @@ MSG Msg; // [sp+28h] [bp-3Ch]@20 char Source[64]; // [sp+44h] [bp-20h]@76 - bLoading = uCurrentMenuID == MENU_LoadingProcInMainMenu; + bLoading = sCurrentMenuID == MENU_LoadingProcInMainMenu; SetCurrentMenuID((MENU_STATE)-1); if (bLoading) { @@ -719,7 +719,7 @@ //----- (0044EDE4) -------------------------------------------------------- -bool Game::AlterGamma_BLV(BLVFace *pFace, unsigned int *pColor) +bool Game::AlterGamma_BLV(BLVFace *pFace, signed int *pColor) { if (uFlags2 & GAME_FLAGS_2_SATURATE_LIGHTMAPS && pFace->uAttributes & FACE_CAN_SATURATE_COLOR) @@ -732,7 +732,7 @@ } //----- (0044EE30) -------------------------------------------------------- -bool Game::AlterGamma_ODM(ODMFace *pFace, unsigned int *pColor) +bool Game::AlterGamma_ODM(ODMFace *pFace, signed int *pColor) { if (uFlags2 & GAME_FLAGS_2_SATURATE_LIGHTMAPS && pFace->uAttributes & FACE_CAN_SATURATE_COLOR) diff -r 8fa26b63244a -r 30c2b575d25c Game.h --- a/Game.h Wed Nov 06 00:09:47 2013 -0800 +++ b/Game.h Wed Nov 06 13:06:02 2013 +0000 @@ -98,8 +98,8 @@ void OutlineSelection(); signed int _44EC23(struct Polygon *a2, int *a3, signed int a4); signed int _44ED0A(struct BLVFace *a2, int *a3, signed int a4); - bool AlterGamma_BLV(struct BLVFace *pFace, unsigned int *pColor); - bool AlterGamma_ODM(struct ODMFace *pFace, unsigned int *pColor); + bool AlterGamma_BLV(struct BLVFace *pFace, signed int *pColor); + bool AlterGamma_ODM(struct ODMFace *pFace, signed int *pColor); bool draw_debug_outlines(); bool _44EEA7(); bool _44F07B(); diff -r 8fa26b63244a -r 30c2b575d25c Indoor.cpp --- a/Indoor.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/Indoor.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -4631,7 +4631,7 @@ v30 = HIDWORD(p->pActorBuffs[ACTOR_BUFF_STONED].uExpireTime) < 0; v0->field_1E = v41; v0->pSpriteFrame = v10; - v0->uTintColor = pMonsterList->pMonsters[p->pMonsterInfo.uID - 1].uTintColor; + v0->sTintColor = pMonsterList->pMonsters[p->pMonsterInfo.uID - 1].sTintColor; if ( !v30 && (!(v30 | v29) || LODWORD(p->pActorBuffs[ACTOR_BUFF_STONED].uExpireTime)) ) { HIBYTE(v26) = HIBYTE(v41) | 1; @@ -4785,7 +4785,7 @@ v3->world_z = a3; v3->uScreenSpaceX = v36; v22 = v35; - v3->uTintColor = 0; + v3->sTintColor = 0; v3->uScreenSpaceY = v22; //v23 = 8 * i; //LOBYTE(v23) = PID(OBJECT_Item,i); @@ -5047,7 +5047,7 @@ v15->actual_z = HIWORD(x); v15->object_pid = PID(OBJECT_Decoration,uDecorationID); - v15->uTintColor = 0; + v15->sTintColor = 0; v15->pSpriteFrame = v12; } } diff -r 8fa26b63244a -r 30c2b575d25c IndoorCameraD3D.cpp --- a/IndoorCameraD3D.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/IndoorCameraD3D.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -549,7 +549,7 @@ } //----- (00437C96) -------------------------------------------------------- -void IndoorCameraD3D::do_draw_debug_line_d3d(const RenderVertexD3D3 *pLineBegin, unsigned int uDiffuseBegin, const RenderVertexD3D3 *pLineEnd, unsigned int uDiffuseEnd, float z_stuff) +void IndoorCameraD3D::do_draw_debug_line_d3d(const RenderVertexD3D3 *pLineBegin, signed int sDiffuseBegin, const RenderVertexD3D3 *pLineEnd, signed int sDiffuseEnd, float z_stuff) { double v6; // st7@2 IDirect3DDevice3 *v7; // eax@2 @@ -568,8 +568,8 @@ v13[0].pos.z = v6; v13[1].pos.z = v6; v12 = 0; - v13[0].diffuse = uDiffuseBegin; - v13[1].diffuse = uDiffuseEnd; + v13[0].diffuse = sDiffuseBegin; + v13[1].diffuse = sDiffuseEnd; v7 = pRenderer->pRenderD3D->pDevice; v11 = 0; //v10 = (const char *)v7; @@ -588,7 +588,7 @@ } //----- (00437AB5) -------------------------------------------------------- -void IndoorCameraD3D::do_draw_debug_line_sw(RenderVertexSoft *pLineBegin, unsigned int uStartDiffuse, RenderVertexSoft *pLineEnd, unsigned int uEndDiffuse, unsigned int uOutNumVertices, float z_stuff) +void IndoorCameraD3D::do_draw_debug_line_sw(RenderVertexSoft *pLineBegin, signed int sStartDiffuse, RenderVertexSoft *pLineEnd, signed int sEndDiffuse, unsigned int uOutNumVertices, float z_stuff) { char *v7; // eax@2 signed int v8; // edx@2 @@ -636,13 +636,13 @@ v24[0].pos.x = pVertices[0].vWorldViewProjX; v24[0].pos.y = pVertices[0].vWorldViewProjY; v24[0].pos.z = v16; - v24[0].diffuse = uStartDiffuse; + v24[0].diffuse = sStartDiffuse; v24[0].rhw = 0.001; v24[1].pos.x = pVertices[1].vWorldViewProjX; v24[0].texcoord.x = 0.0; v24[1].pos.y = pVertices[1].vWorldViewProjY; v24[0].texcoord.y = 0.0; - v24[1].diffuse = uEndDiffuse; + v24[1].diffuse = sEndDiffuse; v24[1].pos.z = v16; v24[1].specular = 0; v21 = 0; diff -r 8fa26b63244a -r 30c2b575d25c IndoorCameraD3D.h --- a/IndoorCameraD3D.h Wed Nov 06 00:09:47 2013 -0800 +++ b/IndoorCameraD3D.h Wed Nov 06 13:06:02 2013 +0000 @@ -152,8 +152,8 @@ void PrepareAndDrawDebugOutline(struct BLVFace *pFace, unsigned int uDiffuse); void debug_outline_sw(struct RenderVertexSoft *a2, unsigned int uNumVertices, unsigned int uDiffuse, float a5); void debug_outline_d3d(const struct RenderVertexD3D3 *pLineVertices, unsigned int uNumLines, int uDiffuse, float z_stuff); - void do_draw_debug_line_sw(struct RenderVertexSoft *pLineBegin, unsigned int uStartDiffuse, struct RenderVertexSoft *pLineEnd, unsigned int uEndDiffuse, unsigned int uOutNumVertices, float z_stuff); - void do_draw_debug_line_d3d(const struct RenderVertexD3D3 *pLineBegin, unsigned int uDiffuseBegin, const RenderVertexD3D3 *pLineEnd, unsigned int uDiffuseEnd, float z_stuff); + void do_draw_debug_line_sw(struct RenderVertexSoft *pLineBegin, signed int sStartDiffuse, struct RenderVertexSoft *pLineEnd, signed int sEndDiffuse, unsigned int uOutNumVertices, float z_stuff); + void do_draw_debug_line_d3d(const struct RenderVertexD3D3 *pLineBegin, signed int sDiffuseBegin, const RenderVertexD3D3 *pLineEnd, signed int sDiffuseEnd, float z_stuff); //void sr_437D4A_draw_some_vertices(float x, float y, float z, unsigned int a5, char a6, float a7); //void sr_438141_draw_list_0037C(); //void sr_438240_draw_lits(); diff -r 8fa26b63244a -r 30c2b575d25c Monsters.cpp --- a/Monsters.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/Monsters.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -440,7 +440,7 @@ Argsb = atoi(v25.pProperties[13]) & 0xFF; v26 = atoi(v25.pProperties[14]) & 0xFF; v18 = atoi(v25.pProperties[15]); - v2->pMonsters[v2->uNumMonsters].uTintColor = v18 | ((v26 | ((Argsb | (v17 << 8)) << 8)) << 8); + v2->pMonsters[v2->uNumMonsters].sTintColor = v18 | ((v26 | ((Argsb | (v17 << 8)) << 8)) << 8); v19 = 0; do { @@ -478,7 +478,7 @@ dst->uMonsterRadius = src->uMonsterRadius; dst->uMovementSpeed = src->uMovementSpeed; dst->uToHitRadius = src->uToHitRadius; - dst->uTintColor = 0xFFFFFFFF; + dst->sTintColor = -1; memcpy(dst->pSoundSampleIDs, src->pSoundSampleIDs, sizeof(src->pSoundSampleIDs)); memcpy(dst->pMonsterName, src->pMonsterName, sizeof(src->pMonsterName)); memcpy(dst->pSpriteNames, src->pSpriteNames, sizeof(src->pSpriteNames)); diff -r 8fa26b63244a -r 30c2b575d25c Monsters.h --- a/Monsters.h Wed Nov 06 00:09:47 2013 -0800 +++ b/Monsters.h Wed Nov 06 13:06:02 2013 +0000 @@ -232,7 +232,7 @@ unsigned __int16 uMonsterRadius; unsigned __int16 uMovementSpeed; __int16 uToHitRadius; - unsigned int uTintColor; + signed int sTintColor; unsigned __int16 pSoundSampleIDs[4]; char pMonsterName[32]; char pSpriteNames[10][10]; diff -r 8fa26b63244a -r 30c2b575d25c Mouse.cpp --- a/Mouse.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/Mouse.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -479,7 +479,7 @@ int *pXY_; // esi@1 signed int y; // eax@7 signed int x; // ecx@7 - unsigned int v4; // eax@11 + signed int v4; // eax@11 signed int v5; // eax@17 signed int v6; // esi@19 int v7; // esi@30 @@ -518,7 +518,7 @@ goto LABEL_30; v4 = GetCurrentMenuID(); x = pX; - if ( v4 != 0xFFFFFFFF + if ( v4 != -1 || (signed int)pX < (signed int)pViewport->uViewportTL_X || (signed int)pX > (signed int)pViewport->uViewportBR_X ) { diff -r 8fa26b63244a -r 30c2b575d25c Outdoor.cpp --- a/Outdoor.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/Outdoor.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -1170,15 +1170,15 @@ v1->pFaceIDLIST = (unsigned __int16 *)v6; *(short *)v6 = 0; strcpy(v1->pSkyTextureName, pDefaultSkyTexture.data()); - v1->uSky_TextureID = pBitmaps_LOD->LoadTexture(v1->pSkyTextureName); + v1->sSky_TextureID = pBitmaps_LOD->LoadTexture(v1->pSkyTextureName); strcpy(v1->pGroundTileset, byte_6BE124_cfg_textures_DefaultGroundTexture.data()); v7 = pBitmaps_LOD->LoadTexture(v1->pGroundTileset); - v1->uMainTile_BitmapID = v7; + v1->sMainTile_BitmapID = v7; - if ( v1->uSky_TextureID == -1 ) + if ( v1->sSky_TextureID == -1 ) Error("Invalid Sky Tex Handle"); - if ( v1->uMainTile_BitmapID == -1 ) + if ( v1->sMainTile_BitmapID == -1 ) Error("Invalid Ground Tex Handle"); } @@ -1667,16 +1667,16 @@ v108 = 0; v107 = (int)pDefaultSkyTexture; } - uSky_TextureID = pBitmaps_LOD->LoadTexture((const char *)v107, (enum TEXTURE_TYPE)v108); + sSky_TextureID = pBitmaps_LOD->LoadTexture((const char *)v107, (enum TEXTURE_TYPE)v108); strcpy(pGroundTileset, byte_6BE124_cfg_textures_DefaultGroundTexture); v34 = pTileTable->GetTileById(pTileTypes[0].uTileID); v35 = pBitmaps_LOD->LoadTexture(v34->pTileName); - v36 = uSky_TextureID; - uMainTile_BitmapID = v35; + v36 = sSky_TextureID; + sMainTile_BitmapID = v35; if ( v36 != -1 ) pBitmaps_LOD->pTextures[v36].palette_id2 = pPaletteManager->LoadPalette(pBitmaps_LOD->pTextures[v36].palette_id1); - v37 = uMainTile_BitmapID; + v37 = sMainTile_BitmapID; if ( v37 != -1 ) pBitmaps_LOD->pTextures[v37].palette_id2 = pPaletteManager->LoadPalette(pBitmaps_LOD->pTextures[v37].palette_id1); @@ -2323,9 +2323,9 @@ //v108 = 0; TileDesc* v98 = pTileTable->GetTileById(pTileTypes[0].uTileID); //v99 = pBitmaps_LOD->LoadTexture(v98->pTileName, TEXTURE_DEFAULT); - uMainTile_BitmapID = pBitmaps_LOD->LoadTexture(v98->pTileName, TEXTURE_DEFAULT); - if (uMainTile_BitmapID != -1) - pBitmaps_LOD->pTextures[uMainTile_BitmapID].palette_id2 = pPaletteManager->LoadPalette(pBitmaps_LOD->pTextures[uMainTile_BitmapID].palette_id1); + sMainTile_BitmapID = pBitmaps_LOD->LoadTexture(v98->pTileName, TEXTURE_DEFAULT); + if (sMainTile_BitmapID != -1) + pBitmaps_LOD->pTextures[sMainTile_BitmapID].palette_id2 = pPaletteManager->LoadPalette(pBitmaps_LOD->pTextures[sMainTile_BitmapID].palette_id1); _47F0E2(); @@ -2349,9 +2349,9 @@ strcpy(loc_time.sky_texture_name, "plansky3"); } //v101 = pBitmaps_LOD->LoadTexture(field_4F8); - uSky_TextureID = pBitmaps_LOD->LoadTexture(loc_time.sky_texture_name); - if (uSky_TextureID != -1) - pBitmaps_LOD->pTextures[uSky_TextureID].palette_id2 = pPaletteManager->LoadPalette(pBitmaps_LOD->pTextures[uSky_TextureID].palette_id1); + sSky_TextureID = pBitmaps_LOD->LoadTexture(loc_time.sky_texture_name); + if (sSky_TextureID != -1) + pBitmaps_LOD->pTextures[sSky_TextureID].palette_id2 = pPaletteManager->LoadPalette(pBitmaps_LOD->pTextures[sSky_TextureID].palette_id1); pPaletteManager->RecalculateAll(); pSoundList->LoadSound(53, 0); @@ -2427,14 +2427,14 @@ } //----- (0047ED08) -------------------------------------------------------- -unsigned int OutdoorLocation::DoGetTileTexture(unsigned int uX, unsigned int uY) +unsigned int OutdoorLocation::DoGetTileTexture(signed int sX, signed int sY) { int v3; // esi@5 unsigned int result; // eax@9 - assert(uX < 128 && uY < 128); + assert(sX < 128 && sY < 128); - v3 = this->pTerrain.pTilemap[uY * 128 + uX]; + v3 = this->pTerrain.pTilemap[sY * 128 + sX]; if (v3 < 198) // < Tileset_3 { if (v3 >= 90) @@ -2490,12 +2490,12 @@ } //----- (0047EDB3) -------------------------------------------------------- -int OutdoorLocation::ActuallyGetSomeOtherTileInfo(unsigned int uX, unsigned int uY) +int OutdoorLocation::ActuallyGetSomeOtherTileInfo(signed int sX, signed int sY) { - assert(uX < 128 && uY < 128); + assert(sX < 128 && sY < 128); int v3; // esi@5 - v3 = this->pTerrain.pTilemap[uY * 128 + uX]; + v3 = this->pTerrain.pTilemap[sY * 128 + sX]; if ( v3 >= 90 ) v3 = v3 + this->pTileTypes[(v3 - 90) / 36].uTileID - 36 * ((v3 - 90) / 36) - 90; return pTileTable->pTiles[v3].uAttributes; @@ -3101,7 +3101,7 @@ v36 = actor->pMonsterInfo.uID; v28->field_1E = v62 | 0x200; v28->pSpriteFrame = v15; - v28->uTintColor = pMonsterList->pMonsters[actor->pMonsterInfo.uID-1].uTintColor;//*((int *)&v35[v36] - 36); + v28->sTintColor = pMonsterList->pMonsters[actor->pMonsterInfo.uID-1].sTintColor;//*((int *)&v35[v36] - 36); if (actor->pActorBuffs[ACTOR_BUFF_STONED].uExpireTime) v28->field_1E = v62 | 0x200; } diff -r 8fa26b63244a -r 30c2b575d25c Outdoor.h --- a/Outdoor.h Wed Nov 06 00:09:47 2013 -0800 +++ b/Outdoor.h Wed Nov 06 13:06:02 2013 +0000 @@ -137,9 +137,9 @@ void Release(); bool Load(const char *pFilename, ODMFace *File, size_t a4, int thisa); int GetTileIdByTileMapId(signed int a2); - unsigned int DoGetTileTexture(unsigned int uX, unsigned int uZ); + unsigned int DoGetTileTexture(signed int uX, signed int uZ); int _47ED83(signed int a2, signed int a3); - int ActuallyGetSomeOtherTileInfo(unsigned int uX, unsigned int uY); + int ActuallyGetSomeOtherTileInfo(signed int uX, signed int uY); int DoGetHeightOnTerrain(signed int sX, signed int sZ); int GetSoundIdByPosition(signed int X_pos, signed int Y_pos, int a4); int UpdateDiscoveredArea(int a2, int a3, int a4); @@ -179,8 +179,8 @@ unsigned int numFaceIDListElems; unsigned __int16 *pFaceIDLIST; unsigned int *pOMAP; - unsigned int uSky_TextureID; - unsigned int uMainTile_BitmapID; + signed int sSky_TextureID; + signed int sMainTile_BitmapID; __int16 field_F0; __int16 field_F2; int field_F4; diff -r 8fa26b63244a -r 30c2b575d25c Player.cpp --- a/Player.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/Player.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -7253,7 +7253,7 @@ //----- (00439FCB) -------------------------------------------------------- -void __fastcall DamagePlayerFromMonster(unsigned int uObjID, int dmgSource, Vec3_int_ *pPos, unsigned int a4) +void __fastcall DamagePlayerFromMonster(unsigned int uObjID, int dmgSource, Vec3_int_ *pPos, signed int a4) { Player *playerPtr; // ebx@3 Actor *actorPtr; // esi@3 @@ -7413,7 +7413,7 @@ } if ( activePlayerCounter ) { - playerPtr = &pParty->pPlayers[v72[rand() % activePlayerCounter]];//&stru_AA1058[3].pSounds[6972 * *(&v72 + rand() % v74) + 40552]; + playerPtr = &pParty->pPlayers[v72[rand() % activePlayerCounter] - 1];//&stru_AA1058[3].pSounds[6972 * *(&v72 + rand() % v74) + 40552]; } } int v68; diff -r 8fa26b63244a -r 30c2b575d25c Render.cpp --- a/Render.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/Render.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -185,7 +185,7 @@ soft_billboard._screenspace_y_scaler_packedfloat = p->_screenspace_y_scaler_packedfloat; soft_billboard.sZValue = p->sZValue; soft_billboard.uFlags = p->field_1E; - soft_billboard.uTintColor = p->uTintColor; + soft_billboard.sTintColor = p->sTintColor; v2 = p->uHwSpriteID; if ( v2 != -1 ) { @@ -425,7 +425,7 @@ billboard.uScreenSpaceY = pBillboard->uScreenSpaceY; billboard.sParentBillboardID = i; billboard._screenspace_x_scaler_packedfloat = pBillboard->_screenspace_x_scaler_packedfloat; - billboard.uTintColor = pBillboard->uTintColor; + billboard.sTintColor = pBillboard->sTintColor; billboard._screenspace_y_scaler_packedfloat = pBillboard->_screenspace_y_scaler_packedfloat; billboard.sZValue = pBillboard->sZValue; billboard.uFlags = pBillboard->field_1E; @@ -647,7 +647,7 @@ v27 = (object->uAttributes & 0x20) == 0; v3->sZValue = v26 + (PID(OBJECT_Item,i)); v3->dimming_level = 0; - v3->uTintColor = 0; + v3->sTintColor = 0; if ( !v27 ) { if ( !pRenderer->pRenderD3D ) @@ -1149,7 +1149,7 @@ v27->sZValue = v30 + v31; v27->dimming_level = 0; v27->pSpriteFrame = v8; - v27->uTintColor = 0; + v27->sTintColor = 0; } } goto LABEL_38; @@ -1878,7 +1878,7 @@ unsigned int v55; // [sp+5Ch] [bp-Ch]@34 unsigned int v56; // [sp+60h] [bp-8h]@12 int v57; // [sp+60h] [bp-8h]@34 - unsigned int a2; // [sp+64h] [bp-4h]@4 + signed int a2; // [sp+64h] [bp-4h]@4 v5 = this; v6 = 0; @@ -1888,7 +1888,7 @@ v53 = v7; v54 = v7->std__vector_000004_size; if ( v7->std__vector_000004_size) - a2 = 0xFFFFFFFF; + a2 = -1; pGame->AlterGamma_ODM(a4, &a2); if ( byte_4D864C && pGame->uFlags & GAME_FLAGS_1_01) { @@ -5421,18 +5421,18 @@ //v59 = pGame->pLightmapBuilder; //v9 = v59->std__vector_000004_size; - uint uCorrectedColor = uColor; + int sCorrectedColor = uColor; if (pGame->pLightmapBuilder->std__vector_000004_size) - uCorrectedColor = 0xFFFFFFFF; - pGame->AlterGamma_BLV(pFace, &uCorrectedColor); + sCorrectedColor = -1; + pGame->AlterGamma_BLV(pFace, &sCorrectedColor); if (pFace->uAttributes & FACE_OUTLINED) { int color; if (GetTickCount() % 300 >= 150) - uColor = uCorrectedColor = 0xFF20FF20; - else uColor = uCorrectedColor = 0xFF109010; + uColor = sCorrectedColor = 0xFF20FF20; + else uColor = sCorrectedColor = 0xFF109010; } if (byte_4D864C && pGame->uFlags & GAME_FLAGS_1_01) @@ -5446,7 +5446,7 @@ d3d_vertex_buffer[i].pos.y = array_507D30[i].vWorldViewProjY; d3d_vertex_buffer[i].pos.z = 1.0 - 1.0 / (array_507D30[i].vWorldViewPosition.x * 0.061758894); d3d_vertex_buffer[i].rhw = 1.0 / array_507D30[i].vWorldViewPosition.x; - d3d_vertex_buffer[i].diffuse = uCorrectedColor; + d3d_vertex_buffer[i].diffuse = sCorrectedColor; d3d_vertex_buffer[i].specular = 0; d3d_vertex_buffer[i].texcoord.x = array_507D30[i].u / (double)pTex->uTextureWidth; d3d_vertex_buffer[i].texcoord.y = array_507D30[i].v / (double)pTex->uTextureHeight; @@ -5473,7 +5473,7 @@ d3d_vertex_buffer[i].pos.y = array_507D30[i].vWorldViewProjY; d3d_vertex_buffer[i].pos.z = 1.0 - 1.0 / (array_507D30[i].vWorldViewPosition.x * 0.061758894); d3d_vertex_buffer[i].rhw = 1.0 / array_507D30[i].vWorldViewPosition.x; - d3d_vertex_buffer[i].diffuse = uCorrectedColor; + d3d_vertex_buffer[i].diffuse = sCorrectedColor; d3d_vertex_buffer[i].specular = 0; d3d_vertex_buffer[i].texcoord.x = array_507D30[i].u / (double)pTex->uTextureWidth; d3d_vertex_buffer[i].texcoord.y = array_507D30[i].v / (double)pTex->uTextureHeight; @@ -5543,7 +5543,7 @@ pGame->pLightmapBuilder->DrawLightmaps(/*-1, 0*/); for (uint i = 0; i < uNumVertices; ++i) - d3d_vertex_buffer[i].diffuse = uCorrectedColor; + d3d_vertex_buffer[i].diffuse = sCorrectedColor; /*v33 = uNumVertices; if ( (signed int)uNumVertices > 0 ) { @@ -5636,10 +5636,10 @@ v27 = (double)(pSprite->uBufferHeight - pSprite->uAreaY); if ( pSoftBillboard->uFlags & 4 ) v31 = v31 * -1.0; - if ( pSoftBillboard->uTintColor && this->bTinting ) + if ( pSoftBillboard->sTintColor && this->bTinting ) { v11 = ::GetActorTintColor(dimming_level, 0, pSoftBillboard->zbuffer_depth, 0, 0); - v12 = BlendColors(pSoftBillboard->uTintColor, v11); + v12 = BlendColors(pSoftBillboard->sTintColor, v11); if ( v28 ) v12 = (unsigned int)((char *)&array_77EC08[1852].pEdgeList1[17] + 3) & ((unsigned int)v12 >> 1); } @@ -6079,10 +6079,10 @@ v29 = (a2->_screenspace_y_scaler_packedfloat & 0xFFFF) / 65530.0 + HIWORD(a2->_screenspace_y_scaler_packedfloat); unsigned int diffuse = ::GetActorTintColor(dimming_level, 0, a2->zbuffer_depth, 0, pBillboard); - if (a2->uTintColor & 0x00FFFFFF && bTinting) - { - diffuse = BlendColors(a2->uTintColor, diffuse); - if (a2->uTintColor & 0xFF000000) + if (a2->sTintColor & 0x00FFFFFF && bTinting) + { + diffuse = BlendColors(a2->sTintColor, diffuse); + if (a2->sTintColor & 0xFF000000) diffuse = 0x007F7F7F & ((unsigned int)diffuse >> 1); } @@ -6149,7 +6149,7 @@ pBillboardRenderListD3D[v8].sZValue = a2->sZValue; pBillboardRenderListD3D[v8].sParentBillboardID = a2->sParentBillboardID; - if (a2->uTintColor & 0xFF000000) + if (a2->sTintColor & 0xFF000000) pBillboardRenderListD3D[v8].uOpacity = RenderBillboardD3D::Opaque_3; else pBillboardRenderListD3D[v8].uOpacity = RenderBillboardD3D::Transparent; @@ -8334,14 +8334,14 @@ SetUserInterface(pParty->alignment, true); if ( pVideoPlayer->pVideoFrame.pPixels ) pVideoPlayer->pVideoFrame.Load(pVideoPlayer->pVideoFrameTextureFilename, 1); - if ( uCurrentMenuID != MENU_CREATEPARTY ) - { - if ( uCurrentMenuID == MENU_CREDITSPROC ) + if ( sCurrentMenuID != MENU_CREATEPARTY ) + { + if ( sCurrentMenuID == MENU_CREDITSPROC ) dword_A74C88 = 1; } else { - if ( uCurrentMenuID ) + if ( sCurrentMenuID ) { v6 = &pTexture_PCX; pTexture_PCX.Release(); @@ -8352,7 +8352,7 @@ v6 = &pTexture_PCX; pTexture_PCX.Release(); v8 = "title.pcx"; - if ( uCurrentMenuID ) + if ( sCurrentMenuID ) v8 = "lsave640.pcx"; } v6->Load(v8, 0); @@ -8632,6 +8632,7 @@ if (p->uOpacity != RenderBillboardD3D::NoBlend) SetBillboardBlendOptions(p->uOpacity); + //if((int)p->pTexture!=0xcdcdcdcd) pRenderer->pRenderD3D->pDevice->SetTexture(0, p->pTexture); ErrD3D(pRenderer->pRenderD3D->pDevice->DrawPrimitive(D3DPT_TRIANGLEFAN, D3DFVF_XYZRHW | D3DFVF_DIFFUSE | D3DFVF_SPECULAR | D3DFVF_TEX1, @@ -9054,8 +9055,8 @@ - (double)pGame->pIndoorCameraD3D->vPartyPos.z)); pSkyPolygon.Create_48607B(&stru_8019C8);//заполняется ptr_38 pSkyPolygon.ptr_38->_48694B_frustum_sky(); - pSkyPolygon.uTileBitmapID = pOutdoor->uSky_TextureID;//179(original 166) - pSkyPolygon.pTexture = (Texture *)(SLOWORD(pOutdoor->uSky_TextureID) != -1 ? (int)&pBitmaps_LOD->pTextures[SLOWORD(pOutdoor->uSky_TextureID)] : 0); + pSkyPolygon.uTileBitmapID = pOutdoor->sSky_TextureID;//179(original 166) + pSkyPolygon.pTexture = (Texture *)(SLOWORD(pOutdoor->sSky_TextureID) != -1 ? (int)&pBitmaps_LOD->pTextures[SLOWORD(pOutdoor->sSky_TextureID)] : 0); if ( pSkyPolygon.pTexture ) { pSkyPolygon.dimming_level = 0; diff -r 8fa26b63244a -r 30c2b575d25c Render.h --- a/Render.h Wed Nov 06 00:09:47 2013 -0800 +++ b/Render.h Wed Nov 06 13:06:02 2013 +0000 @@ -42,7 +42,7 @@ { Vec3_float_ pos; float rhw; - unsigned int diffuse; + signed int diffuse; unsigned int specular; Vec2_float_ texcoord; }; @@ -79,7 +79,7 @@ __int16 uScreenSpaceX; __int16 uScreenSpaceY; unsigned __int16 dimming_level; - unsigned int uTintColor; + signed int sTintColor; SpriteFrame *pSpriteFrame; inline float GetFloatZ() const @@ -187,13 +187,13 @@ #pragma pack(push, 1) struct RenderBillboardD3D { - enum OpacityType: unsigned __int32 + enum OpacityType: signed __int32 { Transparent = 0, Opaque_1 = 1, Opaque_2 = 2, Opaque_3 = 3, - NoBlend = 0xFFFFFFFF + NoBlend = -1 }; IDirect3DTexture2 *pTexture; @@ -499,7 +499,7 @@ unsigned int uViewportW; int field_44; int sParentBillboardID; - int uTintColor; + int sTintColor; }; #pragma pack(pop) diff -r 8fa26b63244a -r 30c2b575d25c Vis.cpp --- a/Vis.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/Vis.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -552,7 +552,7 @@ } //----- (004C1C0C) -------------------------------------------------------- -bool Vis::Intersect_Ray_Face(RenderVertexSoft *pRayStart, RenderVertexSoft *pRayEnd, float *pDepth, RenderVertexSoft *Intersection, BLVFace *pFace, unsigned int pBModelID) +bool Vis::Intersect_Ray_Face(RenderVertexSoft *pRayStart, RenderVertexSoft *pRayEnd, float *pDepth, RenderVertexSoft *Intersection, BLVFace *pFace, signed int pBModelID) { float c1; // st5@6 float c2; // st7@11 @@ -603,7 +603,7 @@ } //----- (004C1D2B) -------------------------------------------------------- -bool Vis::CheckIntersectBModel(BLVFace *pFace, Vec3_short_ IntersectPoint, unsigned int uModelID) +bool Vis::CheckIntersectBModel(BLVFace *pFace, Vec3_short_ IntersectPoint, signed int sModelID) { int v5; // esi@10 bool v6; // edi@10 @@ -618,9 +618,9 @@ IntersectPoint.z < pFace->pBounding.z1 || IntersectPoint.z > pFace->pBounding.z2 ) return false; - if (uModelID != -1) + if (sModelID != -1) ODM_CreateIntersectFacesVertexCoordList(&a, &b, intersect_face_vertex_coords_list_a.data(), intersect_face_vertex_coords_list_b.data(), - &IntersectPoint, pFace, uModelID); + &IntersectPoint, pFace, sModelID); else BLV_CreateIntersectFacesVertexCoordList(&a, &b, intersect_face_vertex_coords_list_a.data(), intersect_face_vertex_coords_list_b.data(), &IntersectPoint, pFace); diff -r 8fa26b63244a -r 30c2b575d25c Vis.h --- a/Vis.h Wed Nov 06 00:09:47 2013 -0800 +++ b/Vis.h Wed Nov 06 13:06:02 2013 +0000 @@ -111,8 +111,8 @@ bool SortVectors_x(RenderVertexSoft *a2, int a3, int a4); int get_object_zbuf_val(Vis_ObjectInfo *info); int get_picked_object_zbuf_val(); - bool Intersect_Ray_Face(struct RenderVertexSoft *pRayStart, struct RenderVertexSoft *pRayEnd, float *pDepth, RenderVertexSoft *Intersection, BLVFace *pFace, unsigned int pBModelID); - bool CheckIntersectBModel(BLVFace *pFace, Vec3_short_ IntersectPoint, unsigned int uModelID); + bool Intersect_Ray_Face(struct RenderVertexSoft *pRayStart, struct RenderVertexSoft *pRayEnd, float *pDepth, RenderVertexSoft *Intersection, BLVFace *pFace, signed int pBModelID); + bool CheckIntersectBModel(BLVFace *pFace, Vec3_short_ IntersectPoint, signed int sModelID); void BLV_CreateIntersectFacesVertexCoordList(int *a, int *b, __int16 *intersect_face_vertex_coords_list_a, __int16 *intersect_face_vertex_coords_list_b, Vec3_short_ *IntersectPoint, BLVFace *pFace); void ODM_CreateIntersectFacesVertexCoordList(int *a, int *b, __int16 *intersect_face_vertex_coords_list_a, __int16 *intersect_face_vertex_coords_list_b, Vec3_short_ *IntersectPoint, BLVFace *pFace, unsigned int uModelID); void CastPickRay(RenderVertexSoft *pRay, float fMouseX, float fMouseY, float fPickDepth); diff -r 8fa26b63244a -r 30c2b575d25c _deleted.cpp --- a/_deleted.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/_deleted.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -2122,13 +2122,13 @@ array_77EC08[1999].Create_48607B(&stru_8019C8); array_77EC08[1999].ptr_38->_48694B_frustum_sky(); - if (pOutdoor->uMainTile_BitmapID == -1) + if (pOutdoor->sMainTile_BitmapID == -1) { array_77EC08[1999].pTexture = nullptr; return; } else - array_77EC08[1999].pTexture = pBitmaps_LOD->GetTexture(pOutdoor->uMainTile_BitmapID); + array_77EC08[1999].pTexture = pBitmaps_LOD->GetTexture(pOutdoor->sMainTile_BitmapID); array_77EC08[1999].dimming_level = 23 - (-20 * pOutdoor->vSunlight.z >> 16); if ( array_77EC08[1999].dimming_level > 20 ) array_77EC08[1999].dimming_level = 20; @@ -2145,13 +2145,13 @@ array_77EC08[1999].Create_48607B(&stru_8019C8); array_77EC08[1999].ptr_38->_48694B_frustum_sky(); - if (pOutdoor->uSky_TextureID == -1) + if (pOutdoor->sSky_TextureID == -1) { array_77EC08[1999].pTexture = nullptr; return; } else - array_77EC08[1999].pTexture = pBitmaps_LOD->GetTexture(pOutdoor->uSky_TextureID); + array_77EC08[1999].pTexture = pBitmaps_LOD->GetTexture(pOutdoor->sSky_TextureID); array_77EC08[1999].dimming_level = 0; v11 = stru_5C6E00->Sin(pIndoorCamera->sRotationX + 16); array_77EC08[1999].v_18.y = 0; diff -r 8fa26b63244a -r 30c2b575d25c mm7_2.cpp --- a/mm7_2.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/mm7_2.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -4717,7 +4717,7 @@ }; void SetCurrentMenuID(MENU_STATE uMenu) { - uCurrentMenuID = uMenu; + sCurrentMenuID = uMenu; Log::Warning(L"CurrentMenu = %s", MENU_STATE_to_string(uMenu)); } @@ -4725,7 +4725,7 @@ //----- (00466CA0) -------------------------------------------------------- MENU_STATE GetCurrentMenuID() { - return uCurrentMenuID; + return sCurrentMenuID; } diff -r 8fa26b63244a -r 30c2b575d25c mm7_3.cpp --- a/mm7_3.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/mm7_3.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -4674,7 +4674,7 @@ v[0].pos.y = pViewport->uScreen_TL_Y; v[0].pos.z = 0.99989998; v[0].rhw = 1; - v[0].diffuse = 0xFFFFFFFF; + v[0].diffuse = -1; v[0].specular = 0; v[0].texcoord.x = 0; v[0].texcoord.y = 0; @@ -4683,7 +4683,7 @@ v[1].pos.y = pViewport->uScreen_TL_Y + pViewport->uScreenHeight; v[1].pos.z = 0.99989998; v[1].rhw = 1; - v[1].diffuse = 0xFFFFFFFF; + v[1].diffuse = -1; v[1].specular = 0; v[1].texcoord.x = (float)pViewport->uScreenWidth / skybox_width; v[1].texcoord.y = (float)pViewport->uScreenHeight / skybox_height; @@ -4692,7 +4692,7 @@ v[2].pos.y = pViewport->uScreen_TL_Y; v[2].pos.z = 0.99989998; v[2].rhw = 1; - v[2].diffuse = 0xFFFFFFFF; + v[2].diffuse = -1; v[2].specular = 0; v[2].texcoord.x = (float)pViewport->uScreenWidth / skybox_width; v[2].texcoord.y = 0; @@ -4703,7 +4703,7 @@ v[4].pos.y = pViewport->uScreen_TL_Y + pViewport->uScreenHeight; v[4].pos.z = 0.99989998; v[4].rhw = 1; - v[4].diffuse = 0xFFFFFFFF; + v[4].diffuse = -1; v[4].specular = 0; v[4].texcoord.x = 0; v[4].texcoord.y = (float)pViewport->uScreenHeight / skybox_height; diff -r 8fa26b63244a -r 30c2b575d25c mm7_4.cpp --- a/mm7_4.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/mm7_4.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -401,7 +401,7 @@ } //----- (0048A959) -------------------------------------------------------- -unsigned int ReplaceHSV(unsigned int uColor, float h_replace, float s_replace, float v_replace) +signed int ReplaceHSV(unsigned int uColor, float h_replace, float s_replace, float v_replace) { float r = ((uColor & 0x00FF0000) >> 16) / 255.0f, g = ((uColor & 0x0000FF00) >> 8) / 255.0f, diff -r 8fa26b63244a -r 30c2b575d25c mm7_5.cpp --- a/mm7_5.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/mm7_5.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -290,7 +290,7 @@ layingitem_vel_50FDFC.z = pSpriteObjects[uLayingItemID].vVelocity.z; Vec3_int_::Normalize(&layingitem_vel_50FDFC.x, &layingitem_vel_50FDFC.y, &layingitem_vel_50FDFC.z); - DamagePlayerFromMonster(PID(OBJECT_Item, uLayingItemID), pSpriteObjects[uLayingItemID].field_61, &layingitem_vel_50FDFC, 0xFFFFFFFFu); + DamagePlayerFromMonster(PID(OBJECT_Item, uLayingItemID), pSpriteObjects[uLayingItemID].field_61, &layingitem_vel_50FDFC, -1); } else if (PID_TYPE(a2) == OBJECT_Actor) { diff -r 8fa26b63244a -r 30c2b575d25c mm7_data.cpp --- a/mm7_data.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/mm7_data.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -1148,7 +1148,7 @@ void *ptr_6A0D08; int _6A0D0C_txt_lod_loading; // weak int _6A0D10_txt_lod_loading__unused; // weak -MENU_STATE uCurrentMenuID; +MENU_STATE sCurrentMenuID; unsigned int uGameState; int uDefaultTravelTime_ByFoot; // weak int day_attrib; // weak diff -r 8fa26b63244a -r 30c2b575d25c mm7_data.h --- a/mm7_data.h Wed Nov 06 00:09:47 2013 -0800 +++ b/mm7_data.h Wed Nov 06 13:06:02 2013 +0000 @@ -794,7 +794,7 @@ extern void *ptr_6A0D08; extern int _6A0D0C_txt_lod_loading; // weak extern int _6A0D10_txt_lod_loading__unused; // weak -extern enum MENU_STATE uCurrentMenuID; +extern enum MENU_STATE sCurrentMenuID; extern unsigned int uGameState; extern int uDefaultTravelTime_ByFoot; // weak extern int day_attrib; // weak @@ -1107,7 +1107,7 @@ double get_shading_dist_mist(); void Vec3_short__to_RenderVertexSoft(struct RenderVertexSoft *_this, struct Vec3_short_ *a2); void area_of_effect__damage_evaluate(); -void __fastcall DamagePlayerFromMonster(unsigned int uObjID, int a2, struct Vec3_int_ *pPos, unsigned int a4); +void __fastcall DamagePlayerFromMonster(unsigned int uObjID, int a2, struct Vec3_int_ *pPos, signed int a4); void __fastcall sub_43A97E(unsigned int uLayingItemID, signed int a2); // idb double __fastcall sub_43AE12(signed int a1); int __fastcall _43AFE3_calc_spell_damage(int a1, int a2, signed int a3, int a4); @@ -1221,7 +1221,7 @@ double GetFogDensityByTime(struct OutdoorLocation *_this); bool __fastcall HSV2RGB(float *a1, float *a2, float *a3, float a4, float a5, float a6); void __fastcall RGB2HSV(float *a1, float *a2, float a3, float a4, float a5, float *a6); -unsigned int ReplaceHSV(unsigned int uColor, float a2, float gamma, float a4); +signed int ReplaceHSV(unsigned int uColor, float a2, float gamma, float a4); bool PlayerCreation_Choose4Skills(); int PlayerCreation_GetUnspentAttributePointCount(); void LoadPlayerPortraintsAndVoices(); diff -r 8fa26b63244a -r 30c2b575d25c stru10.cpp --- a/stru10.cpp Wed Nov 06 00:09:47 2013 -0800 +++ b/stru10.cpp Wed Nov 06 13:06:02 2013 +0000 @@ -730,7 +730,7 @@ extern bool draw_debug_line; if ( draw_debug_line ) - pGame->pIndoorCameraD3D->do_draw_debug_line_sw(&v25, 0xFFFFFFFFu, &v26, 0xFFFF00u, 0, 0); + pGame->pIndoorCameraD3D->do_draw_debug_line_sw(&v25, -1, &v26, 0xFFFF00u, 0, 0); } //}