Adding Display message for serialkey:202 error

Results 1 to 6 of 6
  1. #1
    Currently Stoned ! Ronny786 is offline
    MemberRank
    Dec 2011 Join Date
    Lost WorldLocation
    984Posts

    thumbs up Adding Display message for serialkey:202 error

    Not a big thing but Useful one !
    Some people think gunz doesnt work when they directly start with runnable.

    I think this will help them redirect to use launcher.

    Add below code in source.




    CGLEncription.cpp:

    Line 157:

    char *msg;


    Line: 168
    msg = "Please Start from Launcher";
    MessageBox(NULL, msg, "Msg", MB_OK | MB_ICONINFORMATION);

    Press ' Like ' :P
    Last edited by Ronny786; 02-07-12 at 10:51 AM.


  2. #2
    Proficient Member iDelta123 is offline
    MemberRank
    Apr 2012 Join Date
    The NetherlandsLocation
    154Posts

    Re: Adding Display message for serialkey:202 error

    Oh comon -.-

  3. #3
    Currently Stoned ! Ronny786 is offline
    MemberRank
    Dec 2011 Join Date
    Lost WorldLocation
    984Posts

    Re: Adding Display message for serialkey:202 error

    Quote Originally Posted by iDelta123 View Post
    Oh comon -.-

    This is actually important dude. Cause many people ask me "why is ur game not working, blah blah blah " ..n m actually not interested to tell each n every guy to start from launcher ! So its better to have small error code ..

    N i think this isnt waste ! =))

  4. #4

    Re: Adding Display message for serialkey:202 error

    Defining msg is unnecessary.

    Just pass the message parameter to MessageBox()...

    Also, defining char* and giving it a value like that is a terrible programming practice, because char* should have been defined with the const keyword.

  5. #5
    Retired. Don't PM. SecretsOThePast is offline
    DeveloperRank
    Jan 2009 Join Date
    643Posts

    Re: Adding Display message for serialkey:202 error

    MessageBox(NULL, "Please start from the launcher.", NULL, MB_OK | MB_ICONERROR);

    That's all you need to do. Absolutely no variables are needed.

    The only time you would need a variable in that scenario is if you loaded something from a resource, and the message may vary depending on the information in the resource. Since that is not the case in this scenario, you can do what I did above.

  6. #6
    Currently Stoned ! Ronny786 is offline
    MemberRank
    Dec 2011 Join Date
    Lost WorldLocation
    984Posts

    Re: Adding Display message for serialkey:202 error

    Quote Originally Posted by SecretsOThePast View Post
    MessageBox(NULL, "Please start from the launcher.", NULL, MB_OK | MB_ICONERROR);

    That's all you need to do. Absolutely no variables are needed.

    The only time you would need a variable in that scenario is if you loaded something from a resource, and the message may vary depending on the information in the resource. Since that is not the case in this scenario, you can do what I did above.

    NVM . ..
    Variable displays title of error mesage thats all !



Advertisement