encoded version for policy grid. Some problems occur when size of grid gets higher than 11! need to be fixed but for now is okay
flipping policy grid function
working again with encoded statespace
mergeeee conflicts