this should work (assuming that there is only 1 value equal to AnotherRandVar):
PHP Code:
public cmdPrint(id)
{
//...
//SEE FROM HERE:
new AnotherRandVar = random(SIZE)+1
new offset
for(new i=0; i<NUMSTOPRINT; i++)
{
if(var[i] == AnotherRandVar)
{
offset++
}
client_print(id, print_console, "Num: %d", var[i+offset])
}
}
__________________