Ci is indeed a tricky italian word, has it has several different uses and I'm afraid there are no fast rules, as its meaning greatly dependends on the context.
I'll try to go through some of the most common uses
It can be
direct personal pronoun
Il professore ci ha visto copiare.
which corresponds to
Il professore ha visto noi copiare
The professor saw us copying
indirect personal pronoun
Il professore ci ha detto di non copiare
which corresponds to
Il professore ha detto a noi di non copiare
The professor told us not to copy
reciprocal pronoun
Ci vediamo spesso
We see each other often
adverb
Ci sono stato
which corresponds to
Sono stato lì
I've been there
redundant use as adverb
Ci sto proprio comodo qui
I'm really comfortable here
verb compounds
In some cases ci can be incorporated in a verb, some notable examples being: esserci (to be there/here), volerci (to be needed/required), and metterci (take).
Ci sono
I'm here
or
C'è qualcuno?
Is there anybody?
and
Ci vuole una laurea per fare quel lavoro
A degree is needed to do that job
and
Ci si mette un'ora per tornare a casa
It takes an hour to get home
And really, many many other uses, especially in combinations with verbs.