sourcepawn
sourcepawn copied to clipboard
Warning 246: function hitGroupName returns an array but return type is not marked as an array
Warning 246: function hitGroupName returns an array but return type is not marked as an array. Warning on old syntax, don't know if it's still supported?
public OnPluginStart()
{
PrintToServer("%s", hitGroupName(0));
}
stock String:hitGroupName(hitgroup)
{
new String:tmpString[15] = "";
switch (hitgroup)
{
case 0: { tmpString = "body"; }
case 1: { tmpString = "head"; }
case 2: { tmpString = "chest"; }
case 3: { tmpString = "stomach"; }
case 4: { tmpString = "left arm"; }
case 5: { tmpString = "right arm"; }
case 6: { tmpString = "left leg"; }
case 7: { tmpString = "right leg"; }
case 10: { tmpString = "???"; }
}
return tmpString;
}