Raised This Month: $ Target: $400
 0% 

error compile


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
elitecs
Junior Member
Join Date: Jun 2014
Old 11-07-2015 , 13:21   error compile
Reply With Quote #1

why i can't compile this sma?

Last edited by elitecs; 11-07-2015 at 14:02.
elitecs is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 11-07-2015 , 13:28   Re: error compile
Reply With Quote #2

As the error says, if you initialize a variable at a set size and are setting a default value, you must set a value for every slot, or make the size smaller.

Here you are sizing both at 11, but only setting 8 values. So you can either change those 11's to 8's, or add 3 more values to each array.
PHP Code:
#define GROUPS_NAME        11
#define GROUPS_ACCESS        11

new GroupNames[GROUPS_NAME][] = {
    
"---== THE KING==---",
    
"---= Owner + V.I.P =---",
    
"---= Co Owner + V.I.P =---",
    
"---= Moderator =---",
    
"---= Administrator =---",
    
"---== VIP ==---",
    
"---== Helper ==---",
    
"---== Slot ==---"
}

new 
GroupFlags[GROUPS_ACCESS][] = {
    
"abcdefghijklmnopqrstu",
    
"abcdefghijmnoqprstu",
    
"abcdefghijmnoqprst",
    
"bcdefghijm",
    
"bcfeijoqrt",
    
"bcdefijm",
    
"bcfeij",
    
"b"

__________________
Bugsy is offline
elitecs
Junior Member
Join Date: Jun 2014
Old 11-07-2015 , 13:37   Re: error compile
Reply With Quote #3

can u fix it for me? i'm newbie
elitecs is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 11-07-2015 , 13:43   Re: error compile
Reply With Quote #4

I told you what to do, change both 11's to 8's.

Code:
#define GROUPS_NAME        11
#define GROUPS_ACCESS        11
__________________
Bugsy is offline
elitecs
Junior Member
Join Date: Jun 2014
Old 11-07-2015 , 14:01   Re: error compile
Reply With Quote #5

Quote:
Originally Posted by Bugsy View Post
I told you what to do, change both 11's to 8's.

Code:
#define GROUPS_NAME        11
#define GROUPS_ACCESS        11
thank you
elitecs is offline
elitecs
Junior Member
Join Date: Jun 2014
Old 11-07-2015 , 14:16   Re: error compile
Reply With Quote #6

@Bugsy
why it don't show in a motd? it's working but not showing on a motd, it's like this now, and i want the text to be yellow not red

Last edited by elitecs; 11-07-2015 at 14:29.
elitecs is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 11-07-2015 , 14:45   Re: error compile
Reply With Quote #7

What's not showing?
__________________
Bugsy is offline
elitecs
Junior Member
Join Date: Jun 2014
Old 11-07-2015 , 15:08   Re: error compile
Reply With Quote #8

Quote:
Originally Posted by Bugsy View Post
What's not showing?
I mean i I want to appear the admins on a MOTD not text hope u understand
elitecs is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:10.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode