Code:
public static final int[] SCIMITAR =
{
566
};
public static int getWeaponSound(Client c)
{
if (c.playerEquipment[c.playerWeapon] == 4151)
{
return 1080;
}
if (c.playerEquipment[c.playerWeapon] == SCIMITAR)
{
return 396;
}
Code:
Building Server...
src\server\model\content\Sounds.java:21: incomparable types: int and int[]
if (c.playerEquipment[c.playerWeapon] == SCIMITAR)
^
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
1 error
Press any key to continue . . .
I can't use an Array because it's an integer method.. Is there another way to do this that's better?