fixed for compile, forward declaration fix needed in state <-> entity