I get a few errors I need help with.
#1

Good evening. I'm trying to save a players position, and load it back up when they disconnect. But I get 4 errors on one line. Here's the line of code:
pawn Код:
INI_Float("PositionX",PosX[playerid]);
And the errors I'm getting.
Код:
C:\Users\Luke\Desktop\Roleplay\gamemodes\rp.pwn(52) : warning 201: redefinition of constant/macro (symbol "strcpy(%0,%1,%2)")
C:\Users\Luke\Desktop\Roleplay\gamemodes\rp.pwn(220) : error 028: invalid subscript (not an array or too many subscripts): "PosX"
C:\Users\Luke\Desktop\Roleplay\gamemodes\rp.pwn(220) : error 029: invalid expression, assumed zero
C:\Users\Luke\Desktop\Roleplay\gamemodes\rp.pwn(220) : error 001: expected token: ";", but found ")"
C:\Users\Luke\Desktop\Roleplay\gamemodes\rp.pwn(220) : fatal error 107: too many error messages on one line
Is there something I'm missing/forgetting? Would love some help :P
Reply
#2

I'm not sure, but maybe like this

pawn Код:
INI_Float("PositionX=%f",PosX[playerid]);
Reply
#3

Still get the same errors I'm afraid.
Reply
#4

Can you show me how you defined your variable? Example: new test; etc
Reply
#5

Post the full code to your INI_Float function/macro and the deceleration for the PosX variable.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)