Compiling error

Results 1 to 9 of 9
  1. #1
    Account Upgraded | Title Enabled! KeyTrix is offline
    MemberRank
    Feb 2012 Join Date
    EverywhereLocation
    268Posts

    Compiling error

    Getting this error when Building my Gunz solution, I added custom grades:
    Spoiler:
    ../CSCommon\Include\MMatchObject.h(48) : error C2146: syntax error : missing '}' before identifier 'MMUG_GOLDEN'
    ../CSCommon\Include\MMatchObject.h(48) : error C2440: 'initializing' : cannot convert from 'int' to 'MMatchUserGradeID'
    Conversion to enumeration type requires an explicit cast (static_cast, C-style cast or function-style cast)
    ../CSCommon\Include\MMatchObject.h(49) : error C2440: 'initializing' : cannot convert from 'int' to 'MMatchUserGradeID'
    Conversion to enumeration type requires an explicit cast (static_cast, C-style cast or function-style cast)
    ../CSCommon\Include\MMatchObject.h(50) : error C2440: 'initializing' : cannot convert from 'int' to 'MMatchUserGradeID'
    Conversion to enumeration type requires an explicit cast (static_cast, C-style cast or function-style cast)
    ../CSCommon\Include\MMatchObject.h(51) : error C2059: syntax error : '}'
    ../CSCommon\Include\MMatchObject.h(51) : error C2143: syntax error : missing ';' before '}'
    ../CSCommon\Include\MMatchObject.h(51) : error C2059: syntax error : '}'


    My edited function:

    -MMatchObject.h
    Spoiler:
    enum MMatchUserGradeID
    {
    MMUG_FREE = 0, // ¹«·á °èÁ¤
    MMUG_REGULAR = 1, // Á¤¾× À¯Àú
    MMUG_STAR = 2, // ½ºÅ¸À¯Àú(°ÔÀÓ¯)
    MMUG_CHAT_LIMITED = 5, //Mute
    MMUG_VIP = 10, // VIP

    MMUG_CRIMINAL = 100, // Àü°úÀÚ
    MMUG_WARNING_1 = 101, // 1Â÷ °æ°í
    MMUG_WARNING_2 = 102, // 2Â÷ °æ°í
    MMUG_WARNING_3 = 103, // 3Â÷ °æ°í
    MMUG_PENALTY = 105, // ±â°£ Á¤Áö

    MMUG_EVENTMASTER = 252, // À̺¥Æ® ÁøÇàÀÚ
    MMUG_BLOCKED = 253, // »ç¿ë Á¤Áö
    MMUG_DEVELOPER = 254, // °³¹ßÀÚ
    MMUG_ADMIN = 255 // °ü¸®ÀÚ

    MMUG_GOLDEN = 6, // Golden VIP
    MMUG_PLATINUM = 7, // Platinum VIP
    MMUG_METALLIC = 8, // Metallic VIP
    };


  2. #2
    Account Upgraded | Title Enabled! ofiritsmeeee is offline
    MemberRank
    Sep 2011 Join Date
    274Posts

    Re: Compiling error

    Quote Originally Posted by KeyTrix View Post
    Getting this error when Building my Gunz solution, I added custom grades:
    Spoiler:
    ../CSCommon\Include\MMatchObject.h(48) : error C2146: syntax error : missing '}' before identifier 'MMUG_GOLDEN'
    ../CSCommon\Include\MMatchObject.h(48) : error C2440: 'initializing' : cannot convert from 'int' to 'MMatchUserGradeID'
    Conversion to enumeration type requires an explicit cast (static_cast, C-style cast or function-style cast)
    ../CSCommon\Include\MMatchObject.h(49) : error C2440: 'initializing' : cannot convert from 'int' to 'MMatchUserGradeID'
    Conversion to enumeration type requires an explicit cast (static_cast, C-style cast or function-style cast)
    ../CSCommon\Include\MMatchObject.h(50) : error C2440: 'initializing' : cannot convert from 'int' to 'MMatchUserGradeID'
    Conversion to enumeration type requires an explicit cast (static_cast, C-style cast or function-style cast)
    ../CSCommon\Include\MMatchObject.h(51) : error C2059: syntax error : '}'
    ../CSCommon\Include\MMatchObject.h(51) : error C2143: syntax error : missing ';' before '}'
    ../CSCommon\Include\MMatchObject.h(51) : error C2059: syntax error : '}'


    My edited function:

    -MMatchObject.h
    Spoiler:
    enum MMatchUserGradeID
    {
    MMUG_FREE = 0, // ¹«·á °èÁ¤
    MMUG_REGULAR = 1, // Á¤¾× À¯Àú
    MMUG_STAR = 2, // ½ºÅ¸À¯Àú(°ÔÀÓ¯)
    MMUG_CHAT_LIMITED = 5, //Mute
    MMUG_VIP = 10, // VIP

    MMUG_CRIMINAL = 100, // Àü°úÀÚ
    MMUG_WARNING_1 = 101, // 1Â÷ °æ°í
    MMUG_WARNING_2 = 102, // 2Â÷ °æ°í
    MMUG_WARNING_3 = 103, // 3Â÷ °æ°í
    MMUG_PENALTY = 105, // ±â°£ Á¤Áö

    MMUG_EVENTMASTER = 252, // À̺¥Æ® ÁøÇàÀÚ
    MMUG_BLOCKED = 253, // »ç¿ë Á¤Áö
    MMUG_DEVELOPER = 254, // °³¹ßÀÚ
    MMUG_ADMIN = 255 // °ü¸®ÀÚ

    MMUG_GOLDEN = 6, // Golden VIP
    MMUG_PLATINUM = 7, // Platinum VIP
    MMUG_METALLIC = 8, // Metallic VIP
    };
    First Post it the whole code , Secondly :
    MMUG_ADMIN = 255, // °ü¸®ÀÚ

  3. #3
    Account Upgraded | Title Enabled! KeyTrix is offline
    MemberRank
    Feb 2012 Join Date
    EverywhereLocation
    268Posts

    Re: Compiling error

    no lol, that's not the error.

    and why posting the whole code i only edited this part.
    Last edited by KeyTrix; 25-11-12 at 05:30 PM.

  4. #4
    Account Upgraded | Title Enabled! Rejain is offline
    MemberRank
    Jul 2012 Join Date
    201Posts

    Re: Compiling error

    In "MMUG_ADMIN = 255 // °ü¸®ÀÚ" u need to add a comma to 255 and delete the comma here :
    "MMUG_METALLIC = 8, // Metallic VIP"

    So you will get :
    Code:
    enum MMatchUserGradeID
    {
    MMUG_FREE	 = 0,	// ¹«·á °èÁ¤
    MMUG_REGULAR	 = 1,	// Á¤¾× À¯Àú
    MMUG_STAR	 = 2,	// ½ºÅ¸À¯Àú(°ÔÀÓ¯)
    MMUG_CHAT_LIMITED	= 5, //Mute
    MMUG_VIP	 = 10,	// VIP
    
    MMUG_CRIMINAL	 = 100,	// Àü°úÀÚ
    MMUG_WARNING_1	 = 101,	// 1Â÷ °æ°í
    MMUG_WARNING_2	 = 102,	// 2Â÷ °æ°í
    MMUG_WARNING_3	 = 103,	// 3Â÷ °æ°í
    MMUG_PENALTY	 = 105,	// ±â°£ Á¤Áö
    
    MMUG_EVENTMASTER	= 252,	// À̺¥Æ® ÁøÇàÀÚ
    MMUG_BLOCKED	 = 253,	// »ç¿ë Á¤Áö
    MMUG_DEVELOPER	 = 254,	// °³¹ßÀÚ
    MMUG_ADMIN	 = 255,	// °ü¸®ÀÚ
    
    MMUG_GOLDEN	 = 6,	// Golden VIP
    MMUG_PLATINUM	 = 7,	// Platinum VIP
    MMUG_METALLIC	 = 8	// Metallic VIP
    };

  5. #5
    Account Upgraded | Title Enabled! KeyTrix is offline
    MemberRank
    Feb 2012 Join Date
    EverywhereLocation
    268Posts

    Re: Compiling error

    LOL that's really stupid of me not to notice it should be taken off the last line hehe thanks buddy :D

  6. #6
    Account Upgraded | Title Enabled! ofiritsmeeee is offline
    MemberRank
    Sep 2011 Join Date
    274Posts

    Re: Compiling error

    Quote Originally Posted by KeyTrix View Post
    LOL that's really stupid of me not to notice it should be taken off the last line hehe thanks buddy :D
    told ya.

  7. #7
    Account Upgraded | Title Enabled! KeyTrix is offline
    MemberRank
    Feb 2012 Join Date
    EverywhereLocation
    268Posts

    Re: Compiling error

    yeah sorry I forgot to add a comma to the last line.

  8. #8
    Praise the Sun! Solaire is offline
    MemberRank
    Dec 2007 Join Date
    Undead BurgLocation
    2,862Posts

    Re: Compiling error

    Quote Originally Posted by KeyTrix View Post
    yeah sorry I forgot to add a comma to the last line.
    Thank God there's easy tutorials on this forum.

  9. #9
    Account Upgraded | Title Enabled! KeyTrix is offline
    MemberRank
    Feb 2012 Join Date
    EverywhereLocation
    268Posts

    Re: Compiling error

    LOL kid, that has nothing to do with anything, you're so irrelevant.

    I forgot, everybody does. go die in a hole.



Advertisement