20.10.2018, 18:42
The warning is not about expecting constant array but passing a literal value. Make a crime list that you can access anywhere.
pawn Code:
enum
{
CRIME_UNKNOWN, // constant, its value is 0
CRIME_FIRST_DEGREE_MURDER // constant, its value is 1
}
new const CrimeList[][] =
{
"Unknown", // index 0
"First Degree Murder" // index 1
};
pawn Code:
if(PlayerInfo[playerid][pTeam] != 5) SetPlayerCriminal(killerid, CrimeList[CRIME_UNKNOWN], CrimeList[CRIME_FIRST_DEGREE_MURDER ], 1);