07.04.2014, 08:11
Kind of, yes. There is no actual string datatype in PAWN unlike some other languages, you must use arrays for that purpose.
Check out the below example, I've used 3 different methods to print the same character. (a)
There may be more.
If you don't know what %c does in printf, check this page out. It is a specifier for printing characters.
Check out the below example, I've used 3 different methods to print the same character. (a)
There may be more.
pawn Код:
new c = 97, // ASCII code for 'a'
a[1] = 'a', // Direct array assignment
holder = 'a'; // Direct
main() {
printf("%c", c);
printf("%c", a);
printf("%c", holder);
}