Mercurial > mm7
comparison mm7_1.cpp @ 586:3c7fca0e01a0
sub_41CD4F clean
author | zipi |
---|---|
date | Wed, 06 Mar 2013 12:02:40 +0000 |
parents | 3ac7059a3f4f |
children | fb0e105683e9 c615ff03b144 |
comparison
equal
deleted
inserted
replaced
585:3ac7059a3f4f | 586:3c7fca0e01a0 |
---|---|
1931 while ( 1 ) | 1931 while ( 1 ) |
1932 { | 1932 { |
1933 v3 = pVisibleWindowsIdxs[v27] - 1; | 1933 v3 = pVisibleWindowsIdxs[v27] - 1; |
1934 if ( pWindowList[v3].field_44 != v1 ) | 1934 if ( pWindowList[v3].field_44 != v1 ) |
1935 { | 1935 { |
1936 if ( v26 != 34 ) | 1936 switch(v26) |
1937 { | 1937 { |
1938 if ( v26 == 37 ) | 1938 case VK_LEFT: |
1939 { | |
1940 v12 = pWindowList[v3].field_34; | |
1941 if ( pWindowList[v3].pCurrentPosActiveItem - pWindowList[v3].pStartingPosActiveItem - v12 >= 0 ) | |
1942 { | |
1943 v8 = pCurrentScreen == SCREEN_PARTY_CREATION; | |
1944 pWindowList[v3].pCurrentPosActiveItem -= v12; | |
1945 if ( v8 ) | |
1946 { | |
1947 pAudioPlayer->PlaySound(SOUND_Button, v1, v1, -1, v1, v1, v1, v1); | |
1948 v2 = pMessageQueue_50CBD0->uNumMessages; | |
1949 } | |
1950 } | |
1951 if ( pWindowList[v3].field_30 != v1 ) | |
1952 { | |
1953 --v27; | |
1954 if ( v27 < 0 ) | |
1955 return 0; | |
1956 continue; | |
1957 } | |
1958 v9 = pWindowList[v3].pControlsHead; | |
1959 v13 = pWindowList[v3].pCurrentPosActiveItem; | |
1960 if ( v13 > (signed int)v1 ) | |
1961 { | |
1962 do | |
1963 { | |
1964 v9 = v9->pNext; | |
1965 --v13; | |
1966 } | |
1967 while ( v13 ); | |
1968 } | |
1969 v11 = v9->uControlParam; | |
1970 /*if ( (signed int)v2 < 40 ) | |
1971 { | |
1972 pMessageQueue_50CBD0->pMessages[v2].eType = (UIMessageType)v9->uControlID; | |
1973 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = v11; | |
1974 *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = v1; | |
1975 v2 = pMessageQueue_50CBD0->uNumMessages + 1; | |
1976 ++pMessageQueue_50CBD0->uNumMessages; | |
1977 }*/ | |
1978 pMessageQueue_50CBD0->AddMessage((UIMessageType)v9->uControlID, v11, v1); | |
1979 --v27; | |
1980 if ( v27 < 0 ) | |
1981 return 0; | |
1982 continue; | |
1983 } | |
1984 if ( v26 != 38 ) | |
1985 { | |
1986 if ( v26 == 39 ) | |
1987 { | |
1988 v7 = pWindowList[v3].pCurrentPosActiveItem + pWindowList[v3].field_34; | |
1989 if ( v7 < pWindowList[v3].pNumPresenceButton + pWindowList[v3].pStartingPosActiveItem ) | |
1990 { | |
1991 v8 = pCurrentScreen == SCREEN_PARTY_CREATION; | |
1992 pWindowList[v3].pCurrentPosActiveItem = v7; | |
1993 if ( v8 ) | |
1994 { | 1939 { |
1995 pAudioPlayer->PlaySound(SOUND_Button, v1, v1, -1, v1, v1, v1, v1); | 1940 v12 = pWindowList[v3].field_34; |
1996 v2 = pMessageQueue_50CBD0->uNumMessages; | 1941 if ( pWindowList[v3].pCurrentPosActiveItem - pWindowList[v3].pStartingPosActiveItem - v12 >= 0 ) |
1942 { | |
1943 v8 = pCurrentScreen == SCREEN_PARTY_CREATION; | |
1944 pWindowList[v3].pCurrentPosActiveItem -= v12; | |
1945 if ( v8 ) | |
1946 { | |
1947 pAudioPlayer->PlaySound(SOUND_Button, v1, v1, -1, v1, v1, v1, v1); | |
1948 v2 = pMessageQueue_50CBD0->uNumMessages; | |
1949 } | |
1997 } | 1950 } |
1998 } | 1951 if ( pWindowList[v3].field_30 != v1 ) |
1999 if ( pWindowList[v3].field_30 != v1 ) | |
2000 { | |
2001 --v27; | |
2002 if ( v27 < 0 ) | |
2003 return 0; | |
2004 continue; | |
2005 } | |
2006 v9 = pWindowList[v3].pControlsHead; | |
2007 v10 = pWindowList[v3].pCurrentPosActiveItem; | |
2008 if ( v10 > (signed int)v1 ) | |
2009 { | |
2010 do | |
2011 { | 1952 { |
2012 v9 = v9->pNext; | 1953 break; |
2013 --v10; | |
2014 } | 1954 } |
2015 while ( v10 ); | 1955 v9 = pWindowList[v3].pControlsHead; |
2016 } | 1956 v13 = pWindowList[v3].pCurrentPosActiveItem; |
2017 v11 = v9->uControlParam; | 1957 if ( v13 > (signed int)v1 ) |
2018 pMessageQueue_50CBD0->AddMessage((UIMessageType)v9->uControlID, v11, v1); | |
2019 --v27; | |
2020 if ( v27 < 0 ) | |
2021 return 0; | |
2022 continue; | |
2023 } | |
2024 if ( v26 == 40 ) | |
2025 { | |
2026 v17 = pWindowList[v3].pStartingPosActiveItem; | |
2027 v18 = pWindowList[v3].pCurrentPosActiveItem; | |
2028 if ( v18 >= pWindowList[v3].pNumPresenceButton + v17 - 1 ) | |
2029 pWindowList[v3].pCurrentPosActiveItem = v17; | |
2030 else | |
2031 pWindowList[v3].pCurrentPosActiveItem = v18 + 1; | |
2032 if ( pWindowList[v3].field_30 != v1 ) | |
2033 return 1; | |
2034 v19 = pWindowList[v3].pControlsHead; | |
2035 v20 = pWindowList[v3].pCurrentPosActiveItem; | |
2036 if ( v20 > (signed int)v1 ) | |
2037 { | |
2038 do | |
2039 { | 1958 { |
2040 v19 = v19->pNext; | 1959 do |
2041 --v20; | 1960 { |
1961 v9 = v9->pNext; | |
1962 --v13; | |
1963 } | |
1964 while ( v13 ); | |
2042 } | 1965 } |
2043 while ( v20 ); | 1966 v11 = v9->uControlParam; |
2044 } | 1967 /*if ( (signed int)v2 < 40 ) |
2045 v21 = v19->uControlParam; | |
2046 pMessageQueue_50CBD0->AddMessage((UIMessageType)v19->uControlID, v21, v1); | |
2047 return 1; | |
2048 } | |
2049 if ( v26 == 41 ) | |
2050 { | |
2051 pMouse->GetClickPos(&uClickX, &uClickY); | |
2052 v4 = pWindowList[v3].pStartingPosActiveItem; | |
2053 v28 = v4 + pWindowList[v3].pNumPresenceButton; | |
2054 if ( v4 < v4 + pWindowList[v3].pNumPresenceButton ) | |
2055 { | |
2056 while ( 1 ) | |
2057 { | 1968 { |
2058 v5 = pWindowList[v3].pControlsHead; | 1969 pMessageQueue_50CBD0->pMessages[v2].eType = (UIMessageType)v9->uControlID; |
2059 if ( v4 > 0 ) | 1970 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = v11; |
2060 { | 1971 *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = v1; |
2061 v6 = v4; | 1972 v2 = pMessageQueue_50CBD0->uNumMessages + 1; |
1973 ++pMessageQueue_50CBD0->uNumMessages; | |
1974 }*/ | |
1975 pMessageQueue_50CBD0->AddMessage((UIMessageType)v9->uControlID, v11, v1); | |
1976 break; | |
1977 } | |
1978 case VK_RIGHT: | |
1979 { | |
1980 v7 = pWindowList[v3].pCurrentPosActiveItem + pWindowList[v3].field_34; | |
1981 if ( v7 < pWindowList[v3].pNumPresenceButton + pWindowList[v3].pStartingPosActiveItem ) | |
1982 { | |
1983 v8 = pCurrentScreen == SCREEN_PARTY_CREATION; | |
1984 pWindowList[v3].pCurrentPosActiveItem = v7; | |
1985 if ( v8 ) | |
1986 { | |
1987 pAudioPlayer->PlaySound(SOUND_Button, v1, v1, -1, v1, v1, v1, v1); | |
1988 v2 = pMessageQueue_50CBD0->uNumMessages; | |
1989 } | |
1990 } | |
1991 if ( pWindowList[v3].field_30 != v1 ) | |
1992 { | |
1993 break; | |
1994 } | |
1995 v9 = pWindowList[v3].pControlsHead; | |
1996 v10 = pWindowList[v3].pCurrentPosActiveItem; | |
1997 if ( v10 > (signed int)v1 ) | |
1998 { | |
2062 do | 1999 do |
2063 { | 2000 { |
2064 v5 = v5->pNext; | 2001 v9 = v9->pNext; |
2065 --v6; | 2002 --v10; |
2066 } | 2003 } |
2067 while ( v6 ); | 2004 while ( v10 ); |
2068 } | |
2069 if ( (signed int)uClickX >= (signed int)v5->uX | |
2070 && (signed int)uClickX <= (signed int)v5->uZ | |
2071 && (signed int)uClickY >= (signed int)v5->uY | |
2072 && (signed int)uClickY <= (signed int)v5->uW ) | |
2073 break; | |
2074 ++v4; | |
2075 if ( v4 >= v28 ) | |
2076 { | |
2077 v1 = 0; | |
2078 v2 = pMessageQueue_50CBD0->uNumMessages; | |
2079 --v27; | |
2080 if ( v27 < 0 ) | |
2081 return 0; | |
2082 continue; | |
2083 } | |
2084 } | 2005 } |
2085 pWindowList[v3].pCurrentPosActiveItem = v4; | 2006 v11 = v9->uControlParam; |
2007 pMessageQueue_50CBD0->AddMessage((UIMessageType)v9->uControlID, v11, v1); | |
2008 break; | |
2009 } | |
2010 case VK_DOWN: | |
2011 { | |
2012 v17 = pWindowList[v3].pStartingPosActiveItem; | |
2013 v18 = pWindowList[v3].pCurrentPosActiveItem; | |
2014 if ( v18 >= pWindowList[v3].pNumPresenceButton + v17 - 1 ) | |
2015 pWindowList[v3].pCurrentPosActiveItem = v17; | |
2016 else | |
2017 pWindowList[v3].pCurrentPosActiveItem = v18 + 1; | |
2018 if ( pWindowList[v3].field_30 != v1 ) | |
2019 return 1; | |
2020 v19 = pWindowList[v3].pControlsHead; | |
2021 v20 = pWindowList[v3].pCurrentPosActiveItem; | |
2022 if ( v20 > (signed int)v1 ) | |
2023 { | |
2024 do | |
2025 { | |
2026 v19 = v19->pNext; | |
2027 --v20; | |
2028 } | |
2029 while ( v20 ); | |
2030 } | |
2031 v21 = v19->uControlParam; | |
2032 pMessageQueue_50CBD0->AddMessage((UIMessageType)v19->uControlID, v21, v1); | |
2086 return 1; | 2033 return 1; |
2087 } | 2034 } |
2088 v2 = pMessageQueue_50CBD0->uNumMessages; | 2035 case VK_SELECT: |
2089 --v27; | |
2090 if ( v27 < 0 ) | |
2091 return 0; | |
2092 continue; | |
2093 } | |
2094 --v27; | |
2095 if ( v27 < 0 ) | |
2096 return 0; | |
2097 continue; | |
2098 } | |
2099 v22 = pWindowList[v3].pCurrentPosActiveItem; | |
2100 v23 = pWindowList[v3].pStartingPosActiveItem; | |
2101 if ( v22 <= v23 ) | |
2102 v24 = pWindowList[v3].pNumPresenceButton + v23 - 1; | |
2103 else | |
2104 v24 = v22 - 1; | |
2105 v8 = pWindowList[v3].field_30 == v1; | |
2106 pWindowList[v3].pCurrentPosActiveItem = v24; | |
2107 if ( !v8 ) | |
2108 return 1; | |
2109 v19 = pWindowList[v3].pControlsHead; | |
2110 v25 = pWindowList[v3].pCurrentPosActiveItem; | |
2111 if ( v25 > (signed int)v1 ) | |
2112 { | |
2113 do | |
2114 { | |
2115 v19 = v19->pNext; | |
2116 --v25; | |
2117 } | |
2118 while ( v25 ); | |
2119 } | |
2120 v21 = v19->uControlParam; | |
2121 /*if ( (signed int)v2 < 40 ) | |
2122 { | |
2123 pMessageQueue_50CBD0->pMessages[v2].eType = (UIMessageType)v19->uControlID; | |
2124 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = v21; | |
2125 *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = v1; | |
2126 ++pMessageQueue_50CBD0->uNumMessages; | |
2127 }*/ | |
2128 pMessageQueue_50CBD0->AddMessage((UIMessageType)v19->uControlID, v21, v1); | |
2129 return 1; | |
2130 } | |
2131 if ( pWindowList[v3].field_30 != v1 ) | |
2132 { | |
2133 pMouse->GetClickPos(&uClickX, &uClickY); | |
2134 v4 = pWindowList[v3].pStartingPosActiveItem; | |
2135 v29 = v4 + pWindowList[v3].pNumPresenceButton; | |
2136 if ( v4 < v4 + pWindowList[v3].pNumPresenceButton ) | |
2137 { | |
2138 while ( 1 ) | |
2139 { | |
2140 v14 = pWindowList[v3].pControlsHead; | |
2141 if ( v4 > 0 ) | |
2142 { | |
2143 v15 = v4; | |
2144 do | |
2145 { | 2036 { |
2146 v14 = v14->pNext; | 2037 pMouse->GetClickPos(&uClickX, &uClickY); |
2147 --v15; | 2038 v4 = pWindowList[v3].pStartingPosActiveItem; |
2039 v28 = v4 + pWindowList[v3].pNumPresenceButton; | |
2040 if ( v4 < v4 + pWindowList[v3].pNumPresenceButton ) | |
2041 { | |
2042 while ( 1 ) | |
2043 { | |
2044 v5 = pWindowList[v3].pControlsHead; | |
2045 if ( v4 > 0 ) | |
2046 { | |
2047 v6 = v4; | |
2048 do | |
2049 { | |
2050 v5 = v5->pNext; | |
2051 --v6; | |
2052 } | |
2053 while ( v6 ); | |
2054 } | |
2055 if ( (signed int)uClickX >= (signed int)v5->uX | |
2056 && (signed int)uClickX <= (signed int)v5->uZ | |
2057 && (signed int)uClickY >= (signed int)v5->uY | |
2058 && (signed int)uClickY <= (signed int)v5->uW ) | |
2059 break; | |
2060 ++v4; | |
2061 if ( v4 >= v28 ) | |
2062 { | |
2063 v1 = 0; | |
2064 v2 = pMessageQueue_50CBD0->uNumMessages; | |
2065 --v27; | |
2066 if ( v27 < 0 ) | |
2067 return 0; | |
2068 continue; | |
2069 } | |
2070 } | |
2071 pWindowList[v3].pCurrentPosActiveItem = v4; | |
2072 return 1; | |
2148 } | 2073 } |
2149 while ( v15 ); | 2074 v2 = pMessageQueue_50CBD0->uNumMessages; |
2150 } | 2075 break; |
2151 if ( (signed int)uClickX >= (signed int)v14->uX | 2076 } |
2152 && (signed int)uClickX <= (signed int)v14->uZ | 2077 case VK_UP: |
2153 && (signed int)uClickY >= (signed int)v14->uY | 2078 { |
2154 && (signed int)uClickY <= (signed int)v14->uW ) | 2079 v22 = pWindowList[v3].pCurrentPosActiveItem; |
2155 { | 2080 v23 = pWindowList[v3].pStartingPosActiveItem; |
2156 pWindowList[v3].pCurrentPosActiveItem = v4; | 2081 if ( v22 <= v23 ) |
2082 v24 = pWindowList[v3].pNumPresenceButton + v23 - 1; | |
2083 else | |
2084 v24 = v22 - 1; | |
2085 v8 = pWindowList[v3].field_30 == v1; | |
2086 pWindowList[v3].pCurrentPosActiveItem = v24; | |
2087 if ( !v8 ) | |
2088 return 1; | |
2089 v19 = pWindowList[v3].pControlsHead; | |
2090 v25 = pWindowList[v3].pCurrentPosActiveItem; | |
2091 if ( v25 > (signed int)v1 ) | |
2092 { | |
2093 do | |
2094 { | |
2095 v19 = v19->pNext; | |
2096 --v25; | |
2097 } | |
2098 while ( v25 ); | |
2099 } | |
2100 v21 = v19->uControlParam; | |
2101 /*if ( (signed int)v2 < 40 ) | |
2102 { | |
2103 pMessageQueue_50CBD0->pMessages[v2].eType = (UIMessageType)v19->uControlID; | |
2104 pMessageQueue_50CBD0->pMessages[pMessageQueue_50CBD0->uNumMessages].param = v21; | |
2105 *(&pMessageQueue_50CBD0->uNumMessages + 3 * pMessageQueue_50CBD0->uNumMessages + 3) = v1; | |
2106 ++pMessageQueue_50CBD0->uNumMessages; | |
2107 }*/ | |
2108 pMessageQueue_50CBD0->AddMessage((UIMessageType)v19->uControlID, v21, v1); | |
2157 return 1; | 2109 return 1; |
2158 } | 2110 } |
2159 ++v4; | 2111 case VK_NEXT: |
2160 if ( v4 >= v29 ) | 2112 { |
2161 { | 2113 if ( pWindowList[v3].field_30 != v1 ) |
2162 v1 = 0; | 2114 { |
2163 v2 = pMessageQueue_50CBD0->uNumMessages; | 2115 pMouse->GetClickPos(&uClickX, &uClickY); |
2116 v4 = pWindowList[v3].pStartingPosActiveItem; | |
2117 v29 = v4 + pWindowList[v3].pNumPresenceButton; | |
2118 if ( v4 < v4 + pWindowList[v3].pNumPresenceButton ) | |
2119 { | |
2120 while ( 1 ) | |
2121 { | |
2122 v14 = pWindowList[v3].pControlsHead; | |
2123 if ( v4 > 0 ) | |
2124 { | |
2125 v15 = v4; | |
2126 do | |
2127 { | |
2128 v14 = v14->pNext; | |
2129 --v15; | |
2130 } | |
2131 while ( v15 ); | |
2132 } | |
2133 if ( (signed int)uClickX >= (signed int)v14->uX | |
2134 && (signed int)uClickX <= (signed int)v14->uZ | |
2135 && (signed int)uClickY >= (signed int)v14->uY | |
2136 && (signed int)uClickY <= (signed int)v14->uW ) | |
2137 { | |
2138 pWindowList[v3].pCurrentPosActiveItem = v4; | |
2139 return 1; | |
2140 } | |
2141 ++v4; | |
2142 if ( v4 >= v29 ) | |
2143 { | |
2144 v1 = 0; | |
2145 v2 = pMessageQueue_50CBD0->uNumMessages; | |
2146 break; | |
2147 } | |
2148 } | |
2149 } | |
2150 else | |
2151 { | |
2152 v2 = pMessageQueue_50CBD0->uNumMessages; | |
2153 } | |
2154 } | |
2164 break; | 2155 break; |
2165 } | 2156 } |
2166 } | 2157 default: |
2167 } | 2158 { |
2168 else | 2159 break; |
2169 { | 2160 } |
2170 v2 = pMessageQueue_50CBD0->uNumMessages; | 2161 |
2171 } | |
2172 } | 2162 } |
2173 } | 2163 } |
2174 --v27; | 2164 --v27; |
2175 if ( v27 < 0 ) | 2165 if ( v27 < 0 ) |
2176 return 0; | 2166 return 0; |
2443 wHintWindow.DrawTitleText(pFontArrus, 0, 0xCu, var88, v16, 3u); | 2433 wHintWindow.DrawTitleText(pFontArrus, 0, 0xCu, var88, v16, 3u); |
2444 v17 = pFontArrus->CalcTextHeight(pGlobalTXT_LocalizationStrings[32], &wHintWindow, 0, 0); //"Broken Item" | 2434 v17 = pFontArrus->CalcTextHeight(pGlobalTXT_LocalizationStrings[32], &wHintWindow, 0, 0); //"Broken Item" |
2445 v18 = v17 >> 1; | 2435 v18 = v17 >> 1; |
2446 v19 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0x19u, 0x19u); | 2436 v19 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0x19u, 0x19u); |
2447 wHintWindow.DrawTitleText(pFontArrus, 0x64u, ((signed int)wHintWindow.uFrameHeight >> 1) - v18, v19, pGlobalTXT_LocalizationStrings[32], 3); //"Broken Item" | 2437 wHintWindow.DrawTitleText(pFontArrus, 0x64u, ((signed int)wHintWindow.uFrameHeight >> 1) - v18, v19, pGlobalTXT_LocalizationStrings[32], 3); //"Broken Item" |
2448 goto LABEL_116; | 2438 pRenderer->ResetClip(); |
2439 if ( !areWeLoadingTexture ) | |
2440 { | |
2441 v73->Release(); | |
2442 pIcons_LOD->_40F9C5(); | |
2443 } | |
2444 return; | |
2449 } | 2445 } |
2450 if (!inspect_item->Identified()) | 2446 if (!inspect_item->Identified()) |
2451 { | 2447 { |
2452 wHintWindow.DrawMessageBox(0); | 2448 wHintWindow.DrawMessageBox(0); |
2453 pRenderer->Clip(wHintWindow.uFrameX + 12, wHintWindow.uFrameY + 12, | 2449 pRenderer->Clip(wHintWindow.uFrameX + 12, wHintWindow.uFrameY + 12, |
2461 wHintWindow.DrawTitleText(pFontArrus, 0, 0xCu, var88, item_desc->pUnidentifiedName, 3u); | 2457 wHintWindow.DrawTitleText(pFontArrus, 0, 0xCu, var88, item_desc->pUnidentifiedName, 3u); |
2462 v17 = pFontArrus->CalcTextHeight(pGlobalTXT_LocalizationStrings[232], &wHintWindow, 0, 0); ///"Not Identified" | 2458 v17 = pFontArrus->CalcTextHeight(pGlobalTXT_LocalizationStrings[232], &wHintWindow, 0, 0); ///"Not Identified" |
2463 v18 = v17 >> 1; | 2459 v18 = v17 >> 1; |
2464 v19 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0x19u, 0x19u); | 2460 v19 = GenerateColorAsCloseAsPossibleToR8G8B8InTargetFormat(0xFFu, 0x19u, 0x19u); |
2465 wHintWindow.DrawTitleText(pFontArrus, 0x64u, ((signed int)wHintWindow.uFrameHeight >> 1) - v18, v19, pGlobalTXT_LocalizationStrings[232], 3); | 2461 wHintWindow.DrawTitleText(pFontArrus, 0x64u, ((signed int)wHintWindow.uFrameHeight >> 1) - v18, v19, pGlobalTXT_LocalizationStrings[232], 3); |
2466 goto LABEL_116; | 2462 pRenderer->ResetClip(); |
2463 if ( !areWeLoadingTexture ) | |
2464 { | |
2465 v73->Release(); | |
2466 pIcons_LOD->_40F9C5(); | |
2467 } | |
2468 return; | |
2467 } | 2469 } |
2468 | 2470 |
2469 sprintfex(out_text, pGlobalTXT_LocalizationStrings[463], item_desc->pUnidentifiedName); //"Type: %s" | 2471 sprintfex(out_text, pGlobalTXT_LocalizationStrings[463], item_desc->pUnidentifiedName); //"Type: %s" |
2470 out_text[100] = 0; | 2472 out_text[100] = 0; |
2471 out_text[200] = 0; | 2473 out_text[200] = 0; |
2515 case EQUIP_REAGENT: | 2517 case EQUIP_REAGENT: |
2516 sprintf(out_text + 200, "%s: %d", pGlobalTXT_LocalizationStrings[449], pItemsTable->pItems[inspect_item->uItemID].uDamageDice); //"Power" | 2518 sprintf(out_text + 200, "%s: %d", pGlobalTXT_LocalizationStrings[449], pItemsTable->pItems[inspect_item->uItemID].uDamageDice); //"Power" |
2517 break; | 2519 break; |
2518 } | 2520 } |
2519 | 2521 |
2520 if ( v77 ) | 2522 if ( !v77 ) |
2521 goto LABEL_65; | 2523 { |
2522 //v23 = item_desc->uEquipType; | 2524 //v23 = item_desc->uEquipType; |
2525 if ( inspect_item->uEncantmentType ) | |
2526 { | |
2527 sprintf(out_text + 200, "%s: %s +%d", pGlobalTXT_LocalizationStrings[210], | |
2528 pItemsTable->pEnchantments[inspect_item->uEncantmentType-1].pBonusStat, inspect_item->_bonus_strength); //"Special" | |
2529 } | |
2530 else if ( inspect_item->uSpecEnchantmentType ) | |
2531 { | |
2532 sprintf(out_text + 200, "%s: %s", pGlobalTXT_LocalizationStrings[210], | |
2533 pItemsTable->pSpecialEnchantments[inspect_item->uSpecEnchantmentType-1].pBonusStatement, inspect_item->_bonus_strength); | |
2534 } | |
2523 | 2535 |
2524 | 2536 else if ( inspect_item->uNumCharges ) |
2525 if ( inspect_item->uEncantmentType ) | 2537 { |
2526 { | 2538 sprintf(out_text + 200, "%s: %lu", pGlobalTXT_LocalizationStrings[464], inspect_item->uNumCharges); //"Charges" |
2527 sprintf(out_text + 200, "%s: %s +%d", pGlobalTXT_LocalizationStrings[210], | 2539 |
2528 pItemsTable->pEnchantments[inspect_item->uEncantmentType-1].pBonusStat, inspect_item->_bonus_strength); //"Special" | 2540 } |
2529 } | 2541 } |
2530 else if ( inspect_item->uSpecEnchantmentType ) | |
2531 { | |
2532 sprintf(out_text + 200, "%s: %s", pGlobalTXT_LocalizationStrings[210], | |
2533 pItemsTable->pSpecialEnchantments[inspect_item->uSpecEnchantmentType-1].pBonusStatement, inspect_item->_bonus_strength); | |
2534 } | |
2535 | |
2536 else if ( inspect_item->uNumCharges ) | |
2537 { | |
2538 sprintf(out_text + 200, "%s: %lu", pGlobalTXT_LocalizationStrings[464], inspect_item->uNumCharges); //"Charges" | |
2539 | |
2540 } | |
2541 | |
2542 LABEL_65: | |
2543 wHintWindow.uFrameWidth -= 12; | 2542 wHintWindow.uFrameWidth -= 12; |
2544 v85 = 3; | 2543 v85 = 3; |
2545 wHintWindow.uFrameZ = wHintWindow.uFrameX + wHintWindow.uFrameWidth - 1; | 2544 wHintWindow.uFrameZ = wHintWindow.uFrameX + wHintWindow.uFrameWidth - 1; |
2546 wHintWindow.uFrameW = wHintWindow.uFrameY + wHintWindow.uFrameHeight - 1; | 2545 wHintWindow.uFrameW = wHintWindow.uFrameY + wHintWindow.uFrameHeight - 1; |
2547 Str = (char *)(3 * (LOBYTE(pFontArrus->uFontHeight) + 8)); | 2546 Str = (char *)(3 * (LOBYTE(pFontArrus->uFontHeight) + 8)); |
2671 v47 = pGlobalTXT_LocalizationStrings[187]; //"Stolen" | 2670 v47 = pGlobalTXT_LocalizationStrings[187]; //"Stolen" |
2672 } | 2671 } |
2673 else | 2672 else |
2674 { | 2673 { |
2675 if ( !(BYTE1(v38) & 2) ) | 2674 if ( !(BYTE1(v38) & 2) ) |
2676 goto LABEL_116; | 2675 { |
2676 pRenderer->ResetClip(); | |
2677 if ( !areWeLoadingTexture ) | |
2678 { | |
2679 v73->Release(); | |
2680 pIcons_LOD->_40F9C5(); | |
2681 } | |
2682 return; | |
2683 } | |
2677 v61 = 0; | 2684 v61 = 0; |
2678 v56 = 0; | 2685 v56 = 0; |
2679 v51 = 0; | 2686 v51 = 0; |
2680 v47 = pGlobalTXT_LocalizationStrings[651]; //"Hardened" | 2687 v47 = pGlobalTXT_LocalizationStrings[651]; //"Hardened" |
2681 } | 2688 } |
2685 v39 = pFontComic->GetLineWidth(pTmpBuf); | 2692 v39 = pFontComic->GetLineWidth(pTmpBuf); |
2686 v40 = pFontComic; | 2693 v40 = pFontComic; |
2687 v41 = v39 + 132; | 2694 v41 = v39 + 132; |
2688 } | 2695 } |
2689 wHintWindow.DrawText(v40, v41, v42, v44, v47, v51, v56, v61); | 2696 wHintWindow.DrawText(v40, v41, v42, v44, v47, v51, v56, v61); |
2690 LABEL_116: | |
2691 pRenderer->ResetClip(); | 2697 pRenderer->ResetClip(); |
2692 if ( !areWeLoadingTexture ) | 2698 if ( !areWeLoadingTexture ) |
2693 { | 2699 { |
2694 v73->Release(); | 2700 v73->Release(); |
2695 pIcons_LOD->_40F9C5(); | 2701 pIcons_LOD->_40F9C5(); |