4 Errors, Due to a Format.
#1

Код:
C:\Users\Dakota\Desktop\samp03csvr_win32\gamemodes\ww2.pwn(163) : error 001: expected token: "-string end-", but found "-identifier-"
C:\Users\Dakota\Desktop\samp03csvr_win32\gamemodes\ww2.pwn(163) : warning 215: expression has no effect
C:\Users\Dakota\Desktop\samp03csvr_win32\gamemodes\ww2.pwn(163) : warning 215: expression has no effect
C:\Users\Dakota\Desktop\samp03csvr_win32\gamemodes\ww2.pwn(163) : error 001: expected token: ";", but found ")"
C:\Users\Dakota\Desktop\samp03csvr_win32\gamemodes\ww2.pwn(163) : error 029: invalid expression, assumed zero
C:\Users\Dakota\Desktop\samp03csvr_win32\gamemodes\ww2.pwn(163) : fatal error 107: too many error messages on one line
In Line.

Код:
if(seconds < 10) format(string, sizeof string, "%d:0%d" minutes, seconds);
What the f'in fuck did i do wrong.
Reply
#2

pawn Код:
if(seconds < 10) format(string, sizeof(string), "%d:0%d", minutes, seconds);
Reply
#3

.... That's the same as the one i posted....
Reply
#4

No its not..
Notice the:
pawn Код:
sizeof string
And he gave you the fix:
pawn Код:
sizeof(string)
Aswell as the comma after:
"%d:0%d"
Reply
#5

It's not the same, look closely.
Reply
#6

Quote:
Originally Posted by -Rebel Son-
Посмотреть сообщение
.... That's the same as the one i posted....
Nope, you missed a comma:
pawn Код:
if(seconds < 10) format(string, sizeof string, "%d:0%d"/*here*/ minutes, seconds);
Reply
#7

Just do
format(string, sizeof(string), "%02d:%02d", minutes, seconds);
to always have 2 digits.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)