Fixed bugs inside gamputil

Signed-off-by: robertomorati <robertomorati@gmail.com>