changed debug value statement and put value type to string

added resource_value def and moved sort to be used in type