It's possible with EUDs to detect if a player has selected anything for a given selection slot. However, it's not possible to detect if a player is using a multi-selection hack, because there isn't actually any address in SC's memory other than the twelve selection slots.
To check if anything is selected for the current selection slot, use "At least 1" as the value. If the value at the address is 0, it means nothing is selected. Example:
Detecting Number Of Units Selected
Trigger("Player 8"){
Conditions:
Memory(161889, Exactly, 0);
Memory(161890, Exactly, 0);
Memory(161891, Exactly, 0);
Memory(161892, Exactly, 0);
Memory(161893, Exactly, 0);
Memory(161894, Exactly, 0);
Memory(161895, Exactly, 0);
Memory(161896, Exactly, 0);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 0 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, Exactly, 0);
Memory(161891, Exactly, 0);
Memory(161892, Exactly, 0);
Memory(161893, Exactly, 0);
Memory(161894, Exactly, 0);
Memory(161895, Exactly, 0);
Memory(161896, Exactly, 0);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 1 unit selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, Exactly, 0);
Memory(161892, Exactly, 0);
Memory(161893, Exactly, 0);
Memory(161894, Exactly, 0);
Memory(161895, Exactly, 0);
Memory(161896, Exactly, 0);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 2 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, Exactly, 0);
Memory(161893, Exactly, 0);
Memory(161894, Exactly, 0);
Memory(161895, Exactly, 0);
Memory(161896, Exactly, 0);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 3 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, Exactly, 0);
Memory(161894, Exactly, 0);
Memory(161895, Exactly, 0);
Memory(161896, Exactly, 0);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 4 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, At least, 1);
Memory(161894, Exactly, 0);
Memory(161895, Exactly, 0);
Memory(161896, Exactly, 0);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 5 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, At least, 1);
Memory(161894, At least, 1);
Memory(161895, Exactly, 0);
Memory(161896, Exactly, 0);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 6 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, At least, 1);
Memory(161894, At least, 1);
Memory(161895, At least, 1);
Memory(161896, Exactly, 0);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 7 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, At least, 1);
Memory(161894, At least, 1);
Memory(161895, At least, 1);
Memory(161896, At least, 1);
Memory(161897, Exactly, 0);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 8 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, At least, 1);
Memory(161894, At least, 1);
Memory(161895, At least, 1);
Memory(161896, At least, 1);
Memory(161897, At least, 1);
Memory(161898, Exactly, 0);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 9 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, At least, 1);
Memory(161894, At least, 1);
Memory(161895, At least, 1);
Memory(161896, At least, 1);
Memory(161897, At least, 1);
Memory(161898, At least, 1);
Memory(161899, Exactly, 0);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 10 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, At least, 1);
Memory(161894, At least, 1);
Memory(161895, At least, 1);
Memory(161896, At least, 1);
Memory(161897, At least, 1);
Memory(161898, At least, 1);
Memory(161899, At least, 1);
Memory(161900, Exactly, 0);
Actions:
Comment("Player 1 has 11 units selected");
}
//-----------------------------------------------------------------//
Trigger("Player 8"){
Conditions:
Memory(161889, At least, 1);
Memory(161890, At least, 1);
Memory(161891, At least, 1);
Memory(161892, At least, 1);
Memory(161893, At least, 1);
Memory(161894, At least, 1);
Memory(161895, At least, 1);
Memory(161896, At least, 1);
Memory(161897, At least, 1);
Memory(161898, At least, 1);
Memory(161899, At least, 1);
Memory(161900, At least, 1);
Actions:
Comment("Player 1 has 12 units selected");
}
//-----------------------------------------------------------------//
If you're trying to use this as a selection hack detector, I don't think you'll make much progress.