ID:980159
 
(See the best response by Kaiochao.)
Code:
for (var/mob/m in world)
if (m.client)
spawn()
m.client.images += oMoveHighlight
sleep(2)
if (m.client)
m.client.images -= oMoveHighlight // <-- Hit exception here


Problem description:
Hitting null exceptions in animation code when a player exits the game during an animation.

This code is spawned by one client to animate all other clients.

Is there a better design I could try?
for(var/client/m) could be used in place of checking for mobs then checking if they have a client.
Best response
Are you deleting the mob when a player exits the game? If so, you should be checking if 'm' exists before trying to check null.client. It should tell you this in the run-time error you're getting.
Alright, I just added checks for m and that seems to have fixed it. I wrongly assumed m was safe and mis-read the run-time spew.

Thanks!