ID:564461
 
(See the best response by DarkCampainger.)
How do I make it where I allow players to change their icon but it won't let them if it is a blank or like 1 dot... etc?


This is probably already on here but I couldn't find it because I don't really know what to call it.
How about an example of what you have already?

Not many users here just hand out code its best to display what you have already so it seems like you have made an effort.
Best response
You could try using icon/GetPixel() on each pixel in each frame of the icon, but it'll be pretty slow. You'll also have to come up with some kind of "pixel density" heuristic to measure how visible an icon is (ie one that takes alpha, movement states, delays, and other properties into account; or the system will be easily bypassed).

Really, it's probably not worth it. If you're worried about people making themselves invisible, just give them a name overlay.
@A.T.H.K You are right, I didn't make an attempt because I literally had no clue where to even begin to do that. Right now I have just a basic, very basic, change icon verb.

@DarkCompainger Yeah, I like the name overlay so I will just do that. I didn't think about that, Thank you.
In response to DarkCampainger
DarkCampainger wrote:
You could try using icon/GetPixel() on each pixel in each frame of the icon, but it'll be pretty slow.

You can use the icon's Scale() proc to make the icon 1x1, then you just have to look at a single pixel. When you shrink an icon it does some anti-aliasing. If you have at least a few non-blank pixels on the icon, when it's shrunk you'll have a non-blank icon. If the full icon was blank (or really close to it) the 1x1 version will be blank (or really close to it). I'm not sure how well it'd work but it beats looking at 1024 pixels.