Change state actions 251

Fixes #251 
Better to use a new class rather than a dictionary.