The variable for the player's class is actually $class rather than $uclass. $class stores the name of the player's class as a string,
so if you wanted to check if the player was a shadowknight in your example, the first line would be:
Code:
if (($itemcount{8911} == 1) && $class eq "Shadowknight")