• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Pawn] Compilation error
#6
Lightbulb 
I've already found an issue (chatGPT helped me) :)

This happened because my
Code:
Convert
 function was trying to
Code:
return stringTos;
, but in Pawn you cannot return arrays of unknown size.

The solution was to remove the
Code:
return
statement and simply let the function fill the string that is passed by reference. The function call stays the same:

Code:
new time[32];

Convert(GetPVarInt(playerid, "schet_time_to_finish"), time);

Thanks to ChatGPT for helping me figure this out!
  Reply


Messages In This Thread
Compilation error - by primat - 2025-09-05, 07:00 AM
RE: Compilation error - by primat - 2025-09-05, 07:14 AM
RE: Compilation error - by MrKacu13 - 2025-09-06, 04:58 PM
RE: Compilation error - by primat - 2025-09-07, 06:19 AM
RE: Compilation error - by primat - 2025-09-07, 06:29 AM
RE: Compilation error - by primat - 2025-09-07, 07:03 AM
RE: Compilation error - by MrKacu13 - 2025-09-07, 07:18 AM

Forum Jump: