array must be indexed (variable "Subs")
#1

I made a code for advert system that if some body place new ads the other ads move down 1 place but its showing a error please help.

pawn Код:
MoveAds(){
    new Subs[20], Adve[128], Placer[24],idx;
    while (iIndex < 15){
        Subs = strval(AdsInfo[idx][Sub]);
        Adve = strval(AdsInfo[idx][Advert]);
        Placer = strval(AdsInfo[iIndex][Placeby]);
        ++idx;
        AdsInfo[idx][Sub] = strval(Subs);
        AdsInfo[idx][Advert] = strval(Adve);
        AdsInfo[idx][Placeby] = strval(Placer);
    }
    return 1;
}
Код:
C:\Documents and Settings\PRABHAT ZONE\Desktop\metrolife\gamemodes\TestADs.pwn(142) : error 033: array must be indexed (variable "Subs")
C:\Documents and Settings\PRABHAT ZONE\Desktop\metrolife\gamemodes\TestADs.pwn(143) : error 033: array must be indexed (variable "Adve")
C:\Documents and Settings\PRABHAT ZONE\Desktop\metrolife\gamemodes\TestADs.pwn(144) : error 033: array must be indexed (variable "Placer")
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


3 Errors.
Reply
#2

WOW My Name is Prabhat too and Im from New Delhi, India also lol. Im not good at strings. I wish i would have learnt that Chapter properly! Sorry bro. Hope i could help!
Reply
#3

Thanks for reply I hope you can help.
Reply
#4

Don't use ' = ' for strings, try ' format'
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)