You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(42) |
Sep
(42) |
Oct
(57) |
Nov
(12) |
Dec
(47) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(14) |
Feb
(4) |
Mar
(52) |
Apr
(13) |
May
(89) |
Jun
(38) |
Jul
(5) |
Aug
(32) |
Sep
(68) |
Oct
(27) |
Nov
(2) |
Dec
(13) |
2004 |
Jan
(3) |
Feb
(6) |
Mar
(3) |
Apr
(1) |
May
|
Jun
(2) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <ha...@us...> - 2003-03-07 23:37:59
|
Update of /cvsroot/decaldev/source/Decal In directory sc8-pr-cvs1:/tmp/cvs-serv17776 Modified Files: ACHooks.h ACHooks.cpp Log Message: Fix huge merge error Index: ACHooks.h =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.h,v retrieving revision 1.34 retrieving revision 1.35 diff -C2 -d -r1.34 -r1.35 *** ACHooks.h 7 Mar 2003 19:17:26 -0000 1.34 --- ACHooks.h 7 Mar 2003 23:37:55 -0000 1.35 *************** *** 5,9 **** #include "DecalManager.h" #include "DecalCP.h" ! #import "..\Include\Inject.tlb" struct sMemoryLocation --- 5,17 ---- #include "DecalManager.h" #include "DecalCP.h" ! ! // .NET vs VC6.0 Compiler Config ! #if _MSC_VER > 1200 // .NET ! #import "..\Include\Inject.tlb" ! #define IPSite DecalPlugins::IPluginSite ! #else // Not .Net ! #include "..\inject\Inject.h" ! #define IPSite IPluginSite ! #endif struct sMemoryLocation *************** *** 21,24 **** --- 29,58 ---- }; + struct qSkill { + long vTable; + enum eTrainLevel Trained; + int TotalXP; + int FreePoints; + int Clicks; + int unk1; + int unk2; /* float? percent of total? */ + float unk3; + }; + + struct qVital { + long vTable; + int Clicks; + int unk1; + int TotalXP; + int unk2; + }; + + struct qAttribute { + long vTable; + int Clicks; + int Start; + int TotalXP; + }; + struct qPointerList { *************** *** 169,172 **** --- 203,223 ---- long m_lLogout; + bool m_bSecureTrade_Add; + long m_lSecureTrade_Add; + bool m_bSecureTrade_Add_Off1; + long m_lSecureTrade_Add_Off1; + bool m_bSecureTrade_Add_Off2; + long m_lSecureTrade_Add_Off2; + + bool m_bGetSkillInfo; + long m_lGetSkillInfo, m_lGetSkillInfo_vT; + bool m_bGetAttributeInfo; + long m_lGetAttributeInfo, m_lGetAttributeInfo_vT; + bool m_bGetVitalInfo; + long m_lGetVitalInfo, m_lGetVitalInfo_vT; + + bool m_bChatColor; + long m_lChatColor; + bool m_bSelectItemHook; long m_lSelectItemHook; *************** *** 231,233 **** --- 282,302 ---- STDMETHOD(Logout)(); STDMETHOD(SetDecal)(IUnknown *pDecal); + + STDMETHOD(SecureTrade_Add)(long ItemID, VARIANT_BOOL *pVal); + + STDMETHOD(get_SkillTrainLevel)( eSkill SkillID, eTrainLevel *pVal ); + STDMETHOD(get_SkillTotalXP)( eSkill SkillID, int *pVal ); + STDMETHOD(get_SkillFreePoints)( eSkill SkillID, int *pVal ); + STDMETHOD(get_SkillClicks)( eSkill SkillID, int *pVal ); + + STDMETHOD(get_AttributeClicks)( eAttribute AttributeID, int *pVal ); + STDMETHOD(get_AttributeTotalXP)( eAttribute AttributeID, int *pVal ); + STDMETHOD(get_AttributeStart)( eAttribute AttributeID, int *pVal ); + + STDMETHOD(get_VitalClicks)( eVital VitalID, int *pVal ); + STDMETHOD(get_VitalTotalXP)( eVital VitalID, int *pVal ); + + HRESULT GetSkillInfo(eSkill SkillID, struct qSkill *Skill); + HRESULT GetAttributeInfo(eAttribute AttributeID, struct qAttribute *Attribute); + HRESULT GetVitalInfo(eVital VitalID, struct qVital *Vital); }; Index: ACHooks.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.cpp,v retrieving revision 1.40 retrieving revision 1.41 diff -C2 -d -r1.40 -r1.41 *** ACHooks.cpp 7 Mar 2003 19:17:26 -0000 1.40 --- ACHooks.cpp 7 Mar 2003 23:37:55 -0000 1.41 *************** *** 26,30 **** long g_lSelectItemHijackProc = 0; ! void (*pfnOldChatMessage)( char *, DWORD ) = NULL; void (*pfnOldChatText)() = NULL; void (*pfnUseItem)( DWORD, DWORD ) = NULL; --- 26,30 ---- long g_lSelectItemHijackProc = 0; ! void (__fastcall *pfnOldChatMessage)(int _ecx, int _edx, char *, DWORD ) = NULL; void (*pfnOldChatText)() = NULL; void (*pfnUseItem)( DWORD, DWORD ) = NULL; *************** *** 37,41 **** qString* ( __fastcall *pfnInternalStringConstructor)( qString *, long, char * ) = NULL; ! extern void OnChatMessage( char* pText, long dwColor ); extern void OnChatText(); --- 37,44 ---- qString* ( __fastcall *pfnInternalStringConstructor)( qString *, long, char * ) = NULL; ! bool g_bTimestamp; ! char charBufferPreviousCall; ! ! extern void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long dwColor ); extern void OnChatText(); *************** *** 46,50 **** cACHooks::cACHooks() { ! _bstr_t _Unnamed; s_pACHooks = this; USES_CONVERSION; --- 49,54 ---- cACHooks::cACHooks() { ! g_bTimestamp = false; ! _bstr_t _Unnamed; s_pACHooks = this; USES_CONVERSION; *************** *** 79,92 **** m_bGetSkill = false; m_bLogout = false; m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); m_HookCount = 0; char szPath[ MAX_PATH ]; DWORD dwCount = MAX_PATH; ! CRegKey keyPath; ! keyPath.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal\\Agent", KEY_READ ); ! keyPath.QueryValue( szPath, "AgentPath", &dwCount ); strncat( szPath, "\\memlocs.xml", MAX_PATH ); --- 83,113 ---- m_bGetSkill = false; m_bLogout = false; + m_bSecureTrade_Add = false; + m_bSecureTrade_Add_Off1 = false; + m_bSecureTrade_Add_Off2 = false; + m_bGetSkillInfo = false; + m_bGetAttributeInfo = false; + m_bGetVitalInfo = false; + m_bSelectItemHook = false; + m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); m_HookCount = 0; + charBufferPreviousCall = '\n'; char szPath[ MAX_PATH ]; + DWORD dwCount = MAX_PATH; ! DWORD dwTimestamp = 0; ! CRegKey key; ! key.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal", KEY_READ ); ! key.QueryValue( dwTimestamp, "Timestamp" ); ! key.Close(); ! ! g_bTimestamp = static_cast< bool >( dwTimestamp ); ! ! key.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal\\Agent", KEY_READ ); ! key.QueryValue( szPath, "AgentPath", &dwCount ); strncat( szPath, "\\memlocs.xml", MAX_PATH ); *************** *** 181,185 **** if( QueryMemLoc( BSTRT( "ChatMessage" ), &Val ) == S_OK ) ! pfnOldChatMessage = reinterpret_cast< void (*)( char *, DWORD ) >( Val ); if( QueryMemLoc( BSTRT( "ChatMessageAddy" ), &Val ) == S_OK ) m_lChatMessageAddy = Val; --- 202,206 ---- if( QueryMemLoc( BSTRT( "ChatMessage" ), &Val ) == S_OK ) ! pfnOldChatMessage = reinterpret_cast< void (__fastcall*)( int, int, char *, DWORD ) >( Val ); if( QueryMemLoc( BSTRT( "ChatMessageAddy" ), &Val ) == S_OK ) m_lChatMessageAddy = Val; *************** *** 511,514 **** --- 532,620 ---- } + if (QueryMemLoc(BSTRT( "SecureTrade_Add" ), &Val) == S_OK) + { + m_lSecureTrade_Add = Val; + m_bSecureTrade_Add = true; + } + + if (QueryMemLoc(BSTRT( "SecureTrade_Add_Off1" ), &Val) == S_OK) + { + m_lSecureTrade_Add_Off1 = Val; + m_bSecureTrade_Add_Off1 = true; + } + + if (QueryMemLoc(BSTRT( "SecureTrade_Add_Off2" ), &Val) == S_OK) + { + m_lSecureTrade_Add_Off2 = Val; + m_bSecureTrade_Add_Off2 = true; + } + + if (m_bSecureTrade_Add && m_bSecureTrade_Add_Off1 && m_bSecureTrade_Add_Off2 && m_bCombatState) + { + SetHookEx(eSecureTrade_Add); + } + + + if (QueryMemLoc(BSTRT( "GetSkillInfo" ), &Val) == S_OK) + { + m_lGetSkillInfo = Val; + m_bGetSkillInfo = true; + } + + if (QueryMemLoc(BSTRT( "GetVitalInfo" ), &Val) == S_OK) + { + m_lGetVitalInfo = Val; + m_bGetVitalInfo = true; + } + + if (QueryMemLoc(BSTRT( "GetAttributeInfo" ), &Val) == S_OK) + { + m_lGetAttributeInfo = Val; + m_bGetAttributeInfo = true; + } + + + /* I don't believe the vTable is used for any of these, however, if it becomes necessary + the functionality is here to a) detect the problem (crash at 0xFF......), and fix it + without requiring a complete update to Decal */ + if (QueryMemLoc(BSTRT( "GetSkillInfo_vT" ), &Val) == S_OK) + { + m_lGetSkillInfo_vT = Val; + } + else + { + m_lGetSkillInfo_vT = 0xFF111111; + } + + if (QueryMemLoc(BSTRT( "GetVitalInfo_vT" ), &Val) == S_OK) + { + m_lGetVitalInfo_vT = Val; + } + else + { + m_lGetVitalInfo_vT = 0xFF222222; + } + + if (QueryMemLoc(BSTRT( "GetAttributeInfo_vT" ), &Val) == S_OK) + { + m_lGetAttributeInfo_vT = Val; + } + else + { + m_lGetAttributeInfo_vT = 0xFF333333; + } + + if (m_lVitalBase) { + if (m_bGetSkillInfo) { + SetHookEx(eSkillInfo); + } + if (m_bGetVitalInfo) { + SetHookEx(eVitalInfo); + } + if (m_bGetAttributeInfo) { + SetHookEx(eAttributeInfo); + } + } + DWORD dwOldProtect; if( QueryMemLoc( BSTRT( "OnChatText" ), &Val ) == S_OK ) *************** *** 645,670 **** return S_FALSE; - USES_CONVERSION; - - char *strText = OLE2A( szText ); - char *pText = new char[ strlen( strText ) + 3 ]; - _snprintf( pText, strlen( strText ) + 2, "%s\n", strText ); - DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); if( *Addy == NULL ) return S_FALSE; ! __asm { ! mov esi, Addy ! mov ecx, [esi] ! push lColor ! push pText ! call pfnOldChatMessage ! add esp, 0x8 } - - delete [] pText; return S_OK; --- 751,859 ---- return S_FALSE; DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); if( *Addy == NULL ) return S_FALSE; ! USES_CONVERSION; ! ! char *strText = OLE2A( szText ); ! int iStrLen = strlen( strText ); ! ! if( g_bTimestamp ) { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! ! int iOffset = 0; ! char *szTemp = strText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! ! charBufferPreviousCall = '\n'; ! ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); ! } ! } ! ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! ! else ! { ! if( bDoTimeStamp ) ! { ! if( strText != NULL ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, szTimeStamp, lColor ); ! } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! ! else ! { ! //_snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! } ! ! char *szNewLine = "\n"; ! pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); ! ! delete [] szTimeStamp; ! } ! ! else ! { ! char *pText = new char[ iStrLen + 3 ]; ! _snprintf( pText, iStrLen + 2, "%s\n", strText ); ! pfnOldChatMessage( *Addy, 0, pText, lColor ); ! delete [] pText; } return S_OK; *************** *** 676,698 **** return S_FALSE; - USES_CONVERSION; - - char *strText = OLE2A( szText ); - DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); if( *Addy == NULL ) return S_FALSE; ! __asm { ! mov esi, Addy ! mov ecx, [esi] ! push lColor ! push strText ! call pfnOldChatMessage ! add esp, 0x8 } ! return S_OK; } --- 865,964 ---- return S_FALSE; DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); if( *Addy == NULL ) return S_FALSE; ! USES_CONVERSION; ! ! char *strText = OLE2A( szText ); ! ! if( g_bTimestamp ) { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! int iStrLen = strlen( strText ); ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! ! int iOffset = 0; ! char *szTemp = strText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); ! } ! } ! ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! ! else ! { ! if( bDoTimeStamp ) ! { ! if( strText != NULL ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, szTimeStamp, lColor ); ! } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! ! else ! { ! //_snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! } ! ! delete [] szTimeStamp; } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! return S_OK; } *************** *** 823,828 **** if( m_bDecalRef ) { ! CComPtr< DecalPlugins::IPluginSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( DecalPlugins::IPluginSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) --- 1089,1094 ---- if( m_bDecalRef ) { ! CComPtr< IPSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( IPSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) *************** *** 1395,1398 **** --- 1661,1936 ---- } + STDMETHODIMP cACHooks::SecureTrade_Add(long ItemID, VARIANT_BOOL *pVal) + { + void ( __fastcall *Internal_SecureTrade_Add )( struct qPointerList *, int, long ); + struct qPointerList *p; + VARIANT_BOOL ItemExists; + HRESULT hr; + + if (pVal) /* Should probably return an error code. Tough. */ + { + *pVal = VARIANT_FALSE; + } + + if ( m_bSecureTrade_Add && m_bSecureTrade_Add_Off1 && m_bSecureTrade_Add_Off2 && m_bCombatState ) + { + hr = ItemIsKnown(ItemID, &ItemExists); + if (FAILED(hr)) + { + return hr; + } + + if (ItemExists == VARIANT_FALSE) + { + return S_FALSE; + } + + p = (struct qPointerList *)m_lCombatState; + if (!p) + { + return S_FALSE; + } + + p = p->dd[0]; + if (!p) + { + return S_FALSE; + } + + p = p->dd[m_lSecureTrade_Add_Off1 >> 2]; + if (!p) + { + return S_FALSE; + } + + p = p->dd[m_lSecureTrade_Add_Off2 >> 2]; + if (!p) + { + return S_FALSE; + } + + Internal_SecureTrade_Add = reinterpret_cast< void ( __fastcall *)( struct qPointerList *, int, long ) >( m_lSecureTrade_Add ); + Internal_SecureTrade_Add(p, 0, ItemID); + if (pVal) + { + *pVal = VARIANT_TRUE; + } + return S_OK; + } + return S_FALSE; + } + + HRESULT cACHooks::GetSkillInfo(eSkill SkillID, struct qSkill *Skill) { + int ( __fastcall *Internal_GetSkillInfo )( void *, int, int, struct qSkill * ); + + if (!m_bGetSkillInfo) { + return E_FAIL; + } + + if (SkillID > 50) { + SkillID = (eSkill)(SkillID - 50); + } + if ((SkillID < 1) || (SkillID > 50)) { + return E_INVALIDARG; + } + + + Skill->vTable = m_lGetSkillInfo_vT; + + Internal_GetSkillInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qSkill *) >(m_lGetSkillInfo); + if (Internal_GetSkillInfo(*(void **)m_lVitalBase, 0, SkillID, Skill)) { + return S_OK; + } + return E_FAIL; + } + + HRESULT cACHooks::GetAttributeInfo(eAttribute AttributeID, struct qAttribute *Attribute) { + int (__fastcall *Internal_GetAttributeInfo)(void *, int, int, struct qAttribute *); + + if (!m_bGetAttributeInfo) { + return E_FAIL; + } + + if (AttributeID > 6) { + AttributeID = (eAttribute)(AttributeID - 6); + } + if ((AttributeID < 1) || (AttributeID > 6)) { + return E_INVALIDARG; + } + + Attribute->vTable = m_lGetAttributeInfo_vT; + + Internal_GetAttributeInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qAttribute *) >(m_lGetAttributeInfo); + if (Internal_GetAttributeInfo(*(void **)m_lVitalBase, 0, AttributeID, Attribute)) { + return S_OK; + } + return E_FAIL; + } + + HRESULT cACHooks::GetVitalInfo(eVital VitalID, struct qVital *Vital) { + int (__fastcall *Internal_GetVitalInfo)(void *, int, int, struct qVital *); + + if (!m_bGetVitalInfo) { + return E_FAIL; + } + + switch (VitalID) { + case eCurrentHealth: + case eMaximumHealth: + case eBaseHealth: + VitalID = eCurrentHealth; + break; + case eCurrentStamina: + case eMaximumStamina: + case eBaseStamina: + VitalID = eCurrentStamina; + break; + case eCurrentMana: + case eMaximumMana: + case eBaseMana: + VitalID = eCurrentMana; + break; + default: + return E_INVALIDARG; + } + + + Vital->vTable = m_lGetVitalInfo_vT; + + Internal_GetVitalInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qVital *) >(m_lGetVitalInfo); + if (Internal_GetVitalInfo(*(void **)m_lVitalBase, 0, VitalID, Vital)) { + return S_OK; + } + return E_FAIL; + } + + STDMETHODIMP cACHooks::get_SkillTrainLevel( eSkill SkillID, eTrainLevel *pVal ) + { + struct qSkill Skill; + HRESULT hr; + hr = GetSkillInfo(SkillID, &Skill); + if (FAILED(hr)) { + return hr; + } + + *pVal = Skill.Trained; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_SkillTotalXP( eSkill SkillID, int *pVal ) + { + struct qSkill Skill; + HRESULT hr; + hr = GetSkillInfo(SkillID, &Skill); + if (FAILED(hr)) { + return hr; + } + + *pVal = Skill.TotalXP; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_SkillFreePoints( eSkill SkillID, int *pVal ) + { + struct qSkill Skill; + HRESULT hr; + hr = GetSkillInfo(SkillID, &Skill); + if (FAILED(hr)) { + return hr; + } + + *pVal = Skill.FreePoints; + + return S_OK; + } + + + STDMETHODIMP cACHooks::get_SkillClicks( eSkill SkillID, int *pVal ) + { + struct qSkill Skill; + HRESULT hr; + hr = GetSkillInfo(SkillID, &Skill); + if (FAILED(hr)) { + return hr; + } + + *pVal = Skill.Clicks; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_AttributeClicks( eAttribute AttributeID, int *pVal ) + { + struct qAttribute Attribute; + HRESULT hr; + hr = GetAttributeInfo(AttributeID, &Attribute); + if (FAILED(hr)) { + return hr; + } + + *pVal = Attribute.Clicks; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_AttributeTotalXP( eAttribute AttributeID, int *pVal ) + { + struct qAttribute Attribute; + HRESULT hr; + hr = GetAttributeInfo(AttributeID, &Attribute); + if (FAILED(hr)) { + return hr; + } + + *pVal = Attribute.TotalXP; + + return S_OK; + } + + + STDMETHODIMP cACHooks::get_AttributeStart( eAttribute AttributeID, int *pVal ) + { + struct qAttribute Attribute; + HRESULT hr; + hr = GetAttributeInfo(AttributeID, &Attribute); + if (FAILED(hr)) { + return hr; + } + + *pVal = Attribute.Start; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_VitalClicks( eVital VitalID, int *pVal ) + { + struct qVital Vital; + HRESULT hr; + hr = GetVitalInfo(VitalID, &Vital); + if (FAILED(hr)) { + return hr; + } + + *pVal = Vital.Clicks; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_VitalTotalXP( eVital VitalID, int *pVal ) + { + struct qVital Vital; + HRESULT hr; + hr = GetVitalInfo(VitalID, &Vital); + if (FAILED(hr)) { + return hr; + } + + *pVal = Vital.TotalXP; + + return S_OK; + } + void cACHooks::SetHookEx( eAvailableHooksEx HookID ) { *************** *** 1519,1526 **** } ! bool DispatchChatMessage( char *pText, long *pdwColor ) { if( cACHooks::s_pACHooks ) ! return cACHooks::s_pACHooks->InternalChatMessage( pText, *pdwColor ); return false; --- 2057,2064 ---- } ! bool DispatchChatMessage( char *pText, long pdwColor ) { if( cACHooks::s_pACHooks ) ! return cACHooks::s_pACHooks->InternalChatMessage( pText, pdwColor ); return false; *************** *** 1535,1572 **** } ! void __declspec(naked) OnChatMessage( char* pText, long dwColor ) { ! __asm { ! push ebp ! mov ebp, esp ! sub esp, 20h ! push esi ! push ecx ! lea esi, dwColor ! push esi ! push pText ! call DispatchChatMessage ! add esp, 8 ! test al, al ! jz dont_kill_text ! mov dword ptr [pText], 0 ! dont_kill_text: ! pop ecx ! push dwColor ! push pText ! call pfnOldChatMessage ! pop esi ! mov esp, ebp ! pop ebp ! retn 8 } } --- 2073,2161 ---- } ! void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long lColor ) { ! if( !DispatchChatMessage( pText, lColor ) ) { ! if( g_bTimestamp ) ! { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! int iStrLen = strlen( pText ); ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! int iOffset = 0; ! char *szTemp = pText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( _ecx, _edx, szTimeStampA, lColor ); ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( _ecx, _edx, szNewLine, lColor ); ! } ! } ! ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( _ecx, _edx, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! ! else ! { ! if( bDoTimeStamp ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, pText ); ! pfnOldChatMessage( _ecx, _edx, szTimeStamp, lColor ); ! } ! ! else ! { ! _snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, pText ); ! pfnOldChatMessage( _ecx, _edx, szTimeStamp, lColor ); ! } ! } ! ! delete [] szTimeStamp; ! } ! ! else ! pfnOldChatMessage( _ecx, _edx, pText, lColor ); } } |
From: <ha...@us...> - 2003-03-07 23:37:44
|
Update of /cvsroot/decaldev/source/Include In directory sc8-pr-cvs1:/tmp/cvs-serv17653 Modified Files: Decal.idl Log Message: Fix huge merge error Index: Decal.idl =================================================================== RCS file: /cvsroot/decaldev/source/Include/Decal.idl,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** Decal.idl 7 Mar 2003 19:17:53 -0000 1.31 --- Decal.idl 7 Mar 2003 23:37:40 -0000 1.32 *************** *** 8,12 **** import "ocidl.idl"; ! enum eAttribute { eCurrentHealth = 1, --- 8,21 ---- import "ocidl.idl"; ! /* I'm not 100% sure about this */ ! enum eTrainLevel ! { ! eUntrained = 1, ! eTrained = 2, ! eSpecialized = 3, ! eTrainLevel_DWORD = 0x7FFFFFFF ! }; ! ! enum eVital { eCurrentHealth = 1, *************** *** 19,22 **** --- 28,36 ---- eBaseStamina = 8, eBaseMana = 9, + eVital_DWORD = 0x7FFFFFFF + }; + + enum eAttribute + { eCurrentStrength = 1, eCurrentEndurance = 2, *************** *** 30,34 **** eBaseCoordination = 10, eBaseFocus = 11, ! eBaseSelf = 12 }; --- 44,49 ---- eBaseCoordination = 10, eBaseFocus = 11, ! eBaseSelf = 12, ! eAttribute_DWORD = 0x7FFFFFFF }; *************** *** 104,144 **** eBaseFletchingSkill = 87, eBaseAlchemySkill = 88, ! eBaseCookingSkill = 89 }; enum eAvailableHooks { ! ePrevSelect = 0x00000001, ! eCurrentSelect = 0x00000002, ! eMouse = 0x00000004, ! eCastSpell = 0x00000008, ! eMoveItem = 0x00000010, ! eSelectItem = 0x00000020, ! eUseItem = 0x00000040, ! eCombatState = 0x00000080, ! eChatState = 0x00000100, ! eGetFellowStats = 0x00000200, ! eStackCount = 0x00000400, ! eTestFormula = 0x00000800, ! eVendorID = 0x00001000, ! eBusyState = 0x00002000, ! eBusyStateID = 0x00004000, ! ePointerState = 0x00008000, ! eMoveItemEx = 0x00010000, ! ePosition = 0x00020000, ! eFaceHeading = 0x00040000, ! eArea3DWidth = 0x00080000, ! eArea3DHeight = 0x00100000, ! eObjectDestroyed = 0x00200000, ! eSendTell = 0x00400000, ! eSetAutorun = 0x00800000, ! eGetVital = 0x01000000, ! eSendTellEx = 0x02000000, ! eLocalChatText = 0x04000000, ! eLocalChatEmote = 0x08000000, ! eSetCombatState = 0x10000000, ! eGetAttribute = 0x20000000, ! eGetSkill = 0x40000000, ! eHooksAvailEx = 0x80000000 }; --- 119,160 ---- eBaseFletchingSkill = 87, eBaseAlchemySkill = 88, ! eBaseCookingSkill = 89, ! eSkill_DWORD = 0x7FFFFFFF }; enum eAvailableHooks { ! ePrevSelect = 0x00000001, ! eCurrentSelect = 0x00000002, ! eMouse = 0x00000004, ! eCastSpell = 0x00000008, ! eMoveItem = 0x00000010, ! eSelectItem = 0x00000020, ! eUseItem = 0x00000040, ! eCombatState = 0x00000080, ! eChatState = 0x00000100, ! eGetFellowStats = 0x00000200, ! eStackCount = 0x00000400, ! eTestFormula = 0x00000800, ! eVendorID = 0x00001000, ! eBusyState = 0x00002000, ! eBusyStateID = 0x00004000, ! ePointerState = 0x00008000, ! eMoveItemEx = 0x00010000, ! ePosition = 0x00020000, ! eFaceHeading = 0x00040000, ! eArea3DWidth = 0x00080000, ! eArea3DHeight = 0x00100000, ! eObjectDestroyed = 0x00200000, ! eSendTell = 0x00400000, ! eSetAutorun = 0x00800000, ! eGetVital = 0x01000000, ! eSendTellEx = 0x02000000, ! eLocalChatText = 0x04000000, ! eLocalChatEmote = 0x08000000, ! eSetCombatState = 0x10000000, ! eGetAttribute = 0x20000000, ! eGetSkill = 0x40000000, ! eHooksAvailEx = 0x80000000 }; *************** *** 147,155 **** { eLogout = 0, ! eObjectFromGUID = 1, ! eObjectFromGUIDClass = 2, ! eOnSelectItemEvent = 3, ! eAvailableHooksEx_DWORD = 0x7FFFFFFF // coerce enums into 4 byte instead of two }; --- 163,177 ---- { eLogout = 0, ! eSecureTrade_Add = 1, ! eColorEx = 2, ! eSkillInfo = 3, ! eAttributeInfo = 4, ! eVitalInfo = 5, ! eObjectFromGUID = 6, ! eObjectFromGUIDClass = 7, ! eOnSelectItemEvent = 8, ! eAvailableHooksEx_DWORD = 0x7FFFFFFF // coerce enums into 4 byte instead of two }; + *************** *** 246,249 **** --- 268,284 ---- [id(43), helpstring("method Logout")] HRESULT Logout(); [id(44), helpstring("method SetDecal")] HRESULT SetDecal([in] IUnknown *pDecal); + [id(45), helpstring("method SecureTrade_Add")] HRESULT SecureTrade_Add([in] long ItemID, [out, retval] VARIANT_BOOL *pVal); + + [propget, id(46), helpstring("property SkillTrainLevel")] HRESULT SkillTrainLevel([in] enum eSkill SkillID, [out, retval] enum eTrainLevel *pVal); + [propget, id(47), helpstring("property SkillTotalXP")] HRESULT SkillTotalXP([in] enum eSkill SkillID, [out, retval] int *pVal); + [propget, id(48), helpstring("property SkillFreePoints")] HRESULT SkillFreePoints([in] enum eSkill SkillID, [out, retval] int *pVal); + [propget, id(49), helpstring("property SkillClicks")] HRESULT SkillClicks([in] enum eSkill SkillID, [out, retval] int *pVal); + + [propget, id(50), helpstring("property AttributeTotalXP")] HRESULT AttributeTotalXP([in] enum eAttribute AttributeID, [out, retval] int *pVal); + [propget, id(51), helpstring("property AttributeClicks")] HRESULT AttributeClicks([in] enum eAttribute AttributeID, [out, retval] int *pVal); + [propget, id(52), helpstring("property AttributeStart")] HRESULT AttributeStart([in] enum eAttribute AttributeID, [out, retval] int *pVal); + + [propget, id(53), helpstring("property VitalTotalXP")] HRESULT VitalTotalXP([in] enum eVital VitalD, [out, retval] int *pVal); + [propget, id(54), helpstring("property VitalClicks")] HRESULT VitalClicks([in] enum eVital VitalID, [out, retval] int *pVal); }; |
From: <ha...@us...> - 2003-03-07 19:18:03
|
Update of /cvsroot/decaldev/source/Include In directory sc8-pr-cvs1:/tmp/cvs-serv1339 Modified Files: Decal.idl Log Message: SelectItemHook + fix for some of the hook enums Index: Decal.idl =================================================================== RCS file: /cvsroot/decaldev/source/Include/Decal.idl,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** Decal.idl 22 Feb 2003 04:56:52 -0000 1.30 --- Decal.idl 7 Mar 2003 19:17:53 -0000 1.31 *************** *** 8,21 **** import "ocidl.idl"; ! /* I'm not 100% sure about this */ ! enum eTrainLevel ! { ! eUntrained = 1, ! eTrained = 2, ! eSpecialized = 3, ! eTrainLevel_DWORD = 0x7FFFFFFF ! }; ! ! enum eVital { eCurrentHealth = 1, --- 8,12 ---- import "ocidl.idl"; ! enum eAttribute { eCurrentHealth = 1, *************** *** 25,40 **** eCurrentMana = 5, eMaximumMana = 6, ! eBaseHealth = 7, eBaseStamina = 8, ! eBaseMana = 9, ! eVital_DWORD = 0x7FFFFFFF ! }; ! ! enum eAttribute ! { eCurrentStrength = 1, eCurrentEndurance = 2, eCurrentQuickness = 3, ! eCurrentCoordination = 4, eCurrentFocus = 5, eCurrentSelf = 6, --- 16,26 ---- eCurrentMana = 5, eMaximumMana = 6, ! eBaseHealth = 7, eBaseStamina = 8, ! eBaseMana = 9, eCurrentStrength = 1, eCurrentEndurance = 2, eCurrentQuickness = 3, ! eCurrentCoordination = 4, eCurrentFocus = 5, eCurrentSelf = 6, *************** *** 43,75 **** eBaseQuickness = 9, eBaseCoordination = 10, ! eBaseFocus = 11, ! eBaseSelf = 12, ! eAttribute_DWORD = 0x7FFFFFFF }; enum eSkill { ! eCurrentAxe = 1, ! eCurrentBow = 2, ! eCurrentCrossbow = 3, ! eCurrentDagger = 4, ! eCurrentMace = 5, eCurrentMeleeDefense = 6, eCurrentMissileDefense = 7, ! eCurrentSpear = 9, ! eCurrentStaff = 10, ! eCurrentSword = 11, eCurrentThrownWeapons = 12, ! eCurrentUnarmed = 13, ! eCurrentArcaneLore = 14, eCurrentMagicDefense = 15, eCurrentManaConversion = 16, eCurrentItemTinkering = 18, eCurrentAssessPerson = 19, ! eCurrentDeception = 20, ! eCurrentHealing = 21, ! eCurrentJump = 22, ! eCurrentLockpick = 23, ! eCurrentRun = 24, eCurrentAssessCreature = 27, eCurrentWeaponTinkering = 28, --- 29,60 ---- eBaseQuickness = 9, eBaseCoordination = 10, ! eBaseFocus = 11, ! eBaseSelf = 12 }; enum eSkill { ! eCurrentAxe = 1, ! eCurrentBow = 2, ! eCurrentCrossbow = 3, ! eCurrentDagger = 4, ! eCurrentMace = 5, eCurrentMeleeDefense = 6, eCurrentMissileDefense = 7, ! eCurrentSpear = 9, ! eCurrentStaff = 10, ! eCurrentSword = 11, eCurrentThrownWeapons = 12, ! eCurrentUnarmed = 13, ! eCurrentArcaneLore = 14, eCurrentMagicDefense = 15, eCurrentManaConversion = 16, eCurrentItemTinkering = 18, eCurrentAssessPerson = 19, ! eCurrentDeception = 20, ! eCurrentHealing = 21, ! eCurrentJump = 22, ! eCurrentLockpick = 23, ! eCurrentRun = 24, eCurrentAssessCreature = 27, eCurrentWeaponTinkering = 28, *************** *** 78,159 **** eCurrentCreatureEnchantment = 31, eCurrentItemEnchantment = 32, ! eCurrentLifeMagic = 33, ! eCurrentWarMagic = 34, ! eCurrentLeadership = 35, ! eCurrentLoyalty = 36, eCurrentFletchingSkill = 37, eCurrentAlchemySkill = 38, eCurrentCookingSkill = 39, ! eBaseAxe = 51, ! eBaseBow = 52, ! eBaseCrossbow = 53, ! eBaseDagger = 54, ! eBaseMace = 55, ! eBaseMeleeDefense = 56, ! eBaseMissileDefense = 57, ! eBaseSpear = 59, ! eBaseStaff = 60, ! eBaseSword = 61, ! eBaseThrownWeapons = 62, ! eBaseUnarmed = 63, ! eBaseArcaneLore = 64, ! eBaseMagicDefense = 65, ! eBaseManaConversion = 66, ! eBaseItemTinkering = 68, ! eBaseAssessPerson = 69, ! eBaseDeception = 70, ! eBaseHealing = 71, ! eBaseJump = 72, ! eBaseLockpick = 73, ! eBaseRun = 74, ! eBaseAssessCreature = 77, eBaseWeaponTinkering = 78, ! eBaseArmorTinkering = 79, eBaseMagicItemTinkering = 80, eBaseCreatureEnchantment = 81, eBaseItemEnchantment = 82, ! eBaseLifeMagic = 83, ! eBaseWarMagic = 84, ! eBaseLeadership = 85, ! eBaseLoyalty = 86, ! eBaseFletchingSkill = 87, ! eBaseAlchemySkill = 88, ! eBaseCookingSkill = 89, ! eSkill_DWORD = 0x7FFFFFFF }; enum eAvailableHooks { ! ePrevSelect = 0x00000001, eCurrentSelect = 0x00000002, ! eMouse = 0x00000004, ! eCastSpell = 0x00000008, ! eMoveItem = 0x00000010, ! eSelectItem = 0x00000020, ! eUseItem = 0x00000040, eCombatState = 0x00000080, ! eChatState = 0x00000100, eGetFellowStats = 0x00000200, ! eStackCount = 0x00000400, eTestFormula = 0x00000800, ! eVendorID = 0x00001000, ! eBusyState = 0x00002000, eBusyStateID = 0x00004000, ePointerState = 0x00008000, ! eMoveItemEx = 0x00010000, ! ePosition = 0x00020000, eFaceHeading = 0x00040000, eArea3DWidth = 0x00080000, eArea3DHeight = 0x00100000, eObjectDestroyed = 0x00200000, ! eSendTell = 0x00400000, ! eSetAutorun = 0x00800000, ! eGetVital = 0x01000000, ! eSendTellEx = 0x02000000, eLocalChatText = 0x04000000, eLocalChatEmote = 0x08000000, eSetCombatState = 0x10000000, eGetAttribute = 0x20000000, ! eGetSkill = 0x40000000, eHooksAvailEx = 0x80000000 }; --- 63,143 ---- eCurrentCreatureEnchantment = 31, eCurrentItemEnchantment = 32, ! eCurrentLifeMagic = 33, ! eCurrentWarMagic = 34, ! eCurrentLeadership = 35, ! eCurrentLoyalty = 36, eCurrentFletchingSkill = 37, eCurrentAlchemySkill = 38, eCurrentCookingSkill = 39, ! eBaseAxe = 51, ! eBaseBow = 52, ! eBaseCrossbow = 53, ! eBaseDagger = 54, ! eBaseMace = 55, ! eBaseMeleeDefense = 56, ! eBaseMissileDefense = 57, ! eBaseSpear = 59, ! eBaseStaff = 60, ! eBaseSword = 61, ! eBaseThrownWeapons = 62, ! eBaseUnarmed = 63, ! eBaseArcaneLore = 64, ! eBaseMagicDefense = 65, ! eBaseManaConversion = 66, ! eBaseItemTinkering = 68, ! eBaseAssessPerson = 69, ! eBaseDeception = 70, ! eBaseHealing = 71, ! eBaseJump = 72, ! eBaseLockpick = 73, ! eBaseRun = 74, ! eBaseAssessCreature = 77, eBaseWeaponTinkering = 78, ! eBaseArmorTinkering = 79, eBaseMagicItemTinkering = 80, eBaseCreatureEnchantment = 81, eBaseItemEnchantment = 82, ! eBaseLifeMagic = 83, ! eBaseWarMagic = 84, ! eBaseLeadership = 85, ! eBaseLoyalty = 86, ! eBaseFletchingSkill = 87, ! eBaseAlchemySkill = 88, ! eBaseCookingSkill = 89 }; enum eAvailableHooks { ! ePrevSelect = 0x00000001, eCurrentSelect = 0x00000002, ! eMouse = 0x00000004, ! eCastSpell = 0x00000008, ! eMoveItem = 0x00000010, ! eSelectItem = 0x00000020, ! eUseItem = 0x00000040, eCombatState = 0x00000080, ! eChatState = 0x00000100, eGetFellowStats = 0x00000200, ! eStackCount = 0x00000400, eTestFormula = 0x00000800, ! eVendorID = 0x00001000, ! eBusyState = 0x00002000, eBusyStateID = 0x00004000, ePointerState = 0x00008000, ! eMoveItemEx = 0x00010000, ! ePosition = 0x00020000, eFaceHeading = 0x00040000, eArea3DWidth = 0x00080000, eArea3DHeight = 0x00100000, eObjectDestroyed = 0x00200000, ! eSendTell = 0x00400000, ! eSetAutorun = 0x00800000, ! eGetVital = 0x01000000, ! eSendTellEx = 0x02000000, eLocalChatText = 0x04000000, eLocalChatEmote = 0x08000000, eSetCombatState = 0x10000000, eGetAttribute = 0x20000000, ! eGetSkill = 0x40000000, eHooksAvailEx = 0x80000000 }; *************** *** 162,171 **** enum eAvailableHooksEx { ! eLogout = 0, ! eSecureTrade_Add = 1, ! eColorEx = 2, ! eSkillInfo = 3, ! eAttributeInfo = 4, ! eVitalInfo = 5, eAvailableHooksEx_DWORD = 0x7FFFFFFF // coerce enums into 4 byte instead of two }; --- 146,153 ---- enum eAvailableHooksEx { ! eLogout = 0, ! eObjectFromGUID = 1, ! eObjectFromGUIDClass = 2, ! eOnSelectItemEvent = 3, eAvailableHooksEx_DWORD = 0x7FFFFFFF // coerce enums into 4 byte instead of two }; *************** *** 264,280 **** [id(43), helpstring("method Logout")] HRESULT Logout(); [id(44), helpstring("method SetDecal")] HRESULT SetDecal([in] IUnknown *pDecal); - [id(45), helpstring("method SecureTrade_Add")] HRESULT SecureTrade_Add([in] long ItemID, [out, retval] VARIANT_BOOL *pVal); - - [propget, id(46), helpstring("property SkillTrainLevel")] HRESULT SkillTrainLevel([in] enum eSkill SkillID, [out, retval] enum eTrainLevel *pVal); - [propget, id(47), helpstring("property SkillTotalXP")] HRESULT SkillTotalXP([in] enum eSkill SkillID, [out, retval] int *pVal); - [propget, id(48), helpstring("property SkillFreePoints")] HRESULT SkillFreePoints([in] enum eSkill SkillID, [out, retval] int *pVal); - [propget, id(49), helpstring("property SkillClicks")] HRESULT SkillClicks([in] enum eSkill SkillID, [out, retval] int *pVal); - - [propget, id(50), helpstring("property AttributeTotalXP")] HRESULT AttributeTotalXP([in] enum eAttribute AttributeID, [out, retval] int *pVal); - [propget, id(51), helpstring("property AttributeClicks")] HRESULT AttributeClicks([in] enum eAttribute AttributeID, [out, retval] int *pVal); - [propget, id(52), helpstring("property AttributeStart")] HRESULT AttributeStart([in] enum eAttribute AttributeID, [out, retval] int *pVal); - - [propget, id(53), helpstring("property VitalTotalXP")] HRESULT VitalTotalXP([in] enum eVital VitalD, [out, retval] int *pVal); - [propget, id(54), helpstring("property VitalClicks")] HRESULT VitalClicks([in] enum eVital VitalID, [out, retval] int *pVal); }; --- 246,249 ---- *************** *** 419,422 **** --- 388,392 ---- [id(2), helpstring("method OnChatBoxMessage")] VARIANT_BOOL OnChatBoxMessage([in] BSTR bstrText, [in] LONG lColor, [in,out] VARIANT_BOOL *bEat ); [id(3), helpstring("method OnCommandLineText")] VARIANT_BOOL OnCommandLineText([in] BSTR bstrText, [in,out] VARIANT_BOOL *bEat ); + [id(4), helpstring("method SelectItem")] HRESULT SelectItem([in] LONG lGuid); }; |
From: <ha...@us...> - 2003-03-07 19:17:30
|
Update of /cvsroot/decaldev/source/Decal In directory sc8-pr-cvs1:/tmp/cvs-serv1099 Modified Files: DecalCP.h ACHooks.h ACHooks.cpp Log Message: SelectItemHook + fix for some of the hook enums Index: DecalCP.h =================================================================== RCS file: /cvsroot/decaldev/source/Decal/DecalCP.h,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** DecalCP.h 13 Dec 2002 04:53:37 -0000 1.5 --- DecalCP.h 7 Mar 2003 19:17:25 -0000 1.6 *************** *** 112,115 **** --- 112,142 ---- return bEatProc; } + + HRESULT Fire_SelectItem(LONG guid) + { + CComVariant varResult; + T* pT = static_cast<T*>(this); + int nConnectionIndex; + CComVariant* pvars = new CComVariant[1]; + int nConnections = m_vec.GetSize(); + + for (nConnectionIndex = 0; nConnectionIndex < nConnections; nConnectionIndex++) + { + pT->Lock(); + CComPtr<IUnknown> sp = m_vec.GetAt(nConnectionIndex); + pT->Unlock(); + IDispatch* pDispatch = reinterpret_cast<IDispatch*>(sp.p); + if (pDispatch != NULL) + { + VariantClear(&varResult); + pvars[0] = guid; + DISPPARAMS disp = { pvars, NULL, 1, 0 }; + pDispatch->Invoke(0x4, IID_NULL, LOCALE_USER_DEFAULT, DISPATCH_METHOD, &disp, &varResult, NULL, NULL); + } + } + delete[] pvars; + return varResult.scode; + } + }; #endif Index: ACHooks.h =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.h,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** ACHooks.h 22 Feb 2003 04:25:34 -0000 1.33 --- ACHooks.h 7 Mar 2003 19:17:26 -0000 1.34 *************** *** 5,9 **** #include "DecalManager.h" #include "DecalCP.h" ! #include "..\inject\Inject.h" struct sMemoryLocation --- 5,9 ---- #include "DecalManager.h" #include "DecalCP.h" ! #import "..\Include\Inject.tlb" struct sMemoryLocation *************** *** 21,51 **** }; - struct qSkill { - long vTable; - enum eTrainLevel Trained; - int TotalXP; - int FreePoints; - int Clicks; - int unk1; - int unk2; /* float? percent of total? */ - float unk3; - }; - - struct qVital { - long vTable; - int Clicks; - int unk1; - int TotalXP; - int unk2; - }; - - struct qAttribute { - long vTable; - int Clicks; - int Start; - int TotalXP; - }; - - struct qPointerList { --- 21,24 ---- *************** *** 84,91 **** private: - HRESULT GetSkillInfo(eSkill SkillID, struct qSkill *Skill); - HRESULT GetAttributeInfo(eAttribute AttributeID, struct qAttribute *Attribute); - HRESULT GetVitalInfo(eVital VitalID, struct qVital *Vital); - long* GetCs(long offs=0) ; --- 57,60 ---- *************** *** 95,98 **** --- 64,68 ---- bool m_bDecalRef; + bool m_bMismatch; *************** *** 199,218 **** long m_lLogout; ! bool m_bSecureTrade_Add; ! long m_lSecureTrade_Add; ! bool m_bSecureTrade_Add_Off1; ! long m_lSecureTrade_Add_Off1; ! bool m_bSecureTrade_Add_Off2; ! long m_lSecureTrade_Add_Off2; ! ! bool m_bGetSkillInfo; ! long m_lGetSkillInfo, m_lGetSkillInfo_vT; ! bool m_bGetAttributeInfo; ! long m_lGetAttributeInfo, m_lGetAttributeInfo_vT; ! bool m_bGetVitalInfo; ! long m_lGetVitalInfo, m_lGetVitalInfo_vT; ! ! bool m_bChatColor; ! long m_lChatColor; unsigned int m_HooksEx[1]; --- 169,174 ---- long m_lLogout; ! bool m_bSelectItemHook; ! long m_lSelectItemHook; unsigned int m_HooksEx[1]; *************** *** 224,227 **** --- 180,184 ---- static cACHooks* s_pACHooks; void InternalObjectDestroyed( DWORD dwGuid ); + void InternalSelectItem( DWORD dwID ); bool InternalChatText( char *szText ); bool InternalChatMessage( char *szText, long lColor ); *************** *** 274,289 **** STDMETHOD(Logout)(); STDMETHOD(SetDecal)(IUnknown *pDecal); - STDMETHOD(SecureTrade_Add)(long ItemID, VARIANT_BOOL *pVal); - - STDMETHOD(get_SkillTrainLevel)( eSkill SkillID, eTrainLevel *pVal ); - STDMETHOD(get_SkillTotalXP)( eSkill SkillID, int *pVal ); - STDMETHOD(get_SkillFreePoints)( eSkill SkillID, int *pVal ); - STDMETHOD(get_SkillClicks)( eSkill SkillID, int *pVal ); - - STDMETHOD(get_AttributeClicks)( eAttribute AttributeID, int *pVal ); - STDMETHOD(get_AttributeTotalXP)( eAttribute AttributeID, int *pVal ); - STDMETHOD(get_AttributeStart)( eAttribute AttributeID, int *pVal ); - - STDMETHOD(get_VitalClicks)( eVital VitalID, int *pVal ); - STDMETHOD(get_VitalTotalXP)( eVital VitalID, int *pVal ); }; --- 231,233 ---- Index: ACHooks.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.cpp,v retrieving revision 1.39 retrieving revision 1.40 diff -C2 -d -r1.39 -r1.40 *** ACHooks.cpp 22 Feb 2003 04:25:34 -0000 1.39 --- ACHooks.cpp 7 Mar 2003 19:17:26 -0000 1.40 *************** *** 24,29 **** cACHooks* cACHooks::s_pACHooks = NULL; long g_lObjectDestroyedProc = 0; ! void (__fastcall *pfnOldChatMessage)(int _ecx, int _edx, char *, DWORD ) = NULL; void (*pfnOldChatText)() = NULL; void (*pfnUseItem)( DWORD, DWORD ) = NULL; --- 24,30 ---- cACHooks* cACHooks::s_pACHooks = NULL; long g_lObjectDestroyedProc = 0; + long g_lSelectItemHijackProc = 0; ! void (*pfnOldChatMessage)( char *, DWORD ) = NULL; void (*pfnOldChatText)() = NULL; void (*pfnUseItem)( DWORD, DWORD ) = NULL; *************** *** 36,45 **** qString* ( __fastcall *pfnInternalStringConstructor)( qString *, long, char * ) = NULL; ! bool g_bTimestamp; ! char charBufferPreviousCall; ! ! extern void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long dwColor ); extern void OnChatText(); extern void ObjectDestroyedHook(); extern DWORD HookCall (DWORD dwCallAddress, DWORD dwReplacement); --- 37,44 ---- qString* ( __fastcall *pfnInternalStringConstructor)( qString *, long, char * ) = NULL; ! extern void OnChatMessage( char* pText, long dwColor ); extern void OnChatText(); + extern void SelectItemHook(); extern void ObjectDestroyedHook(); extern DWORD HookCall (DWORD dwCallAddress, DWORD dwReplacement); *************** *** 47,52 **** cACHooks::cACHooks() { - g_bTimestamp = false; - _bstr_t _Unnamed; s_pACHooks = this; --- 46,49 ---- *************** *** 82,111 **** m_bGetSkill = false; m_bLogout = false; - m_bSecureTrade_Add = false; - m_bSecureTrade_Add_Off1 = false; - m_bSecureTrade_Add_Off2 = false; - m_bGetSkillInfo = false; - m_bGetAttributeInfo = false; - m_bGetVitalInfo = false; - m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); m_HookCount = 0; - charBufferPreviousCall = '\n'; - char szPath[ MAX_PATH ]; DWORD dwCount = MAX_PATH; ! DWORD dwTimestamp = 0; ! CRegKey key; ! key.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal", KEY_READ ); ! key.QueryValue( dwTimestamp, "Timestamp" ); ! key.Close(); ! ! g_bTimestamp = static_cast< bool >( dwTimestamp ); ! ! key.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal\\Agent", KEY_READ ); ! key.QueryValue( szPath, "AgentPath", &dwCount ); strncat( szPath, "\\memlocs.xml", MAX_PATH ); --- 79,92 ---- m_bGetSkill = false; m_bLogout = false; m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); m_HookCount = 0; char szPath[ MAX_PATH ]; DWORD dwCount = MAX_PATH; ! CRegKey keyPath; ! keyPath.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal\\Agent", KEY_READ ); ! keyPath.QueryValue( szPath, "AgentPath", &dwCount ); strncat( szPath, "\\memlocs.xml", MAX_PATH ); *************** *** 200,204 **** if( QueryMemLoc( BSTRT( "ChatMessage" ), &Val ) == S_OK ) ! pfnOldChatMessage = reinterpret_cast< void (__fastcall*)( int, int, char *, DWORD ) >( Val ); if( QueryMemLoc( BSTRT( "ChatMessageAddy" ), &Val ) == S_OK ) m_lChatMessageAddy = Val; --- 181,185 ---- if( QueryMemLoc( BSTRT( "ChatMessage" ), &Val ) == S_OK ) ! pfnOldChatMessage = reinterpret_cast< void (*)( char *, DWORD ) >( Val ); if( QueryMemLoc( BSTRT( "ChatMessageAddy" ), &Val ) == S_OK ) m_lChatMessageAddy = Val; *************** *** 344,350 **** if( QueryMemLoc( BSTRT( "ObjectFromGUID" ), &Val ) == S_OK ) { m_lObjectFromGuid = Val; if( QueryMemLoc( BSTRT( "ObjectFromGUIDClass" ), &Val ) == S_OK ) { m_lObjectFromGuidClass = Val; ! m_Hooks |= eArea3DHeight ; m_bObjectFromGuid = true; } --- 325,332 ---- if( QueryMemLoc( BSTRT( "ObjectFromGUID" ), &Val ) == S_OK ) { m_lObjectFromGuid = Val; + SetHookEx( eObjectFromGUID ); if( QueryMemLoc( BSTRT( "ObjectFromGUIDClass" ), &Val ) == S_OK ) { m_lObjectFromGuidClass = Val; ! SetHookEx( eObjectFromGUIDClass ); m_bObjectFromGuid = true; } *************** *** 529,617 **** } - if (QueryMemLoc(BSTRT( "SecureTrade_Add" ), &Val) == S_OK) - { - m_lSecureTrade_Add = Val; - m_bSecureTrade_Add = true; - } - - if (QueryMemLoc(BSTRT( "SecureTrade_Add_Off1" ), &Val) == S_OK) - { - m_lSecureTrade_Add_Off1 = Val; - m_bSecureTrade_Add_Off1 = true; - } - - if (QueryMemLoc(BSTRT( "SecureTrade_Add_Off2" ), &Val) == S_OK) - { - m_lSecureTrade_Add_Off2 = Val; - m_bSecureTrade_Add_Off2 = true; - } - - if (m_bSecureTrade_Add && m_bSecureTrade_Add_Off1 && m_bSecureTrade_Add_Off2 && m_bCombatState) - { - SetHookEx(eSecureTrade_Add); - } - - - if (QueryMemLoc(BSTRT( "GetSkillInfo" ), &Val) == S_OK) - { - m_lGetSkillInfo = Val; - m_bGetSkillInfo = true; - } - - if (QueryMemLoc(BSTRT( "GetVitalInfo" ), &Val) == S_OK) - { - m_lGetVitalInfo = Val; - m_bGetVitalInfo = true; - } - - if (QueryMemLoc(BSTRT( "GetAttributeInfo" ), &Val) == S_OK) - { - m_lGetAttributeInfo = Val; - m_bGetAttributeInfo = true; - } - - - /* I don't believe the vTable is used for any of these, however, if it becomes necessary - the functionality is here to a) detect the problem (crash at 0xFF......), and fix it - without requiring a complete update to Decal */ - if (QueryMemLoc(BSTRT( "GetSkillInfo_vT" ), &Val) == S_OK) - { - m_lGetSkillInfo_vT = Val; - } - else - { - m_lGetSkillInfo_vT = 0xFF111111; - } - - if (QueryMemLoc(BSTRT( "GetVitalInfo_vT" ), &Val) == S_OK) - { - m_lGetVitalInfo_vT = Val; - } - else - { - m_lGetVitalInfo_vT = 0xFF222222; - } - - if (QueryMemLoc(BSTRT( "GetAttributeInfo_vT" ), &Val) == S_OK) - { - m_lGetAttributeInfo_vT = Val; - } - else - { - m_lGetAttributeInfo_vT = 0xFF333333; - } - - if (m_lVitalBase) { - if (m_bGetSkillInfo) { - SetHookEx(eSkillInfo); - } - if (m_bGetVitalInfo) { - SetHookEx(eVitalInfo); - } - if (m_bGetAttributeInfo) { - SetHookEx(eAttributeInfo); - } - } - DWORD dwOldProtect; if( QueryMemLoc( BSTRT( "OnChatText" ), &Val ) == S_OK ) --- 511,514 ---- *************** *** 628,631 **** --- 525,536 ---- m_Hooks |= eHooksAvailEx; + + if( QueryMemLoc( BSTRT( "SelectItemHook" ), &Val ) == S_OK ) + { + m_lSelectItemHook = Val; + m_bSelectItemHook = true; + g_lSelectItemHijackProc = HookCall( m_lSelectItemHook, (DWORD) SelectItemHook ); + SetHookEx( eOnSelectItemEvent ); + } } *************** *** 740,849 **** return S_FALSE; - DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); - if( *Addy == NULL ) - return S_FALSE; - USES_CONVERSION; char *strText = OLE2A( szText ); ! int iStrLen = strlen( strText ); ! ! if( g_bTimestamp ) ! { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! ! int iOffset = 0; ! char *szTemp = strText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! ! charBufferPreviousCall = '\n'; ! ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); ! } ! } ! ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! ! else ! { ! if( bDoTimeStamp ) ! { ! if( strText != NULL ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, szTimeStamp, lColor ); ! } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! ! else ! { ! //_snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! } ! ! char *szNewLine = "\n"; ! pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); ! delete [] szTimeStamp; ! } ! else { ! char *pText = new char[ iStrLen + 3 ]; ! _snprintf( pText, iStrLen + 2, "%s\n", strText ); ! pfnOldChatMessage( *Addy, 0, pText, lColor ); ! delete [] pText; } return S_OK; } --- 645,671 ---- return S_FALSE; USES_CONVERSION; char *strText = OLE2A( szText ); ! char *pText = new char[ strlen( strText ) + 3 ]; ! _snprintf( pText, strlen( strText ) + 2, "%s\n", strText ); ! DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); ! if( *Addy == NULL ) ! return S_FALSE; ! __asm { ! mov esi, Addy ! mov ecx, [esi] ! ! push lColor ! push pText ! call pfnOldChatMessage ! add esp, 0x8 } + delete [] pText; + return S_OK; } *************** *** 854,953 **** return S_FALSE; - DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); - if( *Addy == NULL ) - return S_FALSE; - USES_CONVERSION; char *strText = OLE2A( szText ); ! if( g_bTimestamp ) ! { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! int iStrLen = strlen( strText ); ! ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! ! int iOffset = 0; ! char *szTemp = strText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); ! } ! } ! ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! ! else ! { ! if( bDoTimeStamp ) ! { ! if( strText != NULL ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, szTimeStamp, lColor ); ! } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! else ! { ! //_snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! } ! delete [] szTimeStamp; } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! return S_OK; } --- 676,698 ---- return S_FALSE; USES_CONVERSION; char *strText = OLE2A( szText ); ! DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); ! if( *Addy == NULL ) ! return S_FALSE; ! __asm ! { ! mov esi, Addy ! mov ecx, [esi] ! push lColor ! push strText ! call pfnOldChatMessage ! add esp, 0x8 } ! return S_OK; } *************** *** 1078,1083 **** if( m_bDecalRef ) { ! CComPtr< IPluginSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( IPluginSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) --- 823,828 ---- if( m_bDecalRef ) { ! CComPtr< DecalPlugins::IPluginSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( DecalPlugins::IPluginSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) *************** *** 1650,1929 **** } - STDMETHODIMP cACHooks::SecureTrade_Add(long ItemID, VARIANT_BOOL *pVal) - { - void ( __fastcall *Internal_SecureTrade_Add )( struct qPointerList *, int, long ); - struct qPointerList *p; - VARIANT_BOOL ItemExists; - HRESULT hr; - - if (pVal) /* Should probably return an error code. Tough. */ - { - *pVal = VARIANT_FALSE; - } - - if ( m_bSecureTrade_Add && m_bSecureTrade_Add_Off1 && m_bSecureTrade_Add_Off2 && m_bCombatState ) - { - hr = ItemIsKnown(ItemID, &ItemExists); - if (FAILED(hr)) - { - return hr; - } - - if (ItemExists == VARIANT_FALSE) - { - return S_FALSE; - } - - p = (struct qPointerList *)m_lCombatState; - if (!p) - { - return S_FALSE; - } - - p = p->dd[0]; - if (!p) - { - return S_FALSE; - } - - p = p->dd[m_lSecureTrade_Add_Off1 >> 2]; - if (!p) - { - return S_FALSE; - } - - p = p->dd[m_lSecureTrade_Add_Off2 >> 2]; - if (!p) - { - return S_FALSE; - } - - Internal_SecureTrade_Add = reinterpret_cast< void ( __fastcall *)( struct qPointerList *, int, long ) >( m_lSecureTrade_Add ); - Internal_SecureTrade_Add(p, 0, ItemID); - if (pVal) - { - *pVal = VARIANT_TRUE; - } - return S_OK; - } - return S_FALSE; - } - - - HRESULT cACHooks::GetSkillInfo(eSkill SkillID, struct qSkill *Skill) { - int ( __fastcall *Internal_GetSkillInfo )( void *, int, int, struct qSkill * ); - - if (!m_bGetSkillInfo) { - return E_FAIL; - } - - if (SkillID > 50) { - SkillID = (eSkill)(SkillID - 50); - } - if ((SkillID < 1) || (SkillID > 50)) { - return E_INVALIDARG; - } - - - Skill->vTable = m_lGetSkillInfo_vT; - - Internal_GetSkillInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qSkill *) >(m_lGetSkillInfo); - if (Internal_GetSkillInfo(*(void **)m_lVitalBase, 0, SkillID, Skill)) { - return S_OK; - } - return E_FAIL; - } - - HRESULT cACHooks::GetAttributeInfo(eAttribute AttributeID, struct qAttribute *Attribute) { - int (__fastcall *Internal_GetAttributeInfo)(void *, int, int, struct qAttribute *); - - if (!m_bGetAttributeInfo) { - return E_FAIL; - } - - if (AttributeID > 6) { - AttributeID = (eAttribute)(AttributeID - 6); - } - if ((AttributeID < 1) || (AttributeID > 6)) { - return E_INVALIDARG; - } - - Attribute->vTable = m_lGetAttributeInfo_vT; - - Internal_GetAttributeInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qAttribute *) >(m_lGetAttributeInfo); - if (Internal_GetAttributeInfo(*(void **)m_lVitalBase, 0, AttributeID, Attribute)) { - return S_OK; - } - return E_FAIL; - } - - HRESULT cACHooks::GetVitalInfo(eVital VitalID, struct qVital *Vital) { - int (__fastcall *Internal_GetVitalInfo)(void *, int, int, struct qVital *); - - if (!m_bGetVitalInfo) { - return E_FAIL; - } - - switch (VitalID) { - case eCurrentHealth: - case eMaximumHealth: - case eBaseHealth: - VitalID = eCurrentHealth; - break; - case eCurrentStamina: - case eMaximumStamina: - case eBaseStamina: - VitalID = eCurrentStamina; - break; - case eCurrentMana: - case eMaximumMana: - case eBaseMana: - VitalID = eCurrentMana; - break; - default: - return E_INVALIDARG; - } - - - Vital->vTable = m_lGetVitalInfo_vT; - - Internal_GetVitalInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qVital *) >(m_lGetVitalInfo); - if (Internal_GetVitalInfo(*(void **)m_lVitalBase, 0, VitalID, Vital)) { - return S_OK; - } - return E_FAIL; - } - - - STDMETHODIMP cACHooks::get_SkillTrainLevel( eSkill SkillID, eTrainLevel *pVal ) - { - struct qSkill Skill; - HRESULT hr; - hr = GetSkillInfo(SkillID, &Skill); - if (FAILED(hr)) { - return hr; - } - - *pVal = Skill.Trained; - - return S_OK; - } - - STDMETHODIMP cACHooks::get_SkillTotalXP( eSkill SkillID, int *pVal ) - { - struct qSkill Skill; - HRESULT hr; - hr = GetSkillInfo(SkillID, &Skill); - if (FAILED(hr)) { - return hr; - } - - *pVal = Skill.TotalXP; - - return S_OK; - } - - STDMETHODIMP cACHooks::get_SkillFreePoints( eSkill SkillID, int *pVal ) - { - struct qSkill Skill; - HRESULT hr; - hr = GetSkillInfo(SkillID, &Skill); - if (FAILED(hr)) { - return hr; - } - - *pVal = Skill.FreePoints; - - return S_OK; - } - - - STDMETHODIMP cACHooks::get_SkillClicks( eSkill SkillID, int *pVal ) - { - struct qSkill Skill; - HRESULT hr; - hr = GetSkillInfo(SkillID, &Skill); - if (FAILED(hr)) { - return hr; - } - - *pVal = Skill.Clicks; - - return S_OK; - } - - STDMETHODIMP cACHooks::get_AttributeClicks( eAttribute AttributeID, int *pVal ) - { - struct qAttribute Attribute; - HRESULT hr; - hr = GetAttributeInfo(AttributeID, &Attribute); - if (FAILED(hr)) { - return hr; - } - - *pVal = Attribute.Clicks; - - return S_OK; - } - - STDMETHODIMP cACHooks::get_AttributeTotalXP( eAttribute AttributeID, int *pVal ) - { - struct qAttribute Attribute; - HRESULT hr; - hr = GetAttributeInfo(AttributeID, &Attribute); - if (FAILED(hr)) { - return hr; - } - - *pVal = Attribute.TotalXP; - - return S_OK; - } - - - STDMETHODIMP cACHooks::get_AttributeStart( eAttribute AttributeID, int *pVal ) - { - struct qAttribute Attribute; - HRESULT hr; - hr = GetAttributeInfo(AttributeID, &Attribute); - if (FAILED(hr)) { - return hr; - } - - *pVal = Attribute.Start; - - return S_OK; - } - - STDMETHODIMP cACHooks::get_VitalClicks( eVital VitalID, int *pVal ) - { - struct qVital Vital; - HRESULT hr; - hr = GetVitalInfo(VitalID, &Vital); - if (FAILED(hr)) { - return hr; - } - - *pVal = Vital.Clicks; - - return S_OK; - } - - STDMETHODIMP cACHooks::get_VitalTotalXP( eVital VitalID, int *pVal ) - { - struct qVital Vital; - HRESULT hr; - hr = GetVitalInfo(VitalID, &Vital); - if (FAILED(hr)) { - return hr; - } - - *pVal = Vital.TotalXP; - - return S_OK; - } - - - void cACHooks::SetHookEx( eAvailableHooksEx HookID ) { --- 1395,1398 ---- *************** *** 1951,1954 **** --- 1420,1428 ---- } + void cACHooks::InternalSelectItem( DWORD dwID ) + { + Fire_SelectItem( dwID ); + } + void OnObjectDestroyed (DWORD dwGuid) { *************** *** 1957,1960 **** --- 1431,1452 ---- } + void OnSelectItem( DWORD dwID ) + { + if( cACHooks::s_pACHooks ) + cACHooks::s_pACHooks->InternalSelectItem( dwID ); + } + + void __declspec(naked) SelectItemHook() + { + _asm + { + push eax + call OnSelectItem + add esp,4 + + jmp g_lSelectItemHijackProc + } + } + void __declspec(naked) ObjectDestroyedHook() { *************** *** 2027,2034 **** } ! bool DispatchChatMessage( char *pText, long pdwColor ) { if( cACHooks::s_pACHooks ) ! return cACHooks::s_pACHooks->InternalChatMessage( pText, pdwColor ); return false; --- 1519,1526 ---- } ! bool DispatchChatMessage( char *pText, long *pdwColor ) { if( cACHooks::s_pACHooks ) ! return cACHooks::s_pACHooks->InternalChatMessage( pText, *pdwColor ); return false; *************** *** 2043,2131 **** } ! void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long lColor ) { ! if( !DispatchChatMessage( pText, lColor ) ) { ! if( g_bTimestamp ) ! { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! int iStrLen = strlen( pText ); ! ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! ! int iOffset = 0; ! char *szTemp = pText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( _ecx, _edx, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( _ecx, _edx, szNewLine, lColor ); ! } ! } ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( _ecx, _edx, szTimeStampA, lColor ); ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! else ! { ! if( bDoTimeStamp ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, pText ); ! pfnOldChatMessage( _ecx, _edx, szTimeStamp, lColor ); ! } ! else ! { ! _snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, pText ); ! pfnOldChatMessage( _ecx, _edx, szTimeStamp, lColor ); ! } ! } ! delete [] szTimeStamp; ! } ! else ! pfnOldChatMessage( _ecx, _edx, pText, lColor ); } } --- 1535,1572 ---- } ! void __declspec(naked) OnChatMessage( char* pText, long dwColor ) { ! __asm { ! push ebp ! mov ebp, esp ! sub esp, 20h ! push esi ! push ecx ! lea esi, dwColor ! push esi ! push pText ! call DispatchChatMessage ! add esp, 8 ! test al, al ! jz dont_kill_text ! mov dword ptr [pText], 0 ! dont_kill_text: ! pop ecx ! push dwColor ! push pText ! call pfnOldChatMessage ! pop esi ! mov esp, ebp ! pop ebp ! retn 8 } } |
From: <ar...@us...> - 2003-02-22 04:56:55
|
Update of /cvsroot/decaldev/source/Include In directory sc8-pr-cvs1:/tmp/cvs-serv15422/Include Modified Files: Decal.idl Log Message: GetSkills/Vitals/Attributes Code Checkin for Cynica_l Index: Decal.idl =================================================================== RCS file: /cvsroot/decaldev/source/Include/Decal.idl,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** Decal.idl 13 Jan 2003 04:48:33 -0000 1.29 --- Decal.idl 22 Feb 2003 04:56:52 -0000 1.30 *************** *** 8,12 **** import "ocidl.idl"; ! enum eAttribute { eCurrentHealth = 1, --- 8,21 ---- import "ocidl.idl"; ! /* I'm not 100% sure about this */ ! enum eTrainLevel ! { ! eUntrained = 1, ! eTrained = 2, ! eSpecialized = 3, ! eTrainLevel_DWORD = 0x7FFFFFFF ! }; ! ! enum eVital { eCurrentHealth = 1, *************** *** 19,22 **** --- 28,36 ---- eBaseStamina = 8, eBaseMana = 9, + eVital_DWORD = 0x7FFFFFFF + }; + + enum eAttribute + { eCurrentStrength = 1, eCurrentEndurance = 2, *************** *** 30,34 **** eBaseCoordination = 10, eBaseFocus = 11, ! eBaseSelf = 12 }; --- 44,49 ---- eBaseCoordination = 10, eBaseFocus = 11, ! eBaseSelf = 12, ! eAttribute_DWORD = 0x7FFFFFFF }; *************** *** 104,108 **** eBaseFletchingSkill = 87, eBaseAlchemySkill = 88, ! eBaseCookingSkill = 89 }; --- 119,124 ---- eBaseFletchingSkill = 87, eBaseAlchemySkill = 88, ! eBaseCookingSkill = 89, ! eSkill_DWORD = 0x7FFFFFFF }; *************** *** 149,152 **** --- 165,171 ---- eSecureTrade_Add = 1, eColorEx = 2, + eSkillInfo = 3, + eAttributeInfo = 4, + eVitalInfo = 5, eAvailableHooksEx_DWORD = 0x7FFFFFFF // coerce enums into 4 byte instead of two }; *************** *** 246,249 **** --- 265,280 ---- [id(44), helpstring("method SetDecal")] HRESULT SetDecal([in] IUnknown *pDecal); [id(45), helpstring("method SecureTrade_Add")] HRESULT SecureTrade_Add([in] long ItemID, [out, retval] VARIANT_BOOL *pVal); + + [propget, id(46), helpstring("property SkillTrainLevel")] HRESULT SkillTrainLevel([in] enum eSkill SkillID, [out, retval] enum eTrainLevel *pVal); + [propget, id(47), helpstring("property SkillTotalXP")] HRESULT SkillTotalXP([in] enum eSkill SkillID, [out, retval] int *pVal); + [propget, id(48), helpstring("property SkillFreePoints")] HRESULT SkillFreePoints([in] enum eSkill SkillID, [out, retval] int *pVal); + [propget, id(49), helpstring("property SkillClicks")] HRESULT SkillClicks([in] enum eSkill SkillID, [out, retval] int *pVal); + + [propget, id(50), helpstring("property AttributeTotalXP")] HRESULT AttributeTotalXP([in] enum eAttribute AttributeID, [out, retval] int *pVal); + [propget, id(51), helpstring("property AttributeClicks")] HRESULT AttributeClicks([in] enum eAttribute AttributeID, [out, retval] int *pVal); + [propget, id(52), helpstring("property AttributeStart")] HRESULT AttributeStart([in] enum eAttribute AttributeID, [out, retval] int *pVal); + + [propget, id(53), helpstring("property VitalTotalXP")] HRESULT VitalTotalXP([in] enum eVital VitalD, [out, retval] int *pVal); + [propget, id(54), helpstring("property VitalClicks")] HRESULT VitalClicks([in] enum eVital VitalID, [out, retval] int *pVal); }; |
From: <ar...@us...> - 2003-02-22 04:25:37
|
Update of /cvsroot/decaldev/source/Decal In directory sc8-pr-cvs1:/tmp/cvs-serv2660/Decal Modified Files: ACHooks.cpp ACHooks.h Log Message: GetSkillInfo, GetAttributeInfo. GetVitalInfo Hook Code Commited For Cynica_L Index: ACHooks.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.cpp,v retrieving revision 1.38 retrieving revision 1.39 diff -C2 -d -r1.38 -r1.39 *** ACHooks.cpp 11 Feb 2003 22:19:29 -0000 1.38 --- ACHooks.cpp 22 Feb 2003 04:25:34 -0000 1.39 *************** *** 82,88 **** m_bGetSkill = false; m_bLogout = false; ! m_bSecureTrade_Add = false; ! m_bSecureTrade_Add_Off1 = false; ! m_bSecureTrade_Add_Off2 = false; m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); --- 82,92 ---- m_bGetSkill = false; m_bLogout = false; ! m_bSecureTrade_Add = false; ! m_bSecureTrade_Add_Off1 = false; ! m_bSecureTrade_Add_Off2 = false; ! m_bGetSkillInfo = false; ! m_bGetAttributeInfo = false; ! m_bGetVitalInfo = false; ! m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); *************** *** 549,552 **** --- 553,617 ---- + if (QueryMemLoc(BSTRT( "GetSkillInfo" ), &Val) == S_OK) + { + m_lGetSkillInfo = Val; + m_bGetSkillInfo = true; + } + + if (QueryMemLoc(BSTRT( "GetVitalInfo" ), &Val) == S_OK) + { + m_lGetVitalInfo = Val; + m_bGetVitalInfo = true; + } + + if (QueryMemLoc(BSTRT( "GetAttributeInfo" ), &Val) == S_OK) + { + m_lGetAttributeInfo = Val; + m_bGetAttributeInfo = true; + } + + + /* I don't believe the vTable is used for any of these, however, if it becomes necessary + the functionality is here to a) detect the problem (crash at 0xFF......), and fix it + without requiring a complete update to Decal */ + if (QueryMemLoc(BSTRT( "GetSkillInfo_vT" ), &Val) == S_OK) + { + m_lGetSkillInfo_vT = Val; + } + else + { + m_lGetSkillInfo_vT = 0xFF111111; + } + + if (QueryMemLoc(BSTRT( "GetVitalInfo_vT" ), &Val) == S_OK) + { + m_lGetVitalInfo_vT = Val; + } + else + { + m_lGetVitalInfo_vT = 0xFF222222; + } + + if (QueryMemLoc(BSTRT( "GetAttributeInfo_vT" ), &Val) == S_OK) + { + m_lGetAttributeInfo_vT = Val; + } + else + { + m_lGetAttributeInfo_vT = 0xFF333333; + } + + if (m_lVitalBase) { + if (m_bGetSkillInfo) { + SetHookEx(eSkillInfo); + } + if (m_bGetVitalInfo) { + SetHookEx(eVitalInfo); + } + if (m_bGetAttributeInfo) { + SetHookEx(eAttributeInfo); + } + } + DWORD dwOldProtect; if( QueryMemLoc( BSTRT( "OnChatText" ), &Val ) == S_OK ) *************** *** 1013,1018 **** if( m_bDecalRef ) { ! CComPtr< IPSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( IPSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) --- 1078,1083 ---- if( m_bDecalRef ) { ! CComPtr< IPluginSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( IPluginSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) *************** *** 1644,1647 **** --- 1709,1928 ---- return S_FALSE; } + + + HRESULT cACHooks::GetSkillInfo(eSkill SkillID, struct qSkill *Skill) { + int ( __fastcall *Internal_GetSkillInfo )( void *, int, int, struct qSkill * ); + + if (!m_bGetSkillInfo) { + return E_FAIL; + } + + if (SkillID > 50) { + SkillID = (eSkill)(SkillID - 50); + } + if ((SkillID < 1) || (SkillID > 50)) { + return E_INVALIDARG; + } + + + Skill->vTable = m_lGetSkillInfo_vT; + + Internal_GetSkillInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qSkill *) >(m_lGetSkillInfo); + if (Internal_GetSkillInfo(*(void **)m_lVitalBase, 0, SkillID, Skill)) { + return S_OK; + } + return E_FAIL; + } + + HRESULT cACHooks::GetAttributeInfo(eAttribute AttributeID, struct qAttribute *Attribute) { + int (__fastcall *Internal_GetAttributeInfo)(void *, int, int, struct qAttribute *); + + if (!m_bGetAttributeInfo) { + return E_FAIL; + } + + if (AttributeID > 6) { + AttributeID = (eAttribute)(AttributeID - 6); + } + if ((AttributeID < 1) || (AttributeID > 6)) { + return E_INVALIDARG; + } + + Attribute->vTable = m_lGetAttributeInfo_vT; + + Internal_GetAttributeInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qAttribute *) >(m_lGetAttributeInfo); + if (Internal_GetAttributeInfo(*(void **)m_lVitalBase, 0, AttributeID, Attribute)) { + return S_OK; + } + return E_FAIL; + } + + HRESULT cACHooks::GetVitalInfo(eVital VitalID, struct qVital *Vital) { + int (__fastcall *Internal_GetVitalInfo)(void *, int, int, struct qVital *); + + if (!m_bGetVitalInfo) { + return E_FAIL; + } + + switch (VitalID) { + case eCurrentHealth: + case eMaximumHealth: + case eBaseHealth: + VitalID = eCurrentHealth; + break; + case eCurrentStamina: + case eMaximumStamina: + case eBaseStamina: + VitalID = eCurrentStamina; + break; + case eCurrentMana: + case eMaximumMana: + case eBaseMana: + VitalID = eCurrentMana; + break; + default: + return E_INVALIDARG; + } + + + Vital->vTable = m_lGetVitalInfo_vT; + + Internal_GetVitalInfo = reinterpret_cast< int (__fastcall*)(void *, int, int, struct qVital *) >(m_lGetVitalInfo); + if (Internal_GetVitalInfo(*(void **)m_lVitalBase, 0, VitalID, Vital)) { + return S_OK; + } + return E_FAIL; + } + + + STDMETHODIMP cACHooks::get_SkillTrainLevel( eSkill SkillID, eTrainLevel *pVal ) + { + struct qSkill Skill; + HRESULT hr; + hr = GetSkillInfo(SkillID, &Skill); + if (FAILED(hr)) { + return hr; + } + + *pVal = Skill.Trained; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_SkillTotalXP( eSkill SkillID, int *pVal ) + { + struct qSkill Skill; + HRESULT hr; + hr = GetSkillInfo(SkillID, &Skill); + if (FAILED(hr)) { + return hr; + } + + *pVal = Skill.TotalXP; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_SkillFreePoints( eSkill SkillID, int *pVal ) + { + struct qSkill Skill; + HRESULT hr; + hr = GetSkillInfo(SkillID, &Skill); + if (FAILED(hr)) { + return hr; + } + + *pVal = Skill.FreePoints; + + return S_OK; + } + + + STDMETHODIMP cACHooks::get_SkillClicks( eSkill SkillID, int *pVal ) + { + struct qSkill Skill; + HRESULT hr; + hr = GetSkillInfo(SkillID, &Skill); + if (FAILED(hr)) { + return hr; + } + + *pVal = Skill.Clicks; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_AttributeClicks( eAttribute AttributeID, int *pVal ) + { + struct qAttribute Attribute; + HRESULT hr; + hr = GetAttributeInfo(AttributeID, &Attribute); + if (FAILED(hr)) { + return hr; + } + + *pVal = Attribute.Clicks; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_AttributeTotalXP( eAttribute AttributeID, int *pVal ) + { + struct qAttribute Attribute; + HRESULT hr; + hr = GetAttributeInfo(AttributeID, &Attribute); + if (FAILED(hr)) { + return hr; + } + + *pVal = Attribute.TotalXP; + + return S_OK; + } + + + STDMETHODIMP cACHooks::get_AttributeStart( eAttribute AttributeID, int *pVal ) + { + struct qAttribute Attribute; + HRESULT hr; + hr = GetAttributeInfo(AttributeID, &Attribute); + if (FAILED(hr)) { + return hr; + } + + *pVal = Attribute.Start; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_VitalClicks( eVital VitalID, int *pVal ) + { + struct qVital Vital; + HRESULT hr; + hr = GetVitalInfo(VitalID, &Vital); + if (FAILED(hr)) { + return hr; + } + + *pVal = Vital.Clicks; + + return S_OK; + } + + STDMETHODIMP cACHooks::get_VitalTotalXP( eVital VitalID, int *pVal ) + { + struct qVital Vital; + HRESULT hr; + hr = GetVitalInfo(VitalID, &Vital); + if (FAILED(hr)) { + return hr; + } + + *pVal = Vital.TotalXP; + + return S_OK; + } + + void cACHooks::SetHookEx( eAvailableHooksEx HookID ) Index: ACHooks.h =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.h,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** ACHooks.h 11 Feb 2003 22:19:28 -0000 1.32 --- ACHooks.h 22 Feb 2003 04:25:34 -0000 1.33 *************** *** 5,16 **** #include "DecalManager.h" #include "DecalCP.h" - // .NET vs VC6.0 Compiler Config - #if _MSC_VER > 1200 // .NET - #import "..\Include\Inject.tlb" - #define IPSite DecalPlugins::IPluginSite - #else // Not .Net #include "..\inject\Inject.h" - #define IPSite IPluginSite - #endif struct sMemoryLocation --- 5,9 ---- *************** *** 28,31 **** --- 21,51 ---- }; + struct qSkill { + long vTable; + enum eTrainLevel Trained; + int TotalXP; + int FreePoints; + int Clicks; + int unk1; + int unk2; /* float? percent of total? */ + float unk3; + }; + + struct qVital { + long vTable; + int Clicks; + int unk1; + int TotalXP; + int unk2; + }; + + struct qAttribute { + long vTable; + int Clicks; + int Start; + int TotalXP; + }; + + struct qPointerList { *************** *** 64,67 **** --- 84,91 ---- private: + HRESULT GetSkillInfo(eSkill SkillID, struct qSkill *Skill); + HRESULT GetAttributeInfo(eAttribute AttributeID, struct qAttribute *Attribute); + HRESULT GetVitalInfo(eVital VitalID, struct qVital *Vital); + long* GetCs(long offs=0) ; *************** *** 182,185 **** --- 206,216 ---- long m_lSecureTrade_Add_Off2; + bool m_bGetSkillInfo; + long m_lGetSkillInfo, m_lGetSkillInfo_vT; + bool m_bGetAttributeInfo; + long m_lGetAttributeInfo, m_lGetAttributeInfo_vT; + bool m_bGetVitalInfo; + long m_lGetVitalInfo, m_lGetVitalInfo_vT; + bool m_bChatColor; long m_lChatColor; *************** *** 244,246 **** --- 275,289 ---- STDMETHOD(SetDecal)(IUnknown *pDecal); STDMETHOD(SecureTrade_Add)(long ItemID, VARIANT_BOOL *pVal); + + STDMETHOD(get_SkillTrainLevel)( eSkill SkillID, eTrainLevel *pVal ); + STDMETHOD(get_SkillTotalXP)( eSkill SkillID, int *pVal ); + STDMETHOD(get_SkillFreePoints)( eSkill SkillID, int *pVal ); + STDMETHOD(get_SkillClicks)( eSkill SkillID, int *pVal ); + + STDMETHOD(get_AttributeClicks)( eAttribute AttributeID, int *pVal ); + STDMETHOD(get_AttributeTotalXP)( eAttribute AttributeID, int *pVal ); + STDMETHOD(get_AttributeStart)( eAttribute AttributeID, int *pVal ); + + STDMETHOD(get_VitalClicks)( eVital VitalID, int *pVal ); + STDMETHOD(get_VitalTotalXP)( eVital VitalID, int *pVal ); }; |
From: <ha...@us...> - 2003-02-11 22:20:21
|
Update of /cvsroot/decaldev/source/DenAgent In directory sc8-pr-cvs1:/tmp/cvs-serv308 Modified Files: DenAgent.rc OptionsDlg.cpp resource.h Log Message: timestamps! Index: DenAgent.rc =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/DenAgent.rc,v retrieving revision 1.62 retrieving revision 1.63 diff -C2 -d -r1.62 -r1.63 *** DenAgent.rc 3 Jan 2003 00:55:38 -0000 1.62 --- DenAgent.rc 11 Feb 2003 22:20:07 -0000 1.63 *************** *** 123,127 **** END ! IDD_OPTIONS DIALOGEX 0, 0, 271, 214 STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Decal Options" --- 123,127 ---- END ! IDD_OPTIONS DIALOGEX 0, 0, 271, 255 STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Decal Options" *************** *** 165,176 **** CONTROL "One View",IDC_VIEWSINGLE,"Button",BS_AUTORADIOBUTTON,14, 147,52,11 ! GROUPBOX "Font",IDC_STATIC,7,178,257,31 CONTROL "Default",IDC_DEFAULT_FONT_RADIO,"Button", ! BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,14,190,39,10 CONTROL "AC Client",IDC_CLIENT_FONT_RADIO,"Button", ! BS_AUTORADIOBUTTON | WS_TABSTOP,56,190,45,10 CONTROL "Custom",IDC_CUSTOM_FONT_RADIO,"Button", ! BS_AUTORADIOBUTTON | WS_TABSTOP,105,190,39,10 ! EDITTEXT IDC_CUSTOM_FONT_EDIT,147,188,117,14,ES_AUTOHSCROLL GROUPBOX "Bar Options",IDC_STATIC,79,138,95,37,WS_GROUP CONTROL "Draw on Radar",IDC_RADARYES,"Button",BS_AUTORADIOBUTTON, --- 165,176 ---- CONTROL "One View",IDC_VIEWSINGLE,"Button",BS_AUTORADIOBUTTON,14, 147,52,11 ! GROUPBOX "Font",IDC_STATIC,7,217,257,31 CONTROL "Default",IDC_DEFAULT_FONT_RADIO,"Button", ! BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,14,230,39,10 CONTROL "AC Client",IDC_CLIENT_FONT_RADIO,"Button", ! BS_AUTORADIOBUTTON | WS_TABSTOP,56,230,45,10 CONTROL "Custom",IDC_CUSTOM_FONT_RADIO,"Button", ! BS_AUTORADIOBUTTON | WS_TABSTOP,105,230,39,10 ! EDITTEXT IDC_CUSTOM_FONT_EDIT,147,228,117,14,ES_AUTOHSCROLL GROUPBOX "Bar Options",IDC_STATIC,79,138,95,37,WS_GROUP CONTROL "Draw on Radar",IDC_RADARYES,"Button",BS_AUTORADIOBUTTON, *************** *** 178,181 **** --- 178,187 ---- CONTROL "Don't Draw on Radar",IDC_RADARNO,"Button", BS_AUTORADIOBUTTON,84,159,81,11 + GROUPBOX "Static",IDC_STATIC,0,0,48,40 + GROUPBOX "Static",IDC_STATIC,7,176,94,40 + CONTROL "Timestamps Enabled",IDC_TIMESTAMPON,"Button", + BS_AUTORADIOBUTTON,14,186,86,13 + CONTROL "Timestamps Disabled",IDC_TIMESTAMPOFF,"Button", + BS_AUTORADIOBUTTON,14,202,82,12 END *************** *** 306,310 **** VERTGUIDE, 241 TOPMARGIN, 7 ! BOTTOMMARGIN, 207 END --- 312,316 ---- VERTGUIDE, 241 TOPMARGIN, 7 ! BOTTOMMARGIN, 248 END Index: OptionsDlg.cpp =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/OptionsDlg.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** OptionsDlg.cpp 3 Jan 2003 00:55:38 -0000 1.11 --- OptionsDlg.cpp 11 Feb 2003 22:20:09 -0000 1.12 *************** *** 108,111 **** --- 108,116 ---- ::SendMessage( GetDlgItem( IDC_RADARYES )->m_hWnd, BM_SETCHECK, dwRadarDraw, 0 ); + DWORD dwTimestamp = 0; + key.QueryValue( dwTimestamp, "Timestamp" ); + ::SendMessage( GetDlgItem( IDC_TIMESTAMPOFF )->m_hWnd, BM_SETCHECK, !dwTimestamp, 0 ); + ::SendMessage( GetDlgItem( IDC_TIMESTAMPON )->m_hWnd, BM_SETCHECK, dwTimestamp, 0 ); + // Get font type DWORD dwFontType; *************** *** 235,238 **** --- 240,251 ---- key.SetValue( (DWORD) 0, "BarDelta" ); } + + DWORD dwTimestamp = 1; + key.QueryValue( dwTimestamp, "Timestamp" ); + + if( ::SendMessage( GetDlgItem( IDC_TIMESTAMPON )->m_hWnd, BM_GETCHECK, 0, 0 ) ) + key.SetValue( (DWORD) 1, "Timestamp" ); + else + key.SetValue( (DWORD) 0, "Timestamp" ); if(::SendMessage(GetDlgItem(IDC_BLENDINGGDIPLUS)->m_hWnd, BM_GETCHECK, 0, 0)) Index: resource.h =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/resource.h,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** resource.h 3 Jan 2003 00:55:38 -0000 1.17 --- resource.h 11 Feb 2003 22:20:10 -0000 1.18 *************** *** 70,73 **** --- 70,76 ---- #define IDC_RADIO2 1043 #define IDC_RADARNO 1043 + #define IDC_RADIO1 1044 + #define IDC_TIMESTAMPON 1044 + #define IDC_TIMESTAMPOFF 1045 #define ID_SYSTRAY_CONFIGURE 32771 #define ID_SYSTRAY_EXIT 32772 *************** *** 79,83 **** #define _APS_NEXT_RESOURCE_VALUE 149 #define _APS_NEXT_COMMAND_VALUE 32776 ! #define _APS_NEXT_CONTROL_VALUE 1044 #define _APS_NEXT_SYMED_VALUE 105 #endif --- 82,86 ---- #define _APS_NEXT_RESOURCE_VALUE 149 #define _APS_NEXT_COMMAND_VALUE 32776 ! #define _APS_NEXT_CONTROL_VALUE 1046 #define _APS_NEXT_SYMED_VALUE 105 #endif |
From: <ha...@us...> - 2003-02-11 22:19:35
|
Update of /cvsroot/decaldev/source/Decal In directory sc8-pr-cvs1:/tmp/cvs-serv32467 Modified Files: ACHooks.h ACHooks.cpp Log Message: timestamps! Index: ACHooks.h =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.h,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** ACHooks.h 13 Jan 2003 05:30:40 -0000 1.31 --- ACHooks.h 11 Feb 2003 22:19:28 -0000 1.32 *************** *** 71,75 **** bool m_bDecalRef; - bool m_bMismatch; --- 71,74 ---- Index: ACHooks.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.cpp,v retrieving revision 1.37 retrieving revision 1.38 diff -C2 -d -r1.37 -r1.38 *** ACHooks.cpp 13 Jan 2003 05:30:40 -0000 1.37 --- ACHooks.cpp 11 Feb 2003 22:19:29 -0000 1.38 *************** *** 36,39 **** --- 36,42 ---- qString* ( __fastcall *pfnInternalStringConstructor)( qString *, long, char * ) = NULL; + bool g_bTimestamp; + char charBufferPreviousCall; + extern void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long dwColor ); extern void OnChatText(); *************** *** 44,47 **** --- 47,52 ---- cACHooks::cACHooks() { + g_bTimestamp = false; + _bstr_t _Unnamed; s_pACHooks = this; *************** *** 77,93 **** m_bGetSkill = false; m_bLogout = false; ! m_bSecureTrade_Add = false; ! m_bSecureTrade_Add_Off1 = false; ! m_bSecureTrade_Add_Off2 = false; m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); m_HookCount = 0; char szPath[ MAX_PATH ]; DWORD dwCount = MAX_PATH; ! CRegKey keyPath; ! keyPath.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal\\Agent", KEY_READ ); ! keyPath.QueryValue( szPath, "AgentPath", &dwCount ); strncat( szPath, "\\memlocs.xml", MAX_PATH ); --- 82,107 ---- m_bGetSkill = false; m_bLogout = false; ! m_bSecureTrade_Add = false; ! m_bSecureTrade_Add_Off1 = false; ! m_bSecureTrade_Add_Off2 = false; m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); m_HookCount = 0; + charBufferPreviousCall = '\n'; + char szPath[ MAX_PATH ]; DWORD dwCount = MAX_PATH; ! DWORD dwTimestamp = 0; ! CRegKey key; ! key.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal", KEY_READ ); ! key.QueryValue( dwTimestamp, "Timestamp" ); ! key.Close(); ! ! g_bTimestamp = static_cast< bool >( dwTimestamp ); ! ! key.Open( HKEY_LOCAL_MACHINE, "SOFTWARE\\Decal\\Agent", KEY_READ ); ! key.QueryValue( szPath, "AgentPath", &dwCount ); strncat( szPath, "\\memlocs.xml", MAX_PATH ); *************** *** 658,662 **** STDMETHODIMP cACHooks::ChatOut(BSTR szText, long lColor) { ! if( pfnOldChatMessage == NULL ) return S_FALSE; --- 672,680 ---- STDMETHODIMP cACHooks::ChatOut(BSTR szText, long lColor) { ! if( pfnOldChatMessage == NULL ) ! return S_FALSE; ! ! DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); ! if( *Addy == NULL ) return S_FALSE; *************** *** 664,678 **** char *strText = OLE2A( szText ); ! char *pText = new char[ strlen( strText ) + 3 ]; ! _snprintf( pText, strlen( strText ) + 2, "%s\n", strText ); ! DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); ! if( *Addy == NULL ) ! return S_FALSE; ! pfnOldChatMessage(*Addy, 0, pText, lColor); ! ! delete [] pText; return S_OK; } --- 682,784 ---- char *strText = OLE2A( szText ); ! int iStrLen = strlen( strText ); ! if( g_bTimestamp ) ! { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! ! int iOffset = 0; ! char *szTemp = strText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! ! charBufferPreviousCall = '\n'; ! ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); ! } ! } ! ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! ! else ! { ! if( bDoTimeStamp ) ! { ! if( strText != NULL ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, szTimeStamp, lColor ); ! } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! ! else ! { ! //_snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! } + char *szNewLine = "\n"; + pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); + + delete [] szTimeStamp; + } + + else + { + char *pText = new char[ iStrLen + 3 ]; + _snprintf( pText, iStrLen + 2, "%s\n", strText ); + pfnOldChatMessage( *Addy, 0, pText, lColor ); + delete [] pText; + } + return S_OK; } *************** *** 680,684 **** STDMETHODIMP cACHooks::RawChatOut(BSTR szText, long lColor) { ! if( pfnOldChatMessage == NULL ) return S_FALSE; --- 786,794 ---- STDMETHODIMP cACHooks::RawChatOut(BSTR szText, long lColor) { ! if( pfnOldChatMessage == NULL ) ! return S_FALSE; ! ! DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); ! if( *Addy == NULL ) return S_FALSE; *************** *** 687,696 **** char *strText = OLE2A( szText ); ! DWORD *Addy = reinterpret_cast< DWORD * > ( m_lChatMessageAddy ); ! if( *Addy == NULL ) ! return S_FALSE; - pfnOldChatMessage(*Addy, 0, strText, lColor); - return S_OK; } --- 797,888 ---- char *strText = OLE2A( szText ); ! if( g_bTimestamp ) ! { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! int iStrLen = strlen( strText ); ! ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! ! int iOffset = 0; ! char *szTemp = strText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( *Addy, 0, szNewLine, lColor ); ! } ! } ! ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( *Addy, 0, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! ! else ! { ! if( bDoTimeStamp ) ! { ! if( strText != NULL ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, szTimeStamp, lColor ); ! } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! ! else ! { ! //_snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, strText ); ! pfnOldChatMessage( *Addy, 0, strText, lColor ); ! } ! } ! ! delete [] szTimeStamp; ! } ! ! else ! pfnOldChatMessage( *Addy, 0, strText, lColor ); return S_OK; } *************** *** 1570,1579 **** } ! void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long dwColor ) { ! if( !DispatchChatMessage(pText, dwColor) ) ! { ! pfnOldChatMessage(_ecx, _edx, pText, dwColor); ! } } --- 1762,1851 ---- } ! void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long lColor ) { ! if( !DispatchChatMessage( pText, lColor ) ) ! { ! if( g_bTimestamp ) ! { ! bool bDoTimeStamp = (charBufferPreviousCall == '\n') ? true : false; ! int iStrLen = strlen( pText ); ! ! char *szTimeStamp = new char[ iStrLen + 25 ]; ! memset( szTimeStamp, 0, iStrLen + 25 ); ! ! int iOffset = 0; ! char *szTemp = pText; ! while( *szTemp != 0 ) ! { ! szTimeStamp[ iOffset++ ] = *szTemp; ! charBufferPreviousCall = *szTemp; ! szTemp++; ! } ! ! SYSTEMTIME stTime; ! GetLocalTime( &stTime ); ! ! char *szLB = strstr( szTimeStamp, "\n" ); ! if( szLB != NULL ) ! { ! char *szToken = strtok( szTimeStamp, "\n" ); ! ! if( !bDoTimeStamp ) ! { ! if( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "%s\n", szToken ); ! pfnOldChatMessage( _ecx, _edx, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! ! else ! { ! char *szNewLine = "\n"; ! pfnOldChatMessage( _ecx, _edx, szNewLine, lColor ); ! } ! } ! ! while( szToken != NULL ) ! { ! int iStrLenA = strlen( szToken ) + 11; ! char *szTimeStampA = new char[ iStrLenA ]; ! memset( szTimeStampA, 0, iStrLenA ); ! ! _snprintf( szTimeStampA, iStrLenA, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, szToken ); ! pfnOldChatMessage( _ecx, _edx, szTimeStampA, lColor ); ! ! szToken = strtok( NULL, "\n" ); ! delete [] szTimeStampA; ! } ! } ! ! else ! { ! if( bDoTimeStamp ) ! { ! _snprintf( szTimeStamp, iStrLen + 25, "[%d:%02d] %s\n", stTime.wHour, stTime.wMinute, pText ); ! pfnOldChatMessage( _ecx, _edx, szTimeStamp, lColor ); ! } ! ! else ! { ! _snprintf( szTimeStamp, iStrLen + 25, "%s\n", stTime.wHour, stTime.wMinute, pText ); ! pfnOldChatMessage( _ecx, _edx, szTimeStamp, lColor ); ! } ! } ! ! delete [] szTimeStamp; ! } ! ! else ! pfnOldChatMessage( _ecx, _edx, pText, lColor ); ! } } |
From: <ar...@us...> - 2003-01-13 05:30:43
|
Update of /cvsroot/decaldev/source/Decal In directory sc8-pr-cvs1:/tmp/cvs-serv3110/Decal Modified Files: ACHooks.cpp ACHooks.h Log Message: Fixed VC7 vs VC6 Compile Issues #if'd it. Index: ACHooks.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.cpp,v retrieving revision 1.36 retrieving revision 1.37 diff -C2 -d -r1.36 -r1.37 *** ACHooks.cpp 13 Jan 2003 04:48:15 -0000 1.36 --- ACHooks.cpp 13 Jan 2003 05:30:40 -0000 1.37 *************** *** 821,826 **** if( m_bDecalRef ) { ! /* CComPtr< DecalPlugins::IPluginSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( DecalPlugins::IPluginSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) --- 821,826 ---- if( m_bDecalRef ) { ! CComPtr< IPSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( IPSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) *************** *** 835,839 **** *pVal = *pChatState ? VARIANT_TRUE : VARIANT_FALSE; ! return S_OK;*/ } --- 835,839 ---- *pVal = *pChatState ? VARIANT_TRUE : VARIANT_FALSE; ! return S_OK; } Index: ACHooks.h =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.h,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** ACHooks.h 13 Jan 2003 04:48:15 -0000 1.30 --- ACHooks.h 13 Jan 2003 05:30:40 -0000 1.31 *************** *** 5,9 **** --- 5,16 ---- #include "DecalManager.h" #include "DecalCP.h" + // .NET vs VC6.0 Compiler Config + #if _MSC_VER > 1200 // .NET + #import "..\Include\Inject.tlb" + #define IPSite DecalPlugins::IPluginSite + #else // Not .Net #include "..\inject\Inject.h" + #define IPSite IPluginSite + #endif struct sMemoryLocation |
From: <ar...@us...> - 2003-01-13 04:49:18
|
Update of /cvsroot/decaldev/source/Inject In directory sc8-pr-cvs1:/tmp/cvs-serv19827/Inject Modified Files: Inject.cpp Log Message: Cyncia_L - Fix for Inject.dll not closing with decal. Index: Inject.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Inject/Inject.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** Inject.cpp 1 Aug 2002 00:52:24 -0000 1.15 --- Inject.cpp 13 Jan 2003 04:49:15 -0000 1.16 *************** *** 183,186 **** --- 183,188 ---- ::UnhookWindowsHookEx( g_hHook ); g_hHook = NULL; + // Send a broadcast message, this forces the hook to trigger, and thus unload + SendMessage(HWND_BROADCAST,WM_NULL,0,0); } |
From: <ar...@us...> - 2003-01-13 04:48:36
|
Update of /cvsroot/decaldev/source/Include In directory sc8-pr-cvs1:/tmp/cvs-serv19578/Include Modified Files: Decal.idl Log Message: Added SecureTrade_ADD Index: Decal.idl =================================================================== RCS file: /cvsroot/decaldev/source/Include/Decal.idl,v retrieving revision 1.28 retrieving revision 1.29 diff -C2 -d -r1.28 -r1.29 *** Decal.idl 20 Dec 2002 03:49:10 -0000 1.28 --- Decal.idl 13 Jan 2003 04:48:33 -0000 1.29 *************** *** 147,150 **** --- 147,152 ---- { eLogout = 0, + eSecureTrade_Add = 1, + eColorEx = 2, eAvailableHooksEx_DWORD = 0x7FFFFFFF // coerce enums into 4 byte instead of two }; *************** *** 243,246 **** --- 245,249 ---- [id(43), helpstring("method Logout")] HRESULT Logout(); [id(44), helpstring("method SetDecal")] HRESULT SetDecal([in] IUnknown *pDecal); + [id(45), helpstring("method SecureTrade_Add")] HRESULT SecureTrade_Add([in] long ItemID, [out, retval] VARIANT_BOOL *pVal); }; |
From: <ar...@us...> - 2003-01-13 04:48:18
|
Update of /cvsroot/decaldev/source/Decal In directory sc8-pr-cvs1:/tmp/cvs-serv19455/Decal Modified Files: ACHooks.cpp ACHooks.h Log Message: Cynica_L - @log Fix for OnChat Crash on Message Eat - Added SecureTrade_ADD Index: ACHooks.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.cpp,v retrieving revision 1.35 retrieving revision 1.36 diff -C2 -d -r1.35 -r1.36 *** ACHooks.cpp 2 Jan 2003 17:18:02 -0000 1.35 --- ACHooks.cpp 13 Jan 2003 04:48:15 -0000 1.36 *************** *** 25,29 **** long g_lObjectDestroyedProc = 0; ! void (*pfnOldChatMessage)( char *, DWORD ) = NULL; void (*pfnOldChatText)() = NULL; void (*pfnUseItem)( DWORD, DWORD ) = NULL; --- 25,29 ---- long g_lObjectDestroyedProc = 0; ! void (__fastcall *pfnOldChatMessage)(int _ecx, int _edx, char *, DWORD ) = NULL; void (*pfnOldChatText)() = NULL; void (*pfnUseItem)( DWORD, DWORD ) = NULL; *************** *** 36,40 **** qString* ( __fastcall *pfnInternalStringConstructor)( qString *, long, char * ) = NULL; ! extern void OnChatMessage( char* pText, long dwColor ); extern void OnChatText(); --- 36,40 ---- qString* ( __fastcall *pfnInternalStringConstructor)( qString *, long, char * ) = NULL; ! extern void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long dwColor ); extern void OnChatText(); *************** *** 77,80 **** --- 77,83 ---- m_bGetSkill = false; m_bLogout = false; + m_bSecureTrade_Add = false; + m_bSecureTrade_Add_Off1 = false; + m_bSecureTrade_Add_Off2 = false; m_Hooks = 0; memset(m_HooksEx, 0, sizeof(m_HooksEx)); *************** *** 179,183 **** if( QueryMemLoc( BSTRT( "ChatMessage" ), &Val ) == S_OK ) ! pfnOldChatMessage = reinterpret_cast< void (*)( char *, DWORD ) >( Val ); if( QueryMemLoc( BSTRT( "ChatMessageAddy" ), &Val ) == S_OK ) m_lChatMessageAddy = Val; --- 182,186 ---- if( QueryMemLoc( BSTRT( "ChatMessage" ), &Val ) == S_OK ) ! pfnOldChatMessage = reinterpret_cast< void (__fastcall*)( int, int, char *, DWORD ) >( Val ); if( QueryMemLoc( BSTRT( "ChatMessageAddy" ), &Val ) == S_OK ) m_lChatMessageAddy = Val; *************** *** 508,511 **** --- 511,538 ---- } + if (QueryMemLoc(BSTRT( "SecureTrade_Add" ), &Val) == S_OK) + { + m_lSecureTrade_Add = Val; + m_bSecureTrade_Add = true; + } + + if (QueryMemLoc(BSTRT( "SecureTrade_Add_Off1" ), &Val) == S_OK) + { + m_lSecureTrade_Add_Off1 = Val; + m_bSecureTrade_Add_Off1 = true; + } + + if (QueryMemLoc(BSTRT( "SecureTrade_Add_Off2" ), &Val) == S_OK) + { + m_lSecureTrade_Add_Off2 = Val; + m_bSecureTrade_Add_Off2 = true; + } + + if (m_bSecureTrade_Add && m_bSecureTrade_Add_Off1 && m_bSecureTrade_Add_Off2 && m_bCombatState) + { + SetHookEx(eSecureTrade_Add); + } + + DWORD dwOldProtect; if( QueryMemLoc( BSTRT( "OnChatText" ), &Val ) == S_OK ) *************** *** 631,635 **** STDMETHODIMP cACHooks::ChatOut(BSTR szText, long lColor) { ! if( pfnOldChatMessage == NULL ) return S_FALSE; --- 658,662 ---- STDMETHODIMP cACHooks::ChatOut(BSTR szText, long lColor) { ! if( pfnOldChatMessage == NULL ) return S_FALSE; *************** *** 644,657 **** return S_FALSE; ! __asm ! { ! mov esi, Addy ! mov ecx, [esi] ! ! push lColor ! push pText ! call pfnOldChatMessage ! add esp, 0x8 ! } delete [] pText; --- 671,675 ---- return S_FALSE; ! pfnOldChatMessage(*Addy, 0, pText, lColor); delete [] pText; *************** *** 662,666 **** STDMETHODIMP cACHooks::RawChatOut(BSTR szText, long lColor) { ! if( pfnOldChatMessage == NULL ) return S_FALSE; --- 680,684 ---- STDMETHODIMP cACHooks::RawChatOut(BSTR szText, long lColor) { ! if( pfnOldChatMessage == NULL ) return S_FALSE; *************** *** 673,686 **** return S_FALSE; ! __asm ! { ! mov esi, Addy ! mov ecx, [esi] ! ! push lColor ! push strText ! call pfnOldChatMessage ! add esp, 0x8 ! } return S_OK; --- 691,695 ---- return S_FALSE; ! pfnOldChatMessage(*Addy, 0, strText, lColor); return S_OK; *************** *** 812,816 **** if( m_bDecalRef ) { ! CComPtr< DecalPlugins::IPluginSite > pSite; if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( DecalPlugins::IPluginSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { --- 821,825 ---- if( m_bDecalRef ) { ! /* CComPtr< DecalPlugins::IPluginSite > pSite; if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( DecalPlugins::IPluginSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { *************** *** 826,830 **** *pVal = *pChatState ? VARIANT_TRUE : VARIANT_FALSE; ! return S_OK; } --- 835,839 ---- *pVal = *pChatState ? VARIANT_TRUE : VARIANT_FALSE; ! return S_OK;*/ } *************** *** 1384,1387 **** --- 1393,1456 ---- } + STDMETHODIMP cACHooks::SecureTrade_Add(long ItemID, VARIANT_BOOL *pVal) + { + void ( __fastcall *Internal_SecureTrade_Add )( struct qPointerList *, int, long ); + struct qPointerList *p; + VARIANT_BOOL ItemExists; + HRESULT hr; + + if (pVal) /* Should probably return an error code. Tough. */ + { + *pVal = VARIANT_FALSE; + } + + if ( m_bSecureTrade_Add && m_bSecureTrade_Add_Off1 && m_bSecureTrade_Add_Off2 && m_bCombatState ) + { + hr = ItemIsKnown(ItemID, &ItemExists); + if (FAILED(hr)) + { + return hr; + } + + if (ItemExists == VARIANT_FALSE) + { + return S_FALSE; + } + + p = (struct qPointerList *)m_lCombatState; + if (!p) + { + return S_FALSE; + } + + p = p->dd[0]; + if (!p) + { + return S_FALSE; + } + + p = p->dd[m_lSecureTrade_Add_Off1 >> 2]; + if (!p) + { + return S_FALSE; + } + + p = p->dd[m_lSecureTrade_Add_Off2 >> 2]; + if (!p) + { + return S_FALSE; + } + + Internal_SecureTrade_Add = reinterpret_cast< void ( __fastcall *)( struct qPointerList *, int, long ) >( m_lSecureTrade_Add ); + Internal_SecureTrade_Add(p, 0, ItemID); + if (pVal) + { + *pVal = VARIANT_TRUE; + } + return S_OK; + } + return S_FALSE; + } + void cACHooks::SetHookEx( eAvailableHooksEx HookID ) { *************** *** 1485,1492 **** } ! bool DispatchChatMessage( char *pText, long *pdwColor ) { if( cACHooks::s_pACHooks ) ! return cACHooks::s_pACHooks->InternalChatMessage( pText, *pdwColor ); return false; --- 1554,1561 ---- } ! bool DispatchChatMessage( char *pText, long pdwColor ) { if( cACHooks::s_pACHooks ) ! return cACHooks::s_pACHooks->InternalChatMessage( pText, pdwColor ); return false; *************** *** 1501,1539 **** } ! void __declspec(naked) OnChatMessage( char* pText, long dwColor ) { ! __asm ! { ! push ebp ! mov ebp, esp ! sub esp, 20h ! push esi ! ! push ecx ! ! lea esi, dwColor ! push esi ! push pText ! call DispatchChatMessage ! ! add esp, 8 ! ! test al, al ! jz dont_kill_text ! ! mov dword ptr [pText], 0 ! ! dont_kill_text: ! pop ecx ! ! push dwColor ! push pText ! call pfnOldChatMessage ! ! pop esi ! mov esp, ebp ! pop ebp ! retn 8 ! } } --- 1570,1579 ---- } ! void __fastcall OnChatMessage( int _ecx, int _edx, char* pText, long dwColor ) { ! if( !DispatchChatMessage(pText, dwColor) ) ! { ! pfnOldChatMessage(_ecx, _edx, pText, dwColor); ! } } Index: ACHooks.h =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.h,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** ACHooks.h 2 Jan 2003 17:18:02 -0000 1.29 --- ACHooks.h 13 Jan 2003 04:48:15 -0000 1.30 *************** *** 5,9 **** #include "DecalManager.h" #include "DecalCP.h" ! #import "..\Include\Inject.tlb" struct sMemoryLocation --- 5,9 ---- #include "DecalManager.h" #include "DecalCP.h" ! #include "..\inject\Inject.h" struct sMemoryLocation *************** *** 169,172 **** --- 169,182 ---- long m_lLogout; + bool m_bSecureTrade_Add; + long m_lSecureTrade_Add; + bool m_bSecureTrade_Add_Off1; + long m_lSecureTrade_Add_Off1; + bool m_bSecureTrade_Add_Off2; + long m_lSecureTrade_Add_Off2; + + bool m_bChatColor; + long m_lChatColor; + unsigned int m_HooksEx[1]; unsigned int m_HookCount; *************** *** 227,229 **** --- 237,240 ---- STDMETHOD(Logout)(); STDMETHOD(SetDecal)(IUnknown *pDecal); + STDMETHOD(SecureTrade_Add)(long ItemID, VARIANT_BOOL *pVal); }; |
From: <ha...@us...> - 2003-01-03 16:32:58
|
Update of /cvsroot/decaldev/source/Inject In directory sc8-pr-cvs1:/tmp/cvs-serv29052 Modified Files: BarLayer.cpp Log Message: duh bug - i shouldnt code on no sleep :) Index: BarLayer.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Inject/BarLayer.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** BarLayer.cpp 3 Jan 2003 00:55:21 -0000 1.11 --- BarLayer.cpp 3 Jan 2003 16:32:53 -0000 1.12 *************** *** 216,222 **** // 308 - Extreme Right Edge - 418 - Past Radar ! int nVariableWidth = 308; ! if( m_bRadarDraw = false ) ! nVariableWidth = 418; int nWidth = sz.cx - ( nVariableWidth + 230 + m_TotalDelta ); --- 216,222 ---- // 308 - Extreme Right Edge - 418 - Past Radar ! int nVariableWidth = 418; ! if( m_bRadarDraw ) ! nVariableWidth = 308; int nWidth = sz.cx - ( nVariableWidth + 230 + m_TotalDelta ); |
From: <as...@us...> - 2003-01-03 14:50:21
|
Update of /cvsroot/decaldev/source/DenAgent In directory sc8-pr-cvs1:/tmp/cvs-serv5181 Modified Files: AddRemoveDlg.cpp Log Message: Add/Remove dialog now uses correct .Net plugin version Index: AddRemoveDlg.cpp =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/AddRemoveDlg.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** AddRemoveDlg.cpp 18 Jan 2002 20:10:33 -0000 1.13 --- AddRemoveDlg.cpp 3 Jan 2003 14:50:13 -0000 1.14 *************** *** 81,138 **** // Now get matching info from the registry - if available CRegKey keyPlugin; - //TCHAR szVersion[ 20 ]; - //LPSTR lpVersion; CString csVersion; ! if( keyPlugin.Open( HKEY_LOCAL_MACHINE, _T( "SOFTWARE\\Decal\\Plugins\\" ), KEY_READ ) == ERROR_SUCCESS ) ! { ! keyPlugin.Close(); ! if( keyPlugin.Open( HKEY_CLASSES_ROOT, CString(_T("CLSID\\")) + OLE2T(vClsid.bstrVal) + _T("\\InprocServer32"), KEY_READ ) != ERROR_SUCCESS ) goto NotInstalled; ! ! DWORD dwSize = MAX_PATH; ! TCHAR szDllName[MAX_PATH]; - if(keyPlugin.QueryValue(szDllName, "", &dwSize) != ERROR_SUCCESS) goto NotInstalled; keyPlugin.Close(); - - DWORD dwHandle; - DWORD dwVerInfoSize = GetFileVersionInfoSize(szDllName,&dwHandle); - if(!dwVerInfoSize) goto NotInstalled; - - - LPBYTE pVersionData = NULL; - - pVersionData = new BYTE[dwVerInfoSize]; ! if(!GetFileVersionInfo(szDllName, dwHandle, dwVerInfoSize, pVersionData)) ! { ! delete [] pVersionData; goto NotInstalled; - } ! VS_FIXEDFILEINFO* pFixedFileInfo; ! UINT uFixedInfoSize; ! if(!VerQueryValue(pVersionData, "\\", (void**) &pFixedFileInfo, &uFixedInfoSize)) ! { ! delete [] pVersionData; goto NotInstalled; - } - - // The plugin is installed, check for version info - //DWORD dwVersion = 20; - //keyPlugin.QueryValue( szVersion, _T( "Version" ), &dwVersion ); - - //convertVersion( lpVersion, p.m_dwInstalledMajor, p.m_dwInstalledMinor ); ! p.m_dwInstalledMajor = pFixedFileInfo->dwFileVersionMS; ! p.m_dwInstalledMinor = pFixedFileInfo->dwFileVersionLS; ! csVersion.Format("%d.%d.%d.%d", HIWORD(p.m_dwInstalledMajor), LOWORD(p.m_dwInstalledMajor),HIWORD(p.m_dwInstalledMinor), LOWORD(p.m_dwInstalledMinor)); p.m_bInstalled = true; - - delete [] pVersionData; } else --- 81,114 ---- // Now get matching info from the registry - if available CRegKey keyPlugin; CString csVersion; + CString decalPluginKey; ! // See if this plugin is installed in the Decal plugin list ! decalPluginKey.Format("SOFTWARE\\Decal\\Plugins\\%s", OLE2T(vClsid.bstrVal)); ! if (keyPlugin.Open(HKEY_LOCAL_MACHINE, _T(decalPluginKey), KEY_READ) == ERROR_SUCCESS) ! { ! CString szDllName; keyPlugin.Close(); ! // It is! Get the DLL for the CLSID ! if (!CDenAgentApp::getCOMObjectDLL(p.m_clsid, szDllName)) goto NotInstalled; ! int iMajor, iMinor, iBuildMajor, iBuildMinor; ! // Now get the version from the DLL ! if (!CDenAgentApp::getVersionInfo(szDllName, iMajor, iMinor, iBuildMajor, iBuildMinor)) goto NotInstalled; ! // Setup the installed data by shifting the majors into the HIWORDs, minors into the LOWORDs ! p.m_dwInstalledMajor = (iMajor << 16) | iMinor; ! p.m_dwInstalledMinor = (iBuildMajor << 16) | iBuildMinor; ! // Format a version string ! csVersion.Format("%d.%d.%d.%d", iMajor, iMinor, iBuildMajor, iBuildMinor); p.m_bInstalled = true; } else |
From: <ar...@us...> - 2003-01-03 04:49:36
|
Update of /cvsroot/decaldev/source/DecalControls In directory sc8-pr-cvs1:/tmp/cvs-serv24492/DecalControls Modified Files: DecalControls.idl List.cpp List.h Log Message: Added List.CountCols() - Returns Column Count of a List Index: DecalControls.idl =================================================================== RCS file: /cvsroot/decaldev/source/DecalControls/DecalControls.idl,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** DecalControls.idl 17 Jun 2002 07:12:28 -0000 1.11 --- DecalControls.idl 3 Jan 2003 04:49:33 -0000 1.12 *************** *** 70,74 **** [id(103), propput, helpstring("property Data")] HRESULT Data(long nX, long nY, [defaultvalue(0)] long nSubValue, [in] VARIANT* newVal); [id(104), propput, helpstring("property RowEstimate")] HRESULT RowEstimate([in] long newVal); ! [propget, id(105), helpstring("property Count")] HRESULT Count([out, retval] long *pVal); [id(106), helpstring("method Clear")] HRESULT Clear(); [id(107), helpstring("method InsertRow")] HRESULT InsertRow(long lIndex); --- 70,74 ---- [id(103), propput, helpstring("property Data")] HRESULT Data(long nX, long nY, [defaultvalue(0)] long nSubValue, [in] VARIANT* newVal); [id(104), propput, helpstring("property RowEstimate")] HRESULT RowEstimate([in] long newVal); ! [propget, id(105), helpstring("property Count")] HRESULT Count([out, retval] long *pVal); [id(106), helpstring("method Clear")] HRESULT Clear(); [id(107), helpstring("method InsertRow")] HRESULT InsertRow(long lIndex); *************** *** 82,85 **** --- 82,86 ---- [propput, id(111), helpstring("property ScrollPosition")] HRESULT ScrollPosition([in] long newVal); [id(112), helpstring("method JumpToPosition")] HRESULT JumpToPosition(long newVal); + [propget, id(113), helpstring("property CountCols")] HRESULT CountCols([out, retval] long *pVal); }; Index: List.cpp =================================================================== RCS file: /cvsroot/decaldev/source/DecalControls/List.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** List.cpp 16 Oct 2002 22:40:37 -0000 1.20 --- List.cpp 3 Jan 2003 04:49:33 -0000 1.21 *************** *** 458,461 **** --- 458,470 ---- } + STDMETHODIMP cList::get_CountCols( long *pnCount ) + { + _ASSERTE( pnCount != NULL ); + + *pnCount = m_cols.size(); + + return S_OK; + } + STDMETHODIMP cList::Clear() { Index: List.h =================================================================== RCS file: /cvsroot/decaldev/source/DecalControls/List.h,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** List.h 7 Aug 2002 23:05:29 -0000 1.7 --- List.h 3 Jan 2003 04:49:33 -0000 1.8 *************** *** 108,115 **** STDMETHOD(put_RowEstimate)(/*[in]*/ long newVal); STDMETHOD(get_Count)(long *pnCount); STDMETHOD(Clear)(); STDMETHOD(put_ColumnWidth)(long nColumn, long nWidth); STDMETHOD(get_ColumnWidth)(long nColumn, long *nWidth); ! // ILayerRender Methods STDMETHOD(Reformat)(); --- 108,116 ---- STDMETHOD(put_RowEstimate)(/*[in]*/ long newVal); STDMETHOD(get_Count)(long *pnCount); + STDMETHOD(get_CountCols)(long *pnCount); STDMETHOD(Clear)(); STDMETHOD(put_ColumnWidth)(long nColumn, long nWidth); STDMETHOD(get_ColumnWidth)(long nColumn, long *nWidth); ! // ILayerRender Methods STDMETHOD(Reformat)(); |
From: <ha...@us...> - 2003-01-03 00:55:41
|
Update of /cvsroot/decaldev/source/DenAgent In directory sc8-pr-cvs1:/tmp/cvs-serv21748 Modified Files: DenAgent.rc OptionsDlg.cpp OptionsDlg.h resource.h Log Message: Option to turn on/off Decal drawing the plugin bar over the radar in stretch Index: DenAgent.rc =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/DenAgent.rc,v retrieving revision 1.61 retrieving revision 1.62 diff -C2 -d -r1.61 -r1.62 *** DenAgent.rc 30 Dec 2002 20:37:23 -0000 1.61 --- DenAgent.rc 3 Jan 2003 00:55:38 -0000 1.62 *************** *** 1,3 **** ! //Microsoft Developer Studio generated resource script. // #include "resource.h" --- 1,3 ---- ! // Microsoft Visual C++ generated resource script. // #include "resource.h" *************** *** 29,33 **** // Icon with lowest ID value placed first to ensure application icon // remains consistent on all systems. ! IDR_TRAYICON ICON DISCARDABLE "res\\idr_tray.ico" #endif // Neutral (Default) resources ///////////////////////////////////////////////////////////////////////////// --- 29,33 ---- // Icon with lowest ID value placed first to ensure application icon // remains consistent on all systems. ! IDR_TRAYICON ICON "res\\idr_tray.ico" #endif // Neutral (Default) resources ///////////////////////////////////////////////////////////////////////////// *************** *** 50,54 **** // Icon with lowest ID value placed first to ensure application icon // remains consistent on all systems. ! IDR_MAINFRAME ICON DISCARDABLE "res\\DenAgent.ico" ///////////////////////////////////////////////////////////////////////////// --- 50,54 ---- // Icon with lowest ID value placed first to ensure application icon // remains consistent on all systems. ! IDR_MAINFRAME ICON "res\\DenAgent.ico" ///////////////////////////////////////////////////////////////////////////// *************** *** 58,62 **** IDD_DENAGENT_DIALOG DIALOGEX 0, 0, 265, 215 ! STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU EXSTYLE WS_EX_APPWINDOW CAPTION "Decal Agent" --- 58,63 ---- IDD_DENAGENT_DIALOG DIALOGEX 0, 0, 265, 215 ! STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | ! WS_SYSMENU EXSTYLE WS_EX_APPWINDOW CAPTION "Decal Agent" *************** *** 83,87 **** IDD_ADDREMOVE DIALOGEX 0, 0, 301, 171 ! STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Add/Remove Plugins" FONT 8, "MS Sans Serif", 0, 0, 0x1 --- 84,88 ---- IDD_ADDREMOVE DIALOGEX 0, 0, 301, 171 ! STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Add/Remove Plugins" FONT 8, "MS Sans Serif", 0, 0, 0x1 *************** *** 98,103 **** END ! IDD_DOWNLOAD DIALOG DISCARDABLE 0, 0, 203, 71 ! STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION CAPTION "Downloading Component" FONT 8, "MS Sans Serif" --- 99,104 ---- END ! IDD_DOWNLOAD DIALOG 0, 0, 203, 71 ! STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION CAPTION "Downloading Component" FONT 8, "MS Sans Serif" *************** *** 110,115 **** END ! IDD_CHANGEDIR DIALOG DISCARDABLE 0, 0, 236, 49 ! STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Change Decal URL" FONT 8, "MS Sans Serif" --- 111,116 ---- END ! IDD_CHANGEDIR DIALOG 0, 0, 236, 49 ! STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Change Decal URL" FONT 8, "MS Sans Serif" *************** *** 122,133 **** END ! IDD_OPTIONS DIALOG DISCARDABLE 0, 0, 255, 215 ! STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Decal Options" ! FONT 8, "MS Sans Serif" BEGIN ! DEFPUSHBUTTON "OK",IDOK,198,10,50,14 ! PUSHBUTTON "Cancel",IDCANCEL,198,30,50,14 ! GROUPBOX "Transparency Options",IDC_STATIC,7,50,241,45 CTEXT "Bar Alpha",IDC_STATIC,20,64,35,8,SS_CENTERIMAGE EDITTEXT IDC_BARALPHA,14,74,50,14,ES_CENTER | ES_AUTOHSCROLL | --- 123,134 ---- END ! IDD_OPTIONS DIALOGEX 0, 0, 271, 214 ! STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Decal Options" ! FONT 8, "MS Sans Serif", 0, 0, 0x0 BEGIN ! DEFPUSHBUTTON "OK",IDOK,214,12,50,14 ! PUSHBUTTON "Cancel",IDCANCEL,214,30,50,14 ! GROUPBOX "Transparency Options",IDC_STATIC,7,50,257,45 CTEXT "Bar Alpha",IDC_STATIC,20,64,35,8,SS_CENTERIMAGE EDITTEXT IDC_BARALPHA,14,74,50,14,ES_CENTER | ES_AUTOHSCROLL | *************** *** 136,152 **** UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS,53,59,11,14 ! CTEXT "View Alpha",IDC_STATIC,200,64,35,8,SS_CENTERIMAGE ! EDITTEXT IDC_VIEWALPHA,191,74,50,14,ES_CENTER | ES_AUTOHSCROLL | ES_NUMBER CONTROL "Spin2",IDC_VIEWALPHA_SPIN,"msctls_updown32", UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | ! UDS_ARROWKEYS,237,58,11,14 CTEXT "Valid values are from 0 - 255\n\n0 is Transparent - 255 is Opaque", IDC_STATIC,70,64,114,26 ! GROUPBOX "Decal Update URL",IDC_STATIC,7,100,241,33 LTEXT "http://decaldev.sourceforge.net",IDC_PLUGINDIR,14,115, 169,8,SS_CENTERIMAGE ! PUSHBUTTON "Change",IDC_CHANGE_DIR,191,112,50,14 ! GROUPBOX "Blending Options",IDC_STATIC,7,7,190,38 CONTROL "Software Alpha Blending (most compatible)", IDC_BLENDINGSOFTWARE,"Button",BS_AUTORADIOBUTTON,14,18, --- 137,153 ---- UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS,53,59,11,14 ! CTEXT "View Alpha",IDC_STATIC,216,63,35,8,SS_CENTERIMAGE ! EDITTEXT IDC_VIEWALPHA,214,73,50,14,ES_CENTER | ES_AUTOHSCROLL | ES_NUMBER CONTROL "Spin2",IDC_VIEWALPHA_SPIN,"msctls_updown32", UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | ! UDS_ARROWKEYS,253,58,11,14 CTEXT "Valid values are from 0 - 255\n\n0 is Transparent - 255 is Opaque", IDC_STATIC,70,64,114,26 ! GROUPBOX "Decal Update URL",IDC_STATIC,7,100,257,33 LTEXT "http://decaldev.sourceforge.net",IDC_PLUGINDIR,14,115, 169,8,SS_CENTERIMAGE ! PUSHBUTTON "Change",IDC_CHANGE_DIR,214,111,50,14 ! GROUPBOX "Blending Options",IDC_STATIC,7,7,257,38 CONTROL "Software Alpha Blending (most compatible)", IDC_BLENDINGSOFTWARE,"Button",BS_AUTORADIOBUTTON,14,18, *************** *** 155,167 **** IDC_BLENDINGGDIPLUS,"Button",BS_AUTORADIOBUTTON,14,30, 170,10 ! CONTROL "Auto-Start Decal on Bootup",IDC_CHECK_AUTOSTART,"Button", ! BS_AUTOCHECKBOX | BS_LEFTTEXT | WS_TABSTOP,139,163,102,8 ! PUSHBUTTON "Reset Decal Bar Position",IDC_BTN_RESET,142,144,99,12 ! GROUPBOX "View Options",IDC_STATIC,7,137,100,37,WS_GROUP ! CONTROL "Many Views Open",IDC_VIEWMULTI,"Button", ! BS_AUTORADIOBUTTON,14,160,77,11 ! CONTROL "One View Open",IDC_VIEWSINGLE,"Button", ! BS_AUTORADIOBUTTON,14,147,77,11 ! GROUPBOX "Font",IDC_STATIC,7,178,241,31 CONTROL "Default",IDC_DEFAULT_FONT_RADIO,"Button", BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,14,190,39,10 --- 156,169 ---- IDC_BLENDINGGDIPLUS,"Button",BS_AUTORADIOBUTTON,14,30, 170,10 ! CONTROL "Start Decal on Bootup",IDC_CHECK_AUTOSTART,"Button", ! BS_AUTOCHECKBOX | BS_LEFTTEXT | WS_TABSTOP,173,162,91,8, ! WS_EX_RIGHT ! PUSHBUTTON "Reset Decal Bar Position",IDC_BTN_RESET,177,146,87,12 ! GROUPBOX "View Options",IDC_STATIC,7,138,68,37,WS_GROUP ! CONTROL "Many Views",IDC_VIEWMULTI,"Button",BS_AUTORADIOBUTTON, ! 14,160,55,11 ! CONTROL "One View",IDC_VIEWSINGLE,"Button",BS_AUTORADIOBUTTON,14, ! 147,52,11 ! GROUPBOX "Font",IDC_STATIC,7,178,257,31 CONTROL "Default",IDC_DEFAULT_FONT_RADIO,"Button", BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,14,190,39,10 *************** *** 170,178 **** CONTROL "Custom",IDC_CUSTOM_FONT_RADIO,"Button", BS_AUTORADIOBUTTON | WS_TABSTOP,105,190,39,10 ! EDITTEXT IDC_CUSTOM_FONT_EDIT,147,188,94,14,ES_AUTOHSCROLL END ! IDD_DOWNLOADER DIALOG DISCARDABLE 0, 0, 202, 86 ! STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Downloading Components" FONT 8, "MS Sans Serif" --- 172,185 ---- CONTROL "Custom",IDC_CUSTOM_FONT_RADIO,"Button", BS_AUTORADIOBUTTON | WS_TABSTOP,105,190,39,10 ! EDITTEXT IDC_CUSTOM_FONT_EDIT,147,188,117,14,ES_AUTOHSCROLL ! GROUPBOX "Bar Options",IDC_STATIC,79,138,95,37,WS_GROUP ! CONTROL "Draw on Radar",IDC_RADARYES,"Button",BS_AUTORADIOBUTTON, ! 84,145,79,12 ! CONTROL "Don't Draw on Radar",IDC_RADARNO,"Button", ! BS_AUTORADIOBUTTON,84,159,81,11 END ! IDD_DOWNLOADER DIALOG 0, 0, 202, 86 ! STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU CAPTION "Downloading Components" FONT 8, "MS Sans Serif" *************** *** 190,194 **** - #ifndef _MAC ///////////////////////////////////////////////////////////////////////////// // --- 197,200 ---- *************** *** 213,228 **** BLOCK "040904b0" BEGIN ! VALUE "Comments", "DenAgent is the program that manages Decal settings\0" ! VALUE "CompanyName", "\0" ! VALUE "FileDescription", "DenAgent MFC Application\0" ! VALUE "FileVersion", "2, 5, 0, 1\0" ! VALUE "InternalName", "DenAgent\0" ! VALUE "LegalCopyright", "Copyright (C) 2000, 2001\0" ! VALUE "LegalTrademarks", "\0" ! VALUE "OriginalFilename", "DenAgent.EXE\0" ! VALUE "PrivateBuild", "\0" ! VALUE "ProductName", "DenAgent Application\0" ! VALUE "ProductVersion", "2, 5, 0, 1\0" ! VALUE "SpecialBuild", "\0" END END --- 219,230 ---- BLOCK "040904b0" BEGIN ! VALUE "Comments", "DenAgent is the program that manages Decal settings" ! VALUE "FileDescription", "DenAgent MFC Application" ! VALUE "FileVersion", "2, 5, 0, 1" ! VALUE "InternalName", "DenAgent" ! VALUE "LegalCopyright", "Copyright (C) 2000, 2001" ! VALUE "OriginalFilename", "DenAgent.EXE" ! VALUE "ProductName", "DenAgent Application" ! VALUE "ProductVersion", "2, 5, 0, 1" END END *************** *** 233,238 **** END - #endif // !_MAC - ///////////////////////////////////////////////////////////////////////////// --- 235,238 ---- *************** *** 242,246 **** #ifdef APSTUDIO_INVOKED ! GUIDELINES DESIGNINFO MOVEABLE PURE BEGIN IDD_DENAGENT_DIALOG, DIALOG --- 242,246 ---- #ifdef APSTUDIO_INVOKED ! GUIDELINES DESIGNINFO BEGIN IDD_DENAGENT_DIALOG, DIALOG *************** *** 302,310 **** BEGIN LEFTMARGIN, 7 ! RIGHTMARGIN, 248 VERTGUIDE, 14 VERTGUIDE, 241 TOPMARGIN, 7 ! BOTTOMMARGIN, 208 END --- 302,310 ---- BEGIN LEFTMARGIN, 7 ! RIGHTMARGIN, 264 VERTGUIDE, 14 VERTGUIDE, 241 TOPMARGIN, 7 ! BOTTOMMARGIN, 207 END *************** *** 325,329 **** // ! IDR_POPUPS MENU DISCARDABLE BEGIN POPUP "SYSTRAY" --- 325,329 ---- // ! IDR_POPUPS MENU BEGIN POPUP "SYSTRAY" *************** *** 340,344 **** // ! IDR_VERSION_STATES TOOLBAR MOVEABLE PURE 21, 20 BEGIN BUTTON IDC_STATIC --- 340,344 ---- // ! IDR_VERSION_STATES TOOLBAR 21, 20 BEGIN BUTTON IDC_STATIC *************** *** 354,360 **** // ! IDR_VERSION_STATES BITMAP MOVEABLE PURE "res\\version_.bmp" ! IDB_IMAGES BITMAP MOVEABLE PURE "Images.bmp" ! IDB_BITMAP1 BITMAP MOVEABLE PURE "res\\bitmap1.bmp" #endif // English (U.S.) resources ///////////////////////////////////////////////////////////////////////////// --- 354,360 ---- // ! IDR_VERSION_STATES BITMAP "res\\version_.bmp" ! IDB_IMAGES BITMAP "Images.bmp" ! IDB_BITMAP1 BITMAP "res\\bitmap1.bmp" #endif // English (U.S.) resources ///////////////////////////////////////////////////////////////////////////// *************** *** 375,379 **** // ! IDB_GROUPS BITMAP MOVEABLE PURE "res\\groups.bmp" #ifdef APSTUDIO_INVOKED --- 375,379 ---- // ! IDB_GROUPS BITMAP "res\\groups.bmp" #ifdef APSTUDIO_INVOKED *************** *** 383,392 **** // ! 1 TEXTINCLUDE MOVEABLE PURE BEGIN "resource.h\0" END ! 2 TEXTINCLUDE MOVEABLE PURE BEGIN "#include ""afxres.h""\r\n" --- 383,392 ---- // ! 1 TEXTINCLUDE BEGIN "resource.h\0" END ! 2 TEXTINCLUDE BEGIN "#include ""afxres.h""\r\n" *************** *** 394,398 **** END ! 3 TEXTINCLUDE MOVEABLE PURE BEGIN "#define _AFX_NO_SPLITTER_RESOURCES\r\n" --- 394,398 ---- END ! 3 TEXTINCLUDE BEGIN "#define _AFX_NO_SPLITTER_RESOURCES\r\n" *************** *** 420,424 **** // ! IDR_DENAGENT REGISTRY MOVEABLE PURE "DenAgent.rgs" ///////////////////////////////////////////////////////////////////////////// --- 420,424 ---- // ! IDR_DENAGENT REGISTRY "DenAgent.rgs" ///////////////////////////////////////////////////////////////////////////// *************** *** 427,431 **** // ! STRINGTABLE DISCARDABLE BEGIN IDE_NOCLIENTEXE "Could not locate client.exe" --- 427,431 ---- // ! STRINGTABLE BEGIN IDE_NOCLIENTEXE "Could not locate client.exe" Index: OptionsDlg.cpp =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/OptionsDlg.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** OptionsDlg.cpp 24 Jul 2002 03:56:34 -0000 1.10 --- OptionsDlg.cpp 3 Jan 2003 00:55:38 -0000 1.11 *************** *** 103,106 **** --- 103,111 ---- //m_ViewAlpha.SetWindowText("255"); + DWORD dwRadarDraw = 1; + key.QueryValue( dwRadarDraw, "BarRadarDraw" ); + ::SendMessage( GetDlgItem( IDC_RADARNO )->m_hWnd, BM_SETCHECK, !dwRadarDraw, 0 ); + ::SendMessage( GetDlgItem( IDC_RADARYES )->m_hWnd, BM_SETCHECK, dwRadarDraw, 0 ); + // Get font type DWORD dwFontType; *************** *** 211,214 **** --- 216,238 ---- key.SetValue(alpha, "ViewAlpha"); + + + + DWORD dwRadarDraw = 1; + key.QueryValue( dwRadarDraw, "BarRadarDraw" ); + + if( ::SendMessage( GetDlgItem( IDC_RADARYES )->m_hWnd, BM_GETCHECK, 0, 0 ) ) + { + key.SetValue( (DWORD) 1, "BarRadarDraw" ); + if( !dwRadarDraw ) + key.SetValue( (DWORD) 0, "BarDelta" ); + } + + else + { + key.SetValue( (DWORD) 0, "BarRadarDraw" ); + if( dwRadarDraw ) + key.SetValue( (DWORD) 0, "BarDelta" ); + } if(::SendMessage(GetDlgItem(IDC_BLENDINGGDIPLUS)->m_hWnd, BM_GETCHECK, 0, 0)) Index: OptionsDlg.h =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/OptionsDlg.h,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** OptionsDlg.h 24 Jul 2002 03:56:34 -0000 1.4 --- OptionsDlg.h 3 Jan 2003 00:55:38 -0000 1.5 *************** *** 59,62 **** --- 59,64 ---- //}}AFX_MSG DECLARE_MESSAGE_MAP() + public: + afx_msg void OnBnClickedCheckAutostart(); }; Index: resource.h =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/resource.h,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** resource.h 24 Jul 2002 03:56:34 -0000 1.16 --- resource.h 3 Jan 2003 00:55:38 -0000 1.17 *************** *** 1,4 **** //{{NO_DEPENDENCIES}} ! // Microsoft Developer Studio generated include file. // Used by DenAgent.rc // --- 1,4 ---- //{{NO_DEPENDENCIES}} ! // Microsoft Visual C++ generated include file. // Used by DenAgent.rc // *************** *** 67,70 **** --- 67,73 ---- #define IDC_CLIENT_FONT_RADIO 1040 #define IDC_CUSTOM_FONT_RADIO 1041 + #define IDC_RADARYES 1042 + #define IDC_RADIO2 1043 + #define IDC_RADARNO 1043 #define ID_SYSTRAY_CONFIGURE 32771 #define ID_SYSTRAY_EXIT 32772 *************** *** 76,80 **** #define _APS_NEXT_RESOURCE_VALUE 149 #define _APS_NEXT_COMMAND_VALUE 32776 ! #define _APS_NEXT_CONTROL_VALUE 1042 #define _APS_NEXT_SYMED_VALUE 105 #endif --- 79,83 ---- #define _APS_NEXT_RESOURCE_VALUE 149 #define _APS_NEXT_COMMAND_VALUE 32776 ! #define _APS_NEXT_CONTROL_VALUE 1044 #define _APS_NEXT_SYMED_VALUE 105 #endif |
From: <ha...@us...> - 2003-01-03 00:55:24
|
Update of /cvsroot/decaldev/source/Inject In directory sc8-pr-cvs1:/tmp/cvs-serv21427 Modified Files: BarLayer.cpp BarLayer.h Log Message: Option to turn on/off Decal drawing the plugin bar over the radar in stretch Index: BarLayer.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Inject/BarLayer.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** BarLayer.cpp 1 Aug 2002 00:52:24 -0000 1.10 --- BarLayer.cpp 3 Jan 2003 00:55:21 -0000 1.11 *************** *** 18,23 **** }; ! cBarLayer::cBarLayer() ! : m_nPosition( 0 ), m_bDragging(false), m_TotalDelta(0), m_nMinMax( eStateMax ) { } --- 18,22 ---- }; ! cBarLayer::cBarLayer() : m_nPosition( 0 ), m_bDragging( false ), m_TotalDelta( 0 ), m_nMinMax( eStateMax ) { } *************** *** 36,44 **** // Ok, first create the 4 background controls LayerParams lpChild = { eBtnMinMax, { 12, 3, 28, 19 }, eRenderClipped }; - { CComPtr< ILayer > pUnk; ! HRESULT hRes = ::CoCreateInstance( CLSID_Button, NULL, CLSCTX_INPROC_SERVER, IID_ILayer, ! reinterpret_cast< void ** >( &pUnk ) ); _ASSERTE( SUCCEEDED( hRes ) ); --- 35,41 ---- // Ok, first create the 4 background controls LayerParams lpChild = { eBtnMinMax, { 12, 3, 28, 19 }, eRenderClipped }; { CComPtr< ILayer > pUnk; ! HRESULT hRes = ::CoCreateInstance( CLSID_Button, NULL, CLSCTX_INPROC_SERVER, IID_ILayer, reinterpret_cast< void ** >( &pUnk ) ); _ASSERTE( SUCCEEDED( hRes ) ); *************** *** 49,63 **** _ASSERTE( m_pBtnMinMax.p != NULL ); ! m_pBtnMinMax->SetImages(0, 0x0600113C, 0x0600113C); ! ICommandEventsImpl<BUTTON_MINMAX, cBarLayer>::advise(m_pBtnMinMax); m_pBtnMinMax->put_Matte( RGB( 0, 0, 0 ) ); } { - lpChild.ID = eBtnForwards; CComPtr< ILayer > pUnk; ! HRESULT hRes = ::CoCreateInstance( CLSID_Button, NULL, CLSCTX_INPROC_SERVER, IID_ILayer, ! reinterpret_cast< void ** >( &pUnk ) ); _ASSERTE( SUCCEEDED( hRes ) ); --- 46,58 ---- _ASSERTE( m_pBtnMinMax.p != NULL ); ! m_pBtnMinMax->SetImages( 0, 0x0600113C, 0x0600113C ); ! ICommandEventsImpl< BUTTON_MINMAX, cBarLayer >::advise( m_pBtnMinMax ); m_pBtnMinMax->put_Matte( RGB( 0, 0, 0 ) ); } { lpChild.ID = eBtnForwards; CComPtr< ILayer > pUnk; ! HRESULT hRes = ::CoCreateInstance( CLSID_Button, NULL, CLSCTX_INPROC_SERVER, IID_ILayer, reinterpret_cast< void ** >( &pUnk ) ); _ASSERTE( SUCCEEDED( hRes ) ); *************** *** 115,133 **** key.Create( HKEY_LOCAL_MACHINE, _T( "SOFTWARE\\Decal" ) ); ! DWORD alpha; ! if(key.QueryValue(alpha, "BarAlpha")==ERROR_SUCCESS) ! m_pSite->put_Alpha(alpha); ! if (key.QueryValue(m_nMinMax, "BarState") != ERROR_SUCCESS) m_nMinMax = eStateMax; ! if (key.QueryValue((DWORD &)m_TotalDelta, "BarDelta") != ERROR_SUCCESS) m_TotalDelta = 0; ! if (m_nMinMax == eStateMin) ! m_pBtnMinMax->SetImages(0, 0x0600113C, 0x0600113C); else ! m_pBtnMinMax->SetImages(0, 0x0600113B, 0x0600113B); } --- 110,132 ---- key.Create( HKEY_LOCAL_MACHINE, _T( "SOFTWARE\\Decal" ) ); ! DWORD dwAlpha = 255, dwRadarDraw = 1; ! m_bRadarDraw = true; ! if( key.QueryValue( dwAlpha, "BarAlpha" ) == ERROR_SUCCESS ) ! m_pSite->put_Alpha( dwAlpha ); ! if( key.QueryValue( dwRadarDraw, "BarRadarDraw" ) == ERROR_SUCCESS ) ! m_bRadarDraw = dwRadarDraw ? true : false; ! ! if( key.QueryValue( m_nMinMax, "BarState" ) != ERROR_SUCCESS ) m_nMinMax = eStateMax; ! if( key.QueryValue( (DWORD &) m_TotalDelta, "BarDelta" ) != ERROR_SUCCESS ) m_TotalDelta = 0; ! if( m_nMinMax == eStateMin ) ! m_pBtnMinMax->SetImages( 0, 0x0600113C, 0x0600113C ); else ! m_pBtnMinMax->SetImages( 0, 0x0600113B, 0x0600113B ); } *************** *** 184,289 **** STDMETHODIMP cBarLayer::Reformat() { ! _ASSERTE( m_pSite.p != NULL ); ! // ::MessageBox( NULL, _T( "cBarLayer::reformat" ), _T( "Inject.dll" ), MB_OK ); ! SIZE sz; ! CComPtr< IPluginSite > pPlugin; ! m_pSite->get_PluginSite( &pPlugin ); ! pPlugin->GetScreenSize( &sz ); ! ! // Make sure the Decal bar is always at least 112 pixels wide, ! if( !cManager::_p->m_bXMLViewViewer ) ! { ! if( m_TotalDelta > 420 ) ! m_TotalDelta = 420; ! // Also make sure it's never past left edge of the screen. ! if( m_TotalDelta < -230 ) ! m_TotalDelta = -230; ! } ! else ! { ! if( m_TotalDelta > 190 ) ! m_TotalDelta = 190; ! // Also make sure it's never past left edge of the screen. ! if( m_TotalDelta < -230 ) ! m_TotalDelta = -230; ! } ! // Now that we have the resolution, calculate the area we intend to cover ! int nWidth = sz.cx - ( 308 + 230 + m_TotalDelta ); ! RECT rc1 = { 230 + m_TotalDelta, 0, 230 + m_TotalDelta + nWidth, 23 }; ! m_pSite->put_Position( &rc1 ); ! // Now do the backwards ! RECT rc = { 30, 3, 46, 19 }; ! CComPtr< ILayerSite > pBackwardsSite; ! m_pSite->get_Child( eBtnBackwards, ePositionByID, &pBackwardsSite ); ! pBackwardsSite->put_Position( &rc ); ! // Next do the forward button ! rc.left = nWidth - 18; ! rc.top = 3; ! rc.right = nWidth - 2; ! rc.bottom = 19; ! CComPtr< ILayerSite > pFwdSite; ! m_pSite->get_Child( eBtnForwards, ePositionByID, &pFwdSite ); ! pFwdSite->put_Position( &rc ); ! // Now the pager ! CComPtr< ILayerSite > pPagerSite; ! m_pSite->get_Child( ePager, ePositionByID, &pPagerSite ); ! RECT rc3 = { 50, 1, nWidth - 20, 22 }; ! pPagerSite->put_Position( &rc3 ); ! m_offsets.clear(); ! long nOffset = 0; ! long nChildren; ! pPagerSite->get_ChildCount( &nChildren ); ! for( long nChild = 0; nChild < nChildren; ++ nChild ) ! { ! ViewParams pParams; ! CComPtr< ILayerSite > pChildSite; ! pPagerSite->get_Child( nChild, ePositionByIndex, &pChildSite ); ! long nChildID; ! pChildSite->get_ID( &nChildID ); ! if( nChildID < eChildBarFirst ) ! continue; ! CComPtr< ISimpleBar > pBarNative; ! pChildSite->GetSink( IID_ISimpleBar, reinterpret_cast< void ** >( &pBarNative ) ); ! pBarNative->get_Params(&pParams); ! pParams.state = m_nMinMax; ! pBarNative->put_Params(&pParams); ! long nDesired; ! pBarNative->get_RenderWidth( &nDesired ); ! // We always give bars their desired size ! RECT rcChild = { nOffset, 0, nOffset + nDesired, 21 }; ! pChildSite->put_Position( &rcChild ); ! m_offsets.push_back( nOffset ); ! nOffset += nDesired + 2; ! } ! // Check if the position is wrong now ! if( m_nPosition >= m_offsets.size() ) ! m_nPosition = m_offsets.size() - 1; ! POINT pt = { ( m_nPosition <= 0 ) ? 0 : m_offsets[ m_nPosition ], 0 }; ! m_pPager->ScrollTo( &pt ); ! m_pSite->Invalidate(); return S_OK; --- 183,295 ---- STDMETHODIMP cBarLayer::Reformat() { ! _ASSERTE( m_pSite.p != NULL ); ! // ::MessageBox( NULL, _T( "cBarLayer::reformat" ), _T( "Inject.dll" ), MB_OK ); ! SIZE sz; ! CComPtr< IPluginSite > pPlugin; ! m_pSite->get_PluginSite( &pPlugin ); ! pPlugin->GetScreenSize( &sz ); ! // Make sure the Decal bar is always at least 112 pixels wide, ! if( !cManager::_p->m_bXMLViewViewer ) ! { ! if( m_TotalDelta > 420 ) ! m_TotalDelta = 420; ! // Also make sure it's never past left edge of the screen. ! if( m_TotalDelta < -230 ) ! m_TotalDelta = -230; ! } ! else ! { ! if( m_TotalDelta > 190 ) ! m_TotalDelta = 190; ! // Also make sure it's never past left edge of the screen. ! if( m_TotalDelta < -230 ) ! m_TotalDelta = -230; ! } ! // Now that we have the resolution, calculate the area we intend to cover ! // 308 - Extreme Right Edge - 418 - Past Radar ! int nVariableWidth = 308; ! if( m_bRadarDraw = false ) ! nVariableWidth = 418; ! int nWidth = sz.cx - ( nVariableWidth + 230 + m_TotalDelta ); ! RECT rc1 = { 230 + m_TotalDelta, 0, 230 + m_TotalDelta + nWidth, 23 }; ! m_pSite->put_Position( &rc1 ); ! // Now do the backwards ! RECT rc = { 30, 3, 46, 19 }; ! CComPtr< ILayerSite > pBackwardsSite; ! m_pSite->get_Child( eBtnBackwards, ePositionByID, &pBackwardsSite ); ! pBackwardsSite->put_Position( &rc ); ! // Next do the forward button ! rc.left = nWidth - 18; ! rc.top = 3; ! rc.right = nWidth - 2; ! rc.bottom = 19; ! CComPtr< ILayerSite > pFwdSite; ! m_pSite->get_Child( eBtnForwards, ePositionByID, &pFwdSite ); ! pFwdSite->put_Position( &rc ); ! // Now the pager ! CComPtr< ILayerSite > pPagerSite; ! m_pSite->get_Child( ePager, ePositionByID, &pPagerSite ); ! RECT rc3 = { 50, 1, nWidth - 20, 22 }; ! pPagerSite->put_Position( &rc3 ); ! m_offsets.clear(); ! long nOffset = 0; ! long nChildren; ! pPagerSite->get_ChildCount( &nChildren ); ! for( long nChild = 0; nChild < nChildren; ++ nChild ) ! { ! ViewParams pParams; ! CComPtr< ILayerSite > pChildSite; ! pPagerSite->get_Child( nChild, ePositionByIndex, &pChildSite ); ! long nChildID; ! pChildSite->get_ID( &nChildID ); ! if( nChildID < eChildBarFirst ) ! continue; ! CComPtr< ISimpleBar > pBarNative; ! pChildSite->GetSink( IID_ISimpleBar, reinterpret_cast< void ** >( &pBarNative ) ); ! pBarNative->get_Params(&pParams); ! pParams.state = m_nMinMax; ! pBarNative->put_Params(&pParams); ! long nDesired; ! pBarNative->get_RenderWidth( &nDesired ); ! // We always give bars their desired size ! RECT rcChild = { nOffset, 0, nOffset + nDesired, 21 }; ! pChildSite->put_Position( &rcChild ); ! ! m_offsets.push_back( nOffset ); ! nOffset += nDesired + 2; ! } ! ! // Check if the position is wrong now ! if( m_nPosition >= m_offsets.size() ) ! m_nPosition = m_offsets.size() - 1; ! ! POINT pt = { ( m_nPosition <= 0 ) ? 0 : m_offsets[ m_nPosition ], 0 }; ! ! m_pPager->ScrollTo( &pt ); ! m_pSite->Invalidate(); return S_OK; Index: BarLayer.h =================================================================== RCS file: /cvsroot/decaldev/source/Inject/BarLayer.h,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** BarLayer.h 16 Apr 2002 19:56:10 -0000 1.5 --- BarLayer.h 3 Jan 2003 00:55:21 -0000 1.6 *************** *** 48,51 **** --- 48,52 ---- bool m_bDragging; + bool m_bRadarDraw; void onCreate(); |
From: <ha...@us...> - 2003-01-02 17:18:05
|
Update of /cvsroot/decaldev/source/Decal In directory sc8-pr-cvs1:/tmp/cvs-serv18847 Modified Files: ACHooks.cpp ACHooks.h Log Message: fix for needing to include inject.h in achooks... Index: ACHooks.cpp =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.cpp,v retrieving revision 1.34 retrieving revision 1.35 diff -C2 -d -r1.34 -r1.35 *** ACHooks.cpp 18 Dec 2002 02:57:04 -0000 1.34 --- ACHooks.cpp 2 Jan 2003 17:18:02 -0000 1.35 *************** *** 812,817 **** if( m_bDecalRef ) { ! CComPtr< IPluginSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof(IPluginSite), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) --- 812,817 ---- if( m_bDecalRef ) { ! CComPtr< DecalPlugins::IPluginSite > pSite; ! if( m_pDecal->get_Object( _bstr_t( "services\\DecalPlugins.InjectService\\site" ), __uuidof( DecalPlugins::IPluginSite ), reinterpret_cast< void ** >( &pSite ) ) == S_OK ) { if( pSite->get_Focus( pVal ) != S_OK ) Index: ACHooks.h =================================================================== RCS file: /cvsroot/decaldev/source/Decal/ACHooks.h,v retrieving revision 1.28 retrieving revision 1.29 diff -C2 -d -r1.28 -r1.29 *** ACHooks.h 12 Dec 2002 02:31:39 -0000 1.28 --- ACHooks.h 2 Jan 2003 17:18:02 -0000 1.29 *************** *** 5,9 **** #include "DecalManager.h" #include "DecalCP.h" ! #include "..\Inject\Inject.h" struct sMemoryLocation --- 5,9 ---- #include "DecalManager.h" #include "DecalCP.h" ! #import "..\Include\Inject.tlb" struct sMemoryLocation |
From: <ha...@us...> - 2003-01-02 17:17:36
|
Update of /cvsroot/decaldev/source/Include In directory sc8-pr-cvs1:/tmp/cvs-serv18679 Added Files: Inject.tlb Log Message: fix for needing to include inject.h in achooks... --- NEW FILE: Inject.tlb --- (This appears to be a binary file; contents omitted.) |
From: <as...@us...> - 2003-01-01 19:03:16
|
Update of /cvsroot/decaldev/source/Installer/Res In directory sc8-pr-cvs1:/tmp/cvs-serv7351 Modified Files: readme.rtf Install.vbs Log Message: Update for 2.5.0.1 Release Index: readme.rtf =================================================================== RCS file: /cvsroot/decaldev/source/Installer/Res/readme.rtf,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** readme.rtf 30 Dec 2002 20:29:39 -0000 1.22 --- readme.rtf 1 Jan 2003 19:03:12 -0000 1.23 *************** *** 2,6 **** {\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;\red255\green255\blue0;\red255\green255\blue255;\red0\green0\blue128;\red0\green128\blue128;\red0\green128\blue0; \red128\green0\blue128;\red128\green0\blue0;\red128\green128\blue0;\red128\green128\blue128;\red192\green192\blue192;}{\stylesheet{\widctlpar \f4 \snext0 Normal;}{\*\cs10 \additive Default Paragraph Font;}}{\info{\title Decal README}{\author Adam Wright} ! {\operator Adam Wright}{\creatim\yr2002\mo10\dy3\hr3\min43}{\revtim\yr2002\mo12\dy30\hr20\min19}{\version2}{\edmins2}{\nofpages2}{\nofwords277}{\nofchars1580}{\*\company The Anarchs}{\vern57443}} \widowctrl\ftnbj\aenddoc\noxlattoyen\expshrtn\noultrlspc\dntblnsbdb\nospaceforul\hyphcaps0 \fet0\sectd \linex0\headery709\footery709\colsx709 {\*\pnseclvl1\pnucrm\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl2\pnucltr\pnstart1\pnindent720\pnhang {\pntxta .}}{\*\pnseclvl3\pndec\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl4\pnlcltr\pnstart1\pnindent720\pnhang{\pntxta )}}{\*\pnseclvl5\pndec\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl6\pnlcltr\pnstart1\pnindent720\pnhang --- 2,6 ---- {\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;\red255\green255\blue0;\red255\green255\blue255;\red0\green0\blue128;\red0\green128\blue128;\red0\green128\blue0; \red128\green0\blue128;\red128\green0\blue0;\red128\green128\blue0;\red128\green128\blue128;\red192\green192\blue192;}{\stylesheet{\widctlpar \f4 \snext0 Normal;}{\*\cs10 \additive Default Paragraph Font;}}{\info{\title Decal README}{\author Adam Wright} ! {\operator Adam Wright}{\creatim\yr2002\mo10\dy3\hr3\min43}{\revtim\yr2003\mo1\dy1\hr19\min1}{\version2}{\edmins2}{\nofpages2}{\nofwords288}{\nofchars1647}{\*\company The Anarchs}{\vern57443}} \widowctrl\ftnbj\aenddoc\noxlattoyen\expshrtn\noultrlspc\dntblnsbdb\nospaceforul\hyphcaps0 \fet0\sectd \linex0\headery709\footery709\colsx709 {\*\pnseclvl1\pnucrm\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl2\pnucltr\pnstart1\pnindent720\pnhang {\pntxta .}}{\*\pnseclvl3\pndec\pnstart1\pnindent720\pnhang{\pntxta .}}{\*\pnseclvl4\pnlcltr\pnstart1\pnindent720\pnhang{\pntxta )}}{\*\pnseclvl5\pndec\pnstart1\pnindent720\pnhang{\pntxtb (}{\pntxta )}}{\*\pnseclvl6\pnlcltr\pnstart1\pnindent720\pnhang *************** *** 8,19 **** \qc\nowidctlpar \f4 {\b\f41\fs28\cf1 Decal README \par }{\f11\fs20\cf1 ! \par }{\fs20\cf1 This is the 2.5.0.1 Release Candidate 1 of Decal. \par ! \par }\pard \nowidctlpar {\fs22\cf1 This is Decal 2.5.0.1 RC1, a Release Candidate. These releases are not intended for all users, but limited support is available. We hope that our Release Candidates are bug free, so ! if you run into problems, please report them at http://forums.acdev.org/phpBB2/viewforum.php. \par }{\b\fs22\cf1 \par Changes since Release 2.5.0.0 RC3 ! \par {\pntext\pard\plain\b\f1\fs22\cf1\lang1033 \'b7\tab}}\pard \fi-283\li283\nowidctlpar{\*\pn \pnlvlblt\pnf1\pnstart1\pnindent283\pnhang{\pntxtb \'b7}}{\fs22\cf1 .Net plugins will now show their version in the agent, rather than the version of the .Net COM ! proxy.}{\b\fs22\cf1 \par {\pntext\pard\plain\b\f1\fs22\cf1\lang1033 \'b7\tab}}{\fs22\cf1 ACHooks slightly cleaned up, should now behave as it did in 2.5.0.0 RC1.}{\b\fs22\cf1 \par }\pard \nowidctlpar {\b\fs22\cf1 --- 8,22 ---- \qc\nowidctlpar \f4 {\b\f41\fs28\cf1 Decal README \par }{\f11\fs20\cf1 ! \par }{\fs20\cf1 This is the 2.5.0.1 Release of Decal. \par ! \par }\pard \nowidctlpar {\fs22\cf1 This is Decal 2.5.0.1, a supported end user release and a mandatory upgrade. This release is intended for all users, and support is available. We hope that our releases are bug free, but ! if you run into problems, please report them at http://forums.acdev.org/phpBB2/viewforum.php. \par }{\b\fs22\cf1 + \par Changes since Release 2.5.0.1 RC1 + \par {\pntext\pard\plain\b\f1\fs22\cf1\lang1033 \'b7\tab}}\pard \fi-283\li283\nowidctlpar{\*\pn \pnlvlblt\pnf1\pnstart1\pnindent283\pnhang{\pntxtb \'b7}}{\fs22\cf1 Install now enters correct version into the registry}{\b\fs22\cf1 + \par }\pard \nowidctlpar {\b\fs22\cf1 \par Changes since Release 2.5.0.0 RC3 ! \par {\pntext\pard\plain\b\f1\fs22\cf1\lang1033 \'b7\tab}}\pard \fi-283\li283\nowidctlpar{\*\pn \pnlvlblt\pnf1\pnstart1\pnindent283\pnhang{\pntxtb \'b7}}{\fs22\cf1 ! .Net plugins will now show their version in the agent, rather than the version of the .Net COM proxy.}{\b\fs22\cf1 \par {\pntext\pard\plain\b\f1\fs22\cf1\lang1033 \'b7\tab}}{\fs22\cf1 ACHooks slightly cleaned up, should now behave as it did in 2.5.0.0 RC1.}{\b\fs22\cf1 \par }\pard \nowidctlpar {\b\fs22\cf1 Index: Install.vbs =================================================================== RCS file: /cvsroot/decaldev/source/Installer/Res/Install.vbs,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** Install.vbs 30 Dec 2002 20:29:51 -0000 1.30 --- Install.vbs 1 Jan 2003 19:03:12 -0000 1.31 *************** *** 57,61 **** 'All of these -must- be specified Private Const ThisProduct = "Decal" ' The name of your product, used it dialogs and such ! Private Const ThisVersion = "2.5.0.1 RC1" ' The version of your product, used in dialogs and such Private Const MSIFileName = "Decal.msi" ' The name of the MSI file that will be excuted 'Add all of your previous product IDs to the dictionary for removal by the installer --- 57,61 ---- 'All of these -must- be specified Private Const ThisProduct = "Decal" ' The name of your product, used it dialogs and such ! Private Const ThisVersion = "2.5.0.1" ' The version of your product, used in dialogs and such Private Const MSIFileName = "Decal.msi" ' The name of the MSI file that will be excuted 'Add all of your previous product IDs to the dictionary for removal by the installer *************** *** 96,99 **** --- 96,100 ---- 'AllProducts.Add "2.5.0.0 RC3", "{F685D7CA-12EB-11D7-B2DA-009027B6A4F1}" Have no code for this! AllProducts.Add "2.5.0.1 RC1", "{B5B0E8D6-FE22-467C-B09E-1AB5CC837942}" + AllProducts.Add "2.5.0.1", "{CE4276BF-04AE-41C9-B7C2-3DD65B4DAEDD}" |
From: <as...@us...> - 2003-01-01 19:02:59
|
Update of /cvsroot/decaldev/source/Installer In directory sc8-pr-cvs1:/tmp/cvs-serv7155 Modified Files: DecalInstaller.wip Log Message: Update for 2.5.0.1 Release Index: DecalInstaller.wip =================================================================== RCS file: /cvsroot/decaldev/source/Installer/DecalInstaller.wip,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 Binary files /tmp/cvsJhN1eq and /tmp/cvso8hYDF differ |
From: <as...@us...> - 2003-01-01 18:14:18
|
Update of /cvsroot/decaldev/source/Installer In directory sc8-pr-cvs1:/tmp/cvs-serv26235 Modified Files: DecalInstaller.wip Log Message: Wrong version in registry corrected Index: DecalInstaller.wip =================================================================== RCS file: /cvsroot/decaldev/source/Installer/DecalInstaller.wip,v retrieving revision 1.28 retrieving revision 1.29 diff -C2 -d -r1.28 -r1.29 Binary files /tmp/cvsS48R3h and /tmp/cvsSYU9hw differ |
From: <as...@us...> - 2002-12-30 21:12:57
|
Update of /cvsroot/decaldev/source/DenAgent In directory sc8-pr-cvs1:/tmp/cvs-serv10427 Modified Files: DenAgent.cpp Log Message: Small fix to .Net version checking Index: DenAgent.cpp =================================================================== RCS file: /cvsroot/decaldev/source/DenAgent/DenAgent.cpp,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** DenAgent.cpp 30 Dec 2002 16:52:10 -0000 1.16 --- DenAgent.cpp 30 Dec 2002 21:12:50 -0000 1.17 *************** *** 185,193 **** DWORD dwPathSize = MAX_PATH; ! if (rk.QueryValue ( strFilename.GetBuffer ( MAX_PATH ), NULL, &dwPathSize ) != ERROR_SUCCESS) return false; ! // Check to see if the default KeyValue points to the MS.NET core DLL ! if ( strFilename.Find( "mscoree.dll" ) != -1) { // Get CodeBase KeyValue - Should point to the Plugin DLL --- 185,202 ---- DWORD dwPathSize = MAX_PATH; ! ! long regResult = rk.QueryValue ( strFilename.GetBuffer ( MAX_PATH ), NULL, &dwPathSize ); ! ! strFilename.ReleaseBuffer(); ! ! if (regResult != ERROR_SUCCESS) return false; ! // Check to see if the default KeyValue points to the MS.NET core DLL ! const char *dotNetProxy = "mscoree.dll"; ! ! CString dotNetMatchString = strFilename.Right(strlen(dotNetProxy)); ! ! if (dotNetMatchString.CompareNoCase(dotNetProxy) == 0) { // Get CodeBase KeyValue - Should point to the Plugin DLL *************** *** 207,211 **** --- 216,223 ---- dwPathSize = MAX_PATH; if (rk.QueryValue ( strFilename.GetBuffer ( MAX_PATH ), NULL, &dwPathSize ) != ERROR_SUCCESS) + { + strFilename.ReleaseBuffer(); return false; + } } } |
From: <as...@us...> - 2002-12-30 20:38:44
|
Update of /cvsroot/decaldev/source/Decal In directory sc8-pr-cvs1:/tmp/cvs-serv25967 Modified Files: Decal.rc Log Message: 2.5.0.1 version update Index: Decal.rc =================================================================== RCS file: /cvsroot/decaldev/source/Decal/Decal.rc,v retrieving revision 1.34 retrieving revision 1.35 diff -C2 -d -r1.34 -r1.35 *** Decal.rc 12 Dec 2002 02:31:39 -0000 1.34 --- Decal.rc 30 Dec 2002 20:38:40 -0000 1.35 *************** *** 1,3 **** ! // Microsoft Visual C++ generated resource script. // #include "resource.h" --- 1,3 ---- ! //Microsoft Developer Studio generated resource script. // #include "resource.h" *************** *** 28,37 **** // ! 1 TEXTINCLUDE BEGIN "resource.h\0" END ! 2 TEXTINCLUDE BEGIN "#include ""winres.h""\r\n" --- 28,37 ---- // ! 1 TEXTINCLUDE MOVEABLE PURE BEGIN "resource.h\0" END ! 2 TEXTINCLUDE MOVEABLE PURE BEGIN "#include ""winres.h""\r\n" *************** *** 39,43 **** END ! 3 TEXTINCLUDE BEGIN "1 TYPELIB ""Decal.tlb""\r\n" --- 39,43 ---- END ! 3 TEXTINCLUDE MOVEABLE PURE BEGIN "1 TYPELIB ""Decal.tlb""\r\n" *************** *** 48,51 **** --- 48,52 ---- + #ifndef _MAC ///////////////////////////////////////////////////////////////////////////// // *************** *** 54,59 **** VS_VERSION_INFO VERSIONINFO ! FILEVERSION 2,5,0,0 ! PRODUCTVERSION 2,5,0,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG --- 55,60 ---- VS_VERSION_INFO VERSIONINFO ! FILEVERSION 2,5,0,1 ! PRODUCTVERSION 2,5,0,1 FILEFLAGSMASK 0x3fL #ifdef _DEBUG *************** *** 70,80 **** BLOCK "040904b0" BEGIN ! VALUE "FileDescription", "Decal Module" ! VALUE "FileVersion", "2, 5, 0, 0" ! VALUE "InternalName", "Decal" ! VALUE "LegalCopyright", "Copyright 2001-2002" ! VALUE "OriginalFilename", "Decal.DLL" ! VALUE "ProductName", "Decal Module" ! VALUE "ProductVersion", "2, 5, 0, 0" END END --- 71,86 ---- BLOCK "040904b0" BEGIN ! VALUE "Comments", "\0" ! VALUE "CompanyName", "\0" ! VALUE "FileDescription", "Decal Module\0" ! VALUE "FileVersion", "2, 5, 0, 1\0" ! VALUE "InternalName", "Decal\0" ! VALUE "LegalCopyright", "Copyright 2001-2002\0" ! VALUE "LegalTrademarks", "\0" ! VALUE "OriginalFilename", "Decal.DLL\0" ! VALUE "PrivateBuild", "\0" ! VALUE "ProductName", "Decal Module\0" ! VALUE "ProductVersion", "2, 5, 0, 1\0" ! VALUE "SpecialBuild", "\0" END END *************** *** 85,88 **** --- 91,96 ---- END + #endif // !_MAC + ///////////////////////////////////////////////////////////////////////////// *************** *** 91,95 **** // ! IDR_ACHooks REGISTRY "ACHooks.rgs" ///////////////////////////////////////////////////////////////////////////// --- 99,103 ---- // ! IDR_ACHooks REGISTRY MOVEABLE PURE "ACHooks.rgs" ///////////////////////////////////////////////////////////////////////////// *************** *** 98,102 **** // ! STRINGTABLE BEGIN IDS_PROJNAME "Decal" --- 106,110 ---- // ! STRINGTABLE DISCARDABLE BEGIN IDS_PROJNAME "Decal" *************** *** 104,108 **** END ! STRINGTABLE BEGIN IDE_INDEXOUTOFRANGE "The provided index is below 0 or greater than the number of items in the list." --- 112,116 ---- END ! STRINGTABLE DISCARDABLE BEGIN IDE_INDEXOUTOFRANGE "The provided index is below 0 or greater than the number of items in the list." *************** *** 136,143 **** // ! IDR_DECAL REGISTRY "Decal.rgs" ! IDR_SURROGATEREMOVE REGISTRY "SurrogateRemove.rgs" ! IDR_ACTIVEXSURROGATE REGISTRY "ActiveXSurrogate.rgs" ! IDR_DECALRES REGISTRY "DecalRes.rgs" #endif // English (Canada) resources ///////////////////////////////////////////////////////////////////////////// --- 144,151 ---- // ! IDR_DECAL REGISTRY MOVEABLE PURE "Decal.rgs" ! IDR_SURROGATEREMOVE REGISTRY MOVEABLE PURE "SurrogateRemove.rgs" ! IDR_ACTIVEXSURROGATE REGISTRY MOVEABLE PURE "ActiveXSurrogate.rgs" ! IDR_DECALRES REGISTRY MOVEABLE PURE "DecalRes.rgs" #endif // English (Canada) resources ///////////////////////////////////////////////////////////////////////////// |
From: <as...@us...> - 2002-12-30 20:38:29
|
Update of /cvsroot/decaldev/source/DecalControls In directory sc8-pr-cvs1:/tmp/cvs-serv25838 Modified Files: DecalControls.rc Log Message: 2.5.0.1 version update Index: DecalControls.rc =================================================================== RCS file: /cvsroot/decaldev/source/DecalControls/DecalControls.rc,v retrieving revision 1.37 retrieving revision 1.38 diff -C2 -d -r1.37 -r1.38 *** DecalControls.rc 12 Dec 2002 02:32:07 -0000 1.37 --- DecalControls.rc 30 Dec 2002 20:38:26 -0000 1.38 *************** *** 1,3 **** ! // Microsoft Visual C++ generated resource script. // #include "resource.h" --- 1,3 ---- ! //Microsoft Developer Studio generated resource script. // #include "resource.h" *************** *** 28,37 **** // ! 1 TEXTINCLUDE BEGIN "resource.h\0" END ! 2 TEXTINCLUDE BEGIN "#include ""winres.h""\r\n" --- 28,37 ---- // ! 1 TEXTINCLUDE MOVEABLE PURE BEGIN "resource.h\0" END ! 2 TEXTINCLUDE MOVEABLE PURE BEGIN "#include ""winres.h""\r\n" *************** *** 39,43 **** END ! 3 TEXTINCLUDE BEGIN "1 TYPELIB ""DecalControls.tlb""\r\n" --- 39,43 ---- END ! 3 TEXTINCLUDE MOVEABLE PURE BEGIN "1 TYPELIB ""DecalControls.tlb""\r\n" *************** *** 48,51 **** --- 48,52 ---- + #ifndef _MAC ///////////////////////////////////////////////////////////////////////////// // *************** *** 54,59 **** VS_VERSION_INFO VERSIONINFO ! FILEVERSION 2,5,0,0 ! PRODUCTVERSION 2,5,0,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG --- 55,60 ---- VS_VERSION_INFO VERSIONINFO ! FILEVERSION 2,5,0,1 ! PRODUCTVERSION 2,5,0,1 FILEFLAGSMASK 0x3fL #ifdef _DEBUG *************** *** 70,81 **** BLOCK "040904b0" BEGIN ! VALUE "Comments", "DecalControls is a group of control objects that give plug-in developers a basic group of UI elements to work with" ! VALUE "FileDescription", "DecalControls Module" ! VALUE "FileVersion", "2, 5, 0, 0" ! VALUE "InternalName", "DecalControls" ! VALUE "LegalCopyright", "Copyright 2001" ! VALUE "OriginalFilename", "DecalControls.DLL" ! VALUE "ProductName", "DecalControls Module" ! VALUE "ProductVersion", "2, 5, 0, 0" END END --- 71,86 ---- BLOCK "040904b0" BEGIN ! VALUE "Comments", "DecalControls is a group of control objects that give plug-in developers a basic group of UI elements to work with\0" ! VALUE "CompanyName", "\0" ! VALUE "FileDescription", "DecalControls Module\0" ! VALUE "FileVersion", "2, 5, 0, 1\0" ! VALUE "InternalName", "DecalControls\0" ! VALUE "LegalCopyright", "Copyright 2001\0" ! VALUE "LegalTrademarks", "\0" ! VALUE "OriginalFilename", "DecalControls.DLL\0" ! VALUE "PrivateBuild", "\0" ! VALUE "ProductName", "DecalControls Module\0" ! VALUE "ProductVersion", "2, 5, 0, 1\0" ! VALUE "SpecialBuild", "\0" END END *************** *** 86,89 **** --- 91,96 ---- END + #endif // !_MAC + ///////////////////////////////////////////////////////////////////////////// *************** *** 92,112 **** // ! IDR_TEXTCOLUMN REGISTRY "TextColumn.rgs" ! IDR_ICONCOLUMN REGISTRY "IconColumn.rgs" ! IDR_LIST REGISTRY "List.rgs" ! IDR_NOTEBOOK REGISTRY "Notebook.rgs" ! IDR_SCROLLER REGISTRY "Scroller.rgs" ! IDR_CHECKCOLUMN REGISTRY "CheckColumn.rgs" ! IDR_EDIT REGISTRY "Edit.rgs" ! IDR_CHOICE REGISTRY "Choice.rgs" ! IDR_FIXEDLAYOUT REGISTRY "FixedLayout.rgs" ! IDR_BORDERLAYOUT REGISTRY "BorderLayout.rgs" ! IDR_PAGELAYOUT REGISTRY "PageLayout.rgs" ! IDR_PUSHBUTTON REGISTRY "PushButton.rgs" ! IDR_STATIC REGISTRY "Static.rgs" ! IDR_CHECKBOX REGISTRY "Checkbox.rgs" ! IDR_DerethMap REGISTRY "DerethMap.rgs" ! IDR_SLIDER REGISTRY "Slider.rgs" ! IDR_PROGRESS REGISTRY "Progress.rgs" ///////////////////////////////////////////////////////////////////////////// --- 99,119 ---- // ! IDR_TEXTCOLUMN REGISTRY MOVEABLE PURE "TextColumn.rgs" ! IDR_ICONCOLUMN REGISTRY MOVEABLE PURE "IconColumn.rgs" ! IDR_LIST REGISTRY MOVEABLE PURE "List.rgs" ! IDR_NOTEBOOK REGISTRY MOVEABLE PURE "Notebook.rgs" ! IDR_SCROLLER REGISTRY MOVEABLE PURE "Scroller.rgs" ! IDR_CHECKCOLUMN REGISTRY MOVEABLE PURE "CheckColumn.rgs" ! IDR_EDIT REGISTRY MOVEABLE PURE "Edit.rgs" ! IDR_CHOICE REGISTRY MOVEABLE PURE "Choice.rgs" ! IDR_FIXEDLAYOUT REGISTRY MOVEABLE PURE "FixedLayout.rgs" ! IDR_BORDERLAYOUT REGISTRY MOVEABLE PURE "BorderLayout.rgs" ! IDR_PAGELAYOUT REGISTRY MOVEABLE PURE "PageLayout.rgs" ! IDR_PUSHBUTTON REGISTRY MOVEABLE PURE "PushButton.rgs" ! IDR_STATIC REGISTRY MOVEABLE PURE "Static.rgs" ! IDR_CHECKBOX REGISTRY MOVEABLE PURE "Checkbox.rgs" ! IDR_DerethMap REGISTRY MOVEABLE PURE "DerethMap.rgs" ! IDR_SLIDER REGISTRY MOVEABLE PURE "Slider.rgs" ! IDR_PROGRESS REGISTRY MOVEABLE PURE "Progress.rgs" ///////////////////////////////////////////////////////////////////////////// *************** *** 115,124 **** // ! STRINGTABLE BEGIN IDS_PROJNAME "DecalControls" END ! STRINGTABLE BEGIN IDS_DERETHMAP_DESC "DerethMap Class" --- 122,131 ---- // ! STRINGTABLE DISCARDABLE BEGIN IDS_PROJNAME "DecalControls" END ! STRINGTABLE DISCARDABLE BEGIN IDS_DERETHMAP_DESC "DerethMap Class" |