Results 1 to 7 of 7
Like Tree1Likes
  • 1 Post By King-OrgY

Thread: [Help]Cod5bot Error

  1. #1
    Member x33x's Avatar
    Join Date
    May 2011
    Posts
    53

    Question [Help]Cod5bot Error

    Hello Everyone.
    I am having a problem, I using King Orgys Cod5bot unfinnished bot.

    I am using C++ 2010.
    (I have not touched any of the files)

    Ok I wanted to test if I could compile the source to a DLL for a test. (I was testing to see if it would build the DLL)
    Well I got this error.

    (I have this set in Options)Use Multi-Byte Character Set
    And I have it to ignore warnings.

    Error
    Code:
    1>------ Build started: Project: CoD5_Aimbot, Configuration: Debug Win32 ------
    1>  StdAfx.cpp
    1>  Other.cpp
    1>  DLL_Main.cpp
    1>  cWallhack.cpp
    1>  cRadar.cpp
    1>  cMisc.cpp
    1>  cMenu.cpp
    1>  CLog.cpp
    1>  cEsp.cpp
    1>  cError.cpp
    1>  cEngine.cpp
    1>c:\users\*******\desktop\cod5 publicbot test\cod5 multihack\cengine.cpp(161): error C2446: '==' : no conversion from 'PDWORD' to 'DWORD'
    1>          There is no context in which this conversion is possible
    1>c:\users\*******\desktop\cod5 publicbot test\cod5 multihack\cengine.cpp(161): error C2040: '==' : 'DWORD' differs in levels of indirection from 'PDWORD'
    1>c:\users\*******\desktop\cod5 publicbot test\cod5 multihack\cengine.cpp(164): error C2440: '=' : cannot convert from 'PDWORD' to 'DWORD'
    1>          There is no context in which this conversion is possible
    1>  cDraw.cpp
    1>  cCG_Obituary.cpp
    1>  cAimbot.cpp
    1>  Generating Code...
    ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

  2. #2
    Semi-Coder ^attilathedud^'s Avatar
    Join Date
    Dec 2007
    Posts
    87

    Re: [Help]Cod5bot Error

    Visual Studio 2010 is more stringent in conversions than older versions of VS - read the errors, and then cast away.

    It looks like you have something like:
    Code:
    DWORD d;
    PDWORD pd;
    
    if( d == pd )...
    So read the error, find out it can't cast it explicitly, and tell the compiler how to:
    Code:
    if( d == (DWORD)pd)

  3. #3
    Member x33x's Avatar
    Join Date
    May 2011
    Posts
    53

    Re: [Help]Cod5bot Error

    Well this is the cEngine.cpp and where the error is:
    Code:
    if( pThunk->u1.Function == ( PDWORD )pOldFunction )
    		{
    			VirtualProtect( ( void * )&pThunk->u1.Function, sizeof( DWORD ), PAGE_EXECUTE_READWRITE, &dwOldProtect );
    			pThunk->u1.Function = ( PDWORD )pNewFunction;
    			VirtualProtect( ( void * )&pThunk->u1.Function, sizeof( DWORD ), dwOldProtect, &dwOldProtect2 );
    			
    			return( pOldFunction );
    		}
    		pThunk++;
    	}
    	return( NULL ); 
    }
    (All of the errors are in the ==)
    Error is in this line:
    if( pThunk->u1.Function == ( PDWORD )pOldFunction )
    Error: Operand types are incompatible ("DWORD" AND "PDWORD")

    And another error here:
    pThunk->u1.Function = ( PDWORD )pNewFunction;
    Error: A value of type "PDWORD" cannot be assigned to entity of type "DWORD"

    Think you could explain more on how to fix?
    Remember this is King Orgy's work so if he were to answer that would be great.

  4. #4
    Admin King-OrgY's Avatar
    Join Date
    Nov 2007
    Posts
    4,537

    Re: [Help]Cod5bot Error

    Code:
            if( pThunk->u1.Function == ( DWORD )pOldFunction )
            {
                VirtualProtect( ( void * )&pThunk->u1.Function, sizeof( DWORD ), PAGE_EXECUTE_READWRITE, &dwOldProtect );
                pThunk->u1.Function = ( DWORD )pNewFunction;
                VirtualProtect( ( void * )&pThunk->u1.Function, sizeof( DWORD ), dwOldProtect, &dwOldProtect2 );
                
                return( pOldFunction );
            }
    enjoy
    x33x likes this.

  5. #5
    Member x33x's Avatar
    Join Date
    May 2011
    Posts
    53

    Re: [Help]Cod5bot Error

    Ok I can compile it but i get a error when i play the game.
    (As I expected I can never get a break )

    This a ingame error:
    Look in attachment....
    Attached Images Attached Images
    Last edited by x33x; August 2nd, 2012 at 00:57.

  6. #6
    Moderator Seraphim's Avatar
    Join Date
    Aug 2008
    Posts
    1,064

    Re: [Help]Cod5bot Error

    Are you compiling in release?

  7. #7
    Member x33x's Avatar
    Join Date
    May 2011
    Posts
    53

    Re: [Help]Cod5bot Error

    No, Let me try...

    //Edit How?, could not find it?
    I went to Project, Properties, Then configure and change it to release, then hit ok, then I go back to it and it says Actve(DeBug) when I changed it to release.

    //Edit 2: Nvm I am blind as a bate.

    //Edit 3: I love you so much you guys!!! Thanks!!!!!!! It worked!
    Last edited by x33x; August 2nd, 2012 at 02:19.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •