They know exactly what they are doing. If anyone wants proof, see Torulf Jernström's talk "Let’s go whaling: Tricks for monetising mobile game players with free-to-play"[1]. He discusses strategies for building the perfect Skinner Box, and how to design your game around operant conditioning and other psychological tricks that help people become addicted.
[1] https://www.youtube.com/watch?v=xNjI03CGkb4