Array must be indexed
#1

Hello when I insert this code I receive the error:
pawn Код:
error 033: array must be indexed (variable "FACPAY")
Here is the code:
pawn Код:
new finalpaycheck = paycheck + FACPAY(i) - taxamount;
Reply
#2

You have FACPAY macro which probably returns string. Search for it and show it here.
Or try

pawn Код:
new finalpaycheck = paycheck + strval(FACPAY(i)) - taxamount;
but without knowing your code it can screw up everything
Reply
#3

is the FACPAY defined as
pawn Код:
new FACPAY[MAX_PLAYERS];
if yes it must be
pawn Код:
FACPAY[i]
Reply
#4

Quote:
Originally Posted by pds2012
Посмотреть сообщение
is the FACPAY defined as
pawn Код:
new FACPAY[MAX_PLAYERS];
if yes it must be
pawn Код:
FACPAY[i]
I have FACPAY defined as a stock. I believe Misiur provided the solution. Rep for you both.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)